class_docstr: Responsible for a rectangular partitioning of a global domain,
  which is expressed as the numbers of cells in the different
  spatial directions. The partitioning info is expressed as an
  array of integers, each indicating the number of subdomains in
  one spatial direction.
code: def redim(self, global_num_cells, num_parts):
      nsd_ = len(global_num_cells)
      #        print("Inside the redim function, nsd=%d" %nsd_)
  
      if nsd_ < 1 | nsd_ > 3 | nsd_ != len(num_parts):
          print("The input global_num_cells is not ok!")
          return
  
      self.nsd = nsd_
      self.global_num_cells = global_num_cells
      self.num_parts = num_parts
  
imports: from numpy import ascontiguousarray, frombuffer, zeros
label_desc: Use image node_id 2 for calling the RectPartitioner obj's underlying member method code with example usage: obj.redim(global_num_cells, num_parts) without return types