Skip to main content

Open-source Lagrangian Particle Tracking (LPT) with GUI and CLI

Project description

OpenLPT - Open-source Lagrangian Particle Tracking GUI

GitHub Stars Python Version License

OpenLPT is a powerful, user-friendly open-source software for 3D Lagrangian Particle Tracking (LPT), designed for experimental fluid dynamics and flow visualization. Developed by the Ni Research Lab at Johns Hopkins University (JHU), it provides a comprehensive GUI-based workflow for high-precision particle tracking and reconstruction.


🚀 Key Capabilities

  • 3D Particle Tracking: Robust Lagrangian tracking (LPT) and Shake-the-Box (STB) methods.
  • Multi-Camera Calibration: Easy-to-use tools for wand and plate calibration (intrinsic & extrinsic parameters).
  • Cross-Platform: Full support for Windows, macOS, and Linux.
  • Performance: High-performance C++ core with Python Python bindings for flexibility and speed.

Keywords: Lagrangian Particle Tracking (LPT), Shake-the-Box (STB), 3D Flow Visualization, PIV, Particle Reconstruction, Multi-camera Calibration, Experimental Fluid Dynamics, JHU Ni Research Lab.


Quick Start

[!TIP] Ensure you have activated your environment before running these commands: conda activate OpenLPT (On Windows, we recommend using Command Prompt (CMD) as PowerShell may have execution policy restrictions).

1. Graphical User Interface (GUI)

# Launch the interactive GUI from any terminal (CMD recommended on Windows)
openlpt-gui

2. Command Line Interface (CLI)

# Run STB tracking directly with a config file
openlpt path/to/config.txt

3. Python API

import openlpt

# Load and run tracking programmatically
openlpt.run('path/to/config.txt')

# Or launch GUI from within a script
openlpt.launch_gui()

Demo

https://github.com/user-attachments/assets/60579007-4f24-4989-8b36-3de2224c9797


Features

  • User-friendly interface in python
  • Lagrangian particle tracking for multiple objects (point-like particles, spherical particles, etc.)
  • Support stereomatching with multiple cameras (at least 2)
  • Include multiple test cases for users to test and understand the code
  • Better structure for adding new functions

Installation

Method 1: One-Click Installation (Recommended)

We provide automated scripts that set up everything for you (including Conda, environment, and dependencies).

  1. Download the code:

    git clone https://github.com/JHU-NI-LAB/OpenLPT_GUI.git
    cd OpenLPT_GUI
    
  2. Run the Installer:

    • Windows: Double-click install_windows.bat (Or run in terminal: install_windows.bat)

    • macOS: Run in terminal:

      bash install_mac.command
      
    • Linux: Run in terminal:

      bash install_linux.sh
      
  3. Launch the GUI: After installation, simply run:

    openlpt-gui
    

Method 2: Manual Installation (Click to expand)

If you prefer to set up the environment manually:

  1. Prerequisites:

    • Miniforge or Anaconda
    • C++ Compiler (Visual Studio 2022 for Windows, Clang for macOS/Linux)
  2. Create Environment and Install:

    # Create environment
    conda create -n OpenLPT python=3.10
    conda activate OpenLPT
    
    # Build and install the package
    pip install .
    

Troubleshooting

Problem Solution
Windows: Build fails Install VS Build Tools and Win11 SDK
macOS: omp.h not found See macOS OpenMP Fix section below
macOS: Architecture python -c "import platform; print(platform.machine())"
Linux: Permissions Use chmod +x or sudo
All: Stale cache Delete build/ folder and retry
Installation: Build isolation If compilation fails due to network, try pip install . --no-build-isolation

macOS OpenMP Fix

If you get fatal error: 'omp.h' file not found:

export CC="$CONDA_PREFIX/bin/clang"
export CXX="$CONDA_PREFIX/bin/clang++"
export CPPFLAGS="-I$CONDA_PREFIX/include"
export LDFLAGS="-L$CONDA_PREFIX/lib -lomp"
pip install -e .

