class_docstr: Transformer backend wih Huggingface transformer models
class_docstr_tok: ["Transformer","backend","wih","Huggingface","transformer","models"]
docstr: Generate multimodal embeddings.
docstr_tok: ["Generate","multimodal","embeddings","."]
code: def generate_embeddings(
      self,
      tokens_ids: Dict[str, Tensor],
      position_ids: Dict[str, Tensor],
      segment_ids: Dict[str, Tensor],
      attention_mask: Tensor,
  ) -> Tensor:
      """Generate multimodal embeddings."""
      return self.embeddings(
          tokens_ids=tokens_ids,
          position_ids=position_ids,
          segment_ids=segment_ids,
      )
  
imports: from copy import deepcopy
  from typing import Any, Dict, List, Type
  import torch
  from mmf.common.registry import registry
  from mmf.models.transformers.base import BaseTransformer, BaseTransformerBackend
  from mmf.modules.hf_layers import BertModelJit, replace_with_jit
  from omegaconf import OmegaConf
  from torch import nn, Tensor
label_desc: Use image node_id 6 for calling the HuggingfaceBackend obj's underlying member method code with example usage: obj.generate_embeddings(tokens_ids, position_ids, segment_ids, attention_mask) and returns: self