Spaces:
No application file
No application file
Update Dockerfile
Browse files- Dockerfile +7 -2
Dockerfile
CHANGED
|
@@ -26,9 +26,14 @@ RUN pip install --no-cache-dir --upgrade pip && \
|
|
| 26 |
|
| 27 |
# Tạo stub module flash_attn và bitsandbytes để tránh lỗi trên môi trường CPU-only
|
| 28 |
RUN mkdir -p /usr/local/lib/python3.10/site-packages/flash_attn && \
|
| 29 |
-
printf "def _not_available(*args, **kwargs)
|
|
|
|
|
|
|
|
|
|
|
|
|
| 30 |
mkdir -p /usr/local/lib/python3.10/site-packages/bitsandbytes && \
|
| 31 |
-
printf \"raise ImportError('bitsandbytes is not available in this CPU-only build')
|
|
|
|
| 32 |
|
| 33 |
COPY app.py /app/app.py
|
| 34 |
|
|
|
|
| 26 |
|
| 27 |
# Tạo stub module flash_attn và bitsandbytes để tránh lỗi trên môi trường CPU-only
|
| 28 |
RUN mkdir -p /usr/local/lib/python3.10/site-packages/flash_attn && \
|
| 29 |
+
printf '%s\n' "def _not_available(*args, **kwargs):" \
|
| 30 |
+
" raise ImportError('flash_attn is not available in this CPU-only build')" \
|
| 31 |
+
"" \
|
| 32 |
+
"__all__ = ['_not_available']" \
|
| 33 |
+
> /usr/local/lib/python3.10/site-packages/flash_attn/__init__.py && \
|
| 34 |
mkdir -p /usr/local/lib/python3.10/site-packages/bitsandbytes && \
|
| 35 |
+
printf '%s\n' "raise ImportError('bitsandbytes is not available in this CPU-only build')" \
|
| 36 |
+
> /usr/local/lib/python3.10/site-packages/bitsandbytes/__init__.py
|
| 37 |
|
| 38 |
COPY app.py /app/app.py
|
| 39 |
|