GithubHelp home page GithubHelp logo

honglinchu / anim_utils Goto Github PK

View Code? Open in Web Editor NEW

This project forked from eherr/anim_utils

0.0 0.0 0.0 368 KB

Data structures and utilities for skeleton animations.

License: Other

Python 100.00%

anim_utils's Introduction

Skeleton Animation Utilities

Utility functions and data structures for skeleton animations loaded from BVH and ASF/AMC files. The library provides functions for inverse kinematics and retargeting. The main dependency, in addition to NumPy, SciPy and Matplotlib, is the transformations library by Christoph Gohlke https://www.lfd.uci.edu/~gohlke/.

Installation

Clone the repository and install the package with editable flag or use the follwing command:

pip install git+https://github.com/eherr/anim_utils

The optional FBX IO requires the Python FBX SDK

Example

from anim_utils.animation_data import BVHReader, MotionVector, SkeletonBuilder   

bvh = BVHReader("example.bvh")   
mv = MotionVector()  
mv.from_bvh_reader(bvh)  
skeleton = SkeletonBuilder().load_from_bvh(bvh)  
point_clouds = []  
for frame in mv.frames:  
    point_cloud = []  
    for j in skeleton.animated_joints:  
        p = skeleton.nodes[j].get_global_position(frame)  
        point_cloud.append(p)  
    point_clouds.append(point_cloud)

A retargeting script can be found in the example directory.

Developers

Erik Herrmann1, Han Du1, Martin Manns2, Markus Mauer2

1DFKI GmbH
2Daimler AG

License

Copyright (c) 2019 DFKI GmbH.
MIT License, see the LICENSE file.

Contributions by Daimler AG in the following files are also licensed under terms of the MIT license: anim_utils/animation_data/bvh.py
anim_utils/animation_data/utils.py

Each file contains a copyright notice.

anim_utils's People

Contributors

eherr avatar jsprenger2 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.