Jack
commited on
Commit
·
d9346bd
1
Parent(s):
759e968
added various files
Browse files- Dockerfile +4 -1
- app.py +3 -0
Dockerfile
CHANGED
@@ -7,7 +7,10 @@ WORKDIR /app
|
|
7 |
# Copy the current directory contents into the container at /app
|
8 |
COPY . /app
|
9 |
|
10 |
-
#
|
|
|
|
|
|
|
11 |
RUN chmod -R 777 /app
|
12 |
|
13 |
# Install any necessary dependencies
|
|
|
7 |
# Copy the current directory contents into the container at /app
|
8 |
COPY . /app
|
9 |
|
10 |
+
# Set Hugging Face cache directory to /app/.cache
|
11 |
+
ENV HF_HOME=/app/.cache
|
12 |
+
|
13 |
+
# Give write permissions to the /app directory (if needed)
|
14 |
RUN chmod -R 777 /app
|
15 |
|
16 |
# Install any necessary dependencies
|
app.py
CHANGED
@@ -1,6 +1,9 @@
|
|
1 |
import chainlit as cl
|
2 |
from faster_whisper import WhisperModel
|
3 |
from openai import AsyncOpenAI
|
|
|
|
|
|
|
4 |
|
5 |
# Model path for the fine-tuned Whisper model
|
6 |
model_path = "jacktol/whisper-medium.en-fine-tuned-for-ATC-faster-whisper"
|
|
|
1 |
import chainlit as cl
|
2 |
from faster_whisper import WhisperModel
|
3 |
from openai import AsyncOpenAI
|
4 |
+
import os
|
5 |
+
|
6 |
+
os.environ["HF_HOME"] = "/app/.cache"
|
7 |
|
8 |
# Model path for the fine-tuned Whisper model
|
9 |
model_path = "jacktol/whisper-medium.en-fine-tuned-for-ATC-faster-whisper"
|