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

Implement MapAxis.upsample() and MapAxis.downsample() methods #2130

Merged
merged 6 commits into from
May 6, 2019

Conversation

adonath
Copy link
Member

@adonath adonath commented May 4, 2019

This PR includes the following changes:

  • Add MapAxis.upsample() and MapAxis.downsample() methods
  • Add axis argument to WcsGeom.upsample() and WcsGeom.downsample()
  • Add axis argument to WcsNDMap.upsample() and WcsNDMap.downsample()
  • Add tests...

The use case is for example the evaluation of background models or diffuse model using oversampling in the energy axis, instead of integration. The geom is oversampled in the given axis, before the evaluation, then the data is put into a new map and the new map is downsampled again.

@adonath adonath self-assigned this May 4, 2019
@adonath adonath added this to the 0.12 milestone May 4, 2019
@adonath adonath added the feature label May 4, 2019
@adonath adonath force-pushed the axes_up_down_sampling branch 2 times, most recently from 9214509 to c0934ff Compare May 4, 2019 20:34
@adonath adonath merged commit 5c9a539 into gammapy:master May 6, 2019
@adonath adonath changed the title Add MapAxis.upsample() and MapAxis.downsample() methods Implement MapAxis.upsample() and MapAxis.downsample() methods May 27, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant