class CompGCN(*, triples_factory, embedding_dim=64, encoder_kwargs=None, interaction=None, interaction_kwargs=None, **kwargs)[source]

Bases: pykeen.models.nbase.ERModel[torch.FloatTensor, pykeen.typing.RelationRepresentation, torch.FloatTensor]

An implementation of CompGCN from [vashishth2020].

This model uses graph convolutions, and composition functions.

Initialize the model.

  • 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 (Optional[Mapping[str, Any]]) – Additional keyword arguments for the encoder, cf. pykeen.nn.emb.CombinedCompGCNRepresentations.

  • interaction (Union[str, Interaction[FloatTensor, ~RelationRepresentation, FloatTensor], None]) – The interaction function to use as decoder.

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

  • kwargs – Additional keyword based arguments passed to pykeen.models.ERModel.

Attributes Summary


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