ssl_tools.experiments.covid_detection.mlp

Attributes

options

Classes

FlattenBCELoss

MLPClassifierTest

Helper class that provides a standard way to create an ABC using

MLPClassifierTrain

Helper class that provides a standard way to create an ABC using

Module Contents

class ssl_tools.experiments.covid_detection.mlp.FlattenBCELoss

Bases: torch.nn.BCELoss

forward(input, target)
Parameters:
  • input (torch.Tensor)

  • target (torch.Tensor)

Return type:

torch.Tensor

class ssl_tools.experiments.covid_detection.mlp.MLPClassifierTest(input_size=16, hidden_size=128, num_hidden_layers=1, num_classes=1, learning_rate=0.001, *args, **kwargs)

Bases: ssl_tools.experiments.covid_detection.classification_base.CovidDetectionEvaluator

Helper class that provides a standard way to create an ABC using inheritance.

Parameters:
  • input_size (int)

  • hidden_size (int)

  • num_hidden_layers (int)

  • num_classes (int)

  • learning_rate (float)

_MODEL_NAME = 'mlp'
get_model()

Get the model to use for the experiment.

Returns

L.LightningModule

The model to use for the experiment

Return type:

lightning.LightningModule

class ssl_tools.experiments.covid_detection.mlp.MLPClassifierTrain(input_size=16, hidden_size=128, num_hidden_layers=1, num_classes=1, learning_rate=0.001, *args, **kwargs)

Bases: ssl_tools.experiments.covid_detection.classification_base.CovidDetectionTrain

Helper class that provides a standard way to create an ABC using inheritance.

Parameters:
  • input_size (int)

  • hidden_size (int)

  • num_hidden_layers (int)

  • num_classes (int)

  • learning_rate (float)

_MODEL_NAME = 'mlp'
get_model()

Get the model to use for the experiment.

Returns

L.LightningModule

The model to use for the experiment

Return type:

lightning.LightningModule

ssl_tools.experiments.covid_detection.mlp.options