Page 1 of 1

I'm receiving the following error message when scaling

Posted: Sun Mar 12, 2017 8:25 pm
by gumbygabe
java.lang.RuntimeException: SimTK Exception thrown at AssemblyCondition_Markers.h:390:
Error detected by Simbody method Markers::moveAllObservations(): Number of observations provided (29) differs from the number of observations (49) last defined with defineObservationOrder().
(Required condition '(int)observations.size() == (int)observation2marker.size()' was not met.)

at org.opensim.modeling.opensimModelJNI.OpenSimContext_processModelMarkerPlacer__SWIG_0(Native Method)
at org.opensim.modeling.OpenSimContext.processModelMarkerPlacer(OpenSimContext.java:329)
at org.opensim.tracking.ScaleToolModel$ScaleToolWorker.construct(ScaleToolModel.java:348)
at org.opensim.swingui.SwingWorker$2.run(SwingWorker.java:108)
[catch] at java.lang.Thread.run(Thread.java:745)

I'm running OpenSim 3.3 on Windows 62 bit.

I need help understanding what the number observations represent and how I can meet the 'required condition'

any help would be appreciated!

Re: I'm receiving the following error message when scaling

Posted: Sun Mar 12, 2017 11:39 pm
by tkuchida
The exception is being thrown by the Markers::moveAllObservations() method; there are some comments in the doxygen documentation here: https://simtk.org/api_docs/simbody/3.5/ ... 24544415bc (also see the class description here: https://simtk.org/api_docs/simbody/3.5/ ... ml#details). Based on the documentation, it sounds like the algorithm is expecting data for 49 markers but has been provided data for only 29. The same error message was reported on another thread (viewtopicPhpbb.php?f=91&t=7342), but unfortunately the user did not report how the issue was resolved.

Re: I'm receiving the following error message when scaling

Posted: Mon Mar 13, 2017 5:32 am
by gumbygabe
Thanks for the prompt reply, Tom. In the navigator I'm changing the number of markers but still getting the same error. I'm trying to use the one of the gaitmodels (2354) to scale a static trial with less markers. I have done this previously with an older version but is having trouble with it now. What's the best way to change the algorithm so that it expects only the 29 markers?

Re: I'm receiving the following error message when scaling

Posted: Mon Mar 13, 2017 11:25 am
by tkuchida
What's the best way to change the algorithm so that it expects only the 29 markers?
Here's what I did to change the number of markers in the experimental data from 49 to 48:
1. In subject01_static.trc: (a) changed "NumMarkers" in the header from 49 to 48, and (b) removed the last three columns of data (corresponding to the Top.Head marker).
2. In gait2354_Scale_MarkerSet.xml: removed the "<Marker name="Top.Head">" block.
3. Using the Scale Tool: changed the "torso" scaling from "use measurements" to "use manual scales" (because the existing Measurement Set used the Top.Head marker).

Re: I'm receiving the following error message when scaling

Posted: Tue Mar 14, 2017 12:29 pm
by gumbygabe
Got it to work, thank you!