mahmoodlab / CLAM

Open source tools for computational pathology - Nature BME
http://clam.mahmoodlab.org
GNU General Public License v3.0
1.13k stars 365 forks source link

Patch levels #278

Open suminwei opened 3 weeks ago

suminwei commented 3 weeks ago

Hi, I just wanted to double check how to properly set patch_level and seg_level when running create_patches_fp.py. If I have an svs file with the following pyramid levels: Base (40x), level 1 (10x; 4x downsample), level 2 (1.5x; 16x downsample). What does seg_level=-1 mean in this case for image segmentation? What other possible values could seg_level take on for this file? I understand patch_level=0 means patch extraction will be performed at the highest resolution, in this case 40x. What other values could patch_level take on for this file? Would they be 1and 2 for levels 1 and 2? Thank you!

fedshyvana commented 3 weeks ago

Seg level can usually be safely left at -1 yes (it will choose one of the downsampled levels to speed up processing and should not affect the result of patching much). For patch_level, you are right that 0,1,2,3... will each correspond to a pyramid level in your file, with 0 being the highest, 1 being the second highest, etc.

suminwei commented 3 weeks ago

Thank you!!