code: def create_byol_resnet_50(
      # Backbone
      backbone_creator: Callable = create_resnet,  # pyre-ignore[24]
      backbone_embed_dim: int = 128,
      head_pool: Callable = nn.AdaptiveAvgPool3d,  # pyre-ignore[24]
      head_output_size: Tuple[int, int, int] = (1, 1, 1),
      head_activation: Callable = None,  # pyre-ignore[9,24]
      dropout_rate: float = 0.0,
      # Projector
      projector_dim_in: int = 2048,
      projector_inner_dim: int = 4096,
      projector_depth: int = 2,
      # Predictor
      predictor_inner_dim: int = 4096,
      predictor_depth: int = 2,
      predictor_norm: Callable = nn.BatchNorm1d,  # pyre-ignore[24]
      projector_norm: Callable = nn.BatchNorm1d,  # pyre-ignore[24]
      mmt: float = 0.99,
  ) -> BYOL:
      """
      Builds a Resnet video backbone, projector and predictors models for
      BYOL SSL task.
      """
  
      def _make_bacbone_and_projector():  # pyre-ignore[3]
          backbone = backbone_creator(
              dropout_rate=dropout_rate,
              head_activation=head_activation,
              head_output_with_global_average=True,
              head_pool=head_pool,
              head_output_size=head_output_size,
          )
  
          backbone.blocks[-1].proj = None  # Overwite head projection
          projector = create_mlp_util(
              projector_dim_in,
              backbone_embed_dim,
              projector_inner_dim,
              projector_depth,
              norm=projector_norm,
          )
          return backbone, projector
  
      backbone, projector = _make_bacbone_and_projector()
      backbone_mmt, projector_mmt = _make_bacbone_and_projector()
  
      predictor = create_mlp_util(
          backbone_embed_dim,
          backbone_embed_dim,
          predictor_inner_dim,
          predictor_depth,
          norm=predictor_norm,
      )
      byol_model = BYOL(
          mmt=mmt,
          backbone=backbone,
          projector=projector,
          predictor=predictor,
          backbone_mmt=backbone_mmt,
          projector_mmt=projector_mmt,
      )
      return byol_model
  
imports: from dataclasses import dataclass
  from typing import Any, Callable, List, Optional, Tuple, Union
  import torch
  import torch.nn
  import torch.nn.functional
  from hydra.core.config_store import ConfigStore
  from omegaconf import MISSING
  from pytorchvideo.models.resnet import create_resnet
  from pytorchvideo.models.weight_init import init_net_weights
  from pytorchvideo_trainer.module.ssl_helper import create_mlp_util, SSLBaseModule
  from pytorchvideo_trainer.module.video_classification import Batch, BatchKey, EnsembleMethod
  from torchrecipes.core.conf import ModuleConf
  from torchrecipes.utils.config_utils import get_class_name_str
label_desc: Use image node_id 1 for calling a global function with example usage: create_byol_resnet_50(backbone_creator, backbone_embed_dim, head_pool, head_output_size, head_activation, dropout_rate, projector_dim_in, projector_inner_dim, projector_depth, predictor_inner_dim, predictor_depth, predictor_norm, projector_norm, mmt) and returns: byol_model, backbone,  projector