code: def __init__(
      self,
      dataset,
      batch_size,
      chronological=False,
      negativenum=10,
      num_process=5,
      seed=0,
  ):
      self._chronological = chronological
      self._negativenum = negativenum
      if chronological:
          num_process = 1
      random.seed(seed)
      super(NPairwiseSampler, self).__init__(
          dataset=dataset,
          batch_size=batch_size,
          num_process=num_process,
      )
  
file_path: openrec/openrec/tf1/legacy/utils/samplers/n_pairwise_sampler.py
imports: from __future__ import print_function
  import numpy
  import random
  from multiprocessing import Process
  from openrec.tf1.legacy.utils.samplers import Sampler
label_desc: Use image node_id 1 to create a new NPairwiseSampler object from inherited base classes: Sampler with example: obj = NPairwiseSampler(dataset, batch_size, chronological, negativenum, num_process, seed)