class_docstr: Enables different values in a categorical features to have different embeddings.
class_docstr_tok: ["Enables","different","values","in","a","categorical","features","to","have","different","embeddings","."]
code: def __init__(
      self,
      continuous_dim: int,
      categorical_embedding_dims: Tuple[int, int],
      embedding_dropout: float = 0.0,
      batch_norm_continuous_input: bool = False,
      virtual_batch_size: Optional[int] = None,
  ):
      super().__init__()
      self.continuous_dim = continuous_dim
      self.categorical_embedding_dims = categorical_embedding_dims
      self.batch_norm_continuous_input = batch_norm_continuous_input
  
      # Embedding layers
      self.cat_embedding_layers = nn.ModuleList(
          [nn.Embedding(x, y) for x, y in categorical_embedding_dims]
      )
      if embedding_dropout > 0:
          self.embd_dropout = nn.Dropout(embedding_dropout)
      else:
          self.embd_dropout = None
      # Continuous Layers
      if batch_norm_continuous_input:
          self.normalizing_batch_norm = BatchNorm1d(
              continuous_dim, virtual_batch_size
          )
  
imports: import math
  from functools import partial
  from typing import Any, Dict, List, Optional, Tuple
  import torch
  from torch import nn
  from pytorch_tabular.models.common.layers.batch_norm import BatchNorm1d
  from pytorch_tabular.utils import _initialize_kaiming
label_desc: Use image node_id 1 to create a new Embedding1dLayer object from inherited base classes: nn with example: obj = Embedding1dLayer(continuous_dim, categorical_embedding_dims, embedding_dropout, batch_norm_continuous_input, virtual_batch_size)