Skip to content

orbbec/pyorbbecsdk

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

384 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

pyorbbecsdk

Python Bindings for Orbbec SDK v2.x
The official Python wrapper enabling developers to interface with Orbbec RGB-D cameras (Gemini, Femto, Astra series) through a clean, Pythonic API backed by native C++ performance via pybind11.

Documentation Β· PyPI Package Β· Community Β· OrbbecSDK v2 Β· Gitee Mirror

Build PyPI Python License


Branch note: This is the v2-main branch (SDK v2.x). For the legacy v1.x branch, see main. The differences between SDK v1.x and v2.x are described in the OrbbecSDK_v2 README.

Table of Contents

Overview

AMR Grocery Delivery Body Health Tracking 3D Face Payment

Supported Devices

Important:

  • Most new devices come with compatible firmware pre-installed and work out-of-the-box.
  • Starting from October 2025 (Orbbec SDK v2.5.5), devices using the OpenNI protocol will be upgraded to UVC protocol. See the upgrade document for details.
  • For legacy v1.x device support (Astra+, Astra Pro Plus, Gemini 2 XL), use the main branch.

For detailed branch comparison and device support matrix, see Introduction - Device Support Comparison.

Why pyorbbecsdk?

  • πŸ“· RGB-D streaming β€” Depth, color, and infrared streams with configurable resolution and FPS.
  • πŸ› οΈ Post-processing filters β€” Temporal, Spatial (Advanced), HoleFilling, Threshold, Decimation, Noise Removal.
  • 🎯 Depth-color alignment β€” Software AlignFilter and hardware D2C alignment.
  • ☁️ Point cloud generation β€” Colored 3D point clouds via PointCloudFilter.
  • πŸ“ Camera calibration data β€” Access intrinsics, distortion coefficients, and extrinsic transforms.
  • ⚑ Real-time performance β€” Backed by native C++ performance via pybind11.
  • 🌐 Network cameras β€” Connect to Femto Mega / Gemini 2 XL over Ethernet.
  • πŸ“¦ Pre-built wheels β€” No compilation required for Windows x64, Linux x64, and ARM64.

Getting started

The pyorbbecsdk contains all the libraries that power your camera along with tools that let you experiment with its features and settings.

To get started:

1. Install the package via PyPI (recommended) or from GitHub Release:

pip install --upgrade pyorbbecsdk2

πŸ’‘ Recommended: Use Virtual Environment

Modern systems (e.g., macOS, Ubuntu 24.04+) restrict pip installations to the system Python. Using a virtual environment avoids permission errors:

# Create and activate virtual environment
python3 -m venv orbbec_env
source orbbec_env/bin/activate  # Linux/macOS
# .\orbbec_env\Scripts\Activate.ps1  # Windows PowerShell

# Install SDK in virtual environment
pip install --upgrade pyorbbecsdk2

See Virtual Environment Guide for more options (venv, pyenv, conda).

πŸ”§ Building from Source? See the Build with UV Guide for detailed instructions.

2. Setup the environment (one-time OS-level configuration for metadata and udev rules):

# From the repository

# Windows (PowerShell β€” will auto-request Administrator)
python scripts/env_setup/setup_env.py
# Linux (will auto-request sudo)
python3 scripts/env_setup/setup_env.py

# Or from the installed package
python $(python -c "import pyorbbecsdk, os; print(os.path.dirname(pyorbbecsdk.__file__))")/shared/setup_env.py

3. Start experimenting with the SDK's Quick Start code:

from pyorbbecsdk import *

pipeline = Pipeline()
pipeline.start()                        # uses default config from OrbbecSDKConfig.xml
frames = pipeline.wait_for_frames(1000) # get synchronized Color + Depth frames

For full visualisation, check out examples/quick_start.py. Running result:

quick_start_result

Samples

The examples/ directory contains 35+ scripts organized by difficulty to start using the pyorbbecsdk with only a few lines of code.

Level Category Description
⭐ Quick Start Zero-config RGBD viewer β€” first thing to run.
⭐⭐ Beginner Hello camera, depth viz, alignment, calibration, point cloud, multi-stream, IMU, network camera, and firmware update.
⭐⭐⭐ Advanced Recording & playback, device control, filter chains, HDR, presets, depth work modes, multi-device sync, coordinate transforms, high-performance pipeline.
⭐⭐⭐⭐ Applications YOLO object detection with depth overlay; interactive depth ruler.
⭐⭐⭐⭐ LiDAR LiDAR streaming, control, recording, and playback.

See examples/README.md for the full list with per-script descriptions and device compatibility.

πŸ“š Next Steps: Explore our structured learning path from beginner to advanced β†’ Quick Start Guide - Next Steps

Supported Platforms

pyorbbecsdk supports the following operating systems and architectures. Pre-built wheels are available for all platforms via pip install --upgrade pyorbbecsdk2.

Quick Camera Evaluation

Want to test your camera without writing code? Download Orbbec Viewer β€” a standalone GUI application that lets you immediately view camera streams, adjust settings, and verify device functionality.

(Click a platform icon below to download Orbbec Viewer for your OS)

Windows
Linux x64
Linux ARM
macOS
Windows (x64) Linux (x64) Linux (ARM64) macOS (ARM)
Windows 10+ Ubuntu 18.04 / 20.04 / 22.04 Ubuntu 18.04 / 20.04 / 22.04 macOS 13.2+ (Apple Silicon / M1 and later)

Supported Python versions: Python 3.8 to 3.13

Automated Firmware Update

If you encounter errors related to firmware version mismatch, please use the automated update assistant:

python scripts/auto_update_firmware.py

This script will check your current device firmware version, guide you to download the correct firmware, and perform the firmware update safely.

For detailed device support and firmware compatibility information, see Introduction β€” v2-main Branch.

FAQ

See the full FAQ for common issues and solutions.

Community

Join the conversation and connect with other pyorbbecsdk users to share ideas, solve problems, and help make the SDK awesome.

  • GitHub Issues If you come across a bug or want to request a feature, please raise an issue in this GitHub repository.
  • Documentation The comprehensive Orbbec SDK V2 Python Wrapper User Guide covers architecture, API quick-starts, and usage guides.
  • Contributing Contributions are welcome β€” read CONTRIBUTING.md for build instructions, code style, and the PR process.

Changelog

See CHANGELOG.md for a detailed history of changes.

License

This project is licensed under the Apache License 2.0.