class_docstr: This loss allows to distill a SwAV model
class_docstr_tok: ["This","loss","allows","to","distill","a","SwAV","model"]
docstr: Append elements at the beginning of the local_queue
docstr_tok: ["Append","elements","at","the","beginning","of","the","local_queue"]
code: def add_to_teacher_scores_queue(self, scores: torch.Tensor):
      """
      Append elements at the beginning of the local_queue
      """
      with torch.no_grad():
          bs = scores.shape[0]
          queue = self.local_queue
          queue[bs:] = queue[:-bs].clone()
          queue[:bs] = scores
          self.local_queue = queue
          self.local_queue_length = min(
              self.local_queue_length + bs, self.local_queue_max_length
          )
  
imports: import logging
  import os
  import pprint
  from typing import List, Optional, Union
  import numpy
  import torch
  import torch.nn.functional
  from classy_vision.generic.distributed_util import all_reduce_max, get_cuda_device_index, get_rank, get_world_size
  from classy_vision.losses import ClassyLoss, register_loss
  from fvcore.common.file_io import PathManager
  from torch import nn
  from vissl.config import AttrDict
  from vissl.losses.distibuted_sinkhornknopp import distributed_sinkhornknopp
label_desc: Use image node_id 3 for calling the SwAVDistillationCriterion obj's underlying member method code with example usage: obj.add_to_teacher_scores_queue(scores) without return types