Skip to content

Commit

Permalink
Fix coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
ashnair1 committed Nov 9, 2024
1 parent f30e697 commit d60d6fb
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion tests/datasets/test_vhr10.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ def test_plot(self, dataset: VHR10) -> None:
x['prediction_labels'] = x['class']
x['prediction_boxes'] = x['bbox_xyxy']
x['prediction_scores'] = torch.Tensor([scores[i]])
if 'masks' in x:
if 'mask' in x:
x['prediction_masks'] = x['mask']
dataset.plot(x, show_feats='masks')
plt.close()
2 changes: 1 addition & 1 deletion torchgeo/datasets/vhr10.py
Original file line number Diff line number Diff line change
Expand Up @@ -459,7 +459,7 @@ def plot(
)

# Add masks
if show_feats in {'masks', 'both'} and 'masks' in sample:
if show_feats in {'masks', 'both'} and 'mask' in sample:
mask = masks[i]
contours = skimage.measure.find_contours(mask, 0.5)
for verts in contours:
Expand Down

0 comments on commit d60d6fb

Please sign in to comment.