Thanks to visit codestin.com
Credit goes to github.com

Skip to content

polygon_to_mask_array returns mask with inverted shape #267

@alessiamarcolini

Description

@alessiamarcolini

Describe the bug
polygon_to_mask_array in the util module returns mask with inverted shape

To Reproduce
Steps to reproduce the behavior:

from histolab.util import polygon_to_mask_array
from histolab.types import CoordinatePair

vertices = CoordinatePair(1, 0, 2, 0)
mask = polygon_to_mask_array(dims=(5, 6), vertices=vertices)

mask.shape # (6, 5) instead of (5, 6)

Expected behavior
The shape should be (5, 6).

Metadata

Metadata

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions