QHL067 commited on
Commit
c652092
·
1 Parent(s): f2a30f0
Files changed (1) hide show
  1. app.py +7 -1
app.py CHANGED
@@ -245,7 +245,13 @@ def infer(
245
  gif_buffer.seek(0)
246
  gif_bytes = gif_buffer.read()
247
 
248
- return first_image, last_image, gif_bytes, seed
 
 
 
 
 
 
249
  # return first_image, last_image, seed
250
 
251
 
 
245
  gif_buffer.seek(0)
246
  gif_bytes = gif_buffer.read()
247
 
248
+ # Save the GIF bytes to a temporary file and get its path
249
+ temp_gif = tempfile.NamedTemporaryFile(delete=False, suffix=".gif")
250
+ temp_gif.write(gif_bytes)
251
+ temp_gif.close()
252
+ gif_path = temp_gif.name
253
+
254
+ return first_image, last_image, gif_path, seed
255
  # return first_image, last_image, seed
256
 
257