mouseland commited on
Commit
64935e2
·
verified ·
1 Parent(s): ac8a141

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
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