Bindings and Tests for the Julia Language
- Author: Archit Rungta / @archit120
- Link: Raised Issue
- Status: Draft
- Platforms: All
- Complexity: 2-3 Man-Months
Introduction and Rationale
Julia is a popular dynamic language used for scientific and numerical computing, with performance comparable to traditional statically-typed languages. It has powerful libraries for many different tasks such as FluxMl and Zygote. However, the JuliaImages library lacks a lot of functionality.
There are two existing OpenCV wrappers: https://github.com/JuliaOpenCV and https://github.com/maxruby/OpenCV.jl. Both of these do not work with current version of Julia and have been abandoned for multiple years now. The only way of using OpenCV from Julia right now is to call the Python bindings for OpenCV using PyCall.jl
This is aimed at creating bindings for Julia which are similar in scope and ease-of-use to OpenCV's Python bindings. Furthermore, test files similar to Python should be created.
Proposed solution
The solution is to build wrapping for Julia similar to how they are constructed for Python. Ref [1]. Julia has a library CxxWrap.jl which provides the needed functionality of creating Julia wrappers in C++
This wrapper will then call the C++ OpenCV code. All functionality of OpenCV would then be exposed to be called from Julia code.
Impact on existing code, compatibility
The changes will not affect any other part of OpenCV's functionality. A seperate folder for Julia bindings will contain all the related code. Only a flag for make configuration has to be added which can be off by default.
Possible alternatives
Julia supports an alternative form of wrapping using Cxx.jl Unlike CxxWrap this requires wrapper code to be written in Julia. Another alternative is to build the Julia bindings on top of Python. This method, however, is not as preferable because of extra dependencies and overheads.
References
- Home
- Deep Learning in OpenCV
- Running OpenCV on Various Platforms
- OpenCV 5
- OpenCV 4
- OpenCV 3
- Development process
- OpenCV GSoC
- Archive
© Copyright 2024, OpenCV team