How to get iota2?

Licence

iota2 is a free software under the GNU Affero General Public License v3.0. See here for details.

How to install iota2?

iota2 is only frequently tested on some Linux distributions (Ubuntu and CentOS), although others are known to work (Debian). It is distributed through the Conda package management system which installs and manages all its dependencies. You can choose to install it using pixi or conda.

Using pixi

pixi is a modern and faster alternative to conda. You can learn more here.

Step 1: Download and install pixi

First, if not already done, you need to install pixi. For this, you can follow the official installation instructions.

Warning

Installing iota2 with pixi requires at least pixi > 0.45.0. If you have an older version, you can update it with pixi self-update.

Step 2: Installation

Pixi requires to have access to the source code. This means you have to clone the iota2 git repository, using git clone https://framagit.org/iota2-project/iota2.git (see the git documentation if needed). Then cd in the iota2 directory and run pixi install. This shouldn’t take too long. The environment should take around 5GB of disk space.

git clone https://framagit.org/iota2-project/iota2.git
cd iota2
pixi install

Note

If you have troubles installing iota2 using pixi, you can remove the environment and clean your cache to make a fresh reinstall. Use the following code to clean as much as possible:

pixi clean
pixi clean cache -y
rm /path/to/iota2/pixi.lock

If you have errors about conflicts, for example:

Error:   × failed to solve the conda requirements of 'default' 'linux-64'
  ╰─▶ Cannot solve the request because of: rasterio * cannot be installed because there are no viable options:

You can open an issue here with the the commands you used and the complete error output.

Step 3: Quick test

To test if iota2 was correctly installed, type pixi run Iota2.py -h in your terminal. When using pixi, make sure to always use either pixi run *command_name* or pixi shell to activate the environment. For more details on how to use pixi, check out the official documentation. If you want to add packages to this environment, use pixi add package_name.

Warning

If you are used to using conda, pixi environments are only defined for a project (instead of being usable globally, as are conda environments).

Using conda

In this section, steps to install iota2 from scratch will be detailed.

Step 1: download and install Miniconda

If Miniconda or Anaconda is already installed on your system, you can skip this step. Otherwise, you can download and install Miniconda thanks to the bash installer even if your are not the system administrator.

Note

If the installation is inside a virtual machine, do not use a shared directory with the host system as iota2 output directory.

Step 2: add iota2 channel

Add the iota2 channel to inform Conda where iota2 packages are. This information has to be added in the .condarc file. In order to locate the file, please enter the following command:

conda info

Then a list of information is printed, especially:

   active environment : None
           shell level : 0
      user config file : /absolute/path/to/.condarc
populated config files : /absolute/path/to/.condarc
         conda version : 4.7.10
   conda-build version : 3.18.2
   ...

Note

Maintain conda up to date using the conda update conda command.

Once the .condarc file is located (create it at the place user config file if it does not exist), you must add the following in it.

channel_priority: true
channels:
    - iota2
    - conda-forge
    - defaults

Warning

Do not go to Step 3 without making sure your .condarc file is well set.

Step 3: get the iota2 package and install it

Warning

To avoid some conflict or wrong compatibility, always install iota2 in a fresh environment. Also always install iota2 first before another custom package.

Note

Downloading all iota2 dependencies, from a fresh miniconda installation, requires at least 10go of free disk space.

Warning

Installing iota2 may be quite long according to the user computer configuration and network (proxy, internet speed). Sometimes the solving environment step can take a very long time before it ends.

Note

We found mamba to be much faster than conda and thus detail the procedure using this drop in replacement, but conda is still a viable way.

# create an empty conda environment: iota2-env
conda create --name iota2-env
# enable it
conda activate iota2-env
# install mamba
conda install mamba
# install iota2
mamba install iota2 -c iota2
# disable environment and reload it
conda deactivate
conda activate iota2-env
# test if the installation ends well
Iota2.py -h

How to test the installation?

You can test the installation by following the classification tutorial.

Note

More information about iota2 launching parameters are available here.