Skip to content

Patch_sampling possible w/ mask_level > max_level#3

Open
trislaz wants to merge 1 commit into
PeterJackNaylor:masterfrom
trislaz:contribution
Open

Patch_sampling possible w/ mask_level > max_level#3
trislaz wants to merge 1 commit into
PeterJackNaylor:masterfrom
trislaz:contribution

Conversation

@trislaz

@trislaz trislaz commented Mar 13, 2020

Copy link
Copy Markdown

When the level of the mask is set to be greater than the number of
levels of the slide (max_level), then get_whole_image immediately adapt
the level to slide.level_count - 1. This commit updates level for the
rest of the procedure in Patch_sampling, otherwise we would get an
error.

When the level of the mask is set to be greater than the number of
levels of the slide (max_level), then get_whole_image immediately adapt
the level to slide.level_count - 1. This commit updates level for the
rest of the procedure in Patch_sampling, otherwise we would get an
error.
@PeterJackNaylor PeterJackNaylor added the enhancement New feature or request label Mar 17, 2020
@PeterJackNaylor

Copy link
Copy Markdown
Owner

Hey,

That is a good idea. Maybe, we could implement something slightly different:
when the resolution is not possible, we are asking a level that is too high, we could just take the lowest resolution of the image (with true_level for instance), and downsample it to the asked resolution.

This could have extra implication, and specifically for the fonctions in utils.py, like get_x_y, get_x_y_from_0, get_size that would have to deal with this too.
How does that sound? do you see have necessary changes? I believe that if we change those functions, all the functions in patch_sampling should remain the same.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants