The present disclosure relates to a method for use in adaptive radiotherapy and a treatment planning device. The method may comprise accessing a first medical image and a second medical image that represent a region of interest of a patient at different times. Each medical image is segmented into a target region and at least one non-target region. The method may further comprise accessing a deformation vector field including a plurality of vectors, wherein each vector defines a geometric transformation to map a respective voxel in the first medical image to a corresponding voxel in the second medical image. The method may further comprise generating a modified deformation vector field by: identifying a first vector in the deformation vector field that maps a voxel in the first medical image to a voxel that is in a non-target region in the second medical image; and determining whether the first vector causes a distance between the mapped voxel and the target region to increase and, if so, reducing the magnitude of the first vector. The method may further comprise post-processing the modified deformation vector field to compensate for changes in the shape or size of the target region.