Get Started¶
It is highly recommended to install in a virtual environment to keep the system in order.
Installing with uv pip (recommended)¶
The following command installs the latest version of the library:
uv pip install iden
To make the package as slim as possible, only the packages required to use iden are installed.
It is possible to install all the optional dependencies by running the following command:
uv pip install 'iden[all]'
This command also installs NumPy and PyTorch. It is also possible to install the optional packages manually or to select specific packages to install.
Installing specific optional dependencies¶
You can install individual optional dependencies as needed:
# Install with NumPy support
uv pip install 'iden[numpy]'
# Install with PyTorch support
uv pip install 'iden[torch]'
# Install with YAML support
uv pip install 'iden[pyyaml]'
# Install with safetensors support
uv pip install 'iden[safetensors]'
# Install with cloudpickle support
uv pip install 'iden[cloudpickle]'
# Install with joblib support
uv pip install 'iden[joblib]'
Installing from source¶
To install iden from source, you'll need uv for dependency management.
If uv is not already installed, please refer to the uv installation guide.
Then, clone the git repository:
git clone git@github.com:durandtibo/iden.git
cd iden
It is recommended to create a Python 3.10+ virtual environment. This step is optional and
can be skipped. To create a virtual environment, you can use uv to create a virtual environment:
make setup-venv
This will create a virtual environment using uv and install invoke for task management.
Verifying the installation¶
After installation, the required packages can be installed or updated with the following command:
inv install
Finally, the installation can be verified with the following command:
inv unit-test --cov
Development workflow¶
For contributors, the following commands are commonly used:
Running tests¶
# Run unit tests
inv unit-test
# Run unit tests with coverage
inv unit-test --cov
# Run integration tests
inv integration-test
# Run all tests
inv all-test
Code quality checks¶
# Check code formatting
inv check-format
# Check linting
inv check-lint
# Check type hints
inv check-types
# Format docstrings
inv docformat
Building and testing documentation¶
# Install documentation dependencies (if not already installed)
inv install --docs-deps
# Build and serve documentation locally
cd docs
mkdocs serve
Then visit http://localhost:8000 in your browser.
Managing dependencies¶
# Update all dependencies to latest versions
inv update
# Show installed packages
inv show-installed-packages
For more detailed contribution guidelines, please refer to CONTRIBUTING.md.