besskge.embedding.init_KGE_uniform

besskge.embedding.init_KGE_uniform(embedding_table, b=1.0, divide_by_embedding_size=True)[source]

Initialize embeddings according to symmetric uniform distribution.

Parameters:
  • embedding_table (Tensor) – Tensor of embedding parameters to initialize.

  • b (float) – Positive boundary of distribution support. Default: 1.0.

  • divide_by_embedding_size (bool) – Rescale distribution support by 1/row_size. Default: True.

Return type:

Tensor

Returns:

Initialized tensor.