Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updated RGBD point cloud example #495

Open
wants to merge 8 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions gen2-geometry-fitting/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# Gen2 Geometry Fitting

This example demonstrates fitting of predefined geometric primitives onto point clouds of objects detected in RGBD images. The device captures depth and color information and runs YOLOv5 on the image data. Detected bounding boxes are used to fit geometry onto subsets of the full point cloud. Possible types of geometry are plane, cuboid, sphere and cylinder, the fitted geometry depends on the YOLO detection label. You can expect up to 5FPS, depending on the geometry. Cylinder fitting is not officially and will take up to 3 seconds, it is disabled by default, set any detection shape to cylinder to enable. The example was tested on a OAK-D PRO device.
![example](https://github.com/leoogrizek/depthai-experiments/assets/35898289/1b2c212b-92f6-4a56-9cf8-fbc7929a3e8f)

## Installation

1. Clone the repository:
```bash
git clone https://github.com/luxonis/depthai-experiments
cd [example-directory]
```
2. It is recommended to run this example in a virtual environment
```bash
conda create --name myenv
conda activate myenv
```
3. Install the required packages:
```bash
pip install -r requirements.txt
```

## Usage

The example can be run with

```bash
python geometry_fitting.py
```
If you would prefer running this in Jupyter, simply run all cells in `geometry_fitting.ipynb`.

By default this example does not print out the parameters of detected shapes. If you want this functionality change the variable `verbose` to `True`.
1,283 changes: 1,283 additions & 0 deletions gen2-geometry-fitting/geometry fitting.ipynb

Large diffs are not rendered by default.

Loading