code: def test_vectorize_with_if():
      n = te.var("n")
      x = te.var("x")
      ib = tvm.tir.ir_builder.create()
      A = ib.pointer("float32", name="A")
      with ib.for_range(0, 4, kind="vectorize") as i:
          with ib.if_scope(x < n):
              A[i] = A[i] + 1
          with ib.else_scope():
              with ib.if_scope(i < n):
                  A[i] = 2.0
      stmt = ib.get()
  
      mod = tvm.IRModule.from_expr(tvm.tir.PrimFunc([A, n, x], stmt))
      stmt = tvm.tir.transform.VectorizeLoop()(mod)["main"].body
  
      assert isinstance(stmt, tvm.tir.IfThenElse)
      assert len(stmt.then_case.indices) == 1
      assert isinstance(stmt.then_case.indices[0], tvm.tir.Ramp)
      assert isinstance(stmt.then_case.value, tvm.tir.Add)
      assert stmt.then_case.value.dtype == "float32x4"
      assert isinstance(stmt.else_case, tvm.tir.For)
  
file_path: tvm/tests/python/tir-transform/test_tir_transform_vectorize.py
imports: import tvm
  from tvm import te
label_desc: Use image node_id 3 for calling a global function with example usage: test_vectorize_with_if() without return types