Samples and Tests

Please see the sample format of configuration files, camera files and image files in /test/test_STB or /test/test_STB_Bubble.

To run the sample:

  1. Open OpenLPT GUI.
  2. Load the project configuration from the sample folders.
  3. Click 'Run tracking'.

Citation

If you use OpenLPT in your research, please cite our publications:

  • Tan, S., Salibindla, A., Masuk, A.U.M. and Ni, R., 2020. Introducing OpenLPT: new method of removing ghost particles and high-concentration particle shadow tracking. Experiments in Fluids, 61(2), p.47.
  • Tan, S., Zhong, S. and Ni, R., 2023. 3D Lagrangian tracking of polydispersed bubbles at high image densities. Experiments in Fluids, 64(4), p.85.

License

This repository contains a mix of original code and MATLAB Coder-generated files under a MathWorks Academic License.

⚠️ Restricted Paths (MATLAB Coder-generated)

The following paths contain code generated by MATLAB Coder and are NOT covered by the general MIT/Open-source license of this repository:

  • /src/srcObject/BubbleCenterAndSizeByCircle
  • /src/srcObject/BubbleCenterAndSizeByCircle/CircleIdentifier.cpp
  • /src/srcObject/BubbleResize
  • /inc/libObject/BubbleCenterAndSizeByCircle
  • /inc/libObject/CircleIdentifier.h
  • /inc/libObject/BubbleResize

📜 Terms and Conditions

For the paths listed above:

  • ACADEMIC INTERNAL OPERATIONS ONLY: Usage is restricted to teaching, academic research, and course requirements.
  • NO Commercial Use: Government, commercial, or other organizational use is NOT permitted.
  • Header Preservation: Do not modify or remove the "Academic License" header comments in these files.
  • No Sublicensing: These files are not sublicensed under this repository's open-source license.
  • Redistribution: If you redistribute this repository, you must keep the original Academic License headers in the generated files.
  • Modification: If you need to modify the generated code, you must hold a valid MathWorks MATLAB Coder license.

All other files in this repository are original work and are distributed under the MIT License (see LICENSE).


Contact & Contribution

  • Issues: Please report bugs or request features via GitHub Issues.
  • Contact: For questions, please contact szhong12@jhu.edu or tanshiyong84@gmail.com.
  • Organization: Ni Research Lab, Johns Hopkins University.
  • Support: If you find this tool helpful, please give us a ⭐ on GitHub!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

