Basic Questions about the Functionality
- Fabian Bayerlein
- Posts: 18
- Joined: Fri Apr 05, 2013 2:12 pm
Basic Questions about the Functionality
Hi,
I am an absolute newbie to both OpenSim and this board, but I hope there's someone out there willing to answer some basic questions.
I want to conduct research in the area of human walking in combination with different kinds of mounted springs and therefore I need a software with the following functionality:
1) Output the load in every muscle over a walking cycle
2) Alter this data in an automatic way
3) Use altered data as Input for simulation
4) Add elements like springs and dampers to different joints
5) Automatically start an energy minimization study with a set of specific parameters and gather the results
Does OpenSim offer this functionality, or is it rather easy to extend it with this functionality?
Also: What would be the best way to enhance functionality? I already have Matlab installed but I'm also willing to dig into C++.
Any reply is highly appreciated, thank you for your time!
Fabian
I am an absolute newbie to both OpenSim and this board, but I hope there's someone out there willing to answer some basic questions.
I want to conduct research in the area of human walking in combination with different kinds of mounted springs and therefore I need a software with the following functionality:
1) Output the load in every muscle over a walking cycle
2) Alter this data in an automatic way
3) Use altered data as Input for simulation
4) Add elements like springs and dampers to different joints
5) Automatically start an energy minimization study with a set of specific parameters and gather the results
Does OpenSim offer this functionality, or is it rather easy to extend it with this functionality?
Also: What would be the best way to enhance functionality? I already have Matlab installed but I'm also willing to dig into C++.
Any reply is highly appreciated, thank you for your time!
Fabian
- David John Saxby
- Posts: 83
- Joined: Mon May 09, 2011 8:39 pm
Re: Basic Questions about the Functionality
Hi Fabian,
I can comment on what I know OpenSim can do through my own experience, but I think generally you will find most of your goals can be satisfied by OpenSim in theory.
1) Yes you can solve for muscle forces in OpenSim through static optimization and/or CMC. Or potentially by creating your own plugin for a custom muscle force solver.
2) I'm not sure what you mean by automated other than that a computer does it for you . You can certainly change the solution from SO or CMC by altering the muscles in the model (max isometric force, geometry, etc...) or by changing the model's kinematics in some way. You would naturally need a rationale for making these modification other than to test the solver's response to perturbations of the model components/states.
3) Yes you can drive a forward simulation with an arbitrary set of forces. You might get funny results if your system is not dynamically consistent though.
4) Now this is where my personal experience stops, but people in my research group have some experience in this area. Yes damping is possible, and different forms of contact between bodies can be modeled.
5) If I recall is now a metabolic plugin. http://simtk-confluence.stanford.edu:80 ... yzeDevices. I've never used it, but it is published. I think basically you need some measure of muscle activation and it works out metabolic cost from that.
I can't program worth beans in C++, so I use Matlab. With the new scripting tools in OpenSim you can access the entire hierarchy of C++ constructs with a Matlab wrapper around so you can call the API directly. I don't know if the scripting will be extended deeper into the core, SimTK, Simbody, SimMath, etc...If the scripting is advanced it will only strengthen the flexibility of OpenSim.
The scripting tools have proved robust and efficient when dealing with my large data set, and when automation is needed.
Hope that helps,
David
I can comment on what I know OpenSim can do through my own experience, but I think generally you will find most of your goals can be satisfied by OpenSim in theory.
1) Yes you can solve for muscle forces in OpenSim through static optimization and/or CMC. Or potentially by creating your own plugin for a custom muscle force solver.
2) I'm not sure what you mean by automated other than that a computer does it for you . You can certainly change the solution from SO or CMC by altering the muscles in the model (max isometric force, geometry, etc...) or by changing the model's kinematics in some way. You would naturally need a rationale for making these modification other than to test the solver's response to perturbations of the model components/states.
3) Yes you can drive a forward simulation with an arbitrary set of forces. You might get funny results if your system is not dynamically consistent though.
4) Now this is where my personal experience stops, but people in my research group have some experience in this area. Yes damping is possible, and different forms of contact between bodies can be modeled.
5) If I recall is now a metabolic plugin. http://simtk-confluence.stanford.edu:80 ... yzeDevices. I've never used it, but it is published. I think basically you need some measure of muscle activation and it works out metabolic cost from that.
I can't program worth beans in C++, so I use Matlab. With the new scripting tools in OpenSim you can access the entire hierarchy of C++ constructs with a Matlab wrapper around so you can call the API directly. I don't know if the scripting will be extended deeper into the core, SimTK, Simbody, SimMath, etc...If the scripting is advanced it will only strengthen the flexibility of OpenSim.
The scripting tools have proved robust and efficient when dealing with my large data set, and when automation is needed.
Hope that helps,
David
- Fabian Bayerlein
- Posts: 18
- Joined: Fri Apr 05, 2013 2:12 pm
Re: Basic Questions about the Functionality
Hi David,
thank you for your answer, that's a lot of useful information!
Seems like I still got a lot of reading to do, but at least I know the directions now (:
Thank you again,
Fabian
thank you for your answer, that's a lot of useful information!
Seems like I still got a lot of reading to do, but at least I know the directions now (:
Thank you again,
Fabian
- Fabian Bayerlein
- Posts: 18
- Joined: Fri Apr 05, 2013 2:12 pm
Re: Basic Questions about the Functionality
Hello everybody,
and the struggle continues:
I'm currently trying to reproduce the tug-of-war example in its most simple form, just creating a model and naming it.
I'm getting strange errors like "buffer overrun", "access violation" etc.
I'm using Visual Studio 2012 Ultimate (free for me), might this be the problem?
I've also tried Visual Studio 2010 Express, but here CMake aborts due to the "C Compiler not able to build a simple program" error. What can I do to find out, what I'm doing wrong?
Any reply is appreciated, thank you for your time.
Fabian
and the struggle continues:
I'm currently trying to reproduce the tug-of-war example in its most simple form, just creating a model and naming it.
I'm getting strange errors like "buffer overrun", "access violation" etc.
I'm using Visual Studio 2012 Ultimate (free for me), might this be the problem?
I've also tried Visual Studio 2010 Express, but here CMake aborts due to the "C Compiler not able to build a simple program" error. What can I do to find out, what I'm doing wrong?
Any reply is appreciated, thank you for your time.
Fabian
- Ayman Habib
- Posts: 2252
- Joined: Fri Apr 01, 2005 12:24 pm
Re: Basic Questions about the Functionality
Hi Fabian,
Sorry to hear that you're running into problems.
We had many users on various incarnations of VisualStudio 2010, but very few on 2012 (either Professional, Express or Ultimate). Your best bet would be to build from sources to avoid potential compatibility issues and also so it's easier to debug. Please consult the page below for instructions on building from source
http://simtk-confluence.stanford.edu:80 ... rom+Source
If you want to continue using an installed version of OpenSim, please send us the name of the specific version/installer and we'll figure out if it's a compatibility issue or something else on our side.
Best regards,
-Ayman
Sorry to hear that you're running into problems.
We had many users on various incarnations of VisualStudio 2010, but very few on 2012 (either Professional, Express or Ultimate). Your best bet would be to build from sources to avoid potential compatibility issues and also so it's easier to debug. Please consult the page below for instructions on building from source
http://simtk-confluence.stanford.edu:80 ... rom+Source
If you want to continue using an installed version of OpenSim, please send us the name of the specific version/installer and we'll figure out if it's a compatibility issue or something else on our side.
Best regards,
-Ayman
- Fabian Bayerlein
- Posts: 18
- Joined: Fri Apr 05, 2013 2:12 pm
Re: Basic Questions about the Functionality
Hello Ayman,
that's ok, errors always force a better understanding of the process, which is not a bad thing at all.
Thank you for your fast reply.
I will try building from source then, hopefully that resolves my problems.
If not, I will inquire this board again.
Thank you for your help,
Fabian
that's ok, errors always force a better understanding of the process, which is not a bad thing at all.
Thank you for your fast reply.
I will try building from source then, hopefully that resolves my problems.
If not, I will inquire this board again.
Thank you for your help,
Fabian
- Fabian Bayerlein
- Posts: 18
- Joined: Fri Apr 05, 2013 2:12 pm
Re: Basic Questions about the Functionality
Hi,
so I tried building Simbody from Source two times, but it's not building properly. I appended a screenshot of my Cmake configuration and the build output of visual studio for further informations.
To sum up my problem: I want to be able to add functionality to OpenSim in any way. Whether it's a plug in, a standalone executable or all built from source, just anything that works.
Being a student, I can get every possible version of Visual Studio (Currently I have VS2012 Ultimate and VS2010 Pro installed), but unfortunately I did not find a combination of IDE and OpenSim application that works ...
so I tried building Simbody from Source two times, but it's not building properly. I appended a screenshot of my Cmake configuration and the build output of visual studio for further informations.
To sum up my problem: I want to be able to add functionality to OpenSim in any way. Whether it's a plug in, a standalone executable or all built from source, just anything that works.
Being a student, I can get every possible version of Visual Studio (Currently I have VS2012 Ultimate and VS2010 Pro installed), but unfortunately I did not find a combination of IDE and OpenSim application that works ...
- Attachments
-
- simbody_build.txt
- Build output
- (107.95 KiB) Downloaded 90 times
- Fabian Bayerlein
- Posts: 18
- Joined: Fri Apr 05, 2013 2:12 pm
Re: Basic Questions about the Functionality
Hi,
I also tried installing OpenSim 3.0 and building the tugOfWar example again, but it's not building properly either.
I appended the corresponding screenshots. I'm probably just missing something. Thank you for your time.
Best Regards,
Fabian
I also tried installing OpenSim 3.0 and building the tugOfWar example again, but it's not building properly either.
I appended the corresponding screenshots. I'm probably just missing something. Thank you for your time.
Best Regards,
Fabian
- Ayman Habib
- Posts: 2252
- Joined: Fri Apr 01, 2005 12:24 pm
Re: Basic Questions about the Functionality
Hi Fabian,
If you have both VS 2010 and 2012, I'd stay with 2010 as a more traveled route unless you're building from source. I'm suspecting the two installations of VisualStudio on your machine are confusing CMake so it ends up not knowing whether to build 64bit or 32bit. The libraries provided are all 32bit. Can you verify that this is the configuration you're building?
Thanks,
-Ayman
If you have both VS 2010 and 2012, I'd stay with 2010 as a more traveled route unless you're building from source. I'm suspecting the two installations of VisualStudio on your machine are confusing CMake so it ends up not knowing whether to build 64bit or 32bit. The libraries provided are all 32bit. Can you verify that this is the configuration you're building?
Thanks,
-Ayman
- Michael Sherman
- Posts: 812
- Joined: Fri Apr 01, 2005 6:05 pm
Re: Basic Questions about the Functionality
Hi, Fabian and Ayman. On my Windows 7 machine I have Visual Studio 2008, 2010, and 2012 (all Pro) installed and I successfully build both 32 and 64 bit binaries. So I don't think there is any problem mixing the various versions. I am not so confident about mixing Express and Professional versions, though -- I don't think those can be mixed successfully.
In any case, VS 2012 has bugs that prevent it from building Simbody successfully. I reported them to Microsoft, they confirmed the bugs and said the fixes will be in the next update (the are not in update 2 that just came out). So Fabian, you will have to use VS 2010. If you have 2010 Pro, that matches the OpenSim 3.0.1 binary posted on Simtk.org so you wouldn't need to build from source if you are just making a plugin. Otherwise, you should be able to build from source without much trouble since that is the same compiler we used.
I couldn't tell from your screenshots what if anything is wrong. One reminder -- you need to delete the cache in CMake for any changes to take effect. If in doubt, delete the whole build directory and start again.
Regards,
Sherm
In any case, VS 2012 has bugs that prevent it from building Simbody successfully. I reported them to Microsoft, they confirmed the bugs and said the fixes will be in the next update (the are not in update 2 that just came out). So Fabian, you will have to use VS 2010. If you have 2010 Pro, that matches the OpenSim 3.0.1 binary posted on Simtk.org so you wouldn't need to build from source if you are just making a plugin. Otherwise, you should be able to build from source without much trouble since that is the same compiler we used.
I couldn't tell from your screenshots what if anything is wrong. One reminder -- you need to delete the cache in CMake for any changes to take effect. If in doubt, delete the whole build directory and start again.
Regards,
Sherm