code: def default(self, obj):
      if isinstance(obj, np.integer):
          return int(obj)
      elif isinstance(obj, np.floating):
          return float(obj)
      elif isinstance(obj, np.ndarray):
          return obj.tolist()
      else:
          return super(MyEncoder, self).default(obj)
  
file_path: mace/tools/python/visualize/visualize_model.py
imports: import os
  import json
  import numpy
  from google.protobuf.json_format import _Printer
label_desc: Use image node_id 1 for calling the NPEncoder obj's underlying member method code with example usage: obj.default(obj) and returns: int, float, obj, super