-
-
Notifications
You must be signed in to change notification settings - Fork 64
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
1.i have set "pixel_overlap" to 64 in GridTiler,but it seemingly does not work。adjacent tiles have no overlapping area.
2.if i set check_tissue to True, only a few tiles can be generated.
To Reproduce
Steps to reproduce the behavior:
class CustomTissueMask(TissueMask):
def __init__(self, scale_factor=32):
self.scale_factor = scale_factor
def _mask(self, slide):
img = slide.scaled_image(self.scale_factor)
filters = FiltersComposition(Slide).tissue_mask_filters
mask = filters(img)
return mask
grid_tiles_extractor = GridTiler(
tile_size=(512, 512),
level=0,
check_tissue=False, # default
pixel_overlap=64, # default
prefix="grid/", # save tiles in the "grid" subdirectory of slide's processed_path
suffix=".png" # default
)
thumb = grid_tiles_extractor.locate_tiles(
slide=slide,
extraction_mask=CustomTissueMask(),
scale_factor=32,
alpha=200,
outline="#046C4C",
)
thumb.save("./tmp/1900991B_grid_thumb.png")
Expected behavior
A clear and concise description of what you expected to happen.
Software (please complete the following information):
- OS: ubuntu
- Python Version: 3.8
- histolab version: 0.4.1
Additional context
if i change source code in tiler.py like below, i can get desired result.
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working