Spaces:
Sleeping
Sleeping
Update Organoid_Analyzer_AI2_HF.py
Browse files
Organoid_Analyzer_AI2_HF.py
CHANGED
|
@@ -271,7 +271,7 @@ def main(args):
|
|
| 271 |
if len(colonies) <=0:
|
| 272 |
img = pad(np.array(args[0]))
|
| 273 |
caption = np.ones((150, 2048, 3), dtype=np.uint8) * 255 # Multiply by 255 to make it white
|
| 274 |
-
cv2.putText(caption, 'No
|
| 275 |
cv2.imwrite('results.png', np.vstack((img, caption)))
|
| 276 |
colonies = pd.DataFrame({"organoid_number":[], 'organoid_volume':[], "organoid_area":[],'mean_pixel_value':[], "centroid":[], "necrotic_area":[],"percent_necrotic":[]})
|
| 277 |
with pd.ExcelWriter('results.xlsx') as writer:
|
|
|
|
| 271 |
if len(colonies) <=0:
|
| 272 |
img = pad(np.array(args[0]))
|
| 273 |
caption = np.ones((150, 2048, 3), dtype=np.uint8) * 255 # Multiply by 255 to make it white
|
| 274 |
+
cv2.putText(caption, 'No organoids detected.', (40, 40), cv2.FONT_HERSHEY_SIMPLEX, 1, (0, 0, 0), 3)
|
| 275 |
cv2.imwrite('results.png', np.vstack((img, caption)))
|
| 276 |
colonies = pd.DataFrame({"organoid_number":[], 'organoid_volume':[], "organoid_area":[],'mean_pixel_value':[], "centroid":[], "necrotic_area":[],"percent_necrotic":[]})
|
| 277 |
with pd.ExcelWriter('results.xlsx') as writer:
|