Hi,
There's a Windows and a Mac build of the following plugin, but no Linux version ( https://simtk.org/frs/?group_id=986 sources here: https://github.com/opensim-org/Scapulot ... ointPlugin)
Supposing the building it from source is straight forward (bonus point for anyone with a binary), where should we locate the plugin files in Linux (in Windows it's "[INSTALL_DIR] \ plugins") ?
Thanks!
Linux load plugin
- Andrew Stolin
- Posts: 12
- Joined: Thu Mar 05, 2015 9:41 am
- Dimitar Stanev
- Posts: 1096
- Joined: Fri Jan 31, 2014 5:14 am
Re: Linux load plugin
Hi Andrew,
I have a tutorial example where I extend OpenSim by implementing a hypothetical force component (the same can be done with PrescribedForce):
https://github.com/mitkof6/OpenSim_API_ ... tion_force
After this is compiled and tested, one can load the dynamic library and use the component (e.g., Python, Matlab, command line tools). However, not through the API, but in the .osim file of the model. For this to be exposed to the API, a different approach must be followed.
I have a tutorial example where I extend OpenSim by implementing a hypothetical force component (the same can be done with PrescribedForce):
https://github.com/mitkof6/OpenSim_API_ ... tion_force
After this is compiled and tested, one can load the dynamic library and use the component (e.g., Python, Matlab, command line tools). However, not through the API, but in the .osim file of the model. For this to be exposed to the API, a different approach must be followed.
- Ayman Habib
- Posts: 2248
- Joined: Fri Apr 01, 2005 12:24 pm
Re: Linux load plugin
Hi Andrew,
Do you plan to use the plugin in Matlab, python or in a local build of the opensim GUI on linux? The location for windows is only assumed for automatic loading in the GUI, otherwise you specify the location of the shared library on the command line (for command line operation using opensim-cmd) or you can use the instructions on the page below to load plugins in Matlab, python
https://simtk-confluence.stanford.edu/d ... ng+Plugins
Please let us know how it goes,
-Ayman
Do you plan to use the plugin in Matlab, python or in a local build of the opensim GUI on linux? The location for windows is only assumed for automatic loading in the GUI, otherwise you specify the location of the shared library on the command line (for command line operation using opensim-cmd) or you can use the instructions on the page below to load plugins in Matlab, python
https://simtk-confluence.stanford.edu/d ... ng+Plugins
Please let us know how it goes,
-Ayman
- Andrew Stolin
- Posts: 12
- Joined: Thu Mar 05, 2015 9:41 am
Re: Linux load plugin
Thank you both, it worked perfectly after following the instructions at https://github.com/mitkof6/OpenSim_API_ ... tion_force and loading within python with
Code: Select all
lib = opensim.LoadOpenSimLibraryExact('libScapulothoracicJointPlugin40.so')