mmatl / urdfpy

Python parser for URDFs
http://urdfpy.readthedocs.io/
MIT License
224 stars 81 forks source link

Axis import problems #21

Open JanusMaple opened 2 years ago

JanusMaple commented 2 years ago

In some urdf files axis coordinate might be [0.0, 0.0, 0.0], which would cause runtime error for the code in line 2169urdf.py: "value = value / np.linalg.norm(value)". Thus, it would be better if there is a conditional statement that if math.isclose(np.linalg.norm(value), 0.0), then value = np.array([1.0, 0.0, 0.0], dtype=np.float64).