Skip to content

Commit 988cb51

Browse files
committed
Fix a bug in bounding box evaluation
The input Cartesian coordinates can be negative too but not -inf
1 parent 3b799cb commit 988cb51

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

geomdl/utilities.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -516,7 +516,7 @@ def evaluate_bounding_box(ctrlpts):
516516

517517
# Evaluate bounding box
518518
bbmin = [float('inf') for _ in range(0, dimension)]
519-
bbmax = [0.0 for _ in range(0, dimension)]
519+
bbmax = [float('-inf') for _ in range(0, dimension)]
520520
for cpt in ctrlpts:
521521
for i, arr in enumerate(zip(cpt, bbmin)):
522522
if arr[0] < arr[1]:

0 commit comments

Comments
 (0)