Skip to content

When val_data is None, it breaks checkpoint saving #72

Description

@andresespinosapc

It is possible to set val_data to None in SupervisedTrainer.train, and it is handled (for example in CallbackContainer._evaluate_model_on_validation). But, if I set val_data to None, the total_loss in Callback.get_losses is never calculated, so checkpoints are never saved in CallbackContainer.on_batch_end.

So, you should (1) log a warning saying that dev_data should not be None, or (2) handle checkpoint saving in another way when there is no dev_data (such as saving last checkpoints instead of the ones with best loss values.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions