-
-
Notifications
You must be signed in to change notification settings - Fork 284
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
grass.jupyter: fix bbox reprojection for InteractiveMap #2501
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The computation look good.
The failing pytest needs an update. The original function was returning strings, but the new one returns float which is better, more expected behavior. If needed, use pytest.approx.
@@ -47,8 +45,12 @@ def reproject_region(region, from_proj, to_proj): | |||
:return dict region: reprojected region as a dictionary with long key names | |||
""" | |||
region = region.copy() | |||
# reproject all corners, otherwise reproj. region may be underestimated |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you want to mention here the complete v.in.region based solution from r.import?
Region in pseudo mercator tmp location could be smaller than it was supposed to because only 2 corners of the region were reprojected. Now it reprojects all 4 corners and gets maximum bbox from them.