Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

question about ScanMatcher::score #15

Open
asmashine opened this issue Feb 18, 2017 · 5 comments
Open

question about ScanMatcher::score #15

asmashine opened this issue Feb 18, 2017 · 5 comments

Comments

@asmashine
Copy link

in this function ,to caculate pfree,there are
double freeDelta=map.getDelta()*m_freeCellRatio;and
pfree.x+=(*r-map.getDelta()*freeDelta)*cos(lp.theta+*angle); pfree.y+=(*r-map.getDelta()*freeDelta)*sin(lp.theta+*angle);;
obviously r - delta^2sqrt(2) (freeDelta = sqrt(2))
i think r - delta
sqart(2) can show the range of pfree ,but the equation above i don't know its mean.

@lmy19880626
Copy link

me too! I need the explanation.

@KOTOKORURU
Copy link

I have the same question ,have you sloved it?

@1344618323
Copy link

me too! I think there's a bug!

@topin89
Copy link

topin89 commented Nov 3, 2019

I think this is a bug that was shadowed by another bug, #25
making everything about pfree, ipfree, pf and fcell irrelevant.

And yes,

pfree.x+=(*r-map.getDelta()*freeDelta)*cos(lp.theta+*angle);
pfree.y+=(*r-map.getDelta()*freeDelta)*sin(lp.theta+*angle);

should be replaced with

pfree.x+=(*r-*freeDelta)*cos(lp.theta+*angle);
pfree.y+=(*r-*freeDelta)*sin(lp.theta+*angle);

With these two bugs solved, gmapping stops looking for best score inside a wall.

@topin89
Copy link

topin89 commented Nov 3, 2019

Oh, there is a PR to fix that: #10

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants