Commit
·
30516e0
1
Parent(s):
5513895
Fix bug
Browse files- src/prediction.py +4 -2
src/prediction.py
CHANGED
|
@@ -1,7 +1,9 @@
|
|
| 1 |
import os
|
| 2 |
import re
|
| 3 |
-
from glob import glob
|
| 4 |
import cv2
|
|
|
|
|
|
|
|
|
|
| 5 |
from src.cyano import Cyanotype
|
| 6 |
from src.mono_alternative import MonoAlternative
|
| 7 |
|
|
@@ -65,4 +67,4 @@ def optimize_img(process_name, img):
|
|
| 65 |
out_path = f'{out_dir}/x0_{suf}.png'
|
| 66 |
cv2.imwrite(out_path, x0)
|
| 67 |
|
| 68 |
-
return x0, opt_img
|
|
|
|
| 1 |
import os
|
| 2 |
import re
|
|
|
|
| 3 |
import cv2
|
| 4 |
+
import numpy as np
|
| 5 |
+
from glob import glob
|
| 6 |
+
|
| 7 |
from src.cyano import Cyanotype
|
| 8 |
from src.mono_alternative import MonoAlternative
|
| 9 |
|
|
|
|
| 67 |
out_path = f'{out_dir}/x0_{suf}.png'
|
| 68 |
cv2.imwrite(out_path, x0)
|
| 69 |
|
| 70 |
+
return x0.astype(np.uint8), opt_img.astype(np.uint8)
|