code: def batch_moments_nhwc_ref(self, X):
      dims = X.shape
      C = dims[-1]
      X = X.reshape(-1, C)
      mu = np.mean(X, axis=0)
      var = np.mean(np.square(X), axis=0)
      return [mu, var]
  
file_path: pytorch/caffe2/python/operator_test/batch_moments_op_test.py
imports: from caffe2.python import core
  import caffe2.python.hypothesis_test_util
  import caffe2.python.serialized_test.serialized_test_util
  from hypothesis import given, settings
  import hypothesis.strategies
  import numpy
label_desc: Use image node_id 2 for calling the TestBatchMomentsOp obj's underlying member method code with example usage: obj.batch_moments_nhwc_ref(X) and returns: list