TargetPredictions

class TargetPredictions(df: DataFrame, factory: CoreTriplesFactory | None, target: Literal['head', 'relation', 'tail'], other_columns_fixed_ids: tuple[int, int])[source]

Bases: Predictions

Targets with their predicted scores.

Attributes Summary

df

the dataframe; has to have a column named "score"

factory

an optional factory to use for labeling

other_columns_fixed_ids

the other column's fixed IDs

target

the prediction target

Attributes Documentation

Parameters:
df: DataFrame = <dataclasses._MISSING_TYPE object>

the dataframe; has to have a column named “score”

factory: CoreTriplesFactory | None = <dataclasses._MISSING_TYPE object>

an optional factory to use for labeling

other_columns_fixed_ids: tuple[int, int] = <dataclasses._MISSING_TYPE object>

the other column’s fixed IDs

target: Literal['head', 'relation', 'tail'] = <dataclasses._MISSING_TYPE object>

the prediction target