splintered-reality/py_trees

Python implementation of behaviour trees.

What it solves

PyTrees is designed to simplify the creation of decision-making engines for medium-sized projects, particularly in robotics, by providing a structured way to organize complex behaviors.

How it works

It implements behavior trees, which allow developers to build logic flows using a variety of components:

  • Core Components: Includes Behaviours, Decorators, Sequences, Selectors, and Parallels.
  • Data Management: Uses "Blackboards" for sharing data across different parts of the tree.
  • Declarative Definitions: Supports an XML parser and a ports API for defining behaviors declaratively.
  • Visualization: Can render trees as ASCII/Unicode in the terminal or serialize them into dot graphs for visual analysis.

Who it’s for

It is primarily aimed at developers working in robotics or other fields requiring structured decision-making logic.

Highlights

  • Comprehensive Library: Comes with a built-in library of behaviors, decorators, and common idioms.
  • Declarative Approach: Supports XML-based behavior definitions for easier configuration.
  • al Robotics Integration: Specifically designed for use in robotics, with associated libraries for ROS 2 integration.
  • Flexible Visualization: Offers multiple ways to visualize the logic flow, from simple terminal output to graph files.

Related

  • Project
  • Project
  • Project
  • Project
  • Project