code: def testReduceLocal(self):
      for array, typecode in arrayimpl.loop():
          # segfault as of OpenMPI 4.1.1
          if unittest.is_mpi_gpu("openmpi", array):
              continue
          for op in (MPI.SUM, MPI.PROD, MPI.MAX, MPI.MIN):
              if skip_op(typecode, op):
                  continue
              size = 5
              sbuf = array(range(1, size + 1), typecode)
              rbuf = array(range(0, size + 0), typecode)
              try:
                  op.Reduce_local(sbuf.as_mpi(), rbuf.as_mpi())
              except NotImplementedError:
                  self.skipTest("mpi-op-reduce_local")
              for i, value in enumerate(rbuf):
                  self.assertEqual(sbuf[i], i + 1)
                  if op == MPI.SUM:
                      self.assertAlmostEqual(value, i + (i + 1))
                  elif op == MPI.PROD:
                      self.assertAlmostEqual(value, i * (i + 1))
                  elif op == MPI.MAX:
                      self.assertEqual(value, i + 1)
                  elif op == MPI.MIN:
                      self.assertEqual(value, i)
  
imports: from mpi4py import MPI
  import mpiunittest
  import arrayimpl
  from functools import reduce
label_desc: Use image node_id 1 for calling the TestReduceLocal obj's underlying member method code with example usage: obj.testReduceLocal() without return types