Rate this Page

Class Embedding#

Inheritance Relationships#

Base Type#

Class Documentation#

class Embedding : public torch::nn::ModuleHolder<EmbeddingImpl>#

A ModuleHolder subclass for EmbeddingImpl.

See the documentation for EmbeddingImpl class to learn what methods it provides, and examples of how to use Embedding with torch::nn::EmbeddingOptions. See the documentation for ModuleHolder to learn about PyTorch’s module storage semantics.

Public Static Functions

static inline Embedding from_pretrained(const torch::Tensor &embeddings, const EmbeddingFromPretrainedOptions &options = {})#

See the documentation for torch::nn::EmbeddingFromPretrainedOptions class to learn what optional arguments are supported for this function.