Vehicles and custom profiles

Hi all!

I have a question about custom configurations (I’m using GH8). I’m loading the following configuration but While the motorbike configuration is working fine , I’m seeing something strange with the bike configuration.

      - name: motorbike
        vehicle: roads
        weighting: custom
        custom_model_files: [ default_motorbike.json, motorbike.json ]
      - name: bicycle
        vehicle: bike
        weighting: custom
        custom_model_files: [ bike.json ]

Is the vehicle roads required to load a custom model files, are there any other unintended consequences of doing that?

No this is not required. The vehicle just determines the base speed the operators in the custom model are applied to. So if you use vehicle: bike the bike_average_speed will be used for routing, but it will be modified by the rules in the custom model. If you use vehicle: roads the difference is just that all speeds are set to 255km/h (and then the rules of the custom model are applied of course). Besides the speed the vehicle also determines the accces of the edges. So for example vehicle: bike means the bike_access will be used. For vehicle: roads all roads will be open.

Btw the vehicle option will be removed soon (for GH9 or later) such that all profiles will essentially behave like they used vehicle: roads. I.e. all speeds are unlimited and all roads are open. Then you will need to explicitly limit the speed to bike_average_speed and the access to bike_access to get the same results you got using vehicle: bike before.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.