maincold2 / Compact-3DGS

The official repository of Compact 3D Gaussian Representation for Radiance Field
Other
399 stars 21 forks source link

How to get the size of a model? #18

Open GimV88 opened 5 months ago

GimV88 commented 5 months ago

Hello,

I hope this message finds you well.

I am interested in utilizing your algorithm for training a model. Could you please offer guidance on how to determine the storage space occupied by the model before and after compression using the "--comp" command? Specifically, should I only consider the size of the .ply files, or should I also refer to the information in the "storage" file generated by the "--comp" command? I've noticed that the information in the "storage" file appears to be significantly smaller than the size of the .ply files. Could you please explain this difference?

Your assistance in clarifying this matter would be greatly appreciated. Thank you for your time and support.

Best regards

GimV88 commented 5 months ago

and And why is the size of the ply file obtained after using --comp unchanged?

maincold2 commented 5 months ago

Now I am updating the saving code, where the final file reflects the actual storage. It could be done in several hours, please stay tuned!

GimV88 commented 5 months ago

Thank you for your response!

maincold2 commented 5 months ago

Actually, the original ply file stores all parameters in 32 float containers, so it shows constantly high storage. We now updated the code to save the result with npz format, reflecting the actual storage. Please refer to the updated readme (https://github.com/maincold2/Compact-3DGS/tree/main?tab=readme-ov-file#442024). Also, please check here for how to calculate the storage: https://github.com/maincold2/Compact-3DGS/blob/50b48b0afe0205a834d479e3a0511068200d4409/scene/gaussian_model.py#L556

GimV88 commented 5 months ago

How can I obtain the PSNR after using post-processing operations?

maincold2 commented 5 months ago

You can run the evaluation codes. https://github.com/maincold2/Compact-3DGS?tab=readme-ov-file#evaluation

render.py automatically loads one of the stored models with the following priority: point_cloud_pp.npz, point_cloud.npz, point_cloud.ply. (If you have run the train code with --comp and --store_npz options, there are two files:point_cloud_pp.npz, point_cloud.npz.) Even if you didn't use --store_npz but only --comp, post processings are already applied to the resulting ply file, which you can use for performance evaluation. Both of them (_pp.npz and .ply with --comp) shows the same performance (but faster model loading from the ply file).

GimV88 commented 5 months ago

Thanks!And why can't I get the rendered video after using render_video.py?

maincold2 commented 5 months ago

You may use ffmpeg to create a video from saved sequence images.

e.g.,) ffmpeg -r 30 -i input_path\%03d.png -vcodec libx264 output_path