def METHOD_NAME(
    subject,
    index_ini: TypeTripletInt,
    patch_size: TypeSpatialShape,
):
    from ...transforms.preprocessing.spatial.crop import Crop
    shape = np.array(subject.spatial_shape, dtype=np.uint16)
    index_ini_array = np.array(index_ini, dtype=np.uint16)
    patch_size_array = np.array(patch_size, dtype=np.uint16)
    assert len(index_ini_array) == 3
    assert len(patch_size_array) == 3
    index_fin = index_ini_array + patch_size_array
    crop_ini = index_ini_array.tolist()
    crop_fin = (shape - index_fin).tolist()
    start = ()
    cropping = sum(zip(crop_ini, crop_fin), start)
    return Crop(cropping)  # type: ignore[arg-type]