mlrl.common.cython.output_space_info module

@author: Michael Rapp (michael.rapp.ml@gmail.com)

class mlrl.common.cython.output_space_info.LabelVectorSet

Bases: OutputSpaceInfo

Stores a set of unique label vectors, as well as their frequency.

visit(visitor: LabelVectorSetVisitor)

Visits the label vectors and frequencies stored by the set.

Parameters:

visitor – The LabelVectorSetVisitor that should be used to access the label vectors and frequencies

class mlrl.common.cython.output_space_info.LabelVectorSetVisitor

Bases: object

Defines the methods that must be implemented by a visitor that accesses the label vectors and frequencies stored by a LabelVectorSet.

abstractmethod visit_label_vector(label_vector: ndarray, frequency: int)

Must be implemented by subclasses in order to visit label vectors and their frequencies.

Parameters:
  • label_vector – An np.ndarray of type uint8, shape (num_relevant_labels) that stores the indices of the relevant labels

  • frequency – The frequency of the label vector

class mlrl.common.cython.output_space_info.NoOutputSpaceInfo

Bases: OutputSpaceInfo

Does not provide any information about the output space.

class mlrl.common.cython.output_space_info.OutputSpaceInfo

Bases: object

Provides information about the output space that may be used as a basis for making predictions.