Installation¶
xsar relies on gdal and other shared libs, that are not provided by pip. So insallation in a conda environement is recommended.
conda setup¶
First, create and activate a conda environment:
conda create -n xsar
conda activate xsar
You can either install recommended packages or minimal packages.
recommended packages¶
Note
by using recommended install, you will be able to download examples and run them ‘as is’.
# FIXME 'docutils>=0.16' with nbsphinx give "WARNING: Line 710 exceeds the line-length-limit." when converting ipynb to html
conda install -c conda-forge rasterio gdal dask[array] dask[distributed] jupyterlab geoviews cartopy holoviews datashader nbsphinx pandoc jq 'docutils<0.16' pip fiona git lxml
minimal install¶
conda install -c conda-forge rasterio gdal cartopy dask[array]
Install xsar¶
Once conda environment is created and activated, xsar can be installed by pip for a normal user, or with git clone for a developper.
As a normal user¶
pip install git+https://github.com/oarcher/xsar.git
for development installation¶
git clone https://github.com/oarcher/xsar
cd xsar
# this is needed to register git filters
git config --local include.path ../.gitconfig
pip install -e .
pip install -r requirements.txt
Note
While you are here, why not install also xsarsea ?
pip install git+https://gitlab.ifremer.fr/sarlib/xsarsea.git
Update xsar¶
To update xsar installation, just rerun pip install, in your already activated conda environment.
pip install git+https://github.com/oarcher/xsar.git
Note
if you have some problems after updating xsar, you might have to update also your conda environment:
conda install -c conda-forge rasterio gdal cartopy dask[array]