Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The size of tensor a(162) must match the size of tensor b(3) at non-singleton dimension 1 #23

Open
Pattern6 opened this issue Dec 24, 2021 · 4 comments

Comments

@Pattern6
Copy link

Hello, author! I have a question to ask you. When I run the code, I report the following errors. What is the reason? I didn't change the code.
Uploading IMG_2297.JPG…

@weiyithu
Copy link
Owner

What's wrong? I cannot see the uploaded image.

@Pattern6
Copy link
Author

What's wrong? I cannot see the uploaded image.
The wrong with "The size of tensor a(162) must match the size of tensor b(3) at non-singleton dimension 1"
File "/home/ubuntu/ygx/1/NerfingMVS-main/src/run_nerf.py", line 137, in render
all_ret['depth_map'] = -1/rays_d_ori[:, 2]*(1 / (1 - all_ret['depth_map']) + rays_o_ori[:, 2])
File "/home/ubuntu/ygx/1/NerfingMVS-main/src/run_nerf.py", line 162, in render_path
rgb, disp, acc, depth, _ = render(H, W, focal, depth_priors=depth_priors[i], depth_confidences=depth_confidences[i], chunk=chunk, c2w=c2w[:3,:4], **render_kwargs)
File "/home/ubuntu/ygx/1/NerfingMVS-main/src/run_nerf.py", line 624, in train
image_list=image_list
File "/home/ubuntu/ygx/1/NerfingMVS-main/run.py", line 22, in
run_nerf.train(args)

@weiyithu
Copy link
Owner

Since I use '--no_ndc' for all scannet scenes, I do not test this line. In my opinion, the depth map in Cartesian coordinate is not equal to that in ndc coordinate.

@Pattern6
Copy link
Author

Since I use '--no_ndc' for all scannet scenes, I do not test this line. In my opinion, the depth map in Cartesian coordinate is not equal to that in ndc coordinate

OK, thank you very much for your reply. I'll try ‘--no_ndc’ this situation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants