Enable pseudo tags for car profiles
It is hard to add some of the new pseudo tags to a car profile. The only entry point for variable values is the maxspeed parameter.
However, the logic of, for example, consider river is: all paths that are not near a river are penalized. And when you add a penalty to maxspeed this will affect your route duration.
The code is not ready yet, but the feature for the moment is available for testing.
Please see this sample for a river test.
The link is set to car-fast. This is not the original but a replacement with a contact to a new KinematicModel class. This contains now an entry point for costfactor in a similar use as bike profiles.
When you place the penalty on costfactor, it should not bring a duration problem.
Please see the text inside the profile.
Another example for use with avoid_motorways, avoid_trunk and avoid_primary.
Please play around with this examples and test if this fits your needs. The next summer will come with a cabrio ride.
The current car profile doesn't contain all pseudo tags. Which do we need for car driving? Note: On the testserver the tests for issue #848 and the PR #853 are running as well.
@afischerdev
The current car profile doesn't contain all pseudo tags. Which do we need for car driving?
This profile can be used and modified for all vehicles, cars and motorcycles, so we at least need:
- consider_town
- consider_forest
- consider_river
@devemux86 Thanks for the ideas, They are online on test server now - car_fast profile.
@afischerdev Thanks, very interesting results.
The pseudo tags may need stronger costs?
For example this route has very little difference with consider_town and still passes through the city.
@devemux86
The pseudo tags may need stronger costs?
Maybe, I did not care about the values, just copy it from trekking profile. But If you have a look at the same route done with the fastbike less traffic profile, the values are a little bit different. We need to experiment a little with these values to find the best compromise.
just copy it from trekking profile
@afischerdev From the trekking profile in main server?
Because the trekking profile in test server has different (even negative) values.
@devemux86 Could you make some tests with the update #860 and the new kinematic and weight class?
@afischerdev It seems to work, but it can also return unexpected results. Probably because of the cost values?
For example, this route. Enable consider_town, we would expect to avoid Munich completely, but it goes straight through it.
@afischerdev The new car-fast profile has vmax 90 km/h instead of 160 km/h. This also changes the results.
@devemux86 Thanks for the nice example. Go around Munich you should give more penalty to the others. E.g. add 1.0 for every factor and you are around the town. The profile is a sample how to define this new car class. Normaly the profile is a copy from car-vario to car-fast, 160 / car-eco, 90. The new one should go the same way.
The test server has an update with the new profile class KinematicWeightModel
So you can use now
---model:btools.router.KinematicWeightModel
in your profile.
The sample profile for this on test server is the car-fast.
It also has new values for
no_river_penalty
no_forest_penalty
town_penalty
The old text was a copy of the trekking profile.