src.preprocessing.generate_roberta_embedding

Generate the embeddings for the data using a RoBERTa model.

Classes

GenerateRobertaEmbedding(...)

Generate the RoBERTa embeddings for the data.

class src.preprocessing.generate_roberta_embedding.GenerateRobertaEmbedding(pretrained_model_name_or_path)[source]

Generate the RoBERTa embeddings for the data.

Parameters:

pretrained_model_name_or_path (str) – The name or path of the pretrained model.

pretrained_model_name_or_path: str
custom_transform(data, **transform_args)[source]

Generate the RoBERTa embeddings for the data.

Parameters:
  • data (DataFrame) – The data to transform.

  • transform_args (Never) – [UNUSED] Additional keyword arguments.

Return type:

DataFrame

Returns:

The transformed data.