gamma-cat icon indicating copy to clipboard operation
gamma-cat copied to clipboard

Gammapy compatibility completely gone

Open mireianievas opened this issue 4 years ago • 0 comments

Hi,

There are a few classes that were removed in recent gammapy versions (>0.9) that completely break compatibility in gammacat. In particular, GammaCatResource, GammaCatResourceIndex, GammaCatDataCollection are gone from gammapy.catalog.gammacat.py

I managed to run it with gammapy 0.9 and compile everything, with the following quick and dirty fixes:

gammapy.spectrum.models.py L860: cutoff = np.exp(-(energy * lambda_).value) [add the .value at the end, otherwise it is not a proper floating number] gammapy.spectrum.utils.py L261: n = int((logmax - logmin) * ndecade) [add the int(), otherwise it is a float and it does not work in subsequent lines]

mireianievas avatar Dec 04 '20 14:12 mireianievas