We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ce093f7 commit a9310a3Copy full SHA for a9310a3
cellseg_models_pytorch/inference/post_processor.py
@@ -370,10 +370,10 @@ def _prepare_inst_maps(
370
prob_maps = soft_masks.binary_map
371
else:
372
prob_maps = soft_masks.type_map
373
-
374
prob_maps = prob_maps.squeeze(1)
375
376
- inst_maps = list(self._to_ndarray(prob_maps, dtype="i4"))
+ inst_dtype = "i4" if soft_masks.binary_map is None else "f4"
+ inst_maps = list(self._to_ndarray(prob_maps, dtype=inst_dtype))
377
aux_maps = list(self._to_ndarray(soft_masks.aux_map, dtype="f4"))
378
type_maps = list(self._to_ndarray(soft_masks.type_map, dtype="i4"))
379
0 commit comments