Comments (5)
That's an interesting thought, Rune. I usually end up using both the OpenCV for Processing object as well as built-in OpenCV objects like Mat, etc. So I don't very frequently have the use case you're talking about. At the very least I'm going to be using the main OpenCV object for I/O to and from PImages, etc. No?
from opencv-processing.
Yes, I guess it's more of an advanced user thing, as most people will always create a Processing object. I was just porting a Random Forest example in this repo:
https://github.com/runemadsen/random-forest-processing-opencv/blob/master/random_forest.pde
You'll see that my source code looks like this:
// we use Greg's nice little library to load the correct dylibs at runtime. We never actually
// use this object, but we get error if we don't instantiate it before using the core OpenCV classes
OpenCV opencv;
opencv = new OpenCV(this, "test.jpg");
// now use the Mat class
Mat training_data = new Mat(200, 64, CvType.CV_32FC1);
I would consider it low priority, but wanted to ping you so you know the use case.
from opencv-processing.
Yeah. I saw that. Looks great. Implementing Random Decision Forests has been on my list so thanks for getting that ball rolling! I guess what's weird about this is that you're using it without any images. Which is kinda funny in OpenCV! But I see what it would be useful. You're basically in a mode of using OpenCV's machine learning libraries for their own sake rather than with images. That's a good use case. I'll see about adding that init. But in the meantime, you can just give the OpenCV constructor width and height, you don't have to give it an image.
from opencv-processing.
Yes, it is kind of weird. I guess my training data is a matrix, so it's image-like, without an image actual to load.
Ah, didn't see that constructor in the source. I'll remove the test image then. That empty constructor is basically the same as init
, so I think you can close this for now.
Thanks a bunch.
from opencv-processing.
Ok. Cool.
from opencv-processing.
Related Issues (20)
- Error in opening movie files HOT 2
- Issue to built the lib for Raspberry PI (arm and x86) HOT 2
- setROI()
- How can i used your library in Netbeans IDE ?
- Request: Update to OpenCV 3.0?
- Library Processing.video error HOT 2
- crash while running P3D, P2D
- Display contours over image HOT 1
- issue with getAverageFlowInRegion HOT 1
- I cannot find radon transform.
- LiveCamTest.pde is crashing on macOS Catalina HOT 2
- Can't load library in macOS Catalina HOT 1
- All examples give NullPointerException error HOT 5
- OpenCV not Working on Processing 3, on Ubuntu 18.04
- Illegal reflective operation warning in Processing 4 HOT 1
- HSVColorTracking Example not responding
- UnsatisfiedLinkError HOT 6
- Update readme or merge latest development with this repo? HOT 2
- [JAVA opencv library] Have you tried the 'WhichFace' example?
- HoughLineDetection example: another result HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from opencv-processing.