gamma-cat
gamma-cat copied to clipboard
Script to get some specific data
Make an IPython notebook that shows how to get the following data for every TeV source
- Spectral points
- How to dump spectral point data to text files
- Spectral global model (power-law or exp cutoff PL)
- Integral flux above 20 TeV computed from the spectral model
In the best case, the spectral global model is a plot like this: x-axis: energy [TeV], logarithmic scale y-axis: dN/dE * E^2 in [erg cm-2 s-1], logarithmic scale
I've started to write some docs on how gammapy.catalog
works:
http://docs.gammapy.org/en/latest/catalog/index.html
I will update http://nbviewer.jupyter.org/github/gammapy/gammapy-extra/blob/master/notebooks/source_catalogs.ipynb a little bit now, but it will remain incomplete.
@pdeiml - That could be useful for you to get started with accessing gamma-cat
spectral points and models and plotting them.
Instead of continuing with docs (which is time-consuming), I'll write the script next that prints which spectra we're missing.
I just pushed the small update to the notebook ... there's an example how to access Gamma-cat here now: http://nbviewer.jupyter.org/github/gammapy/gammapy-extra/blob/master/notebooks/source_catalogs.ipynb#Access-catalogs-and-sources
@adonath - For gamma-cat, currently _make_source_dict
returns a Row
object, and that gets stored in the data
attribute of the GammaCatSourceObject
. That's a bug, it should be turned into an OrderedDict like for the other catalogs / objects, no?
I'll try to change / fix this now, but wanted to ping you in case you implemented that and there was a reason for this.
I've started to add scripts to dump the info and plot a spectrum for each source here: https://github.com/cdeil/gamma-cat-status