yifanlu0227 / ChatSim

[CVPR2024 Highlight] Editable Scene Simulation for Autonomous Driving via LLM-Agent Collaboration
https://yifanlu0227.github.io/ChatSim
308 stars 20 forks source link

RuntimeError: The size of tensor a (50) must match the size of tensor b (10) at non-singleton dimension 1 #25

Closed nevergone123 closed 4 months ago

nevergone123 commented 4 months ago

I change the frames from 50 to 10, and run the following command: python main.py -y config/waymo-1006.yaml -p 'Remove all cars.Viewpoints ahead slowly and A chevrolet driving away from me fast.' -s demo

I got the following output:

/root/AImodel/wenke/ChatSim/chatsim/background/inpainting/Inpaint-Anything/segment_anything/segment_anything/modeling/tiny_vit_sam.py:657: UserWarning: Overwriting tiny[0/1927]_512 in registry with segment_anything.modeling.tiny_vit_sam.tiny_vit_21m_512. This is because the name being registered conflicts with an existing name. Please check if this is not expected.
  return register_model(fn_wrapper)
sttn
Traceback (most recent call last):
  File "remove_anything_video_npy.py", line 288, in <module>
    all_frame_rm_w_mask = model.forward_inpainter(frames, masks)
  File "remove_anything_video_npy.py", line 132, in forward_inpainter
    frames = inpaint_video_with_builded_sttn(
  File "/root/miniconda3/envs/chatsim/lib/python3.8/site-packages/torch/autograd/grad_mode.py", line 27, in decorate_context
    return func(*args, **kwargs)
  File "/root/AImodel/wenke/ChatSim/chatsim/background/inpainting/Inpaint-Anything/sttn_video_inpaint.py", line 91, in inpaint_video_with_builded_sttn
    feats = (feats * (1 - _masks).float()).view(video_length, 3, h, w)
RuntimeError: The size of tensor a (50) must match the size of tensor b (10) at non-singleton dimension 1
TurtleZhong commented 3 months ago

so I think you have solved it and got the final results, can you share some results like videos, thx :)