500k$ for the impact OpenCV has is dirt cheap. It is a shame they need to do a fund raiser at all. It is a bigger shame I hear about it only now. There are 7 digits "EU sovereignty of AI" projects, that would be so much more efficient by just putting 10% of that money in OSS projects...
What are the best ways to build and generate binaries for mobile platforms, let's say Android, by reducing the binary/.so size considerably? Let's say if I need only warpPerspective (and nothing else at all) - what is the easiest way to build for that? Are there docs around it, something step by step guide for people who are not well versed with CV coding or even C coding? Or has there been a smaller need based Android port (or a maven artefact) planned? (I am assuming you are related to the project). And thank you for the awesome work!
I wonder how open source works in that framework. I wonder if “we make the device, but use an open source library, we didn’t develop it, but could at least fork and maintain operations if we needed” is acceptable.
Politics are playing politics. Also, the EU is pretty liberal and US big tech company are lobbying a lot against FOSS.
Politics don't understand free software, and the people who should be teaching it (GAFAM) don't, because it's not in their interest. As a liberal, free software worth nothing. Big tech worth a lot. They don't understand that's about tools and know-how, not about human resources and money.
i used OpenCV for a facial recognition portion of an engineering graduation project and it was a godsend!! I rememeber OpenCV3 coming out and trying to utilize the functionality. It really is a shame that it needs any funding and more focus isnt on OpenCV!
We have seen this time and time again. Open source libraries/authors begging for a pittance while the large projects built on top of them are flush with cash. Sure there are success stories like Blender, but those are products of survivorship bias. There is no reason that OpenCV should be struggling to get 500k with all the projects that use it.
It's really crappy that large organizations can still keep benefiting from these projects without putting any resources into them. Again I know some companies have donated to open source projects, or hired developers but that is the exception. Part of me wonders if Copy left viral licenses are the only way to combat this. If you are going to use a bunch of critical open source projects in your code base, and you aren't going to pay, you should at least pay it forward by making your source code available.
I've seen some people mention creating some sort of license that is Open source, but if you make more than X amount of money or have X amount of employees then you have to pay X amount in licensing fees. That seems reasonable and still allows small projects to still use these libraries like they always have. But then again that's pretty hard to enforce. And if the GPL is anything to go by, then a license doesn't necessarily stop flagrant misuse of the software anyway
One of the first open source developers I recall seeing raising funds so he could go work on something full time for a year was Paul-Henning Kamp (PHK from FreeBSD). He got the money, but also an insane amount of bullshit complaints from people not wanting to donate because: He pays ~40% in tax, it would be cheaper to pay someone in <insert country>, what if he doesn't deliver, why not someone else, why FreeBSD. I can understand a developer just giving up and not even trying just to avoid the negativity and complaining.
I worked in fintech for a long time, building a product which leveraged a bunch of open source components from the Apache Software Foundation. For years, I advocated with management to sponsor the ASF, or to hire a contributor to build some feature for us. Every time, I was shot down with bullshit arguments. "We don't have money", "It's complicated", etc.
Somehow, there was plenty of money for bonuses for sales weasels, but never any money for key technology. I tried to commit bug fixes whenever I could, and did my best to help out other users on the mailing lists. It would have been nice if the company could have spared a small part of the millions they were raking in ...
A few years ago I worked for a few months with a machine learning team at Google that was using OpenCV. At least at the prototype phase.
The entire $500k donation they're looking for here would have been basically 1 or 1.5 SWE salary.
So yes, there's definitely something wrong with the compensation and financing model of open source infrastructure. And now that the market is contracting, and VC and BigCorp money isn't flowing as freely, people are finally starting to bitch about it, instead of just being happy that a) their projects are being used and b) that that is leading to job opportunities etc.
"but if you make more than X amount of money or have X amount of employees then you have to pay X amount in licensing fees" -- sad to say, projects with licenses like this would be immediately blacklisted at places like Google. Not just for use, but for Googlers to contribute to. And because of the motivation economy in OSS right now, someone else would just fill the niche.
Even the GPL is controversial to these companies (and to many people on this forum, in fact).
We need to name and shame BigCorps that are using and exploiting the very generous and liberal nature of Apache-style licensed projects without (majorly) contributing back.
> We need to name and shame BigCorps that are using and exploiting the very generous and liberal nature of Apache-style licensed projects without (majorly) contributing back.
The corporations are following the exact spirit of the license. If you want to shame them, put it in writing. Make a new license. But it would be proprietary, because you'd be saying some entities are too big to exercise Freedom 0 without paying money to a central organization that held the license.
That's the licensing model for the two big game engines, Unity and Unreal - Gratis, to a point. It seems to work for them, but it ain't FOSS. And for your central benevolent organization to hold that power over the license, they'll also have the power to do worse things to the project. One of the appeals of FOSS was that it's de-centralized. You can always fork it, if you have the code you have the right. A license that required "BigCorps" (because every small company is inherently good?) to pay would have to deny the right to fork.
> Part of me wonders if Copy left viral licenses are the only way to combat this. If you are going to use a bunch of critical open source projects in your code base, and you aren't going to pay, you should at least pay it forward by making your source code available.
This is a tough decision, and one that is going to be different for each project.
GPL will disuade most commercial projects from using your library, which for some people may be a good goal in itself. But the flip side of that is that a GPL'd library has a smaller target audience, which means that the project as a whole will tend to never become as popular as OpenCV has*. That's probably good for the maintainer's health—GPL serves as a good gatekeeper to push away a good chunk of the entitled demands (except for the entitled demands to change the license)—but it may be counter to the maintainer's goal if they set out to make a library with wide reach.
* The notable exceptions to this rule, like Linux, aren't libraries, they're applications or operating systems which can be used without paying it forward.
Yeah, like I said, for some projects I could see it being a net positive: using GPL almost certainly increases the ratio of contributors:users, which reduces the burden on the maintainer. If the maintainer is fine with the now-limited reach of the project, then that might be a great tradeoff to make!
I try to make my company to donate money to open source projects but it’s difficult. They would rather spend 100k on some BS enterprise thing that wraps open source software instead of spending 1k on giving directly to the devs.
It took me a long time working professionally until I realized why this is (and I find myself agreeing).
You're essentially paying for support (and accountability).
This is why a lot of the more successful open source projects are the ones that monetize by offering enterprise support - this is _crucial_ for something that is key to your company's product.
And while we can all share stories of terrible support, in my experience they are outweighed by the positive ones.
On the crowdfunding page [1] they revealed causes why they decided to run the campaign:
> Our goals with crowdfunding the development of OpenCV 5 are several: 1) To make OpenCV 5 our biggest release ever, with the most community participation of any version so far, 2) To prove to other struggling open source projects that crowdfunding is a viable option over seeking corporate donations exclusively, 3) To create a sustainable method of fundraising that OpenCV can return to year after year, making the overall organization and project more robust to global instability.
> Recently, due to global conflicts and instability, OpenCV has lost several core team members, and this has slowed progress on both new feature development and the handling of bugs and requests in the GitHub repository.
> Crowdfunding development of a big Open Source project like OpenCV is a big move. We aren’t aware of ANYONE doing it at this scale. As a non-profit organization, we are constantly fighting to find funding, but we always find support in our community. Instead of spending our time chasing big checks from billionaires, we are putting that community front and center.
There are thousands (millions?) of nonprofits who fundraise incessantly—any org that's mission driven without a profit motive needs to have that activity (and the resulting CRM management) as part of their fabric to thrive.
I think a few of the bigger software projects are realizing relying on a few generous whales is unsustainable when money faucets are turned off... and it's a good thing for the long term stability of these groups to figure out how to sustain the core project.
As long as it doesn't get annoying (multiple appeals every quarter, incessant "support us or we'll DIE!" messages...) I'm fine with fundraising initiatives for OSS.
I wonder if they were lost, as in passed away, or just lost as in they live in countries that can’t do business with the organization for legal reasons anymore. Hopefully the latter and they’ll find some way back eventually…
There was a discussion here lately about how the budget is fulfilled at the end of a year by spending all the rest of the money on some bullshit. Now I wonder if it could be spent on OpenSource projects the company is using either directly or not and would it count for the auditors to receive at least the same amount of money next year.
> Part of me wonders if Copy left viral licenses are the only way to combat this.
It's a good thought, but we've already seen what happens when this is attempted, such as with GPL V3. The projects just get forked, or even outright replaced (as was the case with Bash in MacOS).
It's going to require a broader mindset change in the developer community. Copyleft and the free software mindset fell out of fashion because, I think, it "felt" to many that there was penetration of open source ethic into the corporate world and the very liberal Apache/BSD-style licenses were leading to take-up and contribution of OSS by those parties.
And frankly a lot of "open source" work actually ended being either "resume" material or "corporate contribution" work.
But I think we're seeing more and more where this can lead -- your thousands of hours of work can just turn into a new product launched on AWS etc that does nothing to enrich you or reward your community for its efforts.
The copyleft model was supposed to counteract this by at least demanding contributions back. And if companies felt they wanted/needed a proprietary license, they could always negotiate that separately. But as you say, tossing GPL on a project has become kind of radioactive. And the copyleft model didn't really scale well into the SaaS world.
What if you're a company that built on top of a prior version OpenCV that does everything you need, and contributed at the time but do not need any of the new things?
Do you and your moral stance think they should continue to chip away at their earnings in yet another rent-seeking play?
Does it even matter? When I pay for bread with my credit card, a large portion of the price of the bread goes to the credit card company and the payment processor. Should that stop me from paying for bread?
Sure, the baker -- or OpenCV -- would be happier if they got a bigger slice of the pie, but that's just the cost of doing business.
Yes, I think to me it does. How much of my money is “wasted” (which we all might define differently) does matter to me.
There’s also a factor of what I receive from it. In your bread analogy, there is an exchange of money for a good (bread) received.
In a donation, like with OpenCV, there is no guarantee of a good received, so I care more about how my dollars are “spent” getting to the recipient. I (and many others) look at the filings of charity to understand how much goes to administrative overhead, for the same reason.
> When I pay for bread with my credit card, a large portion of the price of the bread goes to the credit card company and the payment processor.
Unless you are buying a single slice of bread, a large portion does not go to the credit card company. About 3% does, 5% lower than IGG fees, just like with IGG. A lot of food places around me offer a 3-5% discount for using cash and I generally choose that option if I have cash on me. People have long cared about what “middleman” is scraping money of the top of their spend.
Where is your cutoff for percent taken by the processor?
It's your money, you're certainly free to spend it how you like. However, if you oppose giving money to the middle man, and the net result is that OpenCV gets nothing, I can't help but question the wisdom in that decision.
I think it adds to 8%. This page [1] makes it clearer. They charge 5% and their “payment processor also charges a processing fee” which in the US is 3%.
The tip seems to be something entirely separate, which is _additional_ money, on top of your donation, that only goes to IGG, based on another [2] article.
You probably have more experience here though. Your work is great and I always appreciate your posts.
I made an $11 donation, and Indigogo used a dark pattern, automatically selecting it, to try to make me "tip" Indigogo $10 on top of that! A 90.9% "tip!" NO THANKS.
A tip is for a service rendered. Not for being a mendicant middleman.
I like opencv, but can there be a stretch goal where if they raise $1M they agree to move from Blue/Green/Red colour channel order by default to RGB in OpenCV5, like everyone else on planet earth? I genuinely avoid opencv for this reason because I know I will forget to BGR->RGB on loading and RGB->BGR before saving occasionally, and so I'd rather stick to skimage/imageio/PIL. Or hell, add an `as_rgb=False` parameter to the load/save functions or something!
> The reason the early developers at OpenCV chose BGR color format is that back then BGR color format was popular among camera manufacturers and software providers. E.g. in Windows, when specifying color value using COLORREF they use the BGR format 0x00bbggrr.
Yes. It's a different kind of computer vision. Not the kind where you just throw an expensive NN at stuff and hope for the best, but one where we're actually dealing with operations at the pixel level (corner / edge features, image warping, stitching, calibration etc). No neural nets, just very fast operations on the actual image data.
It's useful either as a preprocessing step that you feed into further NN processing or -- super old school -- you are modeling your problem by hand instead of letting a NN figure it out (for better or worse).
Absolutely. Not all computer vision problems are AI related and not all AI problems are solved by pytorch. If I need a program for, say, soft real-time processing of some industrial automation video streams to run on a low power system opencv is my #1 choice. My 2c.
In that example, they're using OpenCV to display images and read from the webcam for a demo. At one point, they make it clear that OpenCV isn't used for any of the CV parts:
> We didn't compile Darknet with OpenCV so it can't display the detections directly. Instead, it saves them in predictions.png. You can open it to see the detected objects.
Yes, it is totally relevant. Creating a product that processes images/videos/photos typically requires composing some small models, applying classical functions to work with polygons, edges, transformation matrices to rotate/shift coordinates and pixels, resizing, working with colors, working with bright/contrast curves, open/write files, classic filters, etc. PyTorch and Tensorflow don't have this or use in their examples OpenCV functions to do it.
It totally is: OpenCV does pixel-level image processing, in a deterministic and generally highly optimized way. For some computer vision, this is definitely enough, and it will have a much better performance than doing it with neural networks. It might be complementary to higher-level frameworks (typically based on machine learning models), e.g. for object detection/classification.
I know a chap that uses it for Arduino-powered drones. He is not a coder.
I agree that projects like OpenCV should be better-supported.
There are a couple of issues, though, that always crop up, when talking about supporting open projects:
1) I don't know of any corporation, anywhere, that actually donates for no reason at all. There's always a hook. Sometimes, it's just brand-building (logo on the free swag stuff), sometimes, it's to attract future employees (for instance, donating to a project that is maintained by a certain set of students from a college curriculum, etc.), sometimes, it's to influence "hearts and minds," and sometimes, it's a pure investment. They need a self-interested reason.
2) I don't know of any corporation, anywhere, that donates, with no expectation of influence. That's one reason why lobbying is such a big deal. There's a fig leaf of "no quid pro quo," but everyone knows that the donator is expecting a return.
3) I don't know if anyone has noticed (</s>), but the corporate environment tends to be, just a bit, on the competitive side. I know many corporations may not be willing to donate to a cause that will serve their competitors, as well as themselves.
I think that foundations help. They can set up a "step and repeat" page, with donors, but keep the branding (and influence) off the actual donations.
Corporations could donate in a way that benefits them. For example, Intel contributes a lot of code to the Linux kernel. Presumably they are at least partially contributing stuff that makes it run better on their chips. But lots of people run Linux on Intel chips. And while working on stuff that benefits Intel, their engineers are probably going to do other ancillary tasks that could be helpful. So it seems like a win-win.
It should be socially acceptable for open source programs to offer the deal: we’ll consider patches from your engineers, but in exchange you have to chip in enough to support one of ours (to keep working on stuff we find interesting), and a little bit more (need some engineer-hours to review your patches).
It sounds quite biased in favor of the project at first, but if the project is popular, the company could get quite a bit out of it.
Is it a bad thing if corporations donate towards features that benefit them? That is a signal to the developers to allocate their energy towards useful ends.
In addition to helping keep the library in development member organizations of OpenCV get some perks as a result of their support such as appearances on our live streams, press releases, and pull request priority. We have tiers for Bronze ($6k/yr), Silver ($30k/yr), Gold ($100k/yr) members with more benefits for each tier.
I very much doubt you can do any image processing on Arduino. A typical Arduino has only 2048 bytes of RAM, like, what kind of an image can fit in there?
There are CV applications where techniques you'd currently get consensus on calling 'AI' would be overkill (unnecessarily intensive to run) or relatively poor performing.
Say you just need to do some edge detection for example.
Of course the 'AI' line is blurry and moving, probably 'computer vision' (vs. 'just processing some image data', which of course it is anyway) has been too.
Definitely. There is still a very large class of problems that are amenable to image processing pipelines and algorithms . And a very large number of problems where there is insufficient training data to simply throw deep learning at it.
I'm not into that space as much lately, as I have been years ago, but in a lot of newer marketing videos I can easily recognize the OpenCV signature markings. For example from tesla videos (not the typical public facing ones, but on the NVidia tegra side) or robotic startups
We decided for OpenCV (on a project that provided vision to a production line, think 50 images per second). The speed and computational cost advantage weighed in favour of OpenCV. I don't think this has changed so much in the last couple of years.
as far as I am aware opencv has a lot of classical Computer Vision stuff that is missing in tensorflow/pytorch. In case you need speed, or can't have data annotation, or something where deep learning is not super useful (slam) it's still very relevant I'd say.
There are lots of ways OpenCV complements Tensorflow, pytorch, and other high level frameworks. They don't need do all those things themselves, because they assume you have OpenCV around for stuff like image io, preprocessing, manipulation, transformation, color space conversions, edge detection, filtering, segmentation, morphological transformations, feature detection, video io, real time video capture, camera calibration, 3d reconstruction, optical flow, object tracking, qr code detection, gui creation, etc.
Check out the official or unofficial examples for TF, PyTorch, and OpenVINO for CV applications; they all use OpenCV as a dependency, eg to get get the image data from a camera or RTSP URL, process the image, draw debug info and display the results etc.
Some of those things could be embedded nicely into OpenCV, though. Without me having to learn about all the underlying concepts, finetune a model and learn how to deploy it on various devices. OpenCV is a wrapper around lots of common image functionality, and it could be extended to cover modern deep learning approaches.
It's not a "hallucination" it's a "miss-prediction".
And the more-classical methods of CV are still very capable of miss-predicting.
No matter what method you choose, you must test how accurate it is, NN have the benefit of being fine-tuned for specific applications as well. If you want to be extra sure then you likely want to use both.
That was also my thought. I have used OpenCV 10 years ago for some small things, but today I would simply look for any existing neural network on HuggingFace and maybe train some custom classifier on top if I need sth custom. I cannot really think of any possible case where this would not work better than what you have in OpenCV. And if speed is a concern, there are also many small models, or otherwise you can quantize them yourself, or maybe train yourself a small model with knowledge distillation. You can get this as fast and as small as you want, while still probably outperforming everything that OpenCV can offer.
I use OpenCV for blur detection and camera shake detection on mobile devices, to qualify the image before handing it along to an AI model to extract data. I can't think that 2 extra neural networks would be faster at this task than OpenCV is, even if they might be better given how subjective blur is.
ACAP version 4 example applications that provide developers with the tools and knowledge to build their own solutions based on the ACAP Computer Vision SDK.
The open source examples are focused on video analytics applications. Giving AI/ML developers the chance to experience the smooth and smart develop environment that ACAP provide, showing how the powerful capacity of Axis devices provides unlimited possibilities for developers to build new AI/ML applications.
Being one of the most active repositories we have, you can find examples written in C++ and Python performing interesting features that varies from object detection, QR decoder, and image capture, using popular open source ML libraries such as OpenCV.
How does it do the blur detection? I assume it's also just a convolutional kernel applied on the image in some way. So it would do just exactly the same as a tiny neural network with one convolutional layer. Thus, they would be exactly the same speed, if they would use the same underlying native kernels. However, the native kernels in TF/PyTorch/etc are more heavily optimized than OpenCV, thus I assume that OpenCV would actually be slower here. And also more complicated, as you need to mix two big frameworks.
Realistically I think you'll often want both depending on what you're doing. Especially for things like blur detection, what's your acceptable specificity, acceptable/scale of performance, where you're running the algorithm (on device vs cloud).
I'm not an expert at all but most image processing network I've seen generally involve at least a few plus a few other layers. I don't think you can get away with a single convolution, at least not that well.
OpenCV you could use Laplacian variance which looks like it's just a single line of code.
> cv2.Laplacian(image, cv2.CV_64F).var()
Many of the NN implementations look like their finetuned off google's ViT checkpoints. I really can't imagine these are faster (at least not without spending extra on GPU/TPU's) than Laplacian variance but I could be wrong.
And I assume you might be able to get better evaluation performance from a finetuned NN but depending on what you're doing, that's a ton of work compared to opencv.
Yes - not sure how this has been overlooked. For Python/torch I tend to use cv2 with an albumentations augmentation pipeline, which is much faster than PIL/torch transforms.
I’ve worked on plenty of problems where all you need is to find what pixels are a specific color. While I’m sure a NN could be setup for that, why make things harder than they have to be?
Why harder? My point is, by using some DL framework, you would make this simpler. You don't need to have a big NN for that, or even any NN at all, and could still use some DL framework, and I would assume this is still easier and probably faster. E.g. finding what pixels are a specific color, this would be sth like:
I'm still using OpenCV 3 and am more than happy with it. Why does every library or application have to be blown up so much that it ends up being too big and complex for a voluntary open source project?
Well, the term "computer vision" (CV) is apparently too vague and unstable to restrict the functional scope of a still manageable library with it. Perhaps they should consider to move the parts that are now apparently beyond the scope and for which they are collecting money into a new library under a new name, rather than endlessly inflating something mature and proven.
When I moved some projects from OpenCV 3 to 4 I got a nice speed up pretty much everywhere, some things no speed up at all and some others pretty big. I can't really remember the numbers, but at the moment it was a global 10 to 20% perf improvement just on updating a library.
Might want to check that. Also 4.something got SIFT as part of OpenCV (instead of living in the contrib module) because the patent expired and you can now use it for free.
As for blowing up with NN packages and such... I don't really use those parts, but if the NN module had easier support to run networks trained on popular frameworks I might've used it. Disclaimer: it's been quite a while since I last tried to use those parts, so maybe now the latest version has fantastic support and I'm talking nonsense.
Thanks. I had a close look at v4, but didn't see a reason to update. Some functions got a bit faster on some architectures, some a bit slower, as usual.
Ah yes, openCV at one time made ImageMagick easier to use, and could be compiled in C. There were even projects focused on transparent fpga hardware acceleration for video streams.
Now, it is a C++ dependency nightmare with conflicting documentation of basic data structures, version specific bugs, and hidden impossible-to-license patents.
It is a cautionary tale of allowing a Second-system effect to twist a project into a set of use-cases for a smaller subset of users.
The core issue was not major version releases, but constant breaking library changes in sub dot version releases. Thus, they turned most of the user-base into full time Beta testers.
They should have forked the library at 4, but knew no one would change what already worked. =)
Tooling around OpenCV and documentation is so intractable.
Having said that it is an integral part of anything on any Android project that deals with what OpenCV does. Because while iOS has a pretty capable Vision lib Google's Android has nothing even compared to that. So your only option is to seek and try solutions in the wild based on OpenCV and then hope that after enough hit and trial you are able to generate the right .so files specific to your solution and not the 100s or dozens of MB large files for multiple platforms. But on many platforms OpenCV is the only option and whatever challenges come with it, it does work!
Python elevated OpenCV to a new level.
I Think node/graph/workflow interface would do the same.
Examples are not missing: Blender, ComfyUI, FFmpeg.guide, ...
Yes, same impression here. I remember trying to get some documentation fixes into the codebase and felt like it all got shelved because the Intel team didn't see those things as necessary. Some community PRs/fixes just went stale like that too. Kind of now hard to merge that in my head that they now need to crowdfund.
If I remember correctly there was a team in Belarus working full time on OpenCV at one point. Anti-Russia sanctions may have killed OpenCV if this is true.
It would be nice to have a high level API with all the plumbing for integrating different popular deep neural network libraries like torch/tensorflow, like how Unity has ARFoundation for integrating ARCore, ARKit, Magic Creep, and HoboLens.
Why are the words 'Computer Vision' not above the fold on the front page? How am I supposed to know that CV stands for Computer Vision rather than Curriculum Vitae?