Skip to content

Commit

Permalink
Debugging: Ensure that mask is integer after scaling
Browse files Browse the repository at this point in the history
  • Loading branch information
hajicj committed Oct 15, 2018
1 parent 069c7d8 commit 82f9c7b
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions muscima/cropobject.py
Original file line number Diff line number Diff line change
Expand Up @@ -1093,6 +1093,7 @@ def scale(self, zoom=1.0):
output_shape=new_mask_shape)
new_mask[new_mask >= 0.5] = 1
new_mask[new_mask < 0.5] = 0
new_mask = new_mask.astype('uint8')

new_height, new_width = new_mask.shape
new_top = int(self.top * zoom)
Expand Down

0 comments on commit 82f9c7b

Please sign in to comment.