class_docstr: The class is used to feed data with some process from a reader into a
  queue and provider a reader interface for data fetching from the queue.
docstr: Build the producer_step to feed data from reader into the queue, and
  return the reader interface.
  Inputs:
      reader:           read data which will be stored in the queue.
      process:          preprocess data before enqueue.
  Outputs:
      reader:           reader to fetch the data from the queue.
      producer_step:    the step insert the data into the queue. Should be
                        run with comsume_step together.
      exit_step:        the step to close queue
      schema:           the schema for the reader.
docstr_tok: ["Build","the","producer_step","to","feed","data","from","reader","into","the","queue",",","and","return","the","reader","interface",".","Inputs",":","reader",":","read","data","which","will","be","stored","in","the","queue",".","process",":","preprocess","data","before","enqueue",".","Outputs",":","reader",":","reader","to","fetch","the","data","from","the","queue",".","producer_step",":","the","step","insert","the","data","into","the","queue",".","Should","be","run","with","comsume_step","together",".","exit_step",":","the","step","to","close","queue","schema",":","the","schema","for","the","reader","."]
code: def build(self, reader, process=None):
      """
      Build the producer_step to feed data from reader into the queue, and
      return the reader interface.
      Inputs:
          reader:           read data which will be stored in the queue.
          process:          preprocess data before enqueue.
      Outputs:
          reader:           reader to fetch the data from the queue.
          producer_step:    the step insert the data into the queue. Should be
                            run with comsume_step together.
          exit_step:        the step to close queue
          schema:           the schema for the reader.
      """
      producer_steps = []
      for i in range(self.num_threads):
          name = "reader_" + str(i)
          net_reader = core.Net(name)
          should_stop, fields = reader.read_record(net_reader)
          step_read = core.execution_step(name, net_reader)
  
          name = "queue_writer" + str(i)
          net_prod = core.Net(name)
          field_blobs = fields.field_blobs()
          if process:
              field_blobs = process(net_prod, fields).field_blobs()
  
          self.writer.write(net_prod, field_blobs)
          step_prod = core.execution_step(name, net_prod)
          step = core.execution_step(
              "producer_" + str(i),
              [step_read, step_prod],
              should_stop_blob=should_stop,
          )
          producer_steps.append(step)
      producer_step = core.execution_step(
          "producers", producer_steps, concurrent_substeps=True
      )
      return self.reader, producer_step, self.exit_step, self.schema
  
file_path: pytorch/caffe2/python/record_queue.py
imports: from caffe2.python import core
  from caffe2.python.dataio import Reader, Writer
  from caffe2.python.schema import Struct, Field, from_column_list
label_desc: Use image node_id 2 for calling the RecordQueue obj's underlying member method code with example usage: obj.build(reader, process) and returns: self,  producer_step,  self,  self