mirror of
https://github.com/nerfstudio-project/nerfstudio.git
synced 2026-11-14 20:03:49 +08:00
Remove PCA colormap bug for float output maps (#2620)
Previously, "PCA" would be offered as a colormap option for float outputs (and throws "PCA is not a known colormap" error).
This commit is contained in:
1 parent
43703fa05a
commit
c896ee4e0a
1 file changed
+1
-1
@@ -445,7 +445,7 @@ def _get_colormap_options(dimensions: int, dtype: type) -> List[Colormaps]:
|
||||
if dimensions == 3:
|
||||
colormap_options = ["default"]
|
||||
if dimensions == 1 and dtype in [torch.float64, torch.float32, torch.float16, torch.bfloat16]:
|
||||
colormap_options = [c for c in list(get_args(Colormaps)) if c != "default"]
|
||||
colormap_options = [c for c in list(get_args(Colormaps)) if c not in ("default", "pca")]
|
||||
if dimensions > 3:
|
||||
colormap_options = ["pca"]
|
||||
return colormap_options
|
||||
Reference in new issue
Block a user