Skip to content

Commit d9969d3

Browse files
authored
Update art/estimators/classification/pytorch.py
Signed-off-by: Beat Buesser <[email protected]>
1 parent 2653944 commit d9969d3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

art/estimators/classification/pytorch.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -505,7 +505,7 @@ def clone_for_refitting(self) -> "PyTorchClassifier": # lgtm [py/inheritance/in
505505
model = copy.deepcopy(self.model)
506506

507507
if self._optimizer is None: # pragma: no cover
508-
raise ValueError("An optimizer is needed to train the model, but none for provided.")
508+
raise ValueError("An optimizer is needed to train the model, but none is provided.")
509509

510510
# create a new optimizer that binds to the cloned model's parameters and uses original optimizer's defaults
511511
new_optimizer = type(self._optimizer)(model.parameters(), **self._optimizer.defaults) # type: ignore

0 commit comments

Comments
 (0)