I need to calculate the spring damper system and try PyODE. It seems that there is also a similar thing called Pybullet. (Please let me know if you have other alternative options)
The author has run the C / C ++ version of ODE about 5 years ago (around 2015). But ... I can't remember almost anything. I usually use Python now, so I'll try using PyODE.
Work time: April 2020 ・ Windows 10 ・ Python 3.8.0 64bit version
↓ I proceeded with reference to here. https://algorithm.joho.info/programming/python/pyode-install/
There is a Windows installer on sourceforge, but it must be Python2 (2.5 or 2.6) and it is the 2010 version, so it is excluded from the options. (Link → http://pyode.sourceforge.net/#download) The conclusion is "no need to use the installer".
Get the whl file according to reference site mentioned above File name: ode-0.15.2-cp38-cp38-win_amd64.whl
Open PowerShell in the save destination of whl. (For example, "Shift" + right click) Install with pip command:
Installation with pip
C:\Python380\python.exe -m pip install .\ode-0.15.2-cp38-cp38-win_amd64.whl
(I'm going to call pip with the "-m" option)
Result: "Successfully installed ode-0.15.2" I didn't have any trouble.
PyODE does not have a visualization function. (How was C ++ ODE? I think that OpenGL-like drawing could be used as standard)
For visualization packages combined with PyODE ・ VPython ・ Pygame ・ PyOpenGL ・ PyOgre There are four candidates. (Not famous) The classic one in the past seems to be "VPython". I tried this "VPython" at first, but there was a problem After all, I moved to "Pygame"
2.1 About VPython I installed the latest "version 7" and tried it. -There was a big change when changing from version "5" to "6", and it seems that there is also a considerable change from "6" to "7". There are few samples and articles that can be used in the current version. -The current version is output on the Web browser like "WebGL"
It turns out that. It was hard to handle I gave up using "VPython" and moved to "Pygame".
2.2 pygame I will use this for the time being. Compared to PyOpenGL and PyOgre, I think the amount of description will be smaller. I was able to install the latest version with pip.
2.3 PyOpenGL The installation took a lot of work. (I couldn't get it from pip → See Tutorial 3) More description than VPython or Pygame.
2.4 PyOgre I haven't tried it yet. There is a story that ODE is built in PyOgre.
There are three tutorials on the original PyODE site. Please also see the article conducted in the foreground.
・ PyODE Tutorial 1 Description: "Falling object" (without ground)
・ PyODE Tutorial 2 Summary: "2D drawing with joints and pygame"
・ PyODE Tutorial 3 Summary: "Many objects falling and stacking and 3D drawing with PyOpenGL" Ground, contact
Recommended Posts