Skip to content

Commit

Permalink
updated dockerfile to work without a requirements.txt and does not us…
Browse files Browse the repository at this point in the history
…e WebUI stuff
  • Loading branch information
JSchmie committed Dec 2, 2024
1 parent d00ec2d commit f9f23c2
Showing 1 changed file with 15 additions and 17 deletions.
32 changes: 15 additions & 17 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
#pytorch Image
FROM pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime
FROM pytorch/pytorch:2.5.1-cuda12.4-cudnn9-runtime

# Labels

LABEL maintainer="Jacob Schmieder"
LABEL email="[email protected]"
LABEL version="0.1.1.dev"
LABEL version="0.0.0"
LABEL description="Scraibe is a tool for automatic speech recognition and speaker diarization. \
It is based on the Hugging Face Transformers library and the Pyannote library. \
It is designed to be used with the Whisper model, a lightweight model for automatic \
Expand All @@ -15,27 +15,25 @@ LABEL url="https://github.com/JSchmie/ScrAIbe"
# Install dependencies
WORKDIR /app
#Enviorment dependencies
ENV TRANSFORMERS_CACHE=/app/models
ENV HF_HOME=/app/models
ENV AUTOT_CACHE=/app/models
ENV PYANNOTE_CACHE=/app/models/pyannote
ENV AUTOT_CACHE=/data/models/
#Copy all necessary files
COPY requirements.txt /app/requirements.txt
COPY README.md /app/README.md
COPY scraibe /app/scraibe
COPY README.md /app/src/README.md
COPY scraibe /app/src/scraibe
COPY pyproject.toml /app/src/pyproject.toml
COPY LICENSE /app/src/LICENSE

#Installing all necessary dependencies and running the application with a personalised Hugging-Face-Token

#Installing all necessary Dependencies and Running the Application with a personalised Hugging-Face-Token
RUN apt update -y && apt upgrade -y && \
apt install -y libsm6 libxrender1 libfontconfig1 && \
apt install -y libsm6 libxrender1 libfontconfig1 git ffmpeg && \
apt clean && \
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*

RUN conda update --all && \
# conda install -y pip ffmpeg && \
conda install -c conda-forge libsndfile && \
RUN conda update --all -y && conda install -y -c conda-forge libsndfile && \
conda clean --all -y
# RUN pip install torchaudio==0.11.0+cu113 -f https://download.pytorch.org/whl/torch_stable.html
RUN pip install --no-cache-dir -r requirements.txt

RUN --mount=source=.git,target=.git,type=bind \
# --mount=source=scraibe_webui,target=scraibe_webui,type=bind \
pip install --no-cache-dir ./src

# Expose port
EXPOSE 7860
Expand Down

0 comments on commit f9f23c2

Please sign in to comment.