Syzygianinfern0 commited on
Commit
0620290
·
1 Parent(s): 6cbbdf5

Create custom docker image

Browse files
Files changed (2) hide show
  1. Dockerfile +3 -55
  2. Dockerfile.stormbase +44 -0
Dockerfile CHANGED
@@ -1,62 +1,10 @@
1
- # Start from a base image with CUDA and Python
2
- # FROM nvidia/cuda:12.4.1-cudnn8-devel-ubuntu22.04
3
- FROM nvidia/cuda:12.8.1-base-ubuntu22.04
4
 
5
- # System setup
6
- ENV DEBIAN_FRONTEND=noninteractive
7
-
8
- # Install system packages
9
- RUN apt-get update && apt-get install -y \
10
- python3 python3-pip python3-dev python3-venv \
11
- git wget unzip cmake build-essential \
12
- libboost-all-dev libginac-dev libglpk-dev \
13
- m4 libcln-dev libgmp-dev automake libhwloc-dev \
14
- libgl1 libglib2.0-0 && \
15
- rm -rf /var/lib/apt/lists/*
16
-
17
- # Set working directory
18
  WORKDIR /app
19
-
20
- # Set Python aliases
21
- # RUN ln -s /usr/bin/python3 /usr/bin/python && \
22
- # ln -s /usr/bin/pip3 /usr/bin/pip
23
-
24
- # Upgrade pip
25
- RUN pip install --upgrade pip
26
-
27
- # Install Python packages
28
- RUN pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu124 && \
29
- pip install gradio transformers opencv-python decord joblib einops timm accelerate sentencepiece
30
-
31
- # Clone and build carl-storm
32
- RUN git clone https://github.com/moves-rwth/carl-storm && \
33
- cd carl-storm && \
34
- mkdir build && \
35
- cd build && \
36
- cmake .. && \
37
- make lib_carl
38
-
39
- # Clone and build storm
40
- RUN mkdir -p storm_build && \
41
- cd storm_build && \
42
- wget https://github.com/moves-rwth/storm/archive/stable.zip && \
43
- unzip stable.zip && \
44
- cd storm-stable && \
45
- mkdir build && \
46
- cd build && \
47
- cmake ../ -DCMAKE_BUILD_TYPE=Release \
48
- -DSTORM_DEVELOPER=OFF \
49
- -DSTORM_LOG_DISABLE_DEBUG=ON \
50
- -DSTORM_PORTABLE=ON \
51
- -DSTORM_USE_SPOT_SHIPPED=ON && \
52
- make -j1
53
-
54
- RUN pip install stormpy
55
-
56
- # Copy your app code into the container
57
  COPY . /app
58
 
59
- # Expose the Gradio port
60
  EXPOSE 7860
61
 
62
  # Run your Gradio app
 
1
+ FROM syzygianinfern0/stormbase:latest
 
 
2
 
3
+ # Set working directory and copy your app
 
 
 
 
 
 
 
 
 
 
 
 
4
  WORKDIR /app
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5
  COPY . /app
6
 
7
+ # Expose Gradio port
8
  EXPOSE 7860
9
 
10
  # Run your Gradio app
Dockerfile.stormbase ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Start from a base image with CUDA and Python
2
+ FROM nvidia/cuda:12.8.1-base-ubuntu22.04
3
+
4
+ # System setup
5
+ ENV DEBIAN_FRONTEND=noninteractive
6
+
7
+ # Install system packages
8
+ RUN apt-get update && apt-get install -y \
9
+ python3 python3-pip python3-dev python3-venv \
10
+ git wget unzip cmake build-essential \
11
+ libboost-all-dev libginac-dev libglpk-dev \
12
+ m4 libcln-dev libgmp-dev automake libhwloc-dev \
13
+ libgl1 libglib2.0-0 && \
14
+ rm -rf /var/lib/apt/lists/*
15
+
16
+ # Set working directory
17
+ WORKDIR /app
18
+
19
+ # Upgrade pip
20
+ RUN pip install --upgrade pip && \
21
+ pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu124 && \
22
+ pip install gradio transformers opencv-python decord joblib einops timm accelerate sentencepiece
23
+
24
+ # ====== Precompile carl-storm ======
25
+ WORKDIR /opt
26
+ RUN git clone https://github.com/moves-rwth/carl-storm && \
27
+ cd carl-storm && \
28
+ mkdir build && cd build && \
29
+ cmake .. && make lib_carl
30
+
31
+ # ====== Precompile Storm ======
32
+ WORKDIR /opt
33
+ RUN wget https://github.com/moves-rwth/storm/archive/stable.zip && \
34
+ unzip stable.zip && \
35
+ cd storm-stable && \
36
+ mkdir build && cd build && \
37
+ cmake ../ -DCMAKE_BUILD_TYPE=Release \
38
+ -DSTORM_DEVELOPER=OFF \
39
+ -DSTORM_LOG_DISABLE_DEBUG=ON \
40
+ -DSTORM_PORTABLE=ON \
41
+ -DSTORM_USE_SPOT_SHIPPED=ON && \
42
+ make -j12
43
+
44
+ RUN pip install stormpy