def METHOD_NAME():
    im_arr = ImageArray(dummy_image(10.0, 4))
    new_im = im_arr.rescale(inline=False)
    assert_equal(im_arr[:, :, :3].max(), 2 * 10.0)
    assert_equal(im_arr[:, :, 3].max(), 3 * 10.0)
    assert_equal(new_im[:, :, :3].sum(axis=2).max(), 1.0)
    assert_equal(new_im[:, :, 3].max(), 1.0)
    im_arr.rescale()
    assert_equal(im_arr[:, :, :3].sum(axis=2).max(), 1.0)
    assert_equal(im_arr[:, :, 3].max(), 1.0)
    im_arr.rescale(cmax=0.0, amax=0.0)
    assert_equal(im_arr[:, :, :3].sum(axis=2).max(), 1.0)
    assert_equal(im_arr[:, :, 3].max(), 1.0)