java.io.IOException (It may not exist or you do not have permission to read it)

Provide easy-to-use, extensible software for modeling, simulating, controlling, and analyzing the neuromusculoskeletal system.
POST REPLY
User avatar
Aparecida Falcão de Andrade
Posts: 4
Joined: Tue Nov 24, 2020 4:13 pm

java.io.IOException (It may not exist or you do not have permission to read it)

Post by Aparecida Falcão de Andrade » Thu Mar 17, 2022 3:05 pm

Hello guys,

Has anyone had the problem below?

java.io.IOException: Object: Cannot open file Model/FESCyclingModel.osim. It may not exist or you do not have permission to read it. Thrown at Object.cpp:105 in Object(). at org.opensim.modeling.opensimSimulationJNI.new_Model__SWIG_1(Native Method) at org.opensim.modeling.Model.<init>(Model.java:821)

Tags:

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

Re: java.io.IOException (It may not exist or you do not have permission to read it)

Post by Thomas Uchida » Thu Mar 17, 2022 3:49 pm

The exception is thrown from line 105 of object.cpp: https://github.com/opensim-org/opensim- ... t.cpp#L102. The file cannot be read. Perhaps the file does not exist, it resides on a directory to which OpenSim does not have access (e.g., in Program Files if you are using a Windows machine), or the file is locked by another program (sharing violation).


User avatar
Aparecida Falcão de Andrade
Posts: 4
Joined: Tue Nov 24, 2020 4:13 pm

Re: java.io.IOException (It may not exist or you do not have permission to read it)

Post by Aparecida Falcão de Andrade » Mon Apr 11, 2022 2:40 pm

Hi Thomas,

I already reinstalled Opensim following the tutorial (https://simtk-confluence.stanford.edu:8 ... ith+Matlab).

I did the installation in public folders, the simulation files are in Windows public folders, however, the error persists, do you have any idea what it could be?

I've had this problem for days and I can't solve it.

Note: I have already reinstalled Windows and Matlab =/

Thank you in advance for your attention.

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

Re: java.io.IOException (It may not exist or you do not have permission to read it)

Post by Thomas Uchida » Mon Apr 11, 2022 3:12 pm

Some things you might want to try to narrow down the issue: Does the model open in the GUI and are any warnings or errors displayed? Do other models open in Matlab or do all models fail to open?

User avatar
Aparecida Falcão de Andrade
Posts: 4
Joined: Tue Nov 24, 2020 4:13 pm

Re: java.io.IOException (It may not exist or you do not have permission to read it)

Post by Aparecida Falcão de Andrade » Sat Apr 16, 2022 7:12 am

Hello John,

Thanks for your feedback once again! :D

I managed to find the error, it was in the Matlab Path, it was finding ambiguity in the functions it was using for the simulations, after correcting the Path problems it returned to work normally.

Thank you!

POST REPLY