NaN Loss Monitor

Monitors loss and stops training if loss is NaN. Can either fail with exception or just stop training.

hook_nan_tensor(loss_tensor, fail_on_nan_loss = TRUE)

Arguments

loss_tensor

The loss tensor.

fail_on_nan_loss

A boolean indicating whether to raise exception when loss is NaN.

See also

Other session_run_hook wrappers: hook_checkpoint_saver, hook_global_step_waiter, hook_history_saver, hook_logging_tensor, hook_progress_bar, hook_step_counter, hook_stop_at_step, hook_summary_saver, session_run_hook