class_docstr: This is a base class used to create Caffe2 operator benchmark
class_docstr_tok: ["This","is","a","base","class","used","to","create","Caffe2","operator","benchmark"]
docstr: A wapper function to create C2 tensor filled with random data.
  The name/label of the tensor is returned and it is available
  throughout the benchmark execution phase.
  Args:
      shapes: int or a sequence of ints to defining the shapes of the tensor
      dtype: use the dtypes from numpy
          (https://docs.scipy.org/doc/numpy/user/basics.types.html)
  Return:
      C2 tensor of dtype
docstr_tok: ["A","wapper","function","to","create","C2","tensor","filled","with","random","data",".","The","name\/label","of","the","tensor","is","returned","and","it","is","available","throughout","the","benchmark","execution","phase",".","Args",":","shapes",":","int","or","a","sequence","of","ints","to","defining","the","shapes","of","the","tensor","dtype",":","use","the","dtypes","from","numpy","(","https",":","\/\/docs.scipy.org\/doc\/numpy\/user\/basics.types.html",")","Return",":","C2","tensor","of","dtype"]
code: def tensor(self, shapes, dtype="float32", device="cpu"):
      """A wapper function to create C2 tensor filled with random data.
      The name/label of the tensor is returned and it is available
      throughout the benchmark execution phase.
      Args:
          shapes: int or a sequence of ints to defining the shapes of the tensor
          dtype: use the dtypes from numpy
              (https://docs.scipy.org/doc/numpy/user/basics.types.html)
      Return:
          C2 tensor of dtype
      """
      return self.feed_tensor(
          benchmark_utils.numpy_random(dtype, *shapes), device
      )
  
imports: from collections import namedtuple
  import benchmark_utils
  from benchmark_test_generator import _register_test
  from caffe2.proto import caffe2_pb2
  from caffe2.python import core, workspace
  from .benchmark_core import TestConfig
label_desc: Use image node_id 4 for calling the Caffe2BenchmarkBase obj's underlying member method code with example usage: obj.tensor(shapes, dtype, device) and returns: self