Skip to content

C4dynamics/c4dynamics

Tsipor Dynamics

Algorithms Engineering and Development

Tsipor (bird) Dynamics (c4dynamics) is the Python framework for state-space modeling and algorithm development.

Static Badge PyPI - Version GitHub deployments GitHub Actions Workflow Status GitHub Actions Workflow Status Pepy Total Downloads

Documentation

Why c4dynamics?

✅ State objects for easy modeling

✅ Built-in functions for Kalman filters

✅ Integrated sensors and object detection models

✅ Out-of-the-box environments for reinforcement learning

✅ Seamless integration with OpenCV & Open3D

✅ Optimization for Monte Carlo simulations

c4dynamics is designed to simplify the development of algorithms for dynamic systems, using state space representations. It offers engineers and researchers a systematic approach to model, simulate, and control systems in fields like robotics, aerospace, and navigation.

The framework introduces state objects, which are foundational data structures that encapsulate state vectors and provide the tools for managing data, simulating system behavior, and analyzing results.

With integrated modules for sensors, detectors, and filters, c4dynamics accelerates algorithm development while maintaining flexibility and scalability.

Requirements

Installation

For detailed instructions on installing c4dynamics, including setup for virtual environments, Python version requirements, and troubleshooting, refer to the c4dynamics setup guide.

>>> pip install c4dynamics

To run the latest GitHub version, download the repo and install required packages:

>>> pip install -r requirements.txt

Quickstart

Import c4dynamics:

>>> import c4dynamics as c4d

Define state space object of two variables in the state space (y, vy) with initial conditions (change the state with your variables):

>>> s = c4d.state(y = 1, vy = 0.5)

Multiply the state vector by a matrix and store:

>>> F = [[1, 1],                      
         [0, 1]]              
>>> s.X += F @ s.X                     
>>> s.store(t = 1)                    

Print the state variables, the state vector, and the stored data:

>>> print(s)  
[ y  vy ]
>>> s.X 
[2.5  1]
>>> s.data('y') 
([0,  1], [1,  2.5])

Support

If you encounter problems, have questions, or would like to suggest improvements, please open an Issue in this repository.

New in Block 2

Enhancements and modules in latest release:

  • Complete state space objects mechanism
  • Seeker and radar measurements
  • Kalman filter and Extended Kalman filter
  • YOLOv3 object detection API
  • Datasets fetching to run examples
  • Documentation