Skip to content

Commit

Permalink
Merge pull request #10 from eduardo-rodrigues/eduardo-ostap
Browse files Browse the repository at this point in the history
Added info on ostap
  • Loading branch information
eduardo-rodrigues committed Nov 22, 2018
2 parents 1767f67 + 51ad307 commit 298d613
Showing 1 changed file with 17 additions and 9 deletions.
26 changes: 17 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ Some more advanced talks of interested:
* David Beazley, "Discovering python" https://www.youtube.com/watch?v=RZ4Sn-Y7AP8.
* Thomas Ballinger, "Finding closure with closures" https://www.youtube.com/watch?v=E9wS6LdXM8Y


## Getting Python

| Name | Use |
Expand Down Expand Up @@ -81,31 +82,26 @@ General information through talks tthat maybe useful on PyData (various confere
* Enthought: https://www.youtube.com/user/EnthoughtMedia
* Continuum Analytics: https://www.youtube.com/channel/UCND4vKhJssAtK8p1Blfj14Q


## Particle Physics packages
| Name | Use |
| ------------ | --------------- |
| [numpythia](https://github.com/scikit-hep/numpythia) | Interface between FastJet and NumPy. |
| [pyjet](https://github.com/scikit-hep/pyjet) | Interface between PYTHIA and NumPy. |

## Jupyter extensions

Jupyter has a wide ecosystem of extensions that can be used to extend the functionality. Some useful extensions for HEP data analysis are summarised here.

| Name | Use |
| ------------ | --------------- |
| nbdime | Simplifies diffing and merging of jupyter notebooks that are stored in version control. |
| jupytext | Splits notebooks into a `.ipynb` and `.py` file for easier version control and to allow them to be run as scripts idependently of jupyter. |

## Tutorials

See tutorials here and other resources collected by [IML HEP-ML Resources](https://github.com/iml-wg/HEP-ML-Resources#tutorials)
See tutorials here and other resources collected by [IML HEP-ML Resources](https://github.com/iml-wg/HEP-ML-Resources#tutorials).


## ROOT and interoperability with ROOT

For many particle physics experiments, a lot of data is stored within ROOT files. This means at very least one must have the ability to read ROOT files. ROOT also serves as a tool suite designed to solve many computational problems encountered in HEP, which means that one may want to access some of this tool suite. The following packages below are worth knowing for these situations:

| Package name | Use | Pro | Con | Further information |
| ------------ | --- | --- | --- | ------------------- |
| [ostap](https://github.com/OstapHEP/ostap) | User-friendly & more intuitive interface to(Py)ROOT | Many decorations to ROOT classes | Requires C++ code compilation | |
| [uproot](https://github.com/scikit-hep/uproot) | Native Python ROOT I/O | Easy to install, fast, no dependence on C++ ROOT | Although can read all ROOT files, can only write ROOT files with specific objects. | |
| root_numpy, root_pandas | ROOT to/from Numpy and Pandas, like uproot | full ROOT functionality, like TFormula | slower than uproot, binary incompatibilities with different versions of ROOT | |
| [ROOT conda](https://nlesc.gitbooks.io/cern-root-conda-recipes/content/installing_root_via_anaconda.html) | Using ROOT within Anaconda | Easy to get ROOT installed with PyROOT support | Not all features of ROOT and getting dated (6.04 Py2.7/3.4 since XENON1T uses that) | [Recipes](https://github.com/NLeSC/root-conda-recipes) |
Expand All @@ -115,6 +111,16 @@ For many particle physics experiments, a lot of data is stored within ROOT files
| [pyhf](https://github.com/diana-hep/pyhf) | statistical analysis / fitting | pure python implementation of HistFactory specification with auto-diff enabled backends in tensorflow, pytorch, and MXNet | not yet interoperable with ROOT-based RooFit models | [pyhf](https://github.com/diana-hep/pyhf) |


## Jupyter extensions

Jupyter has a wide ecosystem of extensions that can be used to extend the functionality. Some useful extensions for HEP data analysis are summarised here.

| Name | Use |
| ------------ | --------------- |
| nbdime | Simplifies diffing and merging of jupyter notebooks that are stored in version control. |
| jupytext | Splits notebooks into a `.ipynb` and `.py` file for easier version control and to allow them to be run as scripts idependently of jupyter. |


## Speeding up code

Often, it is not needed anymore to write C++/C routines that get wrapped since there are other ways to speed up your Python code. Namely:
Expand All @@ -126,6 +132,7 @@ Often, it is not needed anymore to write C++/C routines that get wrapped since t
| [numpy](http://www.numpy.org) | Expressing your code as array options means you get native-C speeds. |
| NumExpr | single pass "mapper" operations (one input → one output). |


## Binding C/C++ to Python

*Before you read this, realize that this is for existing C++ code. If you want to write new C/C++ code for speed, see section above.*
Expand All @@ -145,6 +152,7 @@ At present, the best summary of how to bind code in HEP applications comes from
| swig | Wrapping C++ code | Widely used. | Have to write wrapper file and feels dated. | |
| Boost | Wrapping C++ code | Widely used. | Giant dependency since Boost does many other things.| |


## Experimental codes

Stealing code from other physicists is its own sign of flattery. Codes that are abandoned more than two years will get struck through.:
Expand Down

0 comments on commit 298d613

Please sign in to comment.