class_docstr: The criterion corresponding to the SimCLR loss as defined in the paper
  https://arxiv.org/abs/2002.05709.
  
  Args:
      temperature (float): the temperature to be applied on the logits
      buffer_params:
          world_size (int): total number of trainers in training
          embedding_dim (int): output dimensions of the features projects
          effective_batch_size (int): total batch size used (includes positives)
class_docstr_tok: ["The","criterion","corresponding","to","the","SimCLR","loss","as","defined","in","the","paper","https",":","\/\/arxiv.org\/abs\/2002.05709",".","Args",":","temperature","(","float",")",":","the","temperature","to","be","applied","on","the","logits","buffer_params",":","world_size","(","int",")",":","total","number","of","trainers","in","training","embedding_dim","(","int",")",":","output","dimensions","of","the","features","projects","effective_batch_size","(","int",")",":","total","batch","size","used","(","includes","positives",")"]
code: def __init__(self, buffer_params, temperature: float):
      super(SimclrInfoNCECriterion, self).__init__()
  
      self.use_gpu = get_cuda_device_index() > -1
      self.temperature = temperature
      self.num_pos = 2
      self.buffer_params = buffer_params
      self.criterion = nn.CrossEntropyLoss()
      self.dist_rank = get_rank()
      self.pos_mask = None
      self.neg_mask = None
      self.precompute_pos_neg_mask()
      logging.info(f"Creating Info-NCE loss on Rank: {self.dist_rank}")
  
imports: import logging
  import pprint
  import numpy
  import torch
  from classy_vision.generic.distributed_util import get_cuda_device_index, get_rank
  from classy_vision.losses import ClassyLoss, register_loss
  from torch import nn
  from vissl.config import AttrDict
  from vissl.utils.distributed_utils import gather_from_all
label_desc: Use image node_id 1 to create a new SimclrInfoNCECriterion object from inherited base classes: nn with example: obj = SimclrInfoNCECriterion(buffer_params, temperature)