Fix validation for early stopping (#1358)
Browse files
src/axolotl/utils/config/models/input/v0_4_1/__init__.py
CHANGED
@@ -822,7 +822,7 @@ class AxolotlInputConfig(
|
|
822 |
@model_validator(mode="after")
|
823 |
def check_early_stopping(self):
|
824 |
if self.early_stopping_patience:
|
825 |
-
if not self.save_steps or self.eval_steps:
|
826 |
raise ValueError(
|
827 |
"`early_stopping_patience` requires save_steps and eval_steps to be set. eval_steps should evenly divide save_steps."
|
828 |
)
|
|
|
822 |
@model_validator(mode="after")
|
823 |
def check_early_stopping(self):
|
824 |
if self.early_stopping_patience:
|
825 |
+
if not self.save_steps or not self.eval_steps:
|
826 |
raise ValueError(
|
827 |
"`early_stopping_patience` requires save_steps and eval_steps to be set. eval_steps should evenly divide save_steps."
|
828 |
)
|