Installation

EnPT can be installed in two different ways:

  • as a standalone package which can be used via the Python API or from the command line

  • along with the EnMAP-Box (a QGIS plugin) which provides a GUI for EnPT.

Installing EnPT as a standalone package (backend code only)

Optional: Install ACwater for advanced atmospheric correction over water surfaces

For atmospheric correction of water surfaces using the Polymer algorithm instead of SICOR (which is mainly designed for land surfaces), the additional packages ACwater (a Polymer wrapper developed by AWI Bremerhaven) and polymer are required.

  1. Using a previously created enpt conda environment (as described above), first install some dependencies:

    $ conda activate enpt
    $ conda install -c conda-forge cdsapi cython gdal netcdf4 pygrib pyhdf xarray
    $ pip install ecmwf-api-client
    
  2. Then register at the HYGEOS support forum, download polymer from there, unpack it and run the following commands from the unpacked root directory of polymer:

    $ make
    $ make auxdata_common
    $ make ancillary
    $ pip install -e .
    

Note

When using a conda environment on Linux or Mac OSX, the needed compilers to build polymer should be already installed. On Windows, you need to install the Microsoft build tools for visual studio including the C++ build tools, the latest versions of MSVCv142 - VS 2019 C++ x64/x86 build tools and Windows 10 SDK (see here for details). However, polymer is currently not Windows compatible and will likely not run as expected.

Apart from that, you need to register at the CDS registration page and install a CDS API key. Further details are given here.

  1. Finally install ACwater:

    $ pip install git+https://gitlab.awi.de/phytooptics/acwater.git
    

Further details about the installation of ACwater can be found in the ACwater Polymer installation instructions.

Installing EnPT along with QGIS and the EnMAP-Box (backend + GUI)

If you want to use EnPT including the GUI in the EnMAP-Box, it is highly recommended to install QGIS, the EnMAP-Box requirements, the EnPT backend code and the EnPT GUI into a single conda environment.

To do so, run the following command on a conda command line:

$ conda env create -n enpt_full -f https://git.gfz-potsdam.de/EnMAP/GFZ_Tools_EnMAP_BOX/EnPT/raw/master/tests/gitlab_CI_docker/context/environment_enpt_full.yml

Then activate the newly created conda environment and start QGIS:

$ conda activate enpt_full
$ qgis

The EnMAP-Box QGIS plugin can then be installed via the QGIS Plugin manager and the EnPT GUI can be started from within the EnMAP-Box as described here.

If you want to use advanced atmospheric correction over water surfaces, please install the optional requirement polymer as described above.

Note

EnPT has been tested with Python 3.7+ on Linux, Windows and Mac OSX.