def METHOD_NAME(vector_width, target):
    # print("target is %s " % str(target))
    W = 32
    H = 32
    input = hl.Buffer(hl.UInt(8), [W, H])
    for r in range(H):
        for c in range(W):
            input[c, r] = (c + r * W) & 0xFF
    input_f = hl.Func()
    input_f[x, y] = input[x, y]
    tests = [
        (hl.BoundaryConditions.constant_exterior, check_constant_exterior),
        (hl.BoundaryConditions.repeat_edge, check_repeat_edge),
        (hl.BoundaryConditions.repeat_image, check_repeat_image),
        (hl.BoundaryConditions.mirror_image, check_mirror_image),
        (hl.BoundaryConditions.mirror_interior, check_mirror_interior),
    ]
    for bc, checker in tests:
        # print('  Testing %s:%d...' % (bc.__name__, vector_width))
        func_input_args = {"f": input_f, "bounds": [(0, W), (0, H)]}
        image_input_args = {"f": input, "bounds": [(0, W), (0, H)]}
        undef_min_args = {"f": input, "bounds": [(hl.Expr(), hl.Expr()), (0, H)]}
        undef_max_args = {"f": input, "bounds": [(0, W), (hl.Expr(), hl.Expr())]}
        implicit_bounds_args = {"f": input}
        if bc == hl.BoundaryConditions.constant_exterior:
            func_input_args["exterior"] = test_exterior
            image_input_args["exterior"] = test_exterior
            undef_min_args["exterior"] = test_exterior
            undef_max_args["exterior"] = test_exterior
            implicit_bounds_args["exterior"] = test_exterior
        realize_and_check(
            bc(**func_input_args),
            checker,
            input,
            test_min,
            test_extent,
            test_min,
            test_extent,
            vector_width,
            target,
        )
        realize_and_check(
            bc(**image_input_args),
            checker,
            input,
            test_min,
            test_extent,
            test_min,
            test_extent,
            vector_width,
            target,
        )
        realize_and_check(
            bc(**undef_min_args),
            checker,
            input,
            0,
            W,
            test_min,
            test_extent,
            vector_width,
            target,
        )
        realize_and_check(
            bc(**undef_max_args),
            checker,
            input,
            test_min,
            test_extent,
            0,
            H,
            vector_width,
            target,
        )
        realize_and_check(
            bc(**implicit_bounds_args),
            checker,
            input,
            test_min,
            test_extent,
            test_min,
            test_extent,
            vector_width,
            target,
        )