Skip to content

Commit

Permalink
squeeze output map
Browse files Browse the repository at this point in the history
  • Loading branch information
alexriedel1 committed Jun 21, 2023
1 parent b84d753 commit 7188bf7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/anomalib/models/components/base/anomaly_module.py
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ def _collect_outputs(
image_metric.update(output["pred_scores"], output["label"].int())
if "mask" in output.keys() and "anomaly_maps" in output.keys():
pixel_metric.cpu()
pixel_metric.update(output["anomaly_maps"], output["mask"].int())
pixel_metric.update(torch.squeeze(output["anomaly_maps"]), output["mask"].int())

@staticmethod
def _post_process(outputs: STEP_OUTPUT) -> None:
Expand Down

0 comments on commit 7188bf7

Please sign in to comment.