Open CarlottaSartore opened 5 days ago
I did a first implementation of this in https://github.com/CarlottaSartore/jaxsim/tree/add_base_parameter and I tested it with ergocub, i.e. this model https://github.com/icub-tech-iit/ergocub-software/blob/master/urdf/ergoCub/robots/ergoCubSN001/model.urdf and definite the head
as the base link
But it does not work, for instance, if I define head
as base, the only links that get parsed are the head and the real sense
the problem seems that the children of the head link contain only the real sense while they should contain other links such as the head imu
the problem seems here
for reference this is the idyntree function that performs the same action :
Hi @CarlottaSartore, thanks for working on this! The head
and the realsense
are the only links parsed because realsense
is the only child of the head
link. This logic should be changed where the link children are set: https://github.com/ami-iit/jaxsim/blob/524ad4204e2844bc79c94fd42e22725a349d8a81/src/jaxsim/parsers/kinematic_graph.py#L278-L298
In brief, the full ordering of the traversal should be changed, as I guess it's done in iDynTree:
I have seen that it is not possible to set the base from the method
build_from_model_description
although it is the suggested function for loading a model. It would be useful to allow the user to define any base.