Installing SLOPpy#
Setting up an environment#
Before proceeding with the installation, I suggest to create an environment dedicated to SLOPpy using python 3.10
With conda/anaconda:
conda create --name sloppy python=3.10
To list the available environments do:
conda env list
The active environment will be marked with a *
To activate the sloppy environment:
WINDOWS: activate sloppy
LINUX, macOS: conda activate sloppy
Install using pip#
You can then install SLOPpy by using pip inside the code repository:
pip install SLOPpy-package
Note that the name is sloppy-package and not sloppy, as the former was already taken by another package in PyPI. The name for package importation will still be SLOPpy:
python -c "import SLOPpy"
Install from the repository#
Download the latest version from the GitHub repository:
git clone https://github.com/LucaMalavolta/SLOPpy.git
You can then install SLOPpy by using pip inside the code repository:
cd SLOPpy
pip install .
Alternatively, you can install SLOPpy using the setup.py file:
cd SLOPpy
python setup.py install
Requirements#
Give people credit for their work
If you are using any of those packages listed above, please be sure to cite the proper references, as stated in the relative web page.
These packages are installed automatically when using pip.
numpy,scipy,matplotlib: pretty standardnumba: open source JIT compiler, actually required as undeclared dependency by some packages (numba home page)argparse: Parser for command-line options, arguments and sub-commands, required to pass terminal keywords (argpares home page)oyaml: a full-featured YAML framework for the Python programming language. YAML is the language used for the configuration file (oyaml home page, yaml home page)pygtc: Make a publication-ready giant-triangle-confusogram (GTC) (pygtc home page)pyDE: global optimization package ([PyDE home page])emcee: ensemble sampling toolkit for affine-invariant MCMC (emcee home page).
emcee is already included in the requirements, pyDE needs to be installed separately as the GitHub version supports multiprocessing:
pip install git+https://github.com/hpparvi/PyDE.git
THe alternative ensemble slice sampler zeus is supported as well ([zeus home page]).
Tip
pyDE and all the additional requirements can be installed by locating the extra_requirements.txt file in the SLOPpy repository or by downloading it directly from here and then running from a terminal:
pip install -r extra_requirements.txt