Fix: Problem divided by small numbers in PythonAPI/navigation/misc.py

Added eps
This commit is contained in:
German Ros 2019-04-03 15:09:02 -07:00
parent 7451cf1008
commit 5f13bd817e
1 changed files with 1 additions and 1 deletions

View File

@ -103,6 +103,6 @@ def vector(location_1, location_2):
x = location_2.x - location_1.x
y = location_2.y - location_1.y
z = location_2.z - location_1.z
norm = np.linalg.norm([x, y, z])
norm = np.linalg.norm([x, y, z]) + np.finfo(float).eps
return [x / norm, y / norm, z / norm]