diff --git a/components/runpod_trainer/Dockerfile b/components/runpod_trainer/Dockerfile index a0e2e1a..3284d20 100644 --- a/components/runpod_trainer/Dockerfile +++ b/components/runpod_trainer/Dockerfile @@ -5,8 +5,11 @@ WORKDIR /app # Copy requirements first for better caching COPY requirements.txt /app/requirements.txt -# Install dependencies -RUN pip install --no-cache-dir -r requirements.txt +# Upgrade pip and install dependencies +# Force upgrade torch to ensure compatibility with transformers +RUN pip install --upgrade pip && \ + pip install --no-cache-dir torch==2.4.0 --force-reinstall && \ + pip install --no-cache-dir -r requirements.txt # Copy handler and data COPY handler.py /app/handler.py diff --git a/components/runpod_trainer/requirements.txt b/components/runpod_trainer/requirements.txt index 63b3802..a1e3147 100644 --- a/components/runpod_trainer/requirements.txt +++ b/components/runpod_trainer/requirements.txt @@ -1,5 +1,5 @@ runpod>=1.7.0 -transformers>=4.48.0 +transformers==4.47.1 datasets>=2.16.0 accelerate>=0.30.0 boto3>=1.34.0 @@ -8,5 +8,5 @@ scipy>=1.11.0 safetensors>=0.4.0 requests>=2.31.0 peft>=0.14.0 -bitsandbytes>=0.45.0 +bitsandbytes==0.45.0 trl>=0.14.0