martinling / imusim Goto Github PK
View Code? Open in Web Editor NEWIMUSim - see http://www.imusim.org/
License: GNU General Public License v3.0
IMUSim - see http://www.imusim.org/
License: GNU General Public License v3.0
Hey,
I am trying to run the InteractiveAnimation
with a bvh file input (downloaded for examples), seems there is a type discrepancy in the python layer, the method is expecting the vector
field to exist
but the object passed in doesn't contain this field.
Located error from stack trace:
File "/Library/Python/2.7/site-packages/imusim-0.2-py2.7-macosx-10.13-intel.egg/imusim/visualisation/rendering.py", line 187, in renderUpdate
s.set(x=x, y=y, z=z)
File "/Library/Python/2.7/site-packages/mayavi/tools/sources.py", line 106, in set
self.update()
File "/Library/Python/2.7/site-packages/mayavi/tools/sources.py", line 74, in update
(self.scalars is not None or self.vectors is not None):
AttributeError: 'MLineSource' object has no attribute 'vectors'
This is my python code:
# Import symbols from IMUSim
from imusim.all import *
model = loadBVHFile('walk.bvh', CM_TO_M_CONVERSION)# the file is in the current directory and is loaded properly.
print(CM_TO_M_CONVERSION)
renderer = BodyModelRenderer(model)
start = model.startTime
end = model.endTime
animation = InteractiveAnimation(start, end, renderer) #failure point.
Full stack trace including C assertion problems.
/Library/Python/2.7/site-packages/pyface/ui/wx/action/action_item.py:367: wxPyDeprecationWarning: Call to deprecated item. Use :meth:`AddTool` instead.
self.control_id, label, bmp, wx.NullBitmap, kind, tooltip, longtip, None
/Library/Python/2.7/site-packages/pyface/ui/wx/action/action_item.py:385: wxPyDeprecationWarning: Call to deprecated item __call__. Use :meth:`EvtHandler.Bind` instead.
wx.EVT_TOOL(parent, self.control_id, self._on_tool)
Traceback (most recent call last):
File "imusim_biovision.py", line 13, in <module>
animation = InteractiveAnimation(start, end, renderer)
File "/Library/Python/2.7/site-packages/imusim-0.2-py2.7-macosx-10.13-intel.egg/imusim/visualisation/rendering.py", line 72, in __init__
r.renderUpdate(self.time)
File "/Library/Python/2.7/site-packages/imusim-0.2-py2.7-macosx-10.13-intel.egg/imusim/visualisation/rendering.py", line 187, in renderUpdate
s.set(x=x, y=y, z=z)
File "/Library/Python/2.7/site-packages/mayavi/tools/sources.py", line 106, in set
self.update()
File "/Library/Python/2.7/site-packages/mayavi/tools/sources.py", line 74, in update
(self.scalars is not None or self.vectors is not None):
AttributeError: 'MLineSource' object has no attribute 'vectors'
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/atexit.py", line 24, in _run_exitfuncs
func(*targs, **kargs)
wxAssertionError: C++ assertion "GetEventHandler() == this" failed at /Users/robind/projects/buildbots/macosx-vm6/dist-osx-py27/Phoenix/ext/wxWidgets/src/common/wincmn.cpp(478) in ~wxWindowBase(): any pushed event handlers must have been removed
Error in sys.exitfunc:
Traceback (most recent call last):
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/atexit.py", line 24, in _run_exitfuncs
func(*targs, **kargs)
wx._core.wxAssertionError: C++ assertion "GetEventHandler() == this" failed at /Users/robind/projects/buildbots/macosx-vm6/dist-osx-py27/Phoenix/ext/wxWidgets/src/common/wincmn.cpp(478) in ~wxWindowBase(): any pushed event handlers must have been removed
Let me know if you have any ideas on how to fix this.
Thanks.
Cheers.
It would be nice to have IMUSim work with Python 3.
As such, it is fairly non-functional on current platforms.
SimPy changed to simpy, and SimPy.Simulation seems to no longer exist.
imusim seems to be fairly deeply dependent on SimPy.Simulation.
Is this fixable, or is the dependency too deep?
Hi Martin,
could you please provide the API document again as the homepage now is not available.
Thank you very much!
Best regards,
Thomas
Hi,
hope the project is maintained, as this is one and only realistic IMU simulator for mocap.
The sensor reading from a motion also depends on the initial starting sensor orientation.
Is there a way to define initial sensor placement, and then to track the trajectory?
Thank you.
Hi, I am using ubuntu 14.04 to install the imusim, but i meet the following problem, it says can not find the quaternions.c file. I have search the whole repository, also cannot find it. Is there anyone can help me? Thanks very much!
Here are the part of the instructions:
building 'imusim.maths.quaternions' extension
x86_64-linux-gnu-gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -I/usr/lib/python2.7/dist-packages/numpy/core/include -I/usr/include/python2.7 -c imusim/maths/quaternions.c -o build/temp.linux-x86_64-2.7/imusim/maths/quaternions.o
x86_64-linux-gnu-gcc: error: imusim/maths/quaternions.c: No such file or directory
x86_64-linux-gnu-gcc: fatal error: no input files
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 4
...
cpdef inline Quaternion log(Quaternion self):
imusim/maths/quaternions.pyx:293:10: Only final types can have final Python (def/cpdef) methods
Works fine with Cython version 0.14.1
[Note that my cython 0.17.4 is on MacOSX 10.8 with macports]
Trying to install on Mac OSX Sierra with gcc c++11
After installing vtk
cython -a imusim/maths/*.pyx
sudo python setup.py build (getting error here)
imusim/maths/quat_splines.c:1781:8: error: 'inline' can only appear on functions static CYTHON_INLINE void (*__pyx_f_6imusim_5maths_11quaternions_mult_quat_quat)
can you provide a docker for this(imusim) instead?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.