Don't run Turbo on frame 0

it needs precursors that are not there yet.
pull/29/head
Chris Allen 3 years ago committed by GitHub
parent 0a1dde9c4b
commit 4d0bba9d6d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 8
      Disco_Diffusion.ipynb

@ -1100,9 +1100,7 @@
" skip_steps = args.calc_frames_skip_steps\n", " skip_steps = args.calc_frames_skip_steps\n",
"\n", "\n",
" if args.animation_mode == \"3D\":\n", " if args.animation_mode == \"3D\":\n",
" if frame_num == 0:\n", " if frame_num > 0:\n",
" pass\n",
" else:\n",
" seed += 1 \n", " seed += 1 \n",
" if resume_run and frame_num == start_frame:\n", " if resume_run and frame_num == start_frame:\n",
" img_filepath = batchFolder+f\"/{batch_name}({batchNum})_{start_frame-1:04}.png\"\n", " img_filepath = batchFolder+f\"/{batch_name}({batchNum})_{start_frame-1:04}.png\"\n",
@ -1413,7 +1411,7 @@
" image.save(f'{batchFolder}/{filename}')\n", " image.save(f'{batchFolder}/{filename}')\n",
" if args.animation_mode == \"3D\":\n", " if args.animation_mode == \"3D\":\n",
" # If turbo, save a blended image\n", " # If turbo, save a blended image\n",
" if turbo_mode:\n", " if turbo_mode and frame_num > 0:\n",
" # Mix new image with prevFrameScaled\n", " # Mix new image with prevFrameScaled\n",
" blend_factor = (1)/int(turbo_steps)\n", " blend_factor = (1)/int(turbo_steps)\n",
" newFrame = cv2.imread('prevFrame.png') # This is already updated..\n", " newFrame = cv2.imread('prevFrame.png') # This is already updated..\n",
@ -3274,4 +3272,4 @@
}, },
"nbformat": 4, "nbformat": 4,
"nbformat_minor": 4 "nbformat_minor": 4
} }

Loading…
Cancel
Save