Spaces:
Runtime error
Runtime error
Update Dockerfile
Browse files- Dockerfile +4 -2
Dockerfile
CHANGED
@@ -19,6 +19,7 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
|
|
19 |
python3.9 \
|
20 |
python3-pip \
|
21 |
python3.9-dev \
|
|
|
22 |
&& rm -rf /var/lib/apt/lists/*
|
23 |
|
24 |
# Set Python 3.9 as the default python and pip versions
|
@@ -49,8 +50,9 @@ ENV HOME=/home/user \
|
|
49 |
# Set working directory
|
50 |
WORKDIR $HOME/app
|
51 |
|
52 |
-
#
|
53 |
-
RUN pip install --no-cache-dir
|
|
|
54 |
python -c "import torch; print('PyTorch version:', torch.__version__)"
|
55 |
|
56 |
# Clone the repository
|
|
|
19 |
python3.9 \
|
20 |
python3-pip \
|
21 |
python3.9-dev \
|
22 |
+
python3.9-venv \
|
23 |
&& rm -rf /var/lib/apt/lists/*
|
24 |
|
25 |
# Set Python 3.9 as the default python and pip versions
|
|
|
50 |
# Set working directory
|
51 |
WORKDIR $HOME/app
|
52 |
|
53 |
+
# Upgrade pip and install PyTorch first
|
54 |
+
RUN pip install --no-cache-dir --upgrade pip && \
|
55 |
+
pip install --no-cache-dir torch==1.7.1 torchvision --extra-index-url https://download.pytorch.org/whl/cu113 && \
|
56 |
python -c "import torch; print('PyTorch version:', torch.__version__)"
|
57 |
|
58 |
# Clone the repository
|