openlpt-2.1.5.tar.gz (4.1 MB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

openlpt-2.1.5-cp313-cp313-win_amd64.whl (4.8 MB view details)

Uploaded CPython 3.13Windows x86-64

openlpt-2.1.5-cp313-cp313-manylinux_2_28_x86_64.whl (5.3 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.28+ x86-64

openlpt-2.1.5-cp313-cp313-macosx_15_0_arm64.whl (5.1 MB view details)

Uploaded CPython 3.13macOS 15.0+ ARM64

openlpt-2.1.5-cp312-cp312-win_amd64.whl (4.8 MB view details)

Uploaded CPython 3.12Windows x86-64

openlpt-2.1.5-cp312-cp312-manylinux_2_28_x86_64.whl (5.3 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ x86-64

openlpt-2.1.5-cp312-cp312-macosx_15_0_arm64.whl (5.1 MB view details)

Uploaded CPython 3.12macOS 15.0+ ARM64

openlpt-2.1.5-cp311-cp311-win_amd64.whl (4.8 MB view details)

Uploaded CPython 3.11Windows x86-64

openlpt-2.1.5-cp311-cp311-manylinux_2_28_x86_64.whl (5.3 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ x86-64

openlpt-2.1.5-cp311-cp311-macosx_15_0_arm64.whl (5.1 MB view details)

Uploaded CPython 3.11macOS 15.0+ ARM64

openlpt-2.1.5-cp310-cp310-win_amd64.whl (4.8 MB view details)

Uploaded CPython 3.10Windows x86-64

openlpt-2.1.5-cp310-cp310-manylinux_2_28_x86_64.whl (5.3 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ x86-64

openlpt-2.1.5-cp310-cp310-macosx_15_0_arm64.whl (5.1 MB view details)

Uploaded CPython 3.10macOS 15.0+ ARM64

File details

Details for the file openlpt-2.1.5.tar.gz.

File metadata

  • Download URL: openlpt-2.1.5.tar.gz
  • Upload date:
  • Size: 4.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for openlpt-2.1.5.tar.gz
Algorithm Hash digest
SHA256 042719ea875ae24bc86907254aa91d9fd30357f07450e98111a87fd379da40ae
MD5 490bddb799aa6d12c90dab91cc3f789e
BLAKE2b-256 ee3945bb78fcae89d300f33602ba0d163266386620be6a33d6e66369b54d7a81

See more details on using hashes here.

File details

Details for the file openlpt-2.1.5-cp313-cp313-win_amd64.whl.

File metadata

  • Download URL: openlpt-2.1.5-cp313-cp313-win_amd64.whl
  • Upload date:
  • Size: 4.8 MB
  • Tags: CPython 3.13, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for openlpt-2.1.5-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 228ae23308f8a04649411fd6d221a82ae340bba6d1ab5d66e6bd1d812cd342e6
MD5 3fd4bc7d6236909a706321a45e3cc7fb
BLAKE2b-256 c189d581a572f63f13375823a32f063d67d236197ed1481cb3b5795a2d6b9e20

See more details on using hashes here.

File details

Details for the file openlpt-2.1.5-cp313-cp313-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for openlpt-2.1.5-cp313-cp313-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 143a8d970523a27dd1ac9a04e4db0408b8e7d75c9231d00e7c37ab9406b790de
MD5 5ecda452bcda174c4611de6ef0c0c969
BLAKE2b-256 2ac233cd728cb9765426539636f3cadecf3de41b57d34f89755f3d6f85f46aa2

See more details on using hashes here.

File details

Details for the file openlpt-2.1.5-cp313-cp313-macosx_15_0_arm64.whl.

File metadata

File hashes

Hashes for openlpt-2.1.5-cp313-cp313-macosx_15_0_arm64.whl
Algorithm Hash digest
SHA256 28391aac752babcdf259d9e61fa00cfa8ad23b59939571a09f10c86b5330e557
MD5 9cbc9cca5f0c4a557969cb6f98530793
BLAKE2b-256 60534d26ecea4c3fe11008e9e8550e3ad72ae6e370fa300b14452ba1ed0a81d8

See more details on using hashes here.

File details

Details for the file openlpt-2.1.5-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: openlpt-2.1.5-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 4.8 MB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for openlpt-2.1.5-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 a40f11e22208bbde3f146cab8b1c1c0d40532f369852dde0d73b1ca960757760
MD5 221e5ac624e789230177ba8284830bea
BLAKE2b-256 5f991709d6d03b07bfa82c470962a88b8f6e496fa8f5c33693bd0f904b12cbc4

See more details on using hashes here.

File details

Details for the file openlpt-2.1.5-cp312-cp312-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for openlpt-2.1.5-cp312-cp312-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 9dd290b082dbf5c413f9662ec9d92328dff5908340dad49333d1a702899cc456
MD5 ff33d99b8fa454c01cab3cdc0ae8956d
BLAKE2b-256 c070e1c3b2c38f45090630dc738051c0f6f150196baf207bdefb9527c9bb2bd9

See more details on using hashes here.

File details

Details for the file openlpt-2.1.5-cp312-cp312-macosx_15_0_arm64.whl.

File metadata

File hashes

Hashes for openlpt-2.1.5-cp312-cp312-macosx_15_0_arm64.whl
Algorithm Hash digest
SHA256 5af8aeaeeac78cb73c57cf1aba3b7ee7fcc40954561a27c9412c34145f328f8d
MD5 db4e9f221a5bc2277f8813add1ff53cd
BLAKE2b-256 1e962b0ef9d9859b32354547dc6937c18ab20b44b523f983a79c16e18ee0982d

See more details on using hashes here.

File details

Details for the file openlpt-2.1.5-cp311-cp311-win_amd64.whl.

File metadata

  • Download URL: openlpt-2.1.5-cp311-cp311-win_amd64.whl
  • Upload date:
  • Size: 4.8 MB
  • Tags: CPython 3.11, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for openlpt-2.1.5-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 27bf2b9bce3376f20f8b4bcceaf50b52f3b7e24014682167013fd0393dc70fc6
MD5 344952c18a49f021a83e8f2a640b4367
BLAKE2b-256 06e95d7ef7de7b1414c3f42f014bbe08a4f0d6f5289f7da2ea24c23fcd7ec5d5

See more details on using hashes here.

File details

Details for the file openlpt-2.1.5-cp311-cp311-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for openlpt-2.1.5-cp311-cp311-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 23d3b303876dc01afb74d1aeddb37b5582ac370230a252ec1d2daee719792605
MD5 442af0d95feaf2c9163f87f101fca179
BLAKE2b-256 c4a934a9af12463c178c37022710d03261c909502cb8d04fda3015fcfd7871a1

See more details on using hashes here.

File details

Details for the file openlpt-2.1.5-cp311-cp311-macosx_15_0_arm64.whl.

File metadata

File hashes

Hashes for openlpt-2.1.5-cp311-cp311-macosx_15_0_arm64.whl
Algorithm Hash digest
SHA256 15418d35868e353560dbc033041c89a9634e8153fa9695c9ac0046d6c2f3a693
MD5 77f600fa56621eb61bbeabf478c3305d
BLAKE2b-256 b503a7efa081c2cc4475939d63f6dde7f4396bde613c73e4e171c4b67fb24c3f

See more details on using hashes here.

File details

Details for the file openlpt-2.1.5-cp310-cp310-win_amd64.whl.

File metadata

  • Download URL: openlpt-2.1.5-cp310-cp310-win_amd64.whl
  • Upload date:
  • Size: 4.8 MB
  • Tags: CPython 3.10, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for openlpt-2.1.5-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 357ffb30880740b04933522776ad070e644501bc0dac127d595f970702c66735
MD5 d84a2c970b8e06c3592554d258a97385
BLAKE2b-256 67ee4db23792bf3a889588316d8d1bf3b303f01d192b644ce57ce31203150953

See more details on using hashes here.

File details

Details for the file openlpt-2.1.5-cp310-cp310-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for openlpt-2.1.5-cp310-cp310-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 56b4efcb445df5ce4f0f3297a75563aaab2a5efdf75f7135f9fff5b0df2ed8ef
MD5 db74b9a5d5d34f3d7e747230854d4172
BLAKE2b-256 87a9785794fb3b29f69fc1ef3128c7bcf8d64578714f4d992ce8095a5b489ac2

See more details on using hashes here.

File details

Details for the file openlpt-2.1.5-cp310-cp310-macosx_15_0_arm64.whl.

File metadata

File hashes

Hashes for openlpt-2.1.5-cp310-cp310-macosx_15_0_arm64.whl
Algorithm Hash digest
SHA256 22a547ab941f740cd772498c06828dc87a8b0074d12b9a5c0860efdbf440342d
MD5 b3c4d02309ec2c429b003126c863b9e3
BLAKE2b-256 03d3018b3046dffb5a8f51f41337c3daf7efdf2011cab6f1da80d4ef2a08edfa

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page