Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GTFS feed seems too big for Valhalla to handle #175

Open
colletdIFPEN opened this issue Nov 25, 2024 · 1 comment
Open

GTFS feed seems too big for Valhalla to handle #175

colletdIFPEN opened this issue Nov 25, 2024 · 1 comment

Comments

@colletdIFPEN
Copy link

I am trying to run a Valhalla docker with transit on a region slighlty bigger than the Paris Ile de France region. The OSM data I am using is obtained from the Geofabrik France latest data, from which has been extracted the polygon below:

"geometry": {
        "coordinates": [
          [
            [
              0.8552230727017616,
              49.67258642546267
            ],
            [
              0.5986669011061281,
              49.01187512344677
            ],
            [
              0.8133719870081961,
              48.413652943344005
            ],
            [
              2.035685985165088,
              47.650527771508024
            ],
            [
              3.1233526637494435,
              47.66897061648976
            ],
            [
              4.364672745548432,
              48.176767618800966
            ],
            [
              4.6136104444704245,
              48.71262296286602
            ],
            [
              4.412906861412239,
              49.39880413406419
            ],
            [
              3.8370311348944313,
              49.743627315924556
            ],
            [
              2.7683094983392778,
              49.93722014426589
            ],
            [
              2.0934022385610547,
              49.97213820613388
            ],
            [
              1.4875875812286665,
              49.941960817519714
            ],
            [
              0.8552230727017616,
              49.67258642546267
            ]
          ]
        ]
}

The GTFS feed I am trying to use it the Ile De France Mobilité (IDFM) gtfs feed. I am running the docker with the command below:

docker run -dt --name valhalla_pold \
                -p 8002:8002 \
                -v $PWD/custom_files:/custom_files \
                -v $PWD/gtfs_feeds:/gtfs_feeds \
                -e build_elevation=True \
                -e build_time_zones=True \
                -e build_transit=True
                ghcr.io/gis-ops/docker-valhalla/valhalla:latest

And my docker ends up with the following log:

2024-11-25 10:23:53 ==========================
2024-11-25 10:23:53 = Building transit tiles =
2024-11-25 10:23:53 ==========================
2024-11-25 10:23:53 
2024-11-25 10:23:53 2024/11/25 09:23:53.369128 [INFO] Running valhalla_ingest_transit with 20 thread(s).
2024-11-25 10:23:53 2024/11/25 09:23:53.369327 [INFO] Tiling GTFS Feeds
2024-11-25 10:23:53 2024/11/25 09:23:53.372576 [INFO] Loading IDFM-gtfs
2024-11-25 10:24:15 2024/11/25 09:24:15.221467 [INFO] Done loading, now parsing IDFM-gtfs
2024-11-25 10:33:56 2024/11/25 09:33:56.930463 [INFO] Done parsing 33 transit tiles for GTFS feed IDFM-gtfs
2024-11-25 10:33:57 2024/11/25 09:33:57.171469 [INFO] Writing 33 transit pbf tiles with 20 threads...
2024-11-25 10:34:26 /valhalla/scripts/configure_valhalla.sh: line 200:    37 Killed                  valhalla_ingest_transit -c ${CONFIG_FILE}

It should be noted that I tried to make other GTFS feeds with for example only the urban railways, metros or buses. Valhalla runs with the small GTFS alone, but it ends up with the same failure when we give it the two small GTFS together (bus-RATP and pold-metro-RER-transilien-tram-gtfs):

2024-11-25 10:50:01 
2024-11-25 10:50:01 INFO: Running container with user valhalla UID 59999 and GID 59999.
2024-11-25 10:50:01 
2024-11-25 10:50:01 WARNING: Hash not found for: /custom_files/pold.osm.pbf!
2024-11-25 10:50:01 WARNING: Requested transit data build, starting a new tile build
2024-11-25 10:50:01 INFO: Found existing valhalla.json. Updating possibly missing entries.
2024-11-25 10:50:02 
2024-11-25 10:50:02 ==========================
2024-11-25 10:50:02 = Building transit tiles =
2024-11-25 10:50:02 ==========================
2024-11-25 10:50:02 
2024-11-25 10:50:02 2024/11/25 09:50:02.648651 [INFO] Running valhalla_ingest_transit with 20 thread(s).
2024-11-25 10:50:02 2024/11/25 09:50:02.648834 [INFO] Tiling GTFS Feeds
2024-11-25 10:50:02 2024/11/25 09:50:02.651756 [INFO] Loading bus-RATP
2024-11-25 10:50:25 2024/11/25 09:50:25.123509 [INFO] Done loading, now parsing bus-RATP
2024-11-25 11:00:56 2024/11/25 10:00:56.507429 [INFO] Done parsing 33 transit tiles for GTFS feed bus-RATP
2024-11-25 11:00:56 2024/11/25 10:00:56.667235 [INFO] Loading pold-metro-RER-transilien-tram-gtfs
2024-11-25 11:01:03 2024/11/25 10:01:03.475261 [INFO] Done loading, now parsing pold-metro-RER-transilien-tram-gtfs
2024-11-25 11:01:30 2024/11/25 10:01:30.209652 [INFO] Done parsing 45 transit tiles for GTFS feed pold-metro-RER-transilien-tram-gtfs
2024-11-25 11:01:30 2024/11/25 10:01:30.441727 [INFO] Writing 45 transit pbf tiles with 20 threads...
2024-11-25 11:02:09 /valhalla/scripts/configure_valhalla.sh: line 200:   281 Killed                  valhalla_ingest_transit -c ${CONFIG_FILE}

Am I missing something? Is there a parameter to change in order to allow more memory for the GTFS feed?

@chrstnbwnkl
Copy link
Contributor

Yeah, GTFS integration is currently very RAM intense. You could try adjusting memory limits for the docker daemon, I'm not sure if those may be too constrained. Generally though, there's not much you can do apart from a) having enough memory and b) making sure the container has little constraints accessing that memory.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants