Skip to content

Commit 7af6a27

Browse files
committed
Re-enable warning for exceeding max collision pairs.
1 parent d3ccd7c commit 7af6a27

File tree

1 file changed

+10
-11
lines changed

1 file changed

+10
-11
lines changed

genesis/engine/solvers/rigid/collider_decomp.py

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -770,11 +770,11 @@ def _func_broad_phase(self):
770770
continue
771771

772772
if self.n_broad_pairs[i_b] == self._max_collision_pairs:
773-
# print(
774-
# f"{colors.YELLOW}[Genesis] [00:00:00] [WARNING] Ignoring collision pair to avoid "
775-
# f"exceeding max ({self._max_collision_pairs}). Please increase the value of "
776-
# f"RigidSolver's option 'max_collision_pairs'.{formats.RESET}"
777-
# )
773+
ti.static_print(
774+
f"{colors.YELLOW}[Genesis] [00:00:00] [WARNING] Ignoring collision pair to avoid "
775+
f"exceeding max ({self._max_collision_pairs}). Please increase the value of "
776+
f"RigidSolver's option 'max_collision_pairs'.{formats.RESET}"
777+
)
778778
break
779779
self.broad_collision_pairs[self.n_broad_pairs[i_b], i_b][0] = i_ga
780780
self.broad_collision_pairs[self.n_broad_pairs[i_b], i_b][1] = i_gb
@@ -1107,12 +1107,11 @@ def _func_add_contact(self, i_ga, i_gb, normal, contact_pos, penetration, i_b):
11071107
i_col = self.n_contacts[i_b]
11081108

11091109
if i_col == self._max_contact_pairs:
1110-
# print(
1111-
# f"{colors.YELLOW}[Genesis] [00:00:00] [WARNING] Ignoring contact pair to avoid exceeding max "
1112-
# f"({self._max_contact_pairs}). Please increase the value of RigidSolver's option "
1113-
# f"'max_collision_pairs'.{formats.RESET}"
1114-
# )
1115-
pass
1110+
ti.static_print(
1111+
f"{colors.YELLOW}[Genesis] [00:00:00] [WARNING] Ignoring contact pair to avoid exceeding max "
1112+
f"({self._max_contact_pairs}). Please increase the value of RigidSolver's option "
1113+
f"'max_collision_pairs'.{formats.RESET}"
1114+
)
11161115
else:
11171116
ga_info = self._solver.geoms_info[i_ga]
11181117
gb_info = self._solver.geoms_info[i_gb]

0 commit comments

Comments
 (0)