tabensemb.model.AbstractNN.test_epoch#

method

AbstractNN.test_epoch(test_loader: DataLoader, **kwargs) Tuple[ndarray, ndarray, float][source]#

Evaluate a torch.nn.Module model in a single epoch.

Parameters:
test_loader:

The DataLoader of the testing dataset.

**kwargs:

Parameters to train the model returned by AbstractModel._get_params(). It contains all arguments in AbstractModel._initial_values().

Returns:
np.ndarray

The prediction. Always a 2d torch.Tensor.

np.ndarray

The ground truth. Always a 2d torch.Tensor.

float

The default loss get_loss_fn() of the model on the testing dataset.