CompGCN

class CompGCN(*, triples_factory: CoreTriplesFactory, embedding_dim: int = 64, encoder_kwargs: Mapping[str, Any] | None = None, interaction: str | Interaction[Tensor, RelationRepresentation, Tensor] | None = None, interaction_kwargs: Mapping[str, Any] | None = None, **kwargs)[source]

Bases: ERModel[Tensor, RelationRepresentation, Tensor]

An implementation of CompGCN from [vashishth2020].

This model uses graph convolutions, and composition functions.

Initialize the model.

Parameters:
  • triples_factory (CoreTriplesFactory) – The triples factory.

  • embedding_dim (int) – The embedding dimension to be used if embedding_specification is not given explicitly in encoder_kwargs.

  • encoder_kwargs (Mapping[str, Any] | None) – Additional keyword arguments for the encoder, cf. CombinedCompGCNRepresentations.

  • interaction (Interaction) – The interaction function to use as decoder.

  • interaction_kwargs (Mapping[str, Any] | None) – Additional keyword based arguments for the interaction function.

  • kwargs – Additional keyword based arguments passed to ERModel.

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': 512, 'low': 32, 'q': 32, 'type': <class 'int'>}}

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