OpenCV  4.4.0-dev
Open Source Computer Vision
How to enable Halide backend for improve efficiency

Prev Tutorial: Load Caffe framework models

Next Tutorial: How to schedule your network for Halide backend


This tutorial guidelines how to run your models in OpenCV deep learning module using Halide language backend. Halide is an open-source project that let us write image processing algorithms in well-readable format, schedule computations according to specific device and evaluate it with a quite good efficiency.

An official website of the Halide project:

An up to date efficiency comparison:


LLVM compiler

LLVM compilation might take a long time.
\\path-to-llvm-build\\ and \\path-to-llvm-install\\ are different directories.

Halide language.

Build OpenCV with Halide backend

When you build OpenCV add the following configuration flags:

Set Halide as a preferable backend