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

Add quantity support to map coordinates #1685

Merged
merged 7 commits into from Aug 9, 2018
Merged

Conversation

@adonath
Copy link
Member

@adonath adonath commented Aug 9, 2018

This PR adds quantity support to the MapAxis.coord_to_idx(), MapAxis.idx_to_coord() as well as the MapCoord object. This will fix issue #1646 in a general way. This PR also contains a few unrelated changes, as I cleaned up and simplified some code "on the fly". I decided to remove the copy option of MapCoord, as we do not have this in any other class init and the MapCoord object as a .copy() anyway.

@adonath adonath added this to the 0.8 milestone Aug 9, 2018
@adonath adonath self-assigned this Aug 9, 2018
@adonath adonath added this to To do in gammapy.maps via automation Aug 9, 2018
@adonath adonath force-pushed the adonath:fix_issue_#1646 branch from ae4b2e0 to a02e0dc Aug 9, 2018
@adonath adonath merged commit a58e939 into gammapy:master Aug 9, 2018
0 of 2 checks passed
0 of 2 checks passed
continuous-integration/appveyor/pr Waiting for AppVeyor build to complete
Details
continuous-integration/travis-ci/pr The Travis CI build is in progress
Details
gammapy.maps automation moved this from To do to Done Aug 9, 2018
@cdeil

This comment has been minimized.

Copy link
Member

@cdeil cdeil commented on gammapy/maps/tests/test_geom.py in a02e0dc Aug 9, 2018

I'll change back to OrderedDict here in this one case: if we assert on coord order, it has to be passed in by OrderedDict for now.

See https://ci.appveyor.com/project/cdeil/gammapy/build/1.0.4188/job/x78c82dy8mhgvtc5

This comment has been minimized.

Copy link
Member

@cdeil cdeil replied Aug 9, 2018

Should be fixed by 19bb755

@cdeil cdeil changed the title Add quantity support to MapCoord and MapCoord based methods Add quantity support to map coordinates Aug 15, 2018
@adonath adonath deleted the adonath:fix_issue_#1646 branch Nov 20, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
gammapy.maps
  
Done
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants