How to use Analyze tool in OpenSim API

Provide easy-to-use, extensible software for modeling, simulating, controlling, and analyzing the neuromusculoskeletal system.
POST REPLY
User avatar
amirreza kebritchi
Posts: 1
Joined: Thu Oct 29, 2020 10:40 am

How to use Analyze tool in OpenSim API

Post by amirreza kebritchi » Fri May 28, 2021 8:51 am

Hi everyone,
I want to estimate joint reaction forces using scripting in OpenSim, but when I use modeling.AnalyzeTool() to construct the analyze tool from my XML, it always fails to run, the error is like the following while I am sure that XML is right and the input files are in the folder, I am wondering why they could not be found, can anyone help me with this? or give me an example that works when using Analyze tool? I really appreciate your help.
analyzeTool.run()
at org.opensim.modeling.opensimModelJNI.AnalyzeTool_run__SWIG_0(Native Method)
at org.opensim.modeling.AnalyzeTool.run(AnalyzeTool.java:154)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)

java.io.IOException: java.io.IOException: Object: ERR- Could not open file subject01_walk1_grf.xml. It may not exist or you don't have permission to read it.

Tags:

User avatar
Thomas Uchida
Posts: 1790
Joined: Wed May 16, 2012 11:40 am

Re: How to use Analyze tool in OpenSim API

Post by Thomas Uchida » Sat May 29, 2021 6:18 am

It may not exist or you don't have permission to read it.
I suggest providing a full path to the file (e.g., "C:\..."). If you provide only the file name, generally the file must reside in the directory where "out.log" appears when you run the Tool, which may not be the directory in which your model file resides.

POST REPLY