Thank you for creating this excellent light-weight tool for converting into RTStruct.
One thing we notice is that the current contours are smoothed. In most cases, the centres of voxels are connected (corners excluded). This is fine in most cases, but in some scenarios, we want the exact contour as the mask, i.e. full voxel coverage without any smoothing. We've done some tests using rasterio to create the contour coordinates (instead of using cv2.findContours) and it's doing as expected. It will be good to have a mode that preserve the pixelated corners.
Dear authors,
Thank you for creating this excellent light-weight tool for converting into RTStruct.
One thing we notice is that the current contours are smoothed. In most cases, the centres of voxels are connected (corners excluded). This is fine in most cases, but in some scenarios, we want the exact contour as the mask, i.e. full voxel coverage without any smoothing. We've done some tests using rasterio to create the contour coordinates (instead of using cv2.findContours) and it's doing as expected. It will be good to have a mode that preserve the pixelated corners.
Can I make a pull request to include this mode?
Thanks, Yu Sun