emmi.pipeline.batch_processors.moment_normalization

Classes

MomentNormalizationBatchProcessor

Normalizes a value with its mean and standard deviation (i.e., its moments).

Module Contents

class emmi.pipeline.batch_processors.moment_normalization.MomentNormalizationBatchProcessor(items, mean, std)

Bases: ksuit.data.pipeline.BatchProcessor

Normalizes a value with its mean and standard deviation (i.e., its moments).

Initializes the MomentNormalizationPostCollator

Parameters:
items
mean_tensor
std_tensor
denormalize(key, value)

Inverts the normalization from the __call__ method of a single item in the batch.

Parameters:
  • key (str) – The name of the item.

  • value (torch.Tensor) – The value of the item.

Returns:

The same name and the denormalized value.

Return type:

(key, value)