uni-medical / SAM-Med3D

SAM-Med3D: An Efficient General-purpose Promptable Segmentation Model for 3D Volumetric Medical Image
Apache License 2.0
427 stars 56 forks source link

Adds new click methods and inference script for running inference with no label masks #65

Closed k-chrispens closed 2 months ago

k-chrispens commented 2 months ago

Addresses #22 #62 and somewhat #64

Makes a new dataset class (Dataset_Union_ALL_Infer) that doesn't return labels for using during inference.

Implements new click methods (get_next_click3D_torch_no_gt and get_next_click3D_torch_no_gt_naive) that allow naive inference - these generate point prompts based on image thresholding and random selection of points in the volume.

The infer_sequence.py and infer_sequence.sh are built to use these to allow inference with no label mask.

k-chrispens commented 2 months ago

It would be useful to think of better methods for automatically selecting point prompts - both click methods I implemented are quite basic. I've seen decent results for my implementation in ultrasound segmentation though!

adrianzzk commented 2 months ago

what a great job!I also think the method based on image thresholding is a really good way to click points.Its more like human to click points.