Skip to content

Commit 2ab408b

Browse files
committed
Force compatibility with polyscope 2.4.0
1 parent 0a206dc commit 2ab408b

2 files changed

Lines changed: 4 additions & 7 deletions

File tree

python/kiss_icp/tools/visualizer.py

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -271,12 +271,9 @@ def _trajectory_pick_callback(self):
271271
name = ""
272272
idx = 0
273273
pick_selection = self._ps.get_selection()
274-
try: # Compatile with old polyscope versions
275-
name, idx = pick_selection
276-
except TypeError: # Compatible with polyscope >= 2.4.0
277-
if pick_selection.is_hit:
278-
name = pick_selection.structure_name
279-
idx = pick_selection.structure_data["index"]
274+
if pick_selection.is_hit:
275+
name = pick_selection.structure_name
276+
idx = pick_selection.structure_data["index"]
280277
if name == "trajectory" and self._ps.has_point_cloud(name):
281278
pose = self._trajectory[idx]
282279
self._selected_pose = f"x: {pose[0]:7.3f}, y: {pose[1]:7.3f}, z: {pose[2]:7.3f}>"

python/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ dependencies = [
5151
[project.optional-dependencies]
5252
all = [
5353
"open3d>=0.16",
54-
"polyscope>=2.2.1",
54+
"polyscope>=2.4.0",
5555
"ouster-sdk>=0.11",
5656
"pyntcloud",
5757
"PyYAML",

0 commit comments

Comments
 (0)