code: def create_x3d_stem(
      *,
      # Conv configs.
      in_channels: int,
      out_channels: int,
      conv_kernel_size: Tuple[int] = (5, 3, 3),
      conv_stride: Tuple[int] = (1, 2, 2),
      conv_padding: Tuple[int] = (2, 1, 1),
      # BN configs.
      norm: Callable = nn.BatchNorm3d,
      norm_eps: float = 1e-5,
      norm_momentum: float = 0.1,
      # Activation configs.
      activation: Callable = nn.ReLU,
  ) -> nn.Module:
      """
      Creates the stem layer for X3D. It performs spatial Conv, temporal Conv, BN, and Relu.
  
      ::
  
                                          Conv_xy
                                             ↓
                                          Conv_t
                                             ↓
                                       Normalization
                                             ↓
                                         Activation
  
      Args:
          in_channels (int): input channel size of the convolution.
          out_channels (int): output channel size of the convolution.
          conv_kernel_size (tuple): convolutional kernel size(s).
          conv_stride (tuple): convolutional stride size(s).
          conv_padding (tuple): convolutional padding size(s).
  
          norm (callable): a callable that constructs normalization layer, options
              include nn.BatchNorm3d, None (not performing normalization).
          norm_eps (float): normalization epsilon.
          norm_momentum (float): normalization momentum.
  
          activation (callable): a callable that constructs activation layer, options
              include: nn.ReLU, nn.Softmax, nn.Sigmoid, and None (not performing
              activation).
  
      Returns:
          (nn.Module): X3D stem layer.
      """
      conv_xy_module = nn.Conv3d(
          in_channels=in_channels,
          out_channels=out_channels,
          kernel_size=(1, conv_kernel_size[1], conv_kernel_size[2]),
          stride=(1, conv_stride[1], conv_stride[2]),
          padding=(0, conv_padding[1], conv_padding[2]),
          bias=False,
      )
      conv_t_module = nn.Conv3d(
          in_channels=out_channels,
          out_channels=out_channels,
          kernel_size=(conv_kernel_size[0], 1, 1),
          stride=(conv_stride[0], 1, 1),
          padding=(conv_padding[0], 0, 0),
          bias=False,
          groups=out_channels,
      )
      stacked_conv_module = Conv2plus1d(
          conv_t=conv_xy_module,
          norm=None,
          activation=None,
          conv_xy=conv_t_module,
      )
  
      norm_module = (
          None
          if norm is None
          else norm(
              num_features=out_channels,
              eps=norm_eps,
              momentum=norm_momentum,
          )
      )
      activation_module = None if activation is None else activation()
  
      return ResNetBasicStem(
          conv=stacked_conv_module,
          norm=norm_module,
          activation=activation_module,
          pool=None,
      )
  
imports: import math
  from typing import Callable, Tuple
  import numpy
  import torch
  import torch.nn
  from fvcore.nn.squeeze_excitation import SqueezeExcitation
  from pytorchvideo.layers.convolutions import Conv2plus1d
  from pytorchvideo.layers.swish import Swish
  from pytorchvideo.layers.utils import round_repeats, round_width, set_attributes
  from pytorchvideo.models.head import ResNetBasicHead
  from pytorchvideo.models.net import Net
  from pytorchvideo.models.resnet import BottleneckBlock, ResBlock, ResStage
  from pytorchvideo.models.stem import ResNetBasicStem
label_desc: Use image node_id 1 for calling a global function with example usage: create_x3d_stem() and returns: ResNetBasicStem