darknoon commited on
Commit
674d65b
1 Parent(s): 088840e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -11,7 +11,7 @@ from abc import abstractmethod
11
  import torch.backends
12
  import torch.mps
13
  from PIL import Image
14
-
15
 
16
  if torch.cuda.is_available():
17
  device = torch.device("cuda")
@@ -185,7 +185,7 @@ def describe_shape(shape):
185
  return f"Shape: {shape} num elements: {np.prod(shape)}"
186
 
187
 
188
- # @spaces.GPU
189
  @torch.no_grad()
190
  def roundtrip_image(
191
  image,
 
11
  import torch.backends
12
  import torch.mps
13
  from PIL import Image
14
+ import spaces
15
 
16
  if torch.cuda.is_available():
17
  device = torch.device("cuda")
 
185
  return f"Shape: {shape} num elements: {np.prod(shape)}"
186
 
187
 
188
+ @spaces.GPU(duration=32)
189
  @torch.no_grad()
190
  def roundtrip_image(
191
  image,