Skip to content

aai-institute/tfl-training-machine-learning-control

Repository files navigation

TransferLab Training: Machine Learning Control

Welcome to the TransferLab trainings: Machine Learning Control. This is the readme for the participants of the training.

During the training

If you are currently participating in the training, you can find the agenda in the file AGENDA.md. Everything is already set up, so feel free to follow the trainer's presentation or to explore the notebooks and source code on your own.

After the training

You have received this file as part of the training materials.

There are multiple ways of viewing/executing the content.

  1. If you just want to view the rendered notebooks, open _build/html/index.html in your browser.

  2. If you want to execute the notebooks, you will either need to install the dependencies or use docker. For running without docker, create a poetry environment (with python 3.11), e.g., with poetry shell.

    Then, install the dependencies and the package with

    poetry install

    and after that launch jupyter lab

    jupyter lab
  3. If you want to use docker instead, you can build the image locally using:

    docker build -t tfl-training-ml-control:local .

    You can then start the container e.g., with

    docker run -it -p 8888:8888 tfl-training-ml-control:local jupyter lab --ip=0.0.0.0
  4. Finally, for creating source code documentation, you can run

    bash build_scripts/build_docs.sh

    This will execute and cache the notebooks and render them nicely.

  5. In case you experience some issues with the rendering when using docker make sure to add the docker user to xhost. So run on your local machine:

    xhost +SI:localuser:docker_user

    and run docker using:

    docker run -it --rm --privileged --net=host \
       --env DISPLAY --volume /tmp/.X11-unix:/tmp/.X11-unix \
       tfl-training-ml-control:local jupyter lab --ip=0.0.0.0

Note There is some non-trivial logic in the entrypoint that may collide with mounting volumes to paths directly inside /home/jovyan/training_rl. If you want to do that, the easiest way is to override the entrypoint or to mount somewhere else and create a symbolic link. For details on that see the Dockerfile and entrypoint.sh.

License

This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

CC BY-SA 4.0