Has anyone tried creating OpenCV bindings for Julia on Windows?
Iâm using the latest Julia version 1.6.3 for Windows.
I can add the OpenCV package to Julia without error:
Pkg.add(âOpenCVâ)
and can correctly read an image from disk:
img = OpenCV.imread(âc:/myimg.jpgâ)
but I cannot write the image back to the disk (no matching method⌠error):
OpenCV.imwrite(âc:/myimg2.jpgâ, img)
OpenCV.imshow(âmywndâ, img) crashes at Julia
OpenCV.waitKey(Int32(27)) returns -1 result immediately
you could try to run the tests
if they fail, you have material for an official issue
OpenCV.waitKey(Int32(27))
returns -1 result immediately
the argument there is the âtime to waitâ ,
not the âkey to wait forâ (it returns the key, if any was pressed at all).
maybe you confused this ?
-1 is ok, if no key was pressed
You are partly correct, waitKey needs time but it cannot be interrupted while itâs waiting.
imwrite and imshow donât work.
Tests are without test data (only code)
Do you know if OpenCV bindings for Julia is with/without Intel IPP?
i have no idea, but you could look it up from cv.getBuildInformation()
or the cmake output (if you still have it)
yea sorry, did not think of it.
test data is here but itâs probably too much trouble getting it ;(
imho, you should still raise an issue, using some minimal example like in the question
According to the OpenCV bindings developer, the Julia package should contain OpenCV 4.5.4, but it actually contains 4.5.2. The Julia package developer has been ignoring all the questions for over a month now. The useless state of the Julia OpenCV package should be clearly stated (at least for Windows)
what about building from src ?
It doesnât seem trivialâŚ
In the new Julia 1.7, the Windows OpenCV package cannot even be precompiled âŚ
If I remember correctly, it was a Google Summer of Code project. The summer is over, and the code is semi-abandoned. I would not attempt a serious project with OpenCV Julia bindings. Python bindings seem to be in a good shape, if thatâs of any help to you.
or, instead of hoping that stuff will happen â if one has enough interest in these Julia bindings â one could consider helping the maintainer. theyâll probably be happy for the help. the more the merrier.
Julia without OpenCV (and IPP) seems useless for image processing.
There is probably something wrong with Julia, if itâs more difficult to wrap OpenCV than in Python. Using the Julia â Python â OpenCV bridge in the production code actually seems like a joke!
There is nothing fundamentally wrong with Julia. OpenCV is quite difficult to wrap. I mentioned Python/OpenCV as a mature alternative to Julia/Open CV.
Hey crackwitz, I would love to help the maintainer there in opencv_contrib for help with the Julia Bindings but opencv seems like a big maze to traverse. I have tried building opencv from source and it takes a surprising amount of time to build
What I find confusing is where to start?Can you provide me some direction?
From my perspective,
- I can setup according to this:
OpenCV: Introduction to Julia OpenCV Binding
which I already have but the build time and try to build a single module and try to make that work for Julia - opencv/opencv_contrib/blob/4.x/modules/julia/README.md
has some interesting information too
I already have used OpenCV.jl and made even a project using it. I think it deserves a lot more attention and is needed to be better supported as it could have a good impact on computer vision community in Julia.
I am part of GSOCâ22 with Julia Lang for ImagesIO support which provides support EXIF, GIF, JPEG2000 in Julia by writing bindings/wrappers for the corresponding C libraries namely LibExif, GifLib and OpenJpeg. I mean I am reasonably confident I can tackle this with some help and have experience on something similar despite it looking somewhat hard .