ChatSim icon indicating copy to clipboard operation
ChatSim copied to clipboard

FileNotFoundError: No such file: '/home/lferris/ChatSim/results/cache/1137_demo_2024_07_09_11_04_41/blender_output/0/RGB_composite.png'

Open LFerris123 opened this issue 1 year ago • 20 comments
trafficstars

Currently, during the replication process, I encountered the following issue: image when I run the command python main.py -y config/waymo-1137.yaml -p "Add a Benz G in front of me, driving away fast." for testing, I receive the following error:

FileNotFoundError: No such file: '/home/lferris/ChatSim/results/cache/1137_demo_2024_07_09_11_04_41/blender_output/0/RGB_composite.png'

The McNeRF has already been fully trained, and I have also called the valid OpenAI API.

LFerris123 avatar Jul 09 '24 03:07 LFerris123

Has anyone encountered the same issue? What solutions do you have?

LFerris123 avatar Jul 09 '24 03:07 LFerris123

Is there any files in /home/lferris/ChatSim/results/cache/1137_demo_2024_07_09_11_04_41/blender_output/?

yifanlu0227 avatar Jul 09 '24 05:07 yifanlu0227

Thanks for reply!There is no files in /home/lferris/ChatSim/results/cache/1137_demo_2024_07_09_11_04_41/blender_output/

LFerris123 avatar Jul 09 '24 10:07 LFerris123

Run the blender rendering separately to see if it works. You can follow the Blender utils Readme

You can just run the command in usage section if everything for chatsim is set.

Screenshot_20240709_180425_com.github.android.jpg

yifanlu0227 avatar Jul 09 '24 10:07 yifanlu0227

I checked the output folder and found no valid Blender output files, so I reconfigured the documents according to the Blender utils documentation you provided. However, I am currently encountering the following issues: Currently, according to the documentation, there will be three different Blender installation locations. The first one is as shown in the Installation commands, which installs Blender in the background folder (however, there are no required files for subsequent use here, which is clearly incorrect). The second is in the Blender folder under the foreground files that come with the project files (this should be the correct Blender installation location). The third is the path under the Blender utils README file, as shown in the figure below: Which Blender path should be used for successful rendering? image image image

LFerris123 avatar Jul 16 '24 09:07 LFerris123

Hi, sorry for the confusion. Just make a alias to you installed blender, no matter where it is installed.

alias blender='<SOMEWHERE>/blender-3.5.1-linux-x64/blender'
alias blender_python='<SOMEWHERE>/blender-3.5.1-linux-x64/3.5/python/bin/python3.10'

yifanlu0227 avatar Jul 16 '24 09:07 yifanlu0227

If you followed the project's README, <SOMEWHERE> would be ChatSim/chatsim/foreground/Blender

yifanlu0227 avatar Jul 16 '24 09:07 yifanlu0227

I update the README, and hope it is more clear.

yifanlu0227 avatar Jul 16 '24 10:07 yifanlu0227

Thank you for your reply! I have individually tested the Blender module according to the setup in the Blender utils Readme, and it can now produce the same valid output as documented. However, when I directly run "python main.py -y config/waymo-1137.yaml -p 'Add a Benz G in front of me, driving away fast.'", I still encounter the same error. image

LFerris123 avatar Jul 17 '24 03:07 LFerris123

Has anyone encountered the same issue? The result file blender_output is empty

LFerris123 avatar Jul 19 '24 07:07 LFerris123

The blender rendering can run separately,but when I run python main.py -y config/waymo-1137.yaml -p "Add a Benz G in front of me, driving away fast.",I find that the file "blender_output" is still empty

LFerris123 avatar Jul 19 '24 08:07 LFerris123

Probably it is due to OOM, reduce multi_process_num in the yaml file. You can also check the log files under result/cache/

yifanlu0227 avatar Jul 27 '24 08:07 yifanlu0227

Totally the same issue I encountered with you, do you have found some solutions?

xyyu-callen avatar Sep 09 '24 04:09 xyyu-callen

Setting multi_process_num equal to 1, this issue disappears.

xyyu-callen avatar Sep 09 '24 05:09 xyyu-callen

Setting multi_process_num equal to 1, this issue disappears.

I met the same error. But after I set multi_process_num to 1, the error still exists.

wmkai avatar Sep 09 '24 22:09 wmkai

The blender rendering can run separately,but when I run python main.py -y config/waymo-1137.yaml -p "Add a Benz G in front of me, driving away fast.",I find that the file "blender_output" is still empty

Hi, have you solved this problem? I met the same error.

wmkai avatar Sep 09 '24 23:09 wmkai

could you guys share the log file?@wmkai @xyyu-callen

yifanlu0227 avatar Sep 10 '24 04:09 yifanlu0227

could you guys share the log file?@wmkai @xyyu-callen

Thanks for your reply. Do you mean the following log?

python main.py -y config/waymo-1137.yaml -p "Add a Benz G in front of me, driving away fast."
[User prompt] Add a Benz G in front of me, driving away fast.

[Project Manager] decomposing tasks                
[Raw Response>>>] { 1: 'Add a fast driving Benz G in front of me' }
[Extracted Response>>>] { 1: 'Add a fast driving Benz G in front of me' } 

[Performing Single Prompt] Add a fast driving Benz G in front of me

[Project Manager] dispatching each task                 
[Raw Response>>>] {'operation': 1}
[Extracted Response>>>] 1. (adding) 

[Motion Agent LLM] analyzing insertion scene dependency                      
[Raw Response>>>] {'dependency': 0}
[Extracted Response>>>] {'dependency': 0} 

