gtfspy icon indicating copy to clipboard operation
gtfspy copied to clipboard

How to run visualizer for different cities available in the dataset?

Open padshahrohan opened this issue 1 year ago • 2 comments

The script needs a gtfs zip file and osm.pbf file. The dataset has the gtfs file needed but how to get osm.pbf file?

    imported_database_path = "test_db_kuopio.sqlite"
    if not os.path.exists(imported_database_path):  # reimport only if the imported database does not already exist
        print("Importing gtfs zip file")
        import_gtfs.import_gtfs(["data/gtfs_kuopio_finland.zip"],  # input: list of GTFS zip files (or directories)
                                imported_database_path,  # output: where to create the new sqlite3 database
                                print_progress=verbose,  # whether to print progress when importing data
                                location_name="Kuopio")

        # Not this is an optional step, which is not necessary for many things.
        print("Computing walking paths using OSM")
        G = gtfs.GTFS(imported_database_path)
        G.meta['download_date'] = "2017-03-15"

        osm_path = "data/kuopio_extract_mapzen_2017_03_15.osm.pbf"

how to get the osm.pbf file, to generate the sqlite file for any given city to put it in visualizer?

padshahrohan avatar Sep 30 '23 09:09 padshahrohan

Hi,

Try e.g. geofabrik for downloading osm data exports: https://www.geofabrik.de/data/download.html

rmkujala avatar Sep 30 '23 11:09 rmkujala

https://download.geofabrik.de/ This link contains the file continent wise files, this https://zenodo.org/record/1186215 contains the data city wise, now lets say i want to generate the sqlite file for brisbane city, what obm.pbf file i need to put in the script ?

padshahrohan avatar Sep 30 '23 11:09 padshahrohan