Update app.py
Browse files
app.py
CHANGED
@@ -4,10 +4,12 @@ from fastai.vision.all import *
|
|
4 |
import PIL
|
5 |
import torchvision.transforms as transforms
|
6 |
|
|
|
|
|
|
|
7 |
repo_id = "paascorb/practica3_Segmentation"
|
8 |
|
9 |
learner = from_pretrained_fastai(repo_id)
|
10 |
-
learner.load(fast_ai_params.weights)
|
11 |
|
12 |
def transform_image(image):
|
13 |
my_transforms = transforms.Compose([transforms.ToTensor(),
|
|
|
4 |
import PIL
|
5 |
import torchvision.transforms as transforms
|
6 |
|
7 |
+
global Tf
|
8 |
+
Tf = None
|
9 |
+
|
10 |
repo_id = "paascorb/practica3_Segmentation"
|
11 |
|
12 |
learner = from_pretrained_fastai(repo_id)
|
|
|
13 |
|
14 |
def transform_image(image):
|
15 |
my_transforms = transforms.Compose([transforms.ToTensor(),
|