Event-Based Vision software toolkit

Metavision® SDK5 PRO

Turn motion into intelligence

Build Event-Based Vision applications with Metavision SDK5 PRO – a five-time award-winning software toolkit to help you explore event data, develop your ideas and put them to the test.

Looking ahead: Hearth, Prophesee’s next-generation Event-Based Vision software and AI platform.

Metavision SDK5 PRO logo
RBR Award
Vision Systems Design Innovators Award
Vision Award
AutoSens Award
tinyML Award

Tools to move your development forward

64 algorithms

105 code samples

17 tutorials

From event data to application intelligence

Metavision SDK5 PRO brings together tools to explore event data and develop and test Event-Based Vision applications.

Visualize, record and tune

Use Metavision Studio’s intuitive graphical interface to explore live and recorded event data from supported Event-Based Vision systems. You can also begin with provided datasets before connecting a camera.

  • Visualize event streams and provided datasets
  • Control visualization parameters, including accumulation time and frame rate
  • Record and replay event data
  • Export visualizations to AVI video
  • Configure, save and load sensor settings
Metavision Studio interface: streaming view with accumulation time, frame rate and external trigger monitoring

Develop with C++ and Python

Build Event-Based Vision applications through comprehensive C++ and Python APIs. Use C++ for efficient applications and runtime execution, and Python to access algorithms, machine-learning pipelines and more.

  • Run natively on Linux and Windows
  • Connect to compatible Prophesee and partner vision systems
  • Access extensive documentation and code examples
  • Develop through available training and learning resources
/**********************************************************************************************************************
 * Copyright (c) Prophesee S.A.                                                                                       *
 *                                                                                                                    *
 * Licensed under the Apache License, Version 2.0 (the "License");                                                    *
 * you may not use this file except in compliance with the License.                                                   *
 * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0                                 *
 * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed   *
 * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.                      *
 * See the License for the specific language governing permissions and limitations under the License.                 *
 **********************************************************************************************************************/
