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 FOV background image modeling #503

Merged
merged 26 commits into from Apr 12, 2016

Conversation

Projects
None yet
4 participants
@JouvinLea
Contributor

JouvinLea commented Apr 6, 2016

This pull request contains:

  • improvements to the off data background maker class
  • a new image analysis class to compute stacked counts and background images for multiple observations
Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
Show outdated Hide outdated examples/test_curve.py Outdated
@@ -499,6 +500,7 @@ def write(self, filename=None, header=None, **kwargs):
hdulist = fits.HDUList()
for name in self.get('_map_names', sorted(self)):
hdu = self[name].to_image_hdu()
hdu.name = name

This comment has been minimized.

@adonath

adonath Apr 7, 2016

Member

Actually this shouldn't be necessary, because the name is already passed to the ImageHDU object in to_image_hdu(). Can you explain why this is needed?

@adonath

adonath Apr 7, 2016

Member

Actually this shouldn't be necessary, because the name is already passed to the ImageHDU object in to_image_hdu(). Can you explain why this is needed?

This comment has been minimized.

@JouvinLea

JouvinLea Apr 8, 2016

Contributor

I had a mistake without it because it was empty...

@JouvinLea

JouvinLea Apr 8, 2016

Contributor

I had a mistake without it because it was empty...

This comment has been minimized.

@adonath

adonath Apr 11, 2016

Member

This is really not important, but if you have time to find out, I'd be interested in why this error happens...because it might be a bug in .to_image_hdu() or somewhere else.

@adonath

adonath Apr 11, 2016

Member

This is really not important, but if you have time to find out, I'd be interested in why this error happens...because it might be a bug in .to_image_hdu() or somewhere else.

Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated

@cdeil cdeil added the feature label Apr 7, 2016

@cdeil cdeil added this to the 0.4 milestone Apr 7, 2016

Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
Show outdated Hide outdated gammapy/image/maps.py Outdated
Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
@joleroi

This comment has been minimized.

Show comment
Hide comment
@joleroi

joleroi Apr 8, 2016

Contributor

@JouvinLea Can you please add a description for this PR (and all others in the future 😉 ). It would make it easier for me to get an impression what's happening.

Example:
#479 (comment)

Contributor

joleroi commented Apr 8, 2016

@JouvinLea Can you please add a description for this PR (and all others in the future 😉 ). It would make it easier for me to get an impression what's happening.

Example:
#479 (comment)

Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
Show outdated Hide outdated gammapy/image/maps.py Outdated
Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
Lea Jouvin
Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated

Lea Jouvin added some commits Apr 12, 2016

Lea Jouvin
exclusion maps + exposure
Please enter the commit message for your changes. Lines starting
Lea Jouvin
Lea Jouvin
ok
Lea Jouvin
@JouvinLea

This comment has been minimized.

Show comment
Hide comment
@JouvinLea

JouvinLea Apr 12, 2016

Contributor

@cdeil
I know that some test are failing but I'm not sure this is really linked to what I implemented!
Do you think we can merge and I can continue to implement the exposure map!

Contributor

JouvinLea commented Apr 12, 2016

@cdeil
I know that some test are failing but I'm not sure this is really linked to what I implemented!
Do you think we can merge and I can continue to implement the exposure map!

Show outdated Hide outdated examples/test_curve.py Outdated
Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
Show outdated Hide outdated gammapy/scripts/image_pipe.py Outdated
@cdeil

This comment has been minimized.

Show comment
Hide comment
@cdeil

cdeil Apr 12, 2016

Member

@JouvinLea - I've done another round of code review ... all easy to address I think.

Is there a test that exercises ImageAnalysis.make_all?
Can you add one and add one assert, e.g. on the significance value in the pixel containing the Crab nebula?
Or do you want to do this after the HESS collab meeting and merge ASAP?

Member

cdeil commented Apr 12, 2016

@JouvinLea - I've done another round of code review ... all easy to address I think.

Is there a test that exercises ImageAnalysis.make_all?
Can you add one and add one assert, e.g. on the significance value in the pixel containing the Crab nebula?
Or do you want to do this after the HESS collab meeting and merge ASAP?

@cdeil cdeil changed the title from Some changes to the OFFBkgMaker class to Add FOV background image modeling Apr 12, 2016

Lea Jouvin
@JouvinLea

This comment has been minimized.

Show comment
Hide comment
@JouvinLea

JouvinLea Apr 12, 2016

Contributor

There is no test... Yeah I would prefer to do it after the HESS collaboration! You have to remind me to do it...
I would prefer to merge ASAP and continue to work on the exposure!
@cdeil Normally I took all you comments into account, do you think we can merge?

Contributor

JouvinLea commented Apr 12, 2016

There is no test... Yeah I would prefer to do it after the HESS collaboration! You have to remind me to do it...
I would prefer to merge ASAP and continue to work on the exposure!
@cdeil Normally I took all you comments into account, do you think we can merge?

Lea Jouvin
@cdeil

This comment has been minimized.

Show comment
Hide comment
@cdeil

cdeil Apr 12, 2016

Member

OK, merging this now.

If there are build fails on travis-ci I can have a look tonight and fix them.

Member

cdeil commented Apr 12, 2016

OK, merging this now.

If there are build fails on travis-ci I can have a look tonight and fix them.

@cdeil

This comment has been minimized.

Show comment
Hide comment
@cdeil

cdeil Apr 12, 2016

Member

Thank you ... can't wait to use this for my analyses!

Member

cdeil commented Apr 12, 2016

Thank you ... can't wait to use this for my analyses!

@cdeil cdeil merged commit 3b46ba1 into gammapy:master Apr 12, 2016

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
@JouvinLea

This comment has been minimized.

Show comment
Hide comment
@JouvinLea

JouvinLea Apr 12, 2016

Contributor

hahaha thanks to be so enthusiastic for this class!!:-)

Contributor

JouvinLea commented Apr 12, 2016

hahaha thanks to be so enthusiastic for this class!!:-)

@cdeil cdeil referenced this pull request Apr 12, 2016

Closed

FOV background method #5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment