A fine-tuning dataset adapts a pretrained model to a new task or labeling scheme. For CT segmentation, it pairs CT scan slices with nodule masks so a lightweight model can learn automatic segmentation without prompts. section 15.6.3
A practical fine-tuning dataset includes:
- Input images, such as two-dimensional CT scan slices. section 15.6.3 section 15.6.2
- Target labels, such as masks identifying the nodules to segment. section 15.6.3
- Metadata linking image files and masks with information such as series identifiers and candidate locations. section 15.6.3
- A clear storage arrangement, such as separate folders for CT images and masks. section 15.6.3
Generating a CT segmentation dataset
A pretrained SAM model receives a CT slice and a point marking a candidate nodule, then generates a mask. The CT slice and mask become a training pair for fine-tuning SegFormer. This produces a cheaper alternative to manually annotating every scan. section 15.6.3
Listing 15.7 Setting up directory structure for our new dataset
fine_tuning_dir = "data-unversioned/part2/fine-tuning/dataset"
ct_folder = f"{fine_tuning_dir}/ct"
mask_folder = f"{fine_tuning_dir}/mask"
Shows the compact directory layout used for CT images and masks. section 15.6.3
