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

About the .ply file #44

Open
ZhenyuSun-Walker opened this issue Sep 1, 2024 · 7 comments
Open

About the .ply file #44

ZhenyuSun-Walker opened this issue Sep 1, 2024 · 7 comments

Comments

@ZhenyuSun-Walker
Copy link

Hello sir, I wonder how can I use the mvsgs to optimize the .ply file processed by other modeI. I met the error:
(mvsgs) $ python lib/train.py --eval --iterations 3000 -s dataset/mvdif_demo_150_20i -p mvsgs_pointcloud/dtu_pretrain Optimizing ./output/mvdif_demo_150_20i Output folder: ./output/mvdif_demo_150_20i Tensorboard not available: not logging progress Reading camera 20/20 mvsgs_pointcloud/dtu_pretrain/mvdif_demo_150_20i/mvdif_demo_150_20i.ply Loading Training Cameras [ INFO ] Encountered quite large input images (>1.6K pixels width), rescaling to 1.6K. If this is not desired, please explicitly specify '--resolution/-r' as 1 Loading Test Cameras Traceback (most recent call last): File "lib/train.py", line 236, in <module> training(lp.extract(args), op.extract(args), pp.extract(args), args.test_iterations, args.save_iterations, args.checkpoint_iterations, args.start_checkpoint, args.debug_from, init_ply=args.init_ply) File "lib/train.py", line 67, in training scene = Scene(dataset, gaussians, init_ply=init_ply) File "/home/sunzhenyu/Projects/MVSGaussian/lib/scene/__init__.py", line 86, in __init__ self.gaussians.create_from_pcd(scene_info.point_cloud, self.cameras_extent) File "/home/sunzhenyu/Projects/MVSGaussian/lib/scene/gaussian_model.py", line 129, in create_from_pcd fused_point_cloud = torch.tensor(np.asarray(pcd.points)).float().cuda() AttributeError: 'NoneType' object has no attribute 'points'

@ZhenyuSun-Walker
Copy link
Author

I use other models to generate the point cloud from the same input dataset, and try to use it as initialization of gaussian optimization in mvsgs. However, the mistakes above happens. How can I fix the problem?

@TQTQliu
Copy link
Owner

TQTQliu commented Sep 3, 2024

Sorry for the late reply.
We load the point cloud as initialization here. Please check it.

@ZhenyuSun-Walker
Copy link
Author

OK, sir. So you provide me the specific paragraph where I can change the loading directory. However, I found that if I change the point cloud file into the .ply file that I generated throuh other methods, the error
Traceback (most recent call last): File "lib/train.py", line 236, in <module> training(lp.extract(args), op.extract(args), pp.extract(args), args.test_iterations, args.save_iterations, args.checkpoint_iterations, args.start_checkpoint, args.debug_from, init_ply=args.init_ply) File "lib/train.py", line 67, in training scene = Scene(dataset, gaussians, init_ply=init_ply) File "/home/sunzhenyu/Projects/MVSGaussian/lib/scene/__init__.py", line 86, in __init__ self.gaussians.create_from_pcd(scene_info.point_cloud, self.cameras_extent) File "/home/sunzhenyu/Projects/MVSGaussian/lib/scene/gaussian_model.py", line 129, in create_from_pcd fused_point_cloud = torch.tensor(np.asarray(pcd.points)).float().cuda() AttributeError: 'NoneType' object has no attribute 'points'
came up. It seems that there are some constraints while utilizing the .ply file as the initilization of gaussian optimization, and simply changin the original .ply file into another version does not work well.

Anticipating for your earliest reply!

@TQTQliu
Copy link
Owner

TQTQliu commented Sep 5, 2024

I suspect the problem is caused by an incorrect path. Because AttributeError: 'NoneType' object has no attribute 'points'.
You can also set the path here.

And structured array of the point cloud can be found here.

@ZhenyuSun-Walker
Copy link
Author

Howerver, I simply put the new version of the .ply file into the place where the original version should be, and I change the name to avoid the directory error. However, the nonetype error still occuirs.

@ZhenyuSun-Walker
Copy link
Author

From your description, can I infer that: As long as the point cloud .ply file is obtained from the images of the four target views in the input dataset, and its path is correct, it can be optimized using the Gaussian optimization method of MVSGaussian. The point cloud does not necessarily have to be obtained from the previous run.py, right?

@TQTQliu
Copy link
Owner

TQTQliu commented Sep 5, 2024

Right.
If the path is correct, you may need to debug to check if the point cloud is loaded.
Please pay attention here. If an error occurs in the fetchPly function, it will also result in pcd=None.

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