Comments (3)
Is this inherited from BTK? FindChild() used to segfault in python when asked for the contents of a node that did not exist. I favoured GetChild()
from openma.
@marnunez There is a confusion between the method btk::MetaData::FindChild()
and the method ma::Node::findChild()
. Both are not related.
The latter is used to retrieve any child in a tree-like structure. For example, the output of the line my_root = ma::io::read('myfile.ext')
is a tree structure like in the following image.
Usages of ma::Node::findChild()
in Python to access data can be:
ts1 = root.findChild(ma.T_TimeSequence,‘my_ts1’);
evt1 = trial.findChild(ma.T_Event,‘my_evt1’);
The Python documentation is not available (every contribution is welcomed!). However, the C++ documentation ma::node::findChild
may help you to understand its behaviour. The difference between both is the way to manage the template parameter. The first parameter of the Python method corresponds to the template parameter passed in C++. For example
// C++
auto ts1 = root.findChild<ma::TimeSequence>(‘my_ts1’);
# Python
ts1 = root.findChild(ma.T_TimeSequence,‘my_ts1’);
from openma.
@Alzathar Thanks for the clarification! This looks far more versatile. I'll play around some more as soon as I get the python bindings compiled.
from openma.
Related Issues (20)
- Review Doxygen properties' name
- The parser for the TRC files in BTK is too strict an needs to be improved in OpenMA
- Unable to install, no INCLUDES exists HOT 6
- change FindNumPy.cmake for FindNumpy.cmake HOT 6
- Improve the error message when markers are missing to calibrate/reconstruct a model
- SkeletonHelper static properties are not copied in generated models
- Missing documentation for general internal concepts
- Missing documentation for the Python bindings
- Missing documentation for the Matlab bindings
- Implement the plugin mechanism
- Plugin for the Motion Analysis Corp. formats
- Plugin for the Charnwood Dynamics Ltd (Codamotion) formats
- Plugin for the BTS Bioengineering formats
- Trim/cut/resize operations on trial
- Building on Windows 7 with minGW 5.3.0 HOT 4
- Errors in the coveralls script
- Importing vertices data from c3d file HOT 5
- Update all the unit tests to use Catch instead of CxxTest
- Plugins for the Delsys file formats
- Thank you for openma HOT 10
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from openma.