Giter VIP home page Giter VIP logo

depthai_apis_synced_frames's Introduction

depthai_apis_synced_frames

High level APIs to obtain synced frames using simple API calls. Implemented buffer management system to store packets until all frames arrive and flush them regularly.

Design

A buffer is used to store streams using packet sequence number as key. Upon collecting all the streams - frameset is updated and the corresponding buffer entry is deleted.

In the case of missing packets - buffer might accumalate incomplete packets waiting for streams. This is addressed by periodically flushing buffer if it size exceeds certain limit. However, this case has not been observed with buffer size mainitaing at 2 packets.

Setup

  1. copy all files oakd*.py to cloned depthai folder.
  2. replace depthai_helpers/mobilenet_ssd_handler.py of depthai with this one. (landmarks and emotion recognition is made optional)
  3. similarly replace depthai_helpers/calibration_utils.py for saving calibration information.

oakd.py is the API interface class.

'oakd_config.py` contains pipeline config info.

'oakd_synchronized.py` is an example template file.

calibr_info.npz is zipped numpy with intrinsics and distortion coefficients

Run: python3 oakd_syncronized.py this should display synced resized previewout, left, right and depth_raw images.

Testing

Tested for 10, 20, 25 and 30 fps. The buffer size does not exceed more than 2 packets, should work on low computing power devices as well.

jpegout stream is added now. jpeg requests reduces fps from 30 to 7fps. So, currently jpeg is requested for every other frame.

depthai_apis_synced_frames's People

Contributors

jaggik avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.