def METHOD_NAME(variant_scalar_rgb):
    f = mi.load_dict({'type': 'box'})
    a = dr.linspace(Float, 0, 1, 5)
    b = dr.zeros(Float, 5)
    # Resample to same size
    resampler = mi.Resampler(f, 5, 5)
    assert resampler.taps() == 1
    resampler.resample(a, 1, b, 1, 1)
    # Resample to smaller size
    resampler = mi.Resampler(f, 5, 3)
    b = dr.zeros(Float, 3)
    assert resampler.taps() == 2
    resampler.resample(a, 1, b, 1, 1)
    assert dr.all(b == [0.125, 0.5, 0.875])
    # Resample to larger size
    a = dr.linspace(Float, 0, 1, 2)
    resampler = mi.Resampler(f, 2, 3)
    b = dr.zeros(Float, 3)
    assert resampler.taps() == 1
    resampler.resample(a, 1, b, 1, 1)
    assert dr.all(b == [0.0, 1.0, 1.0])