Skip to content

Instantly share code, notes, and snippets.

@vuillaut
Created July 13, 2022 14:08
Show Gist options
  • Save vuillaut/065996c4826e26c14c105881885dc7a0 to your computer and use it in GitHub Desktop.
Save vuillaut/065996c4826e26c14c105881885dc7a0 to your computer and use it in GitHub Desktop.
MAGIC sensitivity in Crab unit
from ctaplot.ana.ana import get_magic_sensitivity
from pyirf.spectral import CRAB_MAGIC_JHEAP2015
def magic_sens_in_crab_unit():
magic_sens = get_magic_sensitivity()
energy = magic_sens['e_center']
crab = CRAB_MAGIC_JHEAP2015(energy)
return energy, (magic_sens['sensitivity_lima_5off']/crab).decompose()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment