ray.train.ValidationConfig#
- class ray.train.ValidationConfig(fn: ValidationFn, task_config: ValidationTaskConfig | None = None, ray_remote_kwargs: Dict[str, Any] | None = None)#
Configuration for validation, passed to the trainer.
- Parameters:
fn – The validation function to run on checkpoints. This function should accept a checkpoint as the first argument and return a dictionary of metrics.
task_config – Default configuration for validation tasks. The fn_kwargs in this config can be overridden by ValidationTaskConfig passed to report().
ray_remote_kwargs – Keyword arguments to pass to
ray.remote()for the validation task. This can be used to specify resource requirements, number of retries, etc.
PublicAPI (alpha): This API is in alpha and may change before becoming stable.
Methods