Spaces:
Running
Running
Update Dockerfile
Browse files- Dockerfile +15 -8
Dockerfile
CHANGED
@@ -10,9 +10,6 @@ ENV PYTHONDONTWRITEBYTECODE=1 \
|
|
10 |
# Set the working directory
|
11 |
WORKDIR /app
|
12 |
|
13 |
-
# Copy the requirements file into the container at /app
|
14 |
-
COPY requirements.txt /app/
|
15 |
-
|
16 |
# Install build dependencies and LLVM components from Debian's default repos (Bookworm)
|
17 |
RUN apt-get update && \
|
18 |
apt-get install -y --no-install-recommends \
|
@@ -36,17 +33,27 @@ RUN apt-get update && \
|
|
36 |
# Set LLVM_CONFIG for clang-14 (needed by llvmlite)
|
37 |
ENV LLVM_CONFIG=/usr/bin/llvm-config-14
|
38 |
|
39 |
-
#
|
40 |
-
#
|
41 |
-
RUN pip
|
42 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
43 |
llvmlite==0.36.0 \
|
44 |
numba==0.53.1 \
|
45 |
resampy==0.3.1 \
|
46 |
librosa==0.9.2
|
47 |
|
|
|
|
|
|
|
48 |
# Install other Python dependencies from requirements.txt
|
49 |
-
#
|
|
|
50 |
RUN pip install --no-cache-dir -r requirements.txt
|
51 |
|
52 |
# Copy the rest of the application
|
|
|
10 |
# Set the working directory
|
11 |
WORKDIR /app
|
12 |
|
|
|
|
|
|
|
13 |
# Install build dependencies and LLVM components from Debian's default repos (Bookworm)
|
14 |
RUN apt-get update && \
|
15 |
apt-get install -y --no-install-recommends \
|
|
|
33 |
# Set LLVM_CONFIG for clang-14 (needed by llvmlite)
|
34 |
ENV LLVM_CONFIG=/usr/bin/llvm-config-14
|
35 |
|
36 |
+
# --- CRITICAL CHANGE: Ensure correct NumPy version ---
|
37 |
+
# First, remove any pre-installed numpy that might conflict
|
38 |
+
RUN pip uninstall -y numpy || true
|
39 |
+
|
40 |
+
# Explicitly install the exact NumPy 1.x version
|
41 |
+
# This must come BEFORE numba and librosa to ensure they compile/install against it.
|
42 |
+
RUN pip install --no-cache-dir numpy==1.22.4
|
43 |
+
|
44 |
+
# Install llvmlite, numba, resampy, librosa which depend on numpy
|
45 |
+
RUN pip install --no-cache-dir \
|
46 |
llvmlite==0.36.0 \
|
47 |
numba==0.53.1 \
|
48 |
resampy==0.3.1 \
|
49 |
librosa==0.9.2
|
50 |
|
51 |
+
# Copy the requirements file into the container at /app
|
52 |
+
COPY requirements.txt /app/
|
53 |
+
|
54 |
# Install other Python dependencies from requirements.txt
|
55 |
+
# IT IS CRUCIAL that requirements.txt does NOT contain any numpy version that would conflict.
|
56 |
+
# If it does, you MUST remove or modify it.
|
57 |
RUN pip install --no-cache-dir -r requirements.txt
|
58 |
|
59 |
# Copy the rest of the application
|