lore_sa.encoder_decoder.LabelEnc

class lore_sa.encoder_decoder.LabelEnc(dataset_descriptor: dict)[source]

It provides an interface to access Label enconding functions.

__init__(dataset_descriptor: dict)[source]

Methods

__init__(dataset_descriptor)

decode(x)

Decode the array staring from the original descriptor

decode_target_class(x)

encode(x)

It applies the encoder to the input features

get_encoded_features()

Provides a dictionary with the new encoded features name and the new index :return:

decode(x: array)[source]

Decode the array staring from the original descriptor

Parameters

x ([Numpy array]) – Array to decode

Return [Numpy array]

Decoded array

encode(x: array)[source]

It applies the encoder to the input features

Parameters

x ([Numpy array]) – Array to encode

Return [Numpy array]

Encoded array

get_encoded_features()[source]

Provides a dictionary with the new encoded features name and the new index :return: