Could Someone Give me Advice on Routing Issues with Custom Vehicle Profiles on GraphHopper?

Hello there,

I have been working on integrating GraphHopper into my application for a project that requires custom routing for various vehicle types. Specifically; I am dealing with a fleet of vehicles that have unique characteristics, such as different speed limits; vehicle dimensions; and restricted areas they need to avoid.

To address these requirements; I have been trying to set up custom vehicle profiles. Although; I have encountered a few challenges and was hoping for some guidance from those more experienced with GraphHopper.

I have managed to set custom speeds for different road types, but I am unsure if I’m implementing it correctly. For instance, I have a vehicle that needs to adhere to specific speed limits based on the cargo it carries. I have used the encoder configuration for this, but the routing results don’t seem to reflect the expected speed adjustments. Has anyone successfully implemented such custom profiles? If so, could you share how you structured the configuration? :thinking:

Another issue I am facing is setting up the routing to avoid certain areas altogether. Some of these areas are defined by geographic boundaries; while others are specific road types or zones. I have read about using custom flags and weighting, but I am struggling to make it work seamlessly with the rest of the routing engine.

Also, I have gone through this post; https://discuss.graphhopper.com/t/can-someone-make-a-video-tutorial-of-how-to-create-customize-a-routing-profile-or-walk-through-the-process-in-much-greater-written-detail-mlops/ which definitely helped me out a lot.

Is there a recommended approach for combining multiple custom profiles, especially when they might have conflicting attributes? :thinking:

Thankyou in advance for your help and assistance. :innocent:

I have used the encoder configuration for this
I have read about using custom flags

I am not sure what you mean here. Which GraphHopper version are you using? The methods for dealing with your use case have changed quite a bit over the last years, so you might find outdated information here and there.

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