opensim-org / opensim-core

SimTK OpenSim C++ libraries and command-line applications, and Java/Python wrapping.
https://opensim.stanford.edu
Apache License 2.0
763 stars 308 forks source link

Scale Tool deletes markers if they are not in .trc file #2406

Open clnsmith opened 5 years ago

clnsmith commented 5 years ago

For the Scale Tool in the GUI and MATLAB scripting, if markers are not in the .trc file they are not written in the output scaled model.

clnsmith commented 5 years ago

Ahh now I see this is a feature, not a bug...

From the gui output : "Deleted 12 unused markers from model FullBodyModel_MuscleActuatedLowerLimb_TorqueActuatedUpperBody-scaled"

In which case it would be nice to have a flag to turn this on or off.

clnsmith commented 5 years ago

... and now I found a real bug.

Only tested in the 4.0 GUI.

I added markers to the .trc file with all zeros for x, y, z so that they would not be deleted by the marker placer (they are all "fixed" in the model). In the "Static Pose Weights" pane, these new markers are all listed as NOT enabled (with a weight of 0.0). However, the resulting static pose is disfigured (as if it is still using these markers to determine the static pose). If I repeat, but now list the markers as enabled but with a weight of 0.0, the static pose appears to be OK.

Unfortunately I am not sure that I can publically share the .trc files I am working with at the moment to make this easy to recreate.

aseth1 commented 5 years ago

@clnsmith it does sound like a bug. Do you think you could reproduce on a simple model and send us that so you don't have to share your working files?

clnsmith commented 5 years ago

@aseth1 Yes. I'll upload an example this week.