patrickvonplaten commited on
Commit
88bc4de
1 Parent(s): af84fa1

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -0
app.py CHANGED
@@ -151,6 +151,7 @@ def txt_to_img(
151
  )
152
 
153
  pipe.to("cpu")
 
154
 
155
  return replace_nsfw_images(result)
156
 
@@ -190,6 +191,7 @@ def img_to_img(
190
  )
191
 
192
  pipe.to("cpu")
 
193
 
194
  return replace_nsfw_images(result)
195
 
 
151
  )
152
 
153
  pipe.to("cpu")
154
+ torch.cuda.empty_cache()
155
 
156
  return replace_nsfw_images(result)
157
 
 
191
  )
192
 
193
  pipe.to("cpu")
194
+ torch.cuda.empty_cache()
195
 
196
  return replace_nsfw_images(result)
197