Skip to main content

Next-generation Python interface to the HepMC high-energy physics event record API

Project description

pyhepmc-ng is a wrapper of the HepMC-v3 C++ library.

Another wrapper is pyhepmc. Why should you use this one?

pyhepmc-ng is easy to install

The command pip install pyhepmc-ng just works! You only need a compiler that supports C++11, everything else is handled by pip.

Under the hood, the bindings are build with the excellent pybind11 library. pybind11 is automatically installed as a requirement by pip. You don't need an external installation of the HepMC library, either. A copy of this light-weight library is included.

pyhepmc-ng is actively developed

pyhepmc-ng is part of the Scikit-HEP project, which aims to provide all tools needed by particle physicists to do data analysis in Python.

pyhepmc-ng is unit tested

Everything in pyhepmc-ng is unit tested.

pyhepmc-ng supports Pythonic code

pyhepmc-ng is a hand-crafted mapping of C++ code to Python. It supports Python idioms where appropriate.

  • C++ methods which act like properties are represented as properties, e.g. GenParticle::set_status and GenParticle::status are mapped to a single GenParticle.status field in Python
  • Tuples and lists are implicitly convertible to FourVectors
  • ReaderAscii and WriterAscii support the context manager protocol

License: pyhepmc-ng is covered by the BSD license, but the license only applies to the binding code. The HepMC3 code is covered by the GPL-v3 license.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyhepmc_ng-0.4.1.tar.gz (84.3 kB view details)

Uploaded Source

File details

Details for the file pyhepmc_ng-0.4.1.tar.gz.

File metadata

  • Download URL: pyhepmc_ng-0.4.1.tar.gz
  • Upload date:
  • Size: 84.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.5.0 requests/2.21.0 setuptools/40.6.3 requests-toolbelt/0.8.0 tqdm/4.29.0 CPython/3.7.3

File hashes

Hashes for pyhepmc_ng-0.4.1.tar.gz
Algorithm Hash digest
SHA256 e8bab361f6d24a613f3b78907303f49372d8a35424072a16c1b42fdb8eeeb3e0
MD5 39d967ab9550f748455fc7de01f4740c
BLAKE2b-256 e92ed9af364c6896266759f8a30d127068418a19951dceaa680badc202fe4014

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page