TransF

class TransF(embedding_dim: int = 128, entity_initializer: str | Callable[[Tensor], Tensor] | None = None, entity_initializer_kwargs: Mapping[str, Any] | None = None, entity_normalizer: str | Callable[[Tensor], Tensor] | None = None, entity_normalizer_kwargs: Mapping[str, Any] | None = None, relation_initializer: str | Callable[[Tensor], Tensor] | None = None, relation_initializer_kwargs: Mapping[str, Any] | None = None, **kwargs)[source]

Bases: ERModel[Tensor, Tensor, Tensor]

An implementation of TransF from [feng2016].

This model represents both entities and relations as \(d\)-dimensional vectors stored in an Embedding matrix. The representations are then passed to the TransFInteraction function to obtain scores.

Initialize the model.

Parameters:

Attributes Summary

hpo_default

The default strategy for optimizing the model's hyper-parameters

Attributes Documentation

hpo_default: ClassVar[Mapping[str, Any]] = {'embedding_dim': {'high': 256, 'low': 16, 'q': 16, 'type': <class 'int'>}}

The default strategy for optimizing the model’s hyper-parameters