Skip to content

Commit fc868e1

Browse files
author
Bhanu Teja Goshikonda
committed
Revert "Fix torch 2.10 version pinning and increase CPU image size baseline"
This reverts commit 73dfc44.
1 parent 3b9e8b3 commit fc868e1

File tree

4 files changed

+16
-28
lines changed

4 files changed

+16
-28
lines changed

pytorch/training/buildspec-2-10-ec2.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ images:
4444
BuildEC2CPUPTTrainPy3DockerImage:
4545
<<: *TRAINING_REPOSITORY
4646
build: &PYTORCH_CPU_TRAINING_PY3 false
47-
image_size_baseline: 12000
47+
image_size_baseline: 7200
4848
device_type: &DEVICE_TYPE cpu
4949
python_version: &DOCKER_PYTHON_VERSION py3
5050
tag_python_version: &TAG_PYTHON_VERSION py313

pytorch/training/buildspec-2-10-sm.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ images:
4444
BuildSageMakerCPUPTTrainPy3DockerImage:
4545
<<: *TRAINING_REPOSITORY
4646
build: &PYTORCH_CPU_TRAINING_PY3 false
47-
image_size_baseline: 12000
47+
image_size_baseline: 7200
4848
device_type: &DEVICE_TYPE cpu
4949
python_version: &DOCKER_PYTHON_VERSION py3
5050
tag_python_version: &TAG_PYTHON_VERSION py313

pytorch/training/docker/2.10/py3/Dockerfile.cpu

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -197,26 +197,20 @@ RUN pip install --no-cache-dir \
197197
pytz \
198198
tzdata
199199

200-
# Install PyTorch - split into separate commands to prevent dependency resolver from downgrading torch
200+
# Install PyTorch
201201
RUN pip install --no-cache-dir -U torch==${PYTORCH_VERSION} \
202202
torchvision==${TORCHVISION_VERSION} \
203203
torchaudio==${TORCHAUDIO_VERSION} \
204-
--index-url https://download.pytorch.org/whl/cpu
205-
206-
# Install torch ecosystem packages
207-
RUN pip install --no-cache-dir -U torchtnt==${TORCHTNT_VERSION} \
204+
--index-url https://download.pytorch.org/whl/cpu \
205+
&& pip install --no-cache-dir -U torchtnt==${TORCHTNT_VERSION} \
208206
torchdata==${TORCHDATA_VERSION} \
209-
s3torchconnector
210-
211-
# Install ML packages with torch version constraint to prevent downgrade
212-
# pin numpy requirement for fastai dependency
213-
# requires explicit declaration of spacy, thinc, blis
214-
# pin thinc due to incompatibility with numpy 1.26.4 (sagemaker doesn't support latest numpy)
215-
RUN pip install --no-cache-dir -U \
216-
"torch==${PYTORCH_VERSION}" \
207+
s3torchconnector \
217208
fastai \
218209
accelerate \
210+
# pin numpy requirement for fastai dependency
211+
# requires explicit declaration of spacy, thic, blis
219212
spacy \
213+
# pin thinc due to incompatibility with numpy 1.26.4 (sagemaker doesn't support latest numpy)
220214
thinc \
221215
blis \
222216
numpy \

pytorch/training/docker/2.10/py3/cu130/Dockerfile.gpu

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -116,27 +116,21 @@ RUN pip install --no-cache-dir \
116116
pytz \
117117
tzdata
118118

119-
# Install PyTorch - split into separate commands to prevent dependency resolver from downgrading torch
119+
# Install PyTorch
120120
RUN pip install --no-cache-dir -U torch==${PYTORCH_VERSION} \
121121
torchvision==${TORCHVISION_VERSION} \
122122
torchaudio==${TORCHAUDIO_VERSION} \
123-
--index-url https://download.pytorch.org/whl/cu130
124-
125-
# Install torch ecosystem packages
126-
RUN pip install --no-cache-dir -U torchtnt==${TORCHTNT_VERSION} \
123+
--index-url https://download.pytorch.org/whl/cu130 \
124+
&& pip install --no-cache-dir -U torchtnt==${TORCHTNT_VERSION} \
127125
torchdata==${TORCHDATA_VERSION} \
128126
triton \
129-
s3torchconnector
130-
131-
# Install ML packages with torch version constraint to prevent downgrade
132-
# pin numpy requirement for fastai dependency
133-
# requires explicit declaration of spacy, thinc, blis
134-
# pin thinc due to incompatibility with numpy 1.26.4 (sagemaker doesn't support latest numpy)
135-
RUN pip install --no-cache-dir -U \
136-
"torch==${PYTORCH_VERSION}" \
127+
s3torchconnector \
137128
fastai \
138129
accelerate \
130+
# pin numpy requirement for fastai dependency
131+
# requires explicit declaration of spacy, thic, blis
139132
spacy \
133+
# pin thinc due to incompatibility with numpy 1.26.4 (sagemaker doesn't support latest numpy)
140134
thinc \
141135
blis \
142136
numpy \

0 commit comments

Comments
 (0)