jeremyLE-Ekimetrics commited on
Commit
4a6f2fb
·
1 Parent(s): 735264e

Update biomap/utils.py

Browse files
Files changed (1) hide show
  1. biomap/utils.py +2 -2
biomap/utils.py CHANGED
@@ -77,8 +77,8 @@ def transform_to_pil(outputs, alpha=0.3):
77
  # Transform label by saving it then open it
78
  label = outputs["linear_preds"][0].numpy()
79
  # image_label = Image.fromarray(label, mode="P")
80
- plt.imsave("output/label.png", label, cmap=cmap)
81
- image_label = Image.open("output/label.png")
82
  # Overlay labels with img wit alpha
83
  background = img.convert("RGBA")
84
  overlay = image_label.convert("RGBA")
 
77
  # Transform label by saving it then open it
78
  label = outputs["linear_preds"][0].numpy()
79
  # image_label = Image.fromarray(label, mode="P")
80
+ plt.imsave("label.png", label, cmap=cmap)
81
+ image_label = Image.open("label.png")
82
  # Overlay labels with img wit alpha
83
  background = img.convert("RGBA")
84
  overlay = image_label.convert("RGBA")