Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -22,7 +22,7 @@ map_location = torch.device("cuda") if enable_gpu else "cpu"
|
|
22 |
from huggingface_hub import hf_hub_download
|
23 |
from fastai.learner import load_learner
|
24 |
|
25 |
-
model = torch.load("h2z-85epoch.pth")
|
26 |
def generate_img(img_path):
|
27 |
img = tf.io.read_file(img_path)
|
28 |
img = tf.image.decode_png(img)
|
|
|
22 |
from huggingface_hub import hf_hub_download
|
23 |
from fastai.learner import load_learner
|
24 |
|
25 |
+
model = torch.load("h2z-85epoch.pth",map_location=torch.device('cpu'))
|
26 |
def generate_img(img_path):
|
27 |
img = tf.io.read_file(img_path)
|
28 |
img = tf.image.decode_png(img)
|