GithubHelp home page GithubHelp logo

utokusa / hermes Goto Github PK

View Code? Open in Web Editor NEW

This project forked from cosmicrays/hermes

0.0 1.0 0.0 22.42 MB

HERMES is a publicly available computational framework for the line of sight integration over galactic radiative processes which creates sky maps in the HEALPix-compatibile format.

License: GNU General Public License v3.0

CMake 3.47% C++ 82.62% Objective-C 1.40% Makefile 0.06% C 2.94% Shell 0.33% Python 8.82% Starlark 0.36%

hermes's Introduction

HERMES - High-Energy Radiative MESsengers

Build Status Coverage Status Codacy Badge GitHub arXiv ascl

About

gamma sky map from pi0

HERMES is a publicly available computational framework for the line of sight integration which creates sky maps in the HEALPix-compatibile format of various galactic radiative processes including Faraday rotation, synchrotron and free-free radio emission, gamma-ray emission from pion-decay, bremsstrahlung and inverse-Compton. The name is an acronym for "High-Energy Radiative MESsengers".

The code is written in C++ relying on features of the language's recent revisions (C++11, C++14). Once compiled, HERMES can optionally be used from Python thanks to pybind11 (Python 2.X is not supported). Some components of the code (such as galactic magnetic field models, vector and grid classes) were adopted from CRPropa 3, a code for cosmic ray propagation.

HERMES provides the following integrators:

  • Dispersion measure
  • Rotation measure
  • Free-Free emission
  • Synchrotron emission (with absorption)
  • Pion decay gamma-ray emission
  • Inverse Compton scattering
  • Bremsstrahlung
  • Gamma-ray emissions from Dark Matter annihilation

The complete feature list is documented on github.io.

Install

Quick procedure for those who know their way around:

mkdir build
cd build
cmake ..
make -j

For detailed installation guides and requirements see INSTALL.

Usage

from pyhermes import *
from pyhermes.units import TeV, deg, kpc, pc

nside = 512
Egamma = 0.1*TeV
obs_pos = Vector3QLength(8.0*kpc, 0*pc, 0*pc)

skymap = GammaSkymap(nside, Egamma)
mask = RectangularWindow([5*deg, 40*deg], [-5*deg, 90*deg])
skymap.setMask(mask)

neutral_gas = neutralgas.RingModel(neutralgas.GasType.HI)
cosmicray_protons = cosmicrays.Dragon2D(Proton)
pp_crosssection = interactions.Kamae06Gamma()

integrator = PiZeroIntegrator(cosmicray_protons, neutral_gas, pp_crosssection)
integrator.setObsPosition(obs_pos)
integrator.setupCacheTable(100, 100, 20)

skymap.setIntegrator(integrator)
skymap.compute()

output = outputs.HEALPixFormat("!pizero-dragon2d.fits.gz")
skymap.save(output)

More examples can be found in the examples repository. Full documentation of the code is available here.

How to cite HERMES

If you use HERMES for your research, please cite

Dundovic et al., Astronomy and Astrophysics (2021); arXiv:2105.13165

Credits

Name Institution
Andrej Dundovic Gran Sasso Science Institute, L'Aquila, Italy
Carmelo Evoli Gran Sasso Science Institute, L'Aquila, Italy
Daniele Gaggero Instituto de Física Teórica UAM/CSIC, Madrid, Spain

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.