Spaces:
Running
on
Zero
Running
on
Zero
gokaygokay
commited on
Commit
•
d2e5583
1
Parent(s):
05c7809
Update app.py
Browse files
app.py
CHANGED
@@ -90,6 +90,8 @@ class LazyRealESRGAN:
|
|
90 |
self.load_model()
|
91 |
return self.model.predict(img)
|
92 |
|
|
|
|
|
93 |
lazy_realesrgan_x2 = LazyRealESRGAN(device, scale=2)
|
94 |
lazy_realesrgan_x4 = LazyRealESRGAN(device, scale=4)
|
95 |
|
|
|
90 |
self.load_model()
|
91 |
return self.model.predict(img)
|
92 |
|
93 |
+
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
94 |
+
|
95 |
lazy_realesrgan_x2 = LazyRealESRGAN(device, scale=2)
|
96 |
lazy_realesrgan_x4 = LazyRealESRGAN(device, scale=4)
|
97 |
|