Update app.py
Browse files
app.py
CHANGED
|
@@ -275,8 +275,9 @@ def tif_view(filepath):
|
|
| 275 |
def norm_path(filepath):
|
| 276 |
img = imread(filepath)
|
| 277 |
img = normalize99(img)
|
|
|
|
| 278 |
fpath, fext = os.path.splitext(filepath)
|
| 279 |
-
filepath = fpath+'.png'
|
| 280 |
imsave(filepath, img)
|
| 281 |
return filepath
|
| 282 |
|
|
|
|
| 275 |
def norm_path(filepath):
|
| 276 |
img = imread(filepath)
|
| 277 |
img = normalize99(img)
|
| 278 |
+
img = np.clip(img, 0, 1)
|
| 279 |
fpath, fext = os.path.splitext(filepath)
|
| 280 |
+
filepath = fpath +'.png'
|
| 281 |
imsave(filepath, img)
|
| 282 |
return filepath
|
| 283 |
|