code: def get_world_size() -> int:
      """
      Simple wrapper for correctly getting worldsize in both distributed
      / non-distributed settings
      """
      return (
          torch.distributed.get_world_size()
          if torch.distributed.is_available()
          and torch.distributed.is_initialized()
          else 1
      )
  
file_path: pytorchvideo/pytorchvideo/layers/distributed.py
imports: import torch
  import torch.distributed
  from torch._C._distributed_c10d import ProcessGroup
  from torch.autograd.function import Function
label_desc: Use image node_id 1 for calling a global function with example usage: get_world_size() and returns: unknown