Getting Started

Initial steps to deploy and configure the software

3 minute read



We strongly recommend using docker containers to deploy the Process Based Analytics component.

With docker

you will need the following:

  • a running docker distribution with docker-compose is the only prerequisite you need. If you are running on windows, make sure to also use the WSL 2 based docker engine.

Without docker

you will need the following:

  • Python 3.6
  • pip3
  • venv or conda (recommended, but not necessary)

Installation & Deployment

The docker way

If your deployment environment fulfils the suggested prerequisite of having a running docker distribution, the installation and deployment is a three-step process.

  1. Navigate your shell into the root folder of the component and build the docker container for the component using the following command.

    If you are in a Windows environment you first have to open a WSL2 shell to run this command, as the build script expects to receive the host machine user’s user-id and group-id as input.

    Note that you need to rebuild the container every time that either your user-id or group-id changes.

$ docker build --pull --rm --progress plain -f "Dockerfile" -t processbasedanalytics:latest --build-arg USER_ID=$(id -u) --build-arg GROUP_ID=$(id -g) "."
  1. Run the docker container by executing the following command in the component’s root directory.

    $ docker-compose up

  2. Open a shell inside the running docker container. To do so you can use the command:

    $ docker exec –it <name> /bin/bash

    To find out your running container’s name by run:

    $ docker ps

    Lastly , run script in order to train the ensemble and run the reinforcement learning agent according to the chosen configuration.

Further instructions on how to use the component are available in the How to use it section section.

The manual way

If you can’t build and run docker images in your environment, the following steps guide you on how to use the component. Please make sure you have the read and your environment fulfils the prerequisites listed above.

  1. Create a virtual environment for the component using either venv or conda, otherwise you will install all dependencies systemwide.
    Please refer to the documentation of the virtualisation tool of your choice to understand how to use it.

  2. Navigate a shell running in your virtual environment into the component’s root directory and execute the following command:

    $ pip3 install -v -r requirements.txt

    This command downloads and installs all required python dependencies, which are listed in the requirements file, to your virtual environment. This might take a while. The “-v” flag tells pip3 to log additional output to the console for potential debugging.

    Alternatively, if you are using conda, you can also run:

    $ conda install -v --file requirements.txt

    Reportedly, installing with conda boosts the performance of tensorflow greatly on some CPUs.

  3. Install the reinforcement learning environment as a editable library using the following command:

    $ pip3 install -v -e prescriptive_process_monitoring/gym-threshold-begone

Further instructions on how to use the component are available in the How to use it section section.

Last modified April 19, 2023: Files update (a811bf0)