code: def update(self):
      if len(_get_input_vars(self.op, only_nonconst_vars=True)) == 2:
          # nothing to update
          return
  
      for input_var in _get_input_vars(self.op):
          if input_var.op and input_var.op.op_type == "const":
              const_input_var = input_var
              break
  
      const_value = const_input_var.val
      if len(const_value.shape) == 0:
          # const is a scalar, no need to modify it
          return
  
      rank = len(self.transpose_axes)
      new_shape = [1] * rank
      new_shape[self.transpose_axes[-1]] = const_value.shape[0]
      new_const_val = np.reshape(const_value, new_shape)
  
      # insert a new constant JUST before the op
      with self.op.enclosing_block:
          new_const_var = mb.const(
              val=new_const_val,
              mode=const_input_var.op.mode,
              before_op=self.op,
          )
  
      self.op.enclosing_block.replace_uses_of_var_after_op(
          anchor_op=new_const_var.op,
          end_op=self.op,
          old_var=const_input_var,
          new_var=new_const_var,
          no_check_var_types=True,
      )
  
imports: from __future__ import print_function
  from __future__ import division
  from __future__ import absolute_import
  from coremltools.converters.mil.mil.passes.pass_registry import register_pass
  from coremltools.converters.mil.mil import Builder
  from coremltools.converters.mil.mil.var import Var
  import logging
  import numpy
  import copy
  from collections import defaultdict
label_desc: Use image node_id 3 for calling the transform_add obj's underlying member method code with example usage: obj.update() without return types