​
// This code sample demonstrate how to use the Metavision C++ SDK. The goal of this sample is to create a simple event
// counter and displayer by introducing some basic concepts of the Metavision SDK.
​
#include <metavision/sdk/driver/camera.h>
#include <metavision/sdk/base/events/event_cd.h>
#include <metavision/sdk/core/algorithms/periodic_frame_generation_algorithm.h>
#include <metavision/sdk/ui/utils/window.h>
#include <metavision/sdk/ui/utils/event_loop.h>
​
// this class will be used to analyze the events
class EventAnalyzer {
public:
    // class variables to store global information
    int global_counter                 = 0; // this will track how many events we processed
    Metavision::timestamp global_max_t = 0; // this will track the highest timestamp we processed
​
    // this function will be associated to the camera callback
    // it is used to compute statistics on the received events
    void analyze_events(const Metavision::EventCD *begin, const Metavision::EventCD *end) {
        std::cout << "----- New callback! -----" << std::endl;
​
        // time analysis
        // Note: events are ordered by timestamp in the callback, so the first event will have the lowest timestamp and
        // the last event will have the highest timestamp
        Metavision::timestamp min_t = begin->t;     // get the timestamp of the first event of this callback
        Metavision::timestamp max_t = (end - 1)->t; // get the timestamp of the last event of this callback
        global_max_t = max_t; // events are ordered by timestamp, so the current last event has the highest timestamp
​
        // counting analysis
        int counter = 0;
        for (const Metavision::EventCD *ev = begin; ev != end; ++ev) {
            ++counter; // increasing local counter
        }
        global_counter += counter; // increase global counter
​
        // report
        std::cout << "There were " << counter << " events in this callback" << std::endl;
        std::cout << "There were " << global_counter << " total events up to now." << std::endl;
        std::cout << "The current callback included events from " << min_t << " up to " << max_t << " microseconds."
                  << std::endl;
​
        std::cout << "----- End of the callback! -----" << std::endl;
    }
};
​
// main loop
int main(int argc, char *argv[]) {
    Metavision::Camera cam;       // create the camera
    EventAnalyzer event_analyzer; // create the event analyzer
​
    if (argc >= 2) {
        // if we passed a file path, open it
        cam = Metavision::Camera::from_file(argv[1]);
    } else {
        // open the first available camera
        cam = Metavision::Camera::from_first_available();
    }
​
    // to analyze the events, we add a callback that will be called periodically to give access to the latest events
    cam.cd().add_callback([&event_analyzer](const Metavision::EventCD *ev_begin, const Metavision::EventCD *ev_end) {
        event_analyzer.analyze_events(ev_begin, ev_end);
    });
​
    // to visualize the events, we will need to build frames and render them.
    // building frame will be done with a frame generator that will accumulate the events over time.
    // we need to provide it the camera resolution that we can retrieve from the camera instance
    int camera_width  = cam.geometry().width();
    int camera_height = cam.geometry().height();
​
    // we also need to choose an accumulation time and a frame rate (here of 20ms and 50 fps)
    const std::uint32_t acc = 20000;
    double fps              = 50;
​
    // now we can create our frame generator using previous variables
    auto frame_gen = Metavision::PeriodicFrameGenerationAlgorithm(camera_width, camera_height, acc, fps);
​
    // we add the callback that will pass the events to the frame generator
    cam.cd().add_callback([&](const Metavision::EventCD *begin, const Metavision::EventCD *end) {
        frame_gen.process_events(begin, end);
    });
​
    // to render the frames, we create a window using the Window class of the UI module
    Metavision::Window window("Metavision SDK Get Started", camera_width, camera_height,
                              Metavision::BaseWindow::RenderMode::BGR);
​
    // we set a callback on the windows to close it when the Escape or Q key is pressed
    window.set_keyboard_callback(
        [&window](Metavision::UIKeyEvent key, int scancode, Metavision::UIAction action, int mods) {
            if (action == Metavision::UIAction::RELEASE &&
                (key == Metavision::UIKeyEvent::KEY_ESCAPE || key == Metavision::UIKeyEvent::KEY_Q)) {
                window.set_close_flag();
            }
        });
​
    // we set a callback on the frame generator so that it calls the window object to display the generated frames
    frame_gen.set_output_callback([&](Metavision::timestamp, cv::Mat &frame) { window.show(frame); });
​
    // start the camera
    cam.start();
​
    // keep running until the camera is off, the recording is finished or the escape key was pressed
    while (cam.is_running() && !window.should_close()) {
        // we poll events (keyboard, mouse etc.) from the system with a 20ms sleep to avoid using 100% of a CPU's core
        // and we push them into the window where the callback on the escape key will ask the windows to close
        static constexpr std::int64_t kSleepPeriodMs = 20;
        Metavision::EventLoop::poll_and_dispatch(kSleepPeriodMs);
    }
​
    // the recording is finished or the user wants to quit, stop the camera.
    cam.stop();
​
    // print the global statistics
    const double length_in_seconds = event_analyzer.global_max_t / 1000000.0;
    std::cout << "There were " << event_analyzer.global_counter << " events in total." << std::endl;
    std::cout << "The total duration was " << length_in_seconds << " seconds." << std::endl;
    if (length_in_seconds >= 1) { // no need to print this statistics if the video was too short
        std::cout << "There were " << event_analyzer.global_counter / length_in_seconds
                  << " events per second on average." << std::endl;
    }
}

Applications and algorithms

Explore tools for machine learning, computer vision, 3D perception, analytics and calibration. Use the demonstrations below to identify capabilities relevant to your application and starting points for development.

Machine learning

Train, evaluate and run models designed for asynchronous event data.

Detection inference

Unlock the potential of Event-Based machine learning, with a set of dedicated tools providing everything you need to start execution of Deep Neural Network (DNN) with events.

Detection training

Train your own Object Detection application with our ready-to use training framework.

Detection KPIs

Evaluate your detection performance with our Object Detection KPI toolkit in line with the latest COCO API.

Optical flow inference

Predict optical flow from Event-Based data leveraging our pretrained Flow Model.

Optical flow training

Train your Optical Flow application with our custom-built FlowNet training framework.

Gesture classification inference

Run a live Rock Paper Scissors game with our pre-trained model on live stream or on event-based recordings.

Gesture classification training

Train your own object classifier with this tailor-made Event-based training pipeline.

Video-to-event

