niteshade.defence.OutlierDefender

class niteshade.defence.OutlierDefender(initial_dataset_x, initial_dataset_y)

Bases: niteshade.defence.Defender

Abstractclass for defenders that use a outlier filtering strategy.

Parameters
  • initial_dataset_x (np.ndarray, torch.Tensor) – point data (shape (batch_size, data dimensionality)).

  • initial_dataset_y (np.ndarray, torch.Tensor) – label data (shape (batch_size, )).

__init__(initial_dataset_x, initial_dataset_y) None

Initialise the OutlierDefender class using a initial dataset.

Methods

__init__(initial_dataset_x, initial_dataset_y)

Initialise the OutlierDefender class using a initial dataset.

defend()

Checks if the .defend method is implemented.