Closed GiulioRomualdi closed 3 years ago
Thanks @GiulioRomualdi for raising this issue and reporting for this bug. I think this is due to some slight but important changes in the way we parse frames in the URDF parser and which has been introduced in Pinocchio 2.6.0. You can use 2.5.6 in meantime, and I will provide a fix later this day.
Hi @jcarpent. Thank you! With pinocchio 2.5.6 the problem disappears
@GiulioRomualdi I've fixed the bug and in fact it was only related to Meshcat support of Pinocchio. Please cherry-pick this commit 24dbede to solve locally your issue.
I will provide a release soon to fix it at least on conda. Thanks again for the quick report.
@GiulioRomualdi Could you confirm that fixes your issue in robotology/icub-models#97?
@GiulioRomualdi I've fixed the bug and in fact it was only related to Meshcat support of Pinocchio. Please cherry-pick this commit 24dbede to solve locally your issue.
I will provide a release soon to fix it at least on conda. Thanks again for the quick report.
https://github.com/stack-of-tasks/pinocchio/commit/24dbede81e884dc0be2bb05ecd1d3f7171cba982 solves the problem with Talos and Pinocchio 2.6.2. However, when I try to load the iCub (robotology/icub-models#97) the meshes are not scaled
without 24dbede the meshes are scaled even if the robot is not correctly loaded
Adding the following lines after
q0 = pin.neutral(model)
viz.display(q0)
viz.loadViewerModel()
here, the robot is scaled and in the neutral configuration.
Looking in the code seems the meshes are scaled only when display
is called (e.g. https://github.com/stack-of-tasks/pinocchio/pull/1472/commits/50f49cc7fc3ddd110f4bd09d381b9afb081e7ffa). Is it wanted?
I've just update #1472 to also scale the geometries when loading the meshes.
Yet, it seems that there is a bug within MeshCat to use the scaling information when changing the placement (via set_transform
).
Small remark: according to https://github.com/rdeits/meshcat/blob/1ea52a649c0c8df800587b54d0910ef2868f8de5/src/index.js#L357-L361, it seems that Meshcat erases the previous scaling.
Solved by #1472
Thanks a lot @jcarpent for the fix!
Hello, I am trying to reproduce the exact scenario as above. The iCub model loads to the viewer by,
viz.initViewer(loadModel=True)
as shown below,
However, when I modify the pose of the robot (or even in neutral) by setting certain angles and upon visualising it using,
q0 = pin.neutral(robot.model())
viz.display(q0)
the robot model completely disappears from the meshcat
viewer. I suspect this has to do with the scaling too.
My setup: Ubuntu 20.04
, pinocchio-2.6.0
Could you use a more recent version of Pinocchio?
Thanks for a super quick reply. I had a bunch of dependency issues between tsid
and pinocchio
versions. But finally pinocchio=2.6.3
with tsid=1.6.1
fixed the issue.
I think the problem experienced by @akhilsathuluri comes from the fact that there is no tsid
build with a recent urdfdom release. This should be fixed in the short term by https://github.com/conda-forge/tsid-feedstock/pull/8, and https://github.com/conda-forge/conda-forge-pinning-feedstock/pull/2925 should avoid that this problem occurs again in the future.
Hi all, first of all, thank you for the effort to develop and maintain
pinocchio
.I was trying to visualize the Talos robot following this example. However I noticed that the model is not correctly loaded in meshcat.
Indeed there seems that the right shoulder and the legs are not correctly attached to the robot body.
I installed
meshcat
andpinocchio
with conda in a cleanUbuntu 20.04
distro.For reference, my packages are:
Could you help me to solve this issue? Thank you in advance
cc @traversaro