[Motion Agent LLM] deciding scene-independent object placement                     
[Raw Response>>>] {'mode':'front', 'distance_constraint': 0, 'distance_min_max':(4, 45)}
[Extracted Response>>>] {'mode': 'front', 'distance_constraint': 0, 'distance_min_max': (4, 45)} 

[Asset Agent LLM] deciding asset type and color                     
[Raw Response>>>] {"color":"default","type":"benz_g"}
[Extracted Response>>>] {'color': 'default', 'type': 'benz_g'} 

[Motion Agent LLM] finding motion prior                     
[Raw Response>>>] {'action': 'straight', 'speed': 'fast', 'direction': 'away', 'wrong_way': 'false'}
[Extracted Response>>>] {'action': 'straight', 'speed': 'fast', 'direction': 'away', 'wrong_way': 'false'} 

scene.added_cars_dict dict_keys(['added_car_0'])
scene.removed_cars []
[Mc-NeRF] is_ego_motion is False, rendering one frame
Working directory is /home/xxx/ChatSim/chatsim/background/mcnerf
/home/xxx/ChatSim/chatsim/background/mcnerf/data/waymo_multi_view/segment-11379226583756500423_6230_810_6250_810_with_camera_labels
register Hash3DAnchoredInfo
register TCNNWPInfo
register volume render info
Aoligei!
[Dataset::Dataset] begin
Load render poses
[LoadImages] begin
[LoadImages] end in 10.9151 seconds
Number of train/test/val images: 105/15/0
[Dataset::Dataset] end in 16.7441 seconds
[PersSampler::PersSampler] begin
[PersOctree::PersOctree] begin
[PersOctree::ConstructEdgePool] begin
edge_pool_.size() is value 6899
[PersOctree::ConstructEdgePool] end in 0.0437458 seconds
[PersOctree::PersOctree] end in 15.0305 seconds
[PersSampler::PersSampler] end in 15.4031 seconds
[Hash3DAnchored::Hash3DAnchored] begin
[Hash3DAnchored::Hash3DAnchored] end in 8.90522 seconds
/home/xxx/ChatSim/chatsim/background/mcnerf/exp/segment-11379226583756500423_6230_810_6250_810_with_camera_labels/exp_coeff_0.3/checkpoints/latest/scalars.pt
sub_div_milestones_ is value 
valid_nodes is value 297020
start rendering wide angle images
0
use shutter
[Inpaint] No inpainting.
[Blender] Start rendering 50 images.
see the log in results/cache/1137_demo_2024_09_10_07_51_44/rendering_log if save_cache is enabled
preparing input files for blender rendering
100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████| 50/50 [00:01<00:00, 27.12it/s]
start rendering in parallel, process number is 5.
This may take a few minutes. To speed up the foreground rendering, you can lower the `frames` number or render not-wide images.
If you find the results are incomplete or missing, that may due to OOM. You can reduce the multi_process_num in config yaml.
You can also check the log file for debugging with `save_cache` enabled in the yaml.
[Blender] Finish rendering 50 images.
[Blender] Copying Remaining 0 images.
Traceback (most recent call last):
  File "/xxx/ChatSim/main.py", line 141, in <module>
    chatsim.execute_funcs()
  File "/home/xxx/ChatSim/main.py", line 126, in execute_funcs
    self.foreground_rendering_agent.func_blender_add_cars(self.scene)
  File "/home/xxx/ChatSim/chatsim/agents/foreground_rendering_agent.py", line 120, in func_blender_add_cars
    img = imageio.imread(video_frame_file)
  File "/root/miniconda3/envs/chatsim/lib/python3.9/site-packages/imageio/v2.py", line 359, in imread
    with imopen(uri, "ri", **imopen_args) as file:
  File "/root/miniconda3/envs/chatsim/lib/python3.9/site-packages/imageio/core/imopen.py", line 113, in imopen
    request = Request(uri, io_mode, format_hint=format_hint, extension=extension)
  File "/root/miniconda3/envs/chatsim/lib/python3.9/site-packages/imageio/core/request.py", line 247, in __init__
    self._parse_uri(uri)
  File "/root/miniconda3/envs/chatsim/lib/python3.9/site-packages/imageio/core/request.py", line 407, in _parse_uri
    raise FileNotFoundError("No such file: '%s'" % fn)
FileNotFoundError: No such file: '/home/xxx/ChatSim/results/cache/1137_demo_2024_09_10_07_51_44/blender_output/0/RGB_composite.png'

There is no log under result/cache/. image

wmkai avatar Sep 10 '24 04:09 wmkai

Blender fails to render the images. Well, you can see we run the blender rendering command following those lines

https://github.com/yifanlu0227/ChatSim/blob/923b20c99d40a7dc4bf0f4c3e6dd4a0a407162f7/chatsim/agents/foreground_rendering_agent.py#L307

Could you run it manually? You can use existing cache dir, set -- {start_frame} -- {end_frame} like -- 0 -- 1.

Just remove the > {log_file} to see the log in terminal and if there is any rendering output

yifanlu0227 avatar Sep 10 '24 09:09 yifanlu0227

I tried to run chatsim/foreground/Blender/blender-3.5.1-linux-x64/blender -b --python chatsim/foreground/Blender/utils/blender_utils/main_multicar.py --results/cache/1137_demo_2024_09_10_07_51_44/blender_yaml -- 0 -- 1.

Then it shows 'chatsim/foreground/Blender/blender-3.5.1-linux-x64/blender: error while loading shared libraries: libXrender.so.1: cannot open shared object file: No such file or directory'.

So I use apt-get install to install libxrender1, libxi6, libxkbcommon0, libsm6. It works!

wmkai avatar Sep 10 '24 17:09 wmkai