def METHOD_NAME(indices_shape, depth, on_value, off_value, axis, dtype):
    indices = relay.var("indices", relay.TensorType(indices_shape, "int32"))
    depth_var = relay.var("depth", relay.TensorType((), "int32"))
    on_value_const = relay.const(on_value)
    off_value_const = relay.const(off_value)
    out = relay.one_hot(indices, on_value_const, off_value_const, depth_var, axis, dtype)
    func = relay.Function([indices, depth_var], out)
    indices_np = np.random.randint(0, depth, size=indices_shape).astype("int32")
    out_np = tvm.topi.testing.one_hot(indices_np, on_value, off_value, depth, axis, dtype)
    for target, dev in tvm.testing.enabled_targets():
        mod = tvm.ir.IRModule.from_expr(func)
        out_relay = relay.create_executor(
            executor_kind, mod=mod, device=dev, target=target
        ).evaluate()(indices_np, np.array(depth).astype("int32"))
        tvm.testing.assert_allclose(out_relay.numpy(), out_np)