Update app.py
Browse files
app.py
CHANGED
|
@@ -8,11 +8,11 @@ import os
|
|
| 8 |
#os.system("sudo apt-get install nvIDia-cuda-toolkit")
|
| 9 |
#os.system("/usr/local/bin/python -m pip install --upgrade pip")
|
| 10 |
#os.system("pip install argparse")
|
| 11 |
-
import pydensecrf.densecrf as dcrf
|
| 12 |
from PIL import Image
|
| 13 |
-
import torch
|
| 14 |
-
import torch.nn.functional as F
|
| 15 |
-
from torchvision import transforms
|
| 16 |
import numpy as np
|
| 17 |
import collections
|
| 18 |
import cv2
|
|
@@ -52,7 +52,7 @@ def test(gpu_id, net, img_list, group_size, img_size):
|
|
| 52 |
print('done')
|
| 53 |
return result
|
| 54 |
|
| 55 |
-
img_lst=[(torch.rand(352,352,3)*255).numpy().astype(np.uint8) for i in range(5)]
|
| 56 |
outputpath1='img2.png'
|
| 57 |
outputpath2='img2.png'
|
| 58 |
outputpath3='img2.png'
|
|
|
|
| 8 |
#os.system("sudo apt-get install nvIDia-cuda-toolkit")
|
| 9 |
#os.system("/usr/local/bin/python -m pip install --upgrade pip")
|
| 10 |
#os.system("pip install argparse")
|
| 11 |
+
#import pydensecrf.densecrf as dcrf
|
| 12 |
from PIL import Image
|
| 13 |
+
#import torch
|
| 14 |
+
#import torch.nn.functional as F
|
| 15 |
+
#from torchvision import transforms
|
| 16 |
import numpy as np
|
| 17 |
import collections
|
| 18 |
import cv2
|
|
|
|
| 52 |
print('done')
|
| 53 |
return result
|
| 54 |
|
| 55 |
+
#img_lst=[(torch.rand(352,352,3)*255).numpy().astype(np.uint8) for i in range(5)]
|
| 56 |
outputpath1='img2.png'
|
| 57 |
outputpath2='img2.png'
|
| 58 |
outputpath3='img2.png'
|