advimman / HiDT

Official repository for the paper "High-Resolution Daytime Translation Without Domain Labels" (CVPR2020, Oral)
BSD 3-Clause "New" or "Revised" License
649 stars 86 forks source link

AssertionError when trying to make a timelapse #6

Open decept opened 4 years ago

decept commented 4 years ago

I am trying to make a timelapse by using frames from another day to night timlapse video but I am getting the following error message in google colab: `result path : ./results/

100%|██████████| 1/1 [00:00<00:00, 18.86it/s] 100%|██████████| 128/128 [00:02<00:00, 61.73it/s] Traceback (most recent call last): File "./bin/infer_on_folders.py", line 112, in main() File "./bin/infer_on_folders.py", line 83, in main return_pil=False) File "/usr/local/lib/python3.6/dist-packages/torch/autograd/grad_mode.py", line 43, in decorate_no_grad return func(*args, *kwargs) File "/content/HiDT/hidt/style_transformer.py", line 204, in transfer_images_to_styles batch_size=batch_size, File "/usr/local/lib/python3.6/dist-packages/torch/autograd/grad_mode.py", line 43, in decorate_no_grad return func(args, **kwargs) File "/content/HiDT/hidt/style_transformer.py", line 153, in transfer_decompositions decomposition_a, decomposition_b) File "/content/HiDT/hidt/trainers/trainer_base.py", line 75, in _mix_decompositions assert target['style'].shape[0] == 1 AssertionError ` I increase the number of frames but quicky ran out of CUDA memory. The problem does not occur when using a few style images, only when those style images are from a video. I am sorry if I come off as naive, I am not that experienced and need help.

Kindly teach me how to make smooth timelapses like in demo videos.

denkorzh commented 4 years ago

Hi! Could you try to process your frames on-by-one, in the loop?

decept commented 4 years ago

Thank You very much, I will try that.