Embedding Layers

[source]

Embedding

polyaxon.layers.embedding.Embedding(mode, input_dim, output_dim, validate_indices=False, weights_init='truncated_normal', trainable=True, restore=True, name='Embedding')

Embedding layer for a sequence of integer ids or floats.

  • Args:
    • mode: str, Specifies if this training, evaluation or prediction. See Modes.
    • input_dim: list of int. Vocabulary size (number of ids).
    • output_dim: list of int. Embedding size.
    • validate_indices: bool. Whether or not to validate gather indices.
    • weights_init: str (name) or Tensor. Weights initialization.
      • Default: 'truncated_normal'.
    • trainable: bool. If True, weights will be trainable.
    • restore: bool. If True, this layer weights will be restored when loading a model.
    • name: A name for this layer (optional). Default: 'Embedding'.