Skip to content

Commit 221c219

Browse files
committed
fix: post ray 2.52.1 fix for mnist script
1 parent ff1238f commit 221c219

File tree

2 files changed

+4
-14
lines changed

2 files changed

+4
-14
lines changed

demo-notebooks/guided-demos/mnist_fashion.py

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,6 @@
88
from ray.train import ScalingConfig
99

1010

11-
def get_dataset():
12-
return datasets.FashionMNIST(
13-
root="/tmp/data",
14-
train=True,
15-
download=True,
16-
transform=ToTensor(),
17-
)
18-
19-
2011
class NeuralNetwork(nn.Module):
2112
def __init__(self):
2213
super().__init__()
@@ -84,9 +75,6 @@ def train_func_distributed():
8475
resources_per_worker={
8576
"CPU": 1,
8677
},
87-
trainer_resources={
88-
"CPU": 0,
89-
},
9078
),
9179
)
9280

tests/e2e/support.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -122,9 +122,11 @@ def create_namespace_with_name(self, namespace_name):
122122
self.api_instance.create_namespace(namespace_body)
123123
except Exception as e:
124124
# Check if it's an AlreadyExists error (409 Conflict) and ignore it
125-
if hasattr(e, 'status') and e.status == 409:
125+
if hasattr(e, "status") and e.status == 409:
126126
# Namespace already exists, which is fine - just continue
127-
print(f"Warning: Namespace '{namespace_name}' already exists, continuing...")
127+
print(
128+
f"Warning: Namespace '{namespace_name}' already exists, continuing..."
129+
)
128130
return
129131
return _kube_api_error_handling(e)
130132

0 commit comments

Comments
 (0)