Bridge frame-based and event-based worlds with our Video to Event Pipeline.

Event-to-video

Build grayscale images based on events with this neural network.

Corner detection and tracking

Detect and track corners in an event stream with high efficiency.

Optical flow

Rediscover this fundamental computer vision building block, but with an event twist.

XYT visualization

Discover the power of time – space continuity for your application by visualizing your data with our XYT viewer.

Ultra slow motion

Slow down time, down to the time-resolution equivalent of over 200,000+ frames per second, live.

Computer vision

Extract motion and visual structure directly from event streams.

3D computer vision

Support spatial perception through event-based tracking, active markers and stereo vision.

Edgelet tracking

Track 3D edges and/or Fiducial markers for your AR/VR application.

Active marker

Track active markers at ultra-high speed in real-time.

Stereo matching

Estimate semi-dense depthmaps by matching natural features in synchronized stereo event streams.

Particle-size monitoring

Control, count and measure the size of objects moving at very high speed in a channel or a conveyor.

Object tracking

Track moving objects in the field of view. Leverage the low data-rate and sparse information provided by event-based sensors.

Vibration monitoring

Monitor vibration frequencies continuously, remotely, with pixel precision, by tracking the temporal evolution of every pixel in a scene.

Spatter monitoring

Track small particles with spatter-like motion.

High-speed counting

Count objects at unprecedented speeds, high accuracy, generating less data and without any motion blur.

Analytics

Turn event data into application-level measurements and operational information.

Calibration

Calibrate individual cameras and multi-camera configurations for accurate system integration.

Calibration

Deploy your applications in real-life environments and control all the optical parameters of your event-based systems.

Extrinsic calibration

Combine multiple cameras to enable 3D geometrical reasoning in your application.

Licensing

Metavision SDK5 PRO is available as a standalone purchase or through selected hardware offers.

Development access includes binaries and source code for all modules, two hours of onboarding support during the first two months, and access to technical knowledge bases.

A development license supports evaluation and application development. Commercial deployment requires a separate commercial license.

Resources for development

Access technical documentation for programming guides, reference information and practical recommendations to support your development.

Explore the Developer Hub for software and additional development resources.

Explore with compatible hardware

Embra HD USB event camera

Embra HD

An Event-Based Vision exploration kit featuring a compact, industrial-grade HD USB camera for hands-on development and real-world validation.

Choose the camera alone or add one-seat development access to Metavision SDK5 PRO at a preferential price.

EVK3 GenX320 evaluation kit

EVK3 – GenX320

A board-level USB evaluation platform built around the GenX320 sensor, available in chip-on-board and optical-module configurations.

Includes one-seat development access to Metavision SDK5 PRO.

Start developing with Metavision SDK5 PRO

Take your application from exploration to testing with the tools to work with event data, develop your ideas and evaluate performance.

Looking ahead to Hearth

Discover Prophesee’s next-generation Event-Based Vision software and AI platform, designed for embedded application integration and deployment.

FAQ

Do I need to buy an EVK to start?

You don’t necessarily need an Evaluation Kit or Event-Based Vision equipment to start your discovery. You could start with Metavision Viewer included in OpenEB and interact with provided recordings first.

Which OS are supported?

Metavision Intelligence suite supports Linux Ubuntu 22.04 / 24.04, Windows 10 64-bit for PC X86-64 architecture, and Windows 11. For other OS compatibilities, the provided source code allows you to customize your own integrations.

Do I get access to the full source code?

Yes, it comes included with the SDK5 PRO software package.

Source code for the fundamental software bricks is available for free in Open-Source via our OpenEB project.

What can I do with the provided license?

The suite is provided under a development license, enabling you to evaluate, develop and test applications using Metavision. Commercial deployment requires a separate commercial license from Prophesee. Read the Development license agreement here.

Which Event-Based Vision hardware is supported?

The software suite is compatible with Prophesee Metavision sensors and USB Cameras. It can also operate with compatible third party products.

Do you provide Python examples?

Yes, we provide python sample code: https://docs.prophesee.ai/stable/samples.html

Can I use Metavision SDK for commercial products?

Yes, commercial deployment of applications developed with Metavision is possible under a separate commercial license agreement with Prophesee. Please contact us to discuss commercial licensing.