-
Notifications
You must be signed in to change notification settings - Fork 18
Convert interface to use Eigen #6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Convert interface to use Eigen #6
Conversation
kinematics_interface/include/kinematics_interface/kinematics_interface_base.hpp
Outdated
Show resolved
Hide resolved
kinematics_interface/include/kinematics_interface/kinematics_interface_base.hpp
Outdated
Show resolved
Hide resolved
kinematics_interface/include/kinematics_interface/kinematics_interface_base.hpp
Outdated
Show resolved
Hide resolved
kinematics_interface/include/kinematics_interface/kinematics_interface_base.hpp
Outdated
Show resolved
Hide resolved
kinematics_interface/include/kinematics_interface/kinematics_interface_base.hpp
Outdated
Show resolved
Hide resolved
kinematics_interface_kdl/test/test_kinematics_interface_kdl.cpp
Outdated
Show resolved
Hide resolved
96d7458
to
c84de51
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I propose to keep both interfaces for two most important methods, i.e., joints_delta
and cartesian_deltas
. The other two methods are also OK if returning only Eigen for now since there is no use-case where one would use other things.
kinematics_interface/include/kinematics_interface/kinematics_interface_base.hpp
Outdated
Show resolved
Hide resolved
kinematics_interface/include/kinematics_interface/kinematics_interface_base.hpp
Outdated
Show resolved
Hide resolved
kinematics_interface/include/kinematics_interface/kinematics_interface_base.hpp
Outdated
Show resolved
Hide resolved
kinematics_interface/include/kinematics_interface/kinematics_interface_base.hpp
Outdated
Show resolved
Hide resolved
kinematics_interface_kdl/include/kinematics_interface_kdl/kinematics_interface_kdl.hpp
Show resolved
Hide resolved
Please rebase on master |
Co-authored-by: AndyZe <andyz@utexas.edu>
Co-authored-by: AndyZe <andyz@utexas.edu>
c84de51
to
7288044
Compare
add pre-commit
Co-authored-by: AndyZe <andyz@utexas.edu>
5904350
to
fcebc37
Compare
fcebc37
to
42af298
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry to keep nit-picking. It's almost there, I think.
kinematics_interface/include/kinematics_interface/kinematics_interface_base.hpp
Show resolved
Hide resolved
kinematics_interface/include/kinematics_interface/kinematics_interface_base.hpp
Outdated
Show resolved
Hide resolved
…nterface into convert-interface-to-eigen � Conflicts: � kinematics_interface/CMakeLists.txt � kinematics_interface/include/kinematics_interface/kinematics_interface_base.hpp � kinematics_interface_kdl/CMakeLists.txt � kinematics_interface_kdl/include/kinematics_interface_kdl/kinematics_interface_kdl.hpp � kinematics_interface_kdl/src/kinematics_interface_kdl.cpp � kinematics_interface_kdl/test/test_kinematics_interface_kdl.cpp
…ics_interface into convert-interface-to-eigen � Conflicts: � kinematics_interface/CMakeLists.txt � kinematics_interface/include/kinematics_interface/kinematics_interface.hpp � kinematics_interface_kdl/CMakeLists.txt � kinematics_interface_kdl/include/kinematics_interface_kdl/kinematics_interface_kdl.hpp � kinematics_interface_kdl/test/test_kinematics_interface_kdl.cpp
Codecov Report
@@ Coverage Diff @@
## master #6 +/- ##
=========================================
Coverage ? 31.11%
=========================================
Files ? 2
Lines ? 180
Branches ? 116
=========================================
Hits ? 56
Misses ? 20
Partials ? 104
Flags with carried forward coverage won't be shown. Click here to find out more. Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Few minor changes and why not use kinematic_interface
as real library with .cpp
file?
kinematics_interface_kdl/include/kinematics_interface_kdl/kinematics_interface_kdl.hpp
Show resolved
Hide resolved
kinematics_interface_kdl/include/kinematics_interface_kdl/kinematics_interface_kdl.hpp
Outdated
Show resolved
Hide resolved
auto joint_pos = Eigen::Map<const Eigen::VectorXd>(joint_pos_vec.data(), joint_pos_vec.size()); | ||
auto delta_x = Eigen::Map<const Eigen::VectorXd>(delta_x_vec.data(), delta_x_vec.size()); | ||
// TODO heap allocation should be removed for realtime use | ||
Eigen::VectorXd delta_theta = | ||
Eigen::Map<Eigen::VectorXd>(delta_theta_vec.data(), delta_theta_vec.size()); | ||
|
||
bool ret = convert_cartesian_deltas_to_joint_deltas(joint_pos, delta_x, link_name, delta_theta); | ||
for (auto i = 0ul; i < delta_theta_vec.size(); i++) | ||
{ | ||
delta_theta_vec[i] = delta_theta[i]; | ||
} | ||
return ret; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not add this default implementation into a cpp
file? We are anyway using this header as library. Isn't it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This also enable those to be overloaded if this is useful from any reason.
kinematics_interface_kdl/include/kinematics_interface_kdl/kinematics_interface_kdl.hpp
Outdated
Show resolved
Hide resolved
kinematics_interface_kdl/test/test_kinematics_interface_kdl.cpp
Outdated
Show resolved
Hide resolved
* bump version: changes to support rolling distro * Add virtual function to avoid compilation error. Signed-off-by: Marco A. Gutierrez <marcogg@marcogg.com> * implement inv jacobian function and tests similar to pinocchio_interface_kdl --------- Signed-off-by: Marco A. Gutierrez <marcogg@marcogg.com> Co-authored-by: Marco A. Gutierrez <marcogg@marcogg.com>
No description provided.