syedMohib44 commited on
Commit
8db356d
·
1 Parent(s): 4e7a032

Fix invalid colorTo value

Browse files
Files changed (2) hide show
  1. Dockerfile +11 -5
  2. requirements.txt +1 -1
Dockerfile CHANGED
@@ -4,25 +4,31 @@ FROM python:3.10-slim
4
  # Set environment variables
5
  ENV PYTHONDONTWRITEBYTECODE=1
6
  ENV PYTHONUNBUFFERED=1
 
7
 
8
  # Install system dependencies
9
  RUN apt-get update && apt-get install -y \
 
10
  git \
 
11
  && rm -rf /var/lib/apt/lists/*
12
 
13
  # Set work directory
14
  WORKDIR /app
15
 
16
- # Copy requirements
17
  COPY requirements.txt .
18
 
19
- # Install Python dependencies
20
- RUN pip install --upgrade pip && pip install -r requirements.txt
21
 
22
- # Copy the application code
23
  COPY . .
24
 
25
- # Expose the port Gradio runs on
 
 
 
26
  EXPOSE 7860
27
 
28
  # Run the Gradio app
 
4
  # Set environment variables
5
  ENV PYTHONDONTWRITEBYTECODE=1
6
  ENV PYTHONUNBUFFERED=1
7
+ ENV PIP_NO_CACHE_DIR=1
8
 
9
  # Install system dependencies
10
  RUN apt-get update && apt-get install -y \
11
+ build-essential \
12
  git \
13
+ && apt-get clean \
14
  && rm -rf /var/lib/apt/lists/*
15
 
16
  # Set work directory
17
  WORKDIR /app
18
 
19
+ # Copy and install Python dependencies
20
  COPY requirements.txt .
21
 
22
+ RUN pip install --upgrade pip \
23
+ && pip install --no-cache-dir -r requirements.txt
24
 
25
+ # Copy application and model code
26
  COPY . .
27
 
28
+ # If you're downloading the model from Hugging Face hub instead of local folder:
29
+ # RUN python -c "from transformers import pipeline; pipeline('text-generation', model='syedmohib/audit-model', tokenizer='syedmohib/audit-model')"
30
+
31
+ # Expose the Gradio port
32
  EXPOSE 7860
33
 
34
  # Run the Gradio app
requirements.txt CHANGED
@@ -2,5 +2,5 @@ torch==2.2.2
2
  transformers==4.39.3
3
  datasets==2.18.0
4
  peft==0.10.0
5
- accelerate==0.30.1
6
  gradio==4.26.0
 
2
  transformers==4.39.3
3
  datasets==2.18.0
4
  peft==0.10.0
5
+ accelerate==0.26.1
6
  gradio==4.26.0