class_docstr: support sync of multiple gpus/nodes.
class_docstr_tok: ["support","sync","of","multiple","gpus\/nodes","."]
code: def __init__(self, config):
      super().__init__(config)
      self.out_dir = os.path.join(
          config.fairseq.checkpoint.save_dir, "retri"
      )
      os.makedirs(self.out_dir, exist_ok=True)
      self.hidden_states = []
      self.video_ids = []
  
imports: import torch
  import os
  import numpy
  import pickle
  from .None import retri
  from ..utils import get_local_rank
label_desc: Use image node_id 1 to create a new DistributedVectorPool object from inherited base classes: VectorPool with example: obj = DistributedVectorPool(config)