You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

123 lines
3.3 KiB

3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
  1. FROM movesrwth/storm-basesystem:ubuntu-22.04 as build
  2. #COPY ./tempest-devel /opt/tempest
  3. #COPY ./tempest-py /opt/tempestpy
  4. #COPY ./pycarl-2.0.4 /opt/pycarl
  5. #COPY ./carl /opt/carl
  6. # RUN rm -r /opt/tempest/.git
  7. # RUN rm -r /opt/tempestpy/.git
  8. # RUN rm -r /opt/Minigrid2PRISM/.git
  9. RUN apt-get update
  10. RUN apt-get install -y python3.10
  11. # Specify number of threads to use for parallel compilation
  12. # This number can be set from the commandline with:
  13. # --build-arg no_threads=<value>
  14. ARG no_threads=6
  15. # Build carl
  16. RUN git clone -b c++14-22.01 https://github.com/ths-rwth/carl.git /opt/carl
  17. RUN mkdir -p /opt/carl/build
  18. WORKDIR /opt/carl/build
  19. RUN cmake .. -DCMAKE_BUILD_TYPE=Release -DUSE_CLN_NUMBERS=ON -DUSE_GINAC=ON
  20. RUN make lib_carl -j $no_threads
  21. # Build tempest
  22. RUN git clone -b tempestpy_adaptions https://git.pranger.xyz/sp/tempest.git /opt/tempest
  23. RUN mkdir -p /opt/tempest/build
  24. WORKDIR /opt/tempest/build
  25. RUN cmake .. -DCMAKE_BUILD_TYPE=Release -DSTORM_DEVELOPER=OFF -DSTORM_LOG_DISABLE_DEBUG=ON -DSTORM_PORTABLE=OFF -DSTORM_USE_SPOT_SHIPPED=ON
  26. RUN make resources storm binaries -j $no_threads
  27. RUN apt-get install -y maven
  28. RUN apt-get install -y uuid-dev
  29. # COPY ./carl-parser /opt/carl-parser
  30. # # Switch to build directory
  31. # RUN mkdir -p /opt/carl-parser/build
  32. # WORKDIR /opt/carl-parser/build
  33. # Configure carl-parser
  34. RUN cmake .. -DCMAKE_BUILD_TYPE=$build_type
  35. # Build carl-parser
  36. # RUN make carl-parser -j $no_threads
  37. # Manage python packages
  38. WORKDIR /opt/
  39. RUN apt-get install -y python3-venv
  40. # Python env handling
  41. ENV VIRTUAL_ENV=/opt/venv
  42. RUN python3 -m venv $VIRTUAL_ENV
  43. ENV PATH="$VIRTUAL_ENV/bin:$PATH"
  44. RUN apt-get install -y python3-pip
  45. # build pycarl
  46. RUN git clone -b 2.0.4 https://github.com/moves-rwth/pycarl.git /opt/pycarl
  47. WORKDIR /opt/pycarl
  48. RUN python setup.py build_ext -j $no_threads
  49. RUN pip install .
  50. # build tempestpy
  51. RUN git clone -b refactoring https://git.pranger.xyz/sp/tempestpy.git /opt/tempestpy
  52. WORKDIR /opt/tempestpy
  53. RUN python3 setup.py build_ext --storm-dir /opt/tempest/ -j $no_threads develop
  54. # build yaml-cpp
  55. COPY ./yaml-cpp /opt/yaml-cpp
  56. RUN mkdir -p /opt/yaml-cpp/build
  57. WORKDIR /opt/yaml-cpp/build
  58. RUN cmake .. -DCMAKE_BUILD_TYPE=Release
  59. RUN make -j $no_threads
  60. RUN make install -j $no_threads
  61. COPY ./Minigrid2PRISM /opt/Minigrid2PRISM
  62. # build minigrid to prism
  63. RUN mkdir -p /opt/Minigrid2PRISM/build
  64. WORKDIR /opt/Minigrid2PRISM/build
  65. RUN cmake ..
  66. RUN make -j $no_threads
  67. # build minigrid
  68. #COPY ./Minigrid /opt/Minigrid
  69. #RUN rm -r /opt/Minigrid/.git
  70. #WORKDIR /opt/Minigrid
  71. #RUN pip install .
  72. RUN apt-get update && apt-get install ffmpeg libsm6 libxext6 -y
  73. WORKDIR /opt/tempestpy
  74. RUN pip install -U "ray[all]==2.6.3"
  75. RUN pip install dm-tree
  76. RUN pip install opencv-python
  77. RUN pip install scikit-image
  78. RUN pip install torch
  79. RUN pip install tensorboard
  80. RUN pip install tensorboardX
  81. RUN pip install gymnasium
  82. RUN pip install tensorflow
  83. RUN pip install jupyterlab
  84. RUN pip install astar
  85. RUN pip install ipywidgets
  86. RUN pip install numpy
  87. RUN pip install matplotlib
  88. RUN pip install sb3-contrib
  89. RUN pip install opencv-python
  90. RUN pip install moviepy
  91. ENV M2P_BINARY=/opt/Minigrid2PRISM/build/main
  92. # We mount the Minigrid directory here manually again, to be able to have the directory hosted in the jupyter notebook
  93. CMD ["pip", "install", "-e", "/opt/Minigrid"]
  94. ENTRYPOINT ["jupyter", "lab","--ip=0.0.0.0","--allow-root", "--notebook-dir=/opt/notebooks"]