mirror of
https://github.com/facebookresearch/pytorch3d.git
synced 2025-08-02 20:02:49 +08:00
Fix plotly pointcloud visualization feature bug
Summary: If a pointcloud had less than pointcloud_max_points, the colors would not render. This diff fixes that. Reviewed By: bottler Differential Revision: D25099044 fbshipit-source-id: 47c3ddcdb4e06284b0a7966ffca1b973f394921f
This commit is contained in:
parent
6c2fc685de
commit
fc7a4cacc3
@ -587,6 +587,8 @@ def _add_pointcloud_trace(
|
||||
|
||||
color = None
|
||||
if features is not None:
|
||||
if indices is not None:
|
||||
# Only select features if we selected vertices above
|
||||
features = features[indices]
|
||||
if features.shape[1] == 4: # rgba
|
||||
template = "rgb(%d, %d, %d, %f)"
|
||||
|
Loading…
x
Reference in New Issue
Block a user