-
Notifications
You must be signed in to change notification settings - Fork 101
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
Fix forcing zones around equator and add force_northern in from_latlon #46
base: master
Are you sure you want to change the base?
Conversation
Codecov Report
@@ Coverage Diff @@
## master #46 +/- ##
==========================================
+ Coverage 95.09% 95.62% +0.53%
==========================================
Files 3 3
Lines 163 160 -3
==========================================
- Hits 155 153 -2
+ Misses 8 7 -1
Continue to review full report at Codecov.
|
Note that the tests have only failed on Python 2.6 and 3.3, as these versions of Python aren't available on TravisCI's default build machine anymore. |
0db0e1d
to
64749d8
Compare
I've rebased this branch to remove merge conflicts. |
64749d8
to
76d6ae1
Compare
Updated so tests cover entire diff (previously missing test for providing |
Logic in from_latlon has been changed to be similar to to_latlon, including adding a force_northern option to mirror northern option in to_latlon. This resolves the issue with northing coordinate incorrectly being set when pasing in -ve or +ve latitude when forcing northern or southern zone respectively. Closes Turbo87#35 - alternative fix for issue.
76d6ae1
to
9dafddb
Compare
Rebased, updating tests to |
@Turbo87 Just wondering if you had any thoughts on this PR. |
I do like the proposed changes in this branch, but there are some concerns which need to be addressed. The current proposal removes some sanity checks for sets of points that check whether points (kind of) belong to the same zone. I think we should be careful about removing those (original comment). If it is desired by the user of our lib to treat lots of points as if they were in the same zone, we'd better be explicit about allowing that by introducing another option (original comment). I may have a look at it later today. If I'm not quick enough, @heathhenley, would you mind having a go at it? |
@bartvanandel happy to help! Just to be clear that I'm on the same page, are you thinking that we should do something like
Or are you thinking that we should add a new option with slightly different behavior? |
I think we're pretty much on the same page indeed. New option according to PR, but keep the sanity checks by default, unless explicitly told to ignore them. This way I think the default behavior makes the most sense. @Turbo87 if you have any thoughts or objections, now is the time 😉 |
Logic in
from_latlon
has been changed to be similar toto_latlon
, including adding aforce_northern
option to mirrornorthern
option into_latlon
. This resolves the issue with northing coordinate incorrectly being set when passing in -ve or +ve latitude when forcing northern or southern zone respectively.Closes #35 - alternative fix for issue.