Skip to main content

MPlib2: a Lightweight Motion Planning Library

License Python Upstream MPlib

MPlib2 is an actively maintained standalone fork of MPlib — a lightweight Python motion planning library decoupled from ROS. It brings modern dependency compatibility (Python 3.10–3.12, NumPy 2, Pinocchio 3, Boost 1.88+, modern pybind11) and stability fixes while remaining a drop-in import mplib replacement for existing ManiSkill, SAPIEN, and MPlib codebases.

Installation

Standard Pip Installation

The PyPI distribution name is mplib2, while the Python import module remains mplib:

pip install mplib2

Note (migrating from upstream mplib): Because mplib2 provides the mplib Python module as a drop-in replacement, it cannot coexist with upstream mplib in the same environment. Uninstall upstream mplib first to avoid package shadowing:

pip uninstall -y mplib && pip install mplib2

Building from Source & Editable Installation

Prerequisites

Building MPlib2 from source requires Python >= 3.10, a C++17 compiler (g++ or clang++), CMake (>= 3.12), Ninja, pybind11 (>= 2.13, required for NumPy 2 compatibility), and C++ dependency libraries:

  • Eigen3 (>= 3.4.0)
  • Pinocchio (>= 3.0, < 4.0)
  • FCL / Coal
  • OMPL (>= 1.5)
  • Boost (>= 1.70: filesystem; system linked conditionally if present)
  • Orocos-KDL
  • URDFDOM
  • Assimp

Pixi automatically installs required C++ libraries and Python toolchains (Python >= 3.10, < 3.13):

# Clone the repository
git clone https://github.com/dd114/MPlib2.git
cd MPlib2

# Install development environment and execute test suite
pixi run pytest tests

Option B: Editable Installation via Pip (Python 3.10–3.12)

Within an existing Conda or system environment providing the prerequisite C++ libraries:

# Install runtime Python dependencies
pip install "numpy>=1.26" "toppra>=0.6.3" "transforms3d>=0.3.1"

# Build C++ pybind11 extension in-place and install editable package
pip install -e . --no-build-isolation

Quickstart

import numpy as np
import mplib

# Initialize planner for Franka Emika Panda arm
planner = mplib.Planner(
    urdf="data/panda/panda.urdf",
    srdf="data/panda/panda.srdf",
    move_group="panda_hand",
)

# Set initial joint configuration (7 arm joints + 2 gripper fingers)
start_qpos = np.array([0.0, 0.2, 0.0, -2.6, 0.0, 2.9, 0.8, 0.02, 0.02])
planner.robot.set_qpos(start_qpos, full=True)

# Forward Kinematics: compute end-effector pose
planner.pinocchio_model.compute_forward_kinematics(start_qpos)
ee_idx = planner.link_name_2_idx["panda_hand"]
target_pose = planner.pinocchio_model.get_link_pose(ee_idx)

# Inverse Kinematics: solve for joint angles matching target pose
status, ik_qpos = planner.IK(target_pose, start_qpos, return_closest=True)
if status == "Success":
    print("IK Solution found:", ik_qpos[:7])

# Motion Planning: plan collision-free trajectory to target pose
target_pose.p[0] += 0.1  # Translate 10 cm in X
result = planner.plan_pose(target_pose, start_qpos)

if result["status"] == "Success":
    print(f"Planned trajectory duration: {result['duration']:.2f} s")
    print(f"Waypoints: {len(result['position'])}")

Documentation & Attribution

Metadata

Release files for mplib2 0.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for mplib2 0.3.0
File Size Uploaded Provenance Actions
mplib2-0.3.0.tar.gz 127.9 kB With provenance Details for mplib2-0.3.0.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for mplib2 0.3.0
File Interpreter ABI Platform Actions
mplib2-0.3.0-cp312-cp312-manylinux_2_28_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.28+ x86-64 Details for mplib2-0.3.0-cp312-cp312-manylinux_2_28_x86_64.whl
mplib2-0.3.0-cp311-cp311-manylinux_2_28_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.28+ x86-64 Details for mplib2-0.3.0-cp311-cp311-manylinux_2_28_x86_64.whl
mplib2-0.3.0-cp310-cp310-manylinux_2_28_x86_64.whl CPython 3.10 CPython 3.10 Linux glibc 2.28+ x86-64 Details for mplib2-0.3.0-cp310-cp310-manylinux_2_28_x86_64.whl

Total release size: 44.8 MB

Release files / mplib2-0.3.0.tar.gz

Download URL mplib2-0.3.0.tar.gz
Size 127.9 kB
Tags Source
SHA-256 checksum
How to use checksums
5ad229bbac02cf53e01dcb77448cdf49bebe2805968584d1300dab64834b9a44
BLAKE2b-256 checksum
How to use checksums
784c500249bc727108e075e6b4e7a690c568805c7139a19c8cebad7333a8c953
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 28, 2026.

Transparency log

Release files / mplib2-0.3.0-cp312-cp312-manylinux_2_28_x86_64.whl

Download URL mplib2-0.3.0-cp312-cp312-manylinux_2_28_x86_64.whl
Size 14.9 MB
Tags CPython 3.12 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
b18cd130ea612fd482dbd6792f9a7a817d665b7d73bb7bc4e2de3202d696d10a
BLAKE2b-256 checksum
How to use checksums
4622e5d35a87cddb124858d1d8d80b397d888c739fc99c7c977f365932e13cde
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 28, 2026.

Transparency log

Release files / mplib2-0.3.0-cp311-cp311-manylinux_2_28_x86_64.whl

Download URL mplib2-0.3.0-cp311-cp311-manylinux_2_28_x86_64.whl
Size 14.9 MB
Tags CPython 3.11 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
7ddfc90bece633aa6b78856de8e5e94d261fd312447e5d07987864389c788b41
BLAKE2b-256 checksum
How to use checksums
d97bbe5fe9a466a64a5ce31b9df5744b5b4ed45212a2d2f11920bf23d6973d8e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 28, 2026.

Transparency log

Release files / mplib2-0.3.0-cp310-cp310-manylinux_2_28_x86_64.whl

Download URL mplib2-0.3.0-cp310-cp310-manylinux_2_28_x86_64.whl
Size 14.9 MB
Tags CPython 3.10 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
68f620bec16380353846ded6074f5d1261eef2108af18c8894c0716723bd01b6
BLAKE2b-256 checksum
How to use checksums
11db065e057c5e49a0ef8ce29b74aeda42b1387aa197a2a0829b84c3bc093d7a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 28, 2026.

Transparency log

Security for mplib2 0.3.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 4 files in this release have been uploaded with provenance metadata.

Select from 4 files

Attestation for mplib2-0.3.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 28, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.3.0 This release

4 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page