Installation#
UNIQUE
is currently compatible with Python 3.8 through 3.12.1. To install the latest release, run the following in a compatible environment of choice:
pip install unique-uncertainty
conda install -c conda-forge unique-uncertainty
mamba install -c conda-forge unique-uncertainty
Tip
To create a dedicated virtual environment for UNIQUE
using conda
/mamba
with all the required and compatible dependencies, check out: For Developers.
For Developers#
See also
If you wish to work on the codebase itself, check first how to best contribute to UNIQUE
.
Warning
The following steps are recommended only for expert/power-users.
First, clone the repository and check into the project folder.
git clone https://github.com/Novartis/UNIQUE.git ./unique
cd unique
The project uses conda
and/or mamba
for dependencies management.
Install first the conda
dependencies and the Jupyter kernel needed to run the examples:
# Install conda environment and jupyter kernel locally
make env && make jupyter-kernel
conda activate .conda/unique
Next, enable the pre-commit hooks for automatic code formatting/linting:
# Setup precommit hooks
make pre-commit
Lastly, install UNIQUE
from source:
pip install -e .
# Use `pip install -e .[dev]` to also install optional dependencies
In this way, you will have access to the UNIQUE
codebase and be able to make local modifications to the source code, within the ./.conda/unique
local environment that contains all the required dependencies.
Additionally, if you use Jupyter Notebooks, the unique
kernel will be available in the “Select kernel” menu of the JupyterLab/JupyterNotebook UI.
Finally, when using git
for code versioning, the predefined pre-commit
hooks will be run against the commited files for automatic formatting and syntax checks.
You can find out more about custom Jupyter kernels here and pre-commit
hooks here.