diff --git a/uuv_control/uuv_trajectory_control/src/uuv_trajectory_generator/path_generator/bezier_curve.py b/uuv_control/uuv_trajectory_control/src/uuv_trajectory_generator/path_generator/bezier_curve.py index d52f104d4..f3f56d994 100644 --- a/uuv_control/uuv_trajectory_control/src/uuv_trajectory_generator/path_generator/bezier_curve.py +++ b/uuv_control/uuv_trajectory_control/src/uuv_trajectory_generator/path_generator/bezier_curve.py @@ -14,8 +14,11 @@ # limitations under the License. import numpy as np -from scipy.misc import factorial - +# Factorial function has moved in recent Scipy version +try: + from scipy.misc import factorial +except ImportError: + from scipy.special import factorial class BezierCurve(object): """ diff --git a/uuv_tutorials/uuv_tutorial_dp_controller/scripts/tutorial_dp_controller.py b/uuv_tutorials/uuv_tutorial_dp_controller/scripts/tutorial_dp_controller.py index d3f6a3d90..9fb3ff8a7 100755 --- a/uuv_tutorials/uuv_tutorial_dp_controller/scripts/tutorial_dp_controller.py +++ b/uuv_tutorials/uuv_tutorial_dp_controller/scripts/tutorial_dp_controller.py @@ -90,7 +90,6 @@ def __init__(self): diag = rospy.get_param('~Kd') if len(diag) == 6: self._Kd = np.diag(diag) - print 'Kd=\n', self._Kd else: # If the vector provided has the wrong dimension, raise an exception raise rospy.ROSException('For the Kd diagonal matrix, 6 coefficients are needed') @@ -99,7 +98,6 @@ def __init__(self): diag = rospy.get_param('~Ki') if len(diag) == 6: self._Ki = np.diag(diag) - print 'Ki=\n', self._Ki else: # If the vector provided has the wrong dimension, raise an exception raise rospy.ROSException('For the Ki diagonal matrix, 6 coefficients are needed')