Locus Map - forum

Support => Troubles & Questions => Topic started by: jusc on September 25, 2016, 13:48:35

Title: BRouter (cycling) profile question
Post by: jusc on September 25, 2016, 13:48:35
mostly  ;D @Poutnikl,
With Openandromaps (perhaps with LoMpas too) and my theme I can see the tag (bicycle=NO).
(http://www.openstreetmap.org/#map=16/50.9606/14.1167)
But if I choose p. E. the MTB BRouter profile, it routes me over these (bicycle=NO) paths.
Is this correct?
Title: Re: BRouter (cycling) profile question
Post by: poutnikl on September 25, 2016, 15:39:28
Hi Jusc,

Yes, it is ( partially, as I have realized later) correct, as both the standard and my profiles do not consider a bicycle as a biker riding a bicycle.

They take a bicycle as a biker WITH bicycle. Leading a bicycle is a perfectly valid bicycle transportation mode, just slow. Such a way, where a riding a bicycle is forbidden, but pedestrians are allowed, the bicycle routing is still allowed.

Allowed, but with a penalty according to the speed ratio. A way segment with bicycle=NO is taken as if it was 5times longer.

Otherwise it could lead to serious not justified detours. Liker 600 m along the road network versus 15 m of a footway.

Special cases are addressed with flags allow_stairs usefule e.g. for handicaped bikers,  and in special profiles like recumbent/velomobile ones.

Edit: I have realized, that because of wrong evaluation order, profiles with positive MTB_factor  decrease the bicycle=NO penalty for way classes and surfaces preferred by MTB-like profiles.

Will be fixed in next profile release.
Title: Re: BRouter (cycling) profile question
Post by: jusc on September 25, 2016, 15:55:12
Thank you, I understand.
On the other side, if you plan a mountain bike tour in the region, without having a map, that shows you the paths, but not the "forbidden" tag, you may be a bit disapointed at start.
Is it possible to create a profile, that considers this tag (analog to "no maut" or "no ferries")?
Title: Re: BRouter (cycling) profile question
Post by: poutnikl on September 25, 2016, 16:29:25
Thank you, I understand.
On the other side, if you plan a mountain bike tour in the region, without having a map, that shows you the paths, but not the "forbidden" tag, you may be a bit disapointed at start.
Is it possible to create a profile, that considers this tag (analog to "no maut" or "no ferries")?

Sure, it is possible, as it is quite simple.
For now, you may tweak the profile code as below. Then bicycle=NO will be forbidden.

But, be aware of it, as you can be hunted 10 km for 300m of forbidden path.
It may as well make sense just to raise the penalty, rather then being forbidden absolutely.

Bear in mind the MTB usage is rather like "bending the trekking rod", and native MTB profiles may be better..
You may want to try the native MTB profile by Zossebart, that I share with his permission on my Github rep .
https://raw.githubusercontent.com/poutnikl/Brouter-profiles/master/mtb-normal.brf (https://raw.githubusercontent.com/poutnikl/Brouter-profiles/master/mtb-normal.brf)
Edit: Note that Zossebart marks it as very outdated, but has not published the update yet.

Code: [Select]
assign accesspenalty =
       if bikeaccess then 0
       else if footaccess then 4
       else 100000
to

Code: [Select]
assign accesspenalty =
       if bikeaccess then 0
       else if footaccess then 100000
       else 100000
Title: Re: BRouter (cycling) profile question
Post by: poutnikl on September 25, 2016, 19:33:32
See the new profile set based of template v2.5.5
https://github.com/poutnikl/Trekking-Poutnik (https://github.com/poutnikl/Trekking-Poutnik)

The above mentioned bug is fixed, and there is introduced new parameter
Code: [Select]
assign   StrictNOBicycleaccess  0 # 0 allows but penalizes foot only access / 1 forbides foot only access.
there is n ot yet an extra profile set to use the flag, will be introduced later.
It must be changed manually for now.
Title: Re: BRouter (cycling) profile question
Post by: jusc on September 26, 2016, 15:48:39
Thank you for your efforts.  ;D
Title: Re: BRouter (cycling) profile question
Post by: poutnikl on October 01, 2016, 11:54:54
Thank you for your efforts.  ;D
But be aware  that it can exclude all the otherwise nice way from consideration  if a little segment is forbidden or  incorrectly tagged, like some small way segments, barriers or small foot bridges,  E.g. searching the bike pass across Donau near Moldau leads to 5 km detour if 3m footway is forbidden. 

It is always good to review the total cost.

Absolute forbidding by costfactor 10000 affects the voice-hint generator and is by standard Trekking limited to "hard cases".
For "soft cases" it is using the highest regular value 9999. I.e. the above 3m of footway have 30 km  of equivalent length.

I am going to follow it.