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 interface to HESS FitSpectrum JSON output #296

Merged
merged 1 commit into from Jul 15, 2015

Conversation

Projects
None yet
2 participants
@cdeil
Member

cdeil commented Jul 2, 2015

In HAP one can dump spectral results to JSON via

FitSpectrum --InputFile hap_output.root --OutputJSONFile spec.json --BatchMode --FitModels PowerLaw,ExpCutoffPL3

This adds some code to read HESS FitSpectrum JSON output files.
It's useful for batch processing and checks and for the HGPS catalog.

@kingj90 – Let me know what you think of if this is overlapping with things you're working on.

@cdeil cdeil added the feature label Jul 2, 2015

@cdeil cdeil self-assigned this Jul 2, 2015

@cdeil cdeil added this to the 0.3 milestone Jul 2, 2015

@joleroi

This comment has been minimized.

Contributor

joleroi commented Jul 9, 2015

Well, I guess you have done everything that I did so far and much more. I just don't see how to integrate this smoothely into gammapy.spectrum but I guess nobody knows that ...

@cdeil

This comment has been minimized.

Member

cdeil commented Jul 11, 2015

I just don't see how to integrate this smoothely into gammapy.spectrum but I guess nobody knows that ...

I don't know yet.

It's difficult and we first have to decide if Gammapy uses Sherpa as a library or if Gammapy is a plugin to Sherpa, extending it with things we need. Maybe the best solution is a mix, i.e. sometimes wrap Sherpa, sometimes extend it.

For now I'd say it's OK for everyone to prototype and hack things together to make it work for them in gammapy.spectrum.
And then in the coming few months we'll find a good solution and clean up (but already have working code and maybe even unit tests for the major things we need to do / compute, just the API / implementation will change heavily).

@joleroi

This comment has been minimized.

Contributor

joleroi commented Jul 15, 2015

Can you merge this so I can add the stuff I did?

@cdeil cdeil force-pushed the cdeil:fitspectrum_interface branch from 9536ff5 to 2f16c94 Jul 15, 2015

@cdeil cdeil force-pushed the cdeil:fitspectrum_interface branch from 2f16c94 to f946939 Jul 15, 2015

@cdeil

This comment has been minimized.

Member

cdeil commented Jul 15, 2015

Added a changelog entry and moved the TODO list from the GH issue to the docstring in that file.
Merging now (there's no tests, so travis-ci should pass OK)

cdeil added a commit that referenced this pull request Jul 15, 2015

Merge pull request #296 from cdeil/fitspectrum_interface
Add interface to HESS FitSpectrum JSON output

@cdeil cdeil merged commit fddf461 into gammapy:master Jul 15, 2015

1 check was pending

continuous-integration/travis-ci/pr The Travis CI build is in progress
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment