docstr: Input:
      main(%x: (1, 3, 20, fp32)(Tensor)) {
        block0() {
          %var_1!: (1, 3, 20, fp32)(Tensor) = relu(x=%x, name="var_1!")
          %1: (1, 3, 20, fp32)(Tensor) = relu(x=%x, name="1")
          %3: (1, 3, 20, fp32)(Tensor) = add(x=%Var_1!, y=%1, name="3")
        } -> (%3)
      }
  
  Output:
      main(%x: (1, 3, 20, fp32)(Tensor)) {
        block0() {
          %var_1_: (1, 3, 20, fp32)(Tensor) = relu(x=%x, name="var_1_")
          %var_1: (1, 3, 20, fp32)(Tensor) = relu(x=%x, name="op_1")
          %var_3: (1, 3, 20, fp32)(Tensor) = add(x=%var_1_, y=%var_1, name="op_3")
        } -> (%var_3)
      }
docstr_tok: ["Input",":","main","(","%","x",":","(","1",",","3",",","20",",","fp32",")","(","Tensor",")",")","{","block0","(",")","{","%","var_1","!",":","(","1",",","3",",","20",",","fp32",")","(","Tensor",")","=","relu","(","x=","%","x",",","name=","''","var_1","!","''",")","%","1",":","(","1",",","3",",","20",",","fp32",")","(","Tensor",")","=","relu","(","x=","%","x",",","name=","''","1","''",")","%","3",":","(","1",",","3",",","20",",","fp32",")","(","Tensor",")","=","add","(","x=","%","Var_1","!",",","y=","%","1",",","name=","''","3","''",")","}","-",">","(","%","3",")","}","Output",":","main","(","%","x",":","(","1",",","3",",","20",",","fp32",")","(","Tensor",")",")","{","block0","(",")","{","%","var_1_",":","(","1",",","3",",","20",",","fp32",")","(","Tensor",")","=","relu","(","x=","%","x",",","name=","''","var_1_","''",")","%","var_1",":","(","1",",","3",",","20",",","fp32",")","(","Tensor",")","=","relu","(","x=","%","x",",","name=","''","op_1","''",")","%","var_3",":","(","1",",","3",",","20",",","fp32",")","(","Tensor",")","=","add","(","x=","%","var_1_",",","y=","%","var_1",",","name=","''","op_3","''",")","}","-",">","(","%","var_3",")","}"]
code: def test_sanitize_numeric_var_names(self):
      """
      Input:
          main(%x: (1, 3, 20, fp32)(Tensor)) {
            block0() {
              %var_1!: (1, 3, 20, fp32)(Tensor) = relu(x=%x, name="var_1!")
              %1: (1, 3, 20, fp32)(Tensor) = relu(x=%x, name="1")
              %3: (1, 3, 20, fp32)(Tensor) = add(x=%Var_1!, y=%1, name="3")
            } -> (%3)
          }
  
      Output:
          main(%x: (1, 3, 20, fp32)(Tensor)) {
            block0() {
              %var_1_: (1, 3, 20, fp32)(Tensor) = relu(x=%x, name="var_1_")
              %var_1: (1, 3, 20, fp32)(Tensor) = relu(x=%x, name="op_1")
              %var_3: (1, 3, 20, fp32)(Tensor) = add(x=%var_1_, y=%var_1, name="op_3")
            } -> (%var_3)
          }
  
      """
  
      @mb.program(input_specs=[mb.TensorSpec(shape=(1, 3, 20))])
      def prog(x):
          y1 = mb.relu(x=x, name="var_1!")
          y2 = mb.relu(x=x, name="1")
          z = mb.add(x=y1, y=y2, name="3")
          return z
  
      PASS_REGISTRY["mil_backend::sanitize_name_strings"](prog)
      block = prog.functions["main"]
      assert (
          block.find_ops(op_type="relu")[0].outputs[0].name == "var_1_"
      )
      assert (
          block.find_ops(op_type="relu")[1].outputs[0].name == "var_1"
      )
      assert prog["main"].outputs[0].name == "var_3"
      assert block.find_ops(op_type="relu")[0].name == "var_1_"
      assert block.find_ops(op_type="relu")[1].name == "op_1"
      assert block.find_ops(op_type="add")[0].name == "op_3"
  
imports: import copy
  import itertools
  import numpy
  import pytest
  import coremltools
  from coremltools.converters.mil._deployment_compatibility import AvailableTarget
  from coremltools.converters.mil.mil import Builder
  from coremltools.converters.mil.mil import types
  from coremltools.converters.mil.mil.passes.pass_registry import PASS_REGISTRY
  from coremltools.converters.mil.testing_utils import apply_pass_and_basic_check, assert_model_is_valid, get_op_types_in_program
label_desc: Use image node_id 1 for calling the TestSanitizerPass obj's underlying member method code with example usage: obj.test_sanitize_numeric_var_names() and returns: z