Download scripts/phase2_counterfactual/print_table.py from KCBtheone/SplatAtlas: direct link, hf CLI and curl.
- Browser
- Download file 1.11 kB
-
https://huggingface.co/KCBtheone/SplatAtlas/resolve/main/scripts/phase2_counterfactual/print_table.py
- Command line
-
hf download hf://KCBtheone/SplatAtlas/scripts/phase2_counterfactual/print_table.py
-
curl -L -o print_table.py https://huggingface.co/KCBtheone/SplatAtlas/resolve/main/scripts/phase2_counterfactual/print_table.py
1.11 kB
| import os, json | |
| methods = ["vanilla_3dgs", "3dgsmcmc", "absgs", "gaussianpro", "pixelgs"] | |
| header = "{:<15} | {:<9} | {:<9} | {:<9} | {:<9} | {:<8} | {:<8} | {:<9} | {:<6} | {}".format( | |
| "method", "psnr_full", "sh_net", "sh_cor_rt", "opa_net", "coverage", "cov_err", "resid_err", "sanity", "sh_neg" | |
| ) | |
| print(header) | |
| print("-" * len(header)) | |
| for m in methods: | |
| p = f"/root/autodl-tmp/SplatAtlas/outputs/error_responsibility/{m}_bonsai/counterfactual_summary.json" | |
| if not os.path.exists(p): | |
| print(f"{m:<15} | MISSING") | |
| continue | |
| with open(p) as f: | |
| d = json.load(f) | |
| row = "{:<15} | {:<9.4f} | {:<9.4f} | {:<9.4f} | {:<9.4f} | {:<8.4f} | {:<8.4f} | {:<9.4f} | {:<6} | {}".format( | |
| m, | |
| d.get("psnr_full", 0), | |
| d.get("sh_net_effect", 0), | |
| d.get("sh_corruption_rate", 0), | |
| d.get("opacity_net_effect", 0), | |
| d.get("coverage", 0), | |
| d.get("coverage_error_fraction", 0), | |
| d.get("residual_error", 0), | |
| d.get("sanity_status", "N/A"), | |
| d.get("sh_negative_flag", "N/A") | |
| ) | |
| print(row) | |