1. Installing rootpy¶
1.1. Requirements¶
- Python 2.6 or 2.7 (Python 3 is currently not supported, but see this issue for progress)
- setuptools 0.7 or newer
- ROOT 5.28+ with PyROOT enabled
The following dependencies are optional:
- NumPy and root_numpy for speed
- matplotlib for plotting
- PyTables for HDF5 IO in rootpy.root2hdf5
- readline and termcolor for roosh
rootpy is developed and tested on Linux and Mac.
1.2. Getting the Latest Source¶
Clone the repository with git:
git clone git://github.com/rootpy/rootpy.git
or checkout with svn:
svn checkout https://github.com/rootpy/rootpy/trunk rootpy
1.3. Manual Installation¶
If you have obtained a copy of rootpy yourself use the setup.py
script to install.
To install in your home directory:
python setup.py install --user
To install system-wide (requires root privileges):
sudo python setup.py install
To install optional requirements (matplotlib, NumPy, etc.):
pip install -U -r requirements/[roosh|array|...].txt
1.4. Automatic Installation¶
To install a released version of rootpy use pip.
To install in your home directory:
pip install --user rootpy
To install system-wide (requires root privileges):
sudo pip install rootpy
Note
The above will install the latest version of rootpy available on PyPI and may be lacking many new unreleased features. You can also use pip to install the latest version of rootpy on github:
pip install --upgrade --user https://github.com/rootpy/rootpy/zipball/master
To install optional requirements (matplotlib, NumPy, etc.):
pip install --user rootpy[array,matplotlib,...]
This requires pip version 1.1 or later.
1.5. Post-Installation¶
If you installed rootpy into your home directory with the –user option
above, add ${HOME}/.local/bin
to your ${PATH}
if it is not there
already (put this in your .bashrc):
export PATH=${HOME}/.local/bin${PATH:+:$PATH}