Tagged Questions
2
votes
1answer
14 views
Crossword digitization using image processing
I am a newbie to image processing.I need to convert a crossword grid in an image file into into corresponding binary equivalent i.e Output should be an array with 1 for the black squares and a 0 for ...
0
votes
1answer
17 views
Enthought Canopy Python and OpenCV
I've installed Enthought Canopy Python 2.7.3 64-bit and it has OpenCV 2.4.2. When I import cv2 I get the following error:
>>> import cv2
Traceback (most recent call last):
File ...
0
votes
0answers
17 views
How can I install python opencv on Heroku?
I tried using this custom buildpack https://github.com/gimlids/heroku-buildpack-python-opencv
But compilation fails due to a 15 minute timeout.
I also tried setting COMPILE_TIMEOUT: 6000 but it ...
2
votes
0answers
37 views
Python and OpenCV 2: Face recognition with SURF and kNN
This post has questions specifically about the use of cv2.SURF(), cv2.KNearest.train() and cv2.KNearest.find_nearest() in the context of face recognition.
There is also a general python programming ...
0
votes
2answers
33 views
Not able to display/Convert Image
I am new to Python and Opencv.
I am using the following code.
import Image
import ImageChops
im1 = Image.open("img1.png")
im2 = Image.open("img2.png")
diff = ImageChops.difference(im2, im1)
When I ...
0
votes
1answer
18 views
Where has getCentralMoment gone in Pythons new openCV API?
I am using some tutorials on object tracking to create an easy gesture detection, but I am having trouble finding the functions GetSpatialMoment and GetCentralMoment or equivalent in the new cv2 API.
...
0
votes
0answers
15 views
Create new image using disparity map opencv python
I am using OpenCV with python. I have to images, one is left and another is right part of same image. I calculated disparity between two images. I want to create new intermediate view image. How can I ...
0
votes
0answers
29 views
Python openCV Motion Detection and mjpeg streaming with one webcam
I can find loads of sample scripts that do some brilliant motion detection and other scripts that serve mjpeg streams using the python built in webserver. However I cant find anything that shows how ...
2
votes
0answers
49 views
Making a video with opencv, getting only 1 frame
I've been trying to add a video making module to my program using opencv, but try as I might I can't get the video to show more than 1 frame.
I got this example code while searching for answers
...
1
vote
1answer
37 views
Turning selected pixels to black based on an HSV hue range
This snippet of code is part of a program that turns pixels to black in an opencv image based on an HSV hue range (here, 180-250).
Does somebody happen to understand why the code below raises the ...
1
vote
1answer
41 views
YUV420p to other formats, color shift problems
So I'm writing a color detection application using an AR Drone. The drone sends my python/opencv socket server an image from its camera in YUV420p format.
What I do to access the image as an opencv ...
1
vote
1answer
39 views
Palette method using numpy
I am trying to apply the numpy palette method to an opencv processed video (references: this question and this tutorial ). I aim at replacing all frame pixels of a certain color range by another. The ...
1
vote
0answers
41 views
Video Manipulation
Before a couple days ago I had never used OpenCV or done any video processing. I've been asked to computationally overlay a video based upon some user inputs and build a new video with the overlays ...
0
votes
0answers
27 views
Use FindStereoCorrespondenceGC using StereoSGBM in python opencv
I am using StereoSGBM to calculate disparity. And I want to calculate graph cut with using FindStereoCorrespondenceGC. But FindStereoCorrespondenceGC takes disparity_left and disparity_right ...
0
votes
0answers
12 views
How to get an edge associated with a vertex point from a Delaunay triangulation?
According to the reference manual of OpenCV, if the point (x,y) of the function:
import cv2.cv as cv
a=cv.Subdiv2DLocate(subdiv,(x,y))
is a vertex of the Delaunay triangulation represented by ...
0
votes
2answers
42 views
How to resize window in opencv2 python
I am using opencv 2 with a webcam. I can get the video stream and process it, but I can't seem to figure out a way to resize the display window. I have some video images stacked horizontally, but the ...
1
vote
1answer
30 views
opencv and python: how to use cv2.surf() with mask
I am a newbie at opencv and python and am trying to collect keypoints and descriptors of faces within an image.
I am using HAAR cascade classifier with frontal face template to look for faces in an ...
0
votes
0answers
44 views
Installing pyopencv using pip
When I first tried installing pyopencv
./vendor/venv/bin/pip install pyopencv
It said there was a problem using CMake.
I built OpenCV on my computer following the instructions here. I also used ...
-5
votes
0answers
36 views
OPEN CV : Analyzing Image data and show the RGB value [closed]
I am gonna do some Image processing job with OPEN CV.
I'd like to know RGB value of Image data using OPEN CV with webcam.
More detail, I am gonna make some robot which tracks with specific ...
0
votes
1answer
46 views
fit an ellipse through points
Using opencv for python I need to fit an ellipse (using cv2.fitEllipse) to the array of points returned by cv.FindCornerSubPix (here named 'features'). I have seen numerous examples of this on the ...
0
votes
1answer
26 views
How to convert a vector to a set of points?
I'm experimenting with Python and OpenCV detecting objects. I got a vector from cv2.CascadeClassifier.detectMultiScale(image), and now I want to draw that rectangle to my image, how do I convert that ...
0
votes
1answer
61 views
How can I use OpenCV (Python) to read a video file WITHOUT looping (Mac OS)?
I'm writing a simple OpenCV script in python to do some machine learning. I want to feed it a sequence of video files that it will process and then exit and spit out some parameters. However when I ...
11
votes
2answers
259 views
Rotate image and crop out black borders
My application: I am trying to rotate an image (using OpenCV and Python)
At the moment I have developed the below code which rotates an input image, padding it with black borders, giving me A. What ...
2
votes
1answer
79 views
Comparing computer vision libraries in python [closed]
I want to decide about a Python computer vision library. I had used OpenCV in C++, and like it very much. However this time I need to develop my algorithm in Python. My short list has three libraries:
...
-1
votes
1answer
75 views
Get Laplacian pyramid using opencv
I'm trying to get a layer of the Laplacian pyramid using the opencv functions: pyrUp and pyrDown.
In the documentation and in more detail in this book, I found that the i-th Laplacian layer should be ...
1
vote
0answers
63 views
Moments as feature and KNN classifier using OpenCV and Python - Knearest doesn't classify
I have a set of twelve shapes and I'm trying to determine the shape of a query image with the my database
For convinience I have done all the preprocessing in MATLAB and have stored the shape ...
1
vote
1answer
45 views
Unable to unwrap image in OpenCV
I am trying to convert an image from cartesian to polar so that I can unravel the image, but I am getting a runtime error. If you are curious how this looks visually, see this example.
Code:
import ...
0
votes
2answers
43 views
Training the OpenCV NormalBayesClassifier in Python
I'm trying to use the NormalBayesClassifier to classify images produced by a Foscam 9821W webcam. They're 1280x720, initially in colour but I'm converting them to greyscale for classification.
I ...
2
votes
2answers
42 views
Faster way to analyze each sub-window in an image?
I'm trying to calculate the entropy feature of sub-windows in an image. Here is the code I wrote:
def genHist(img):
hist = np.histogram(img, np.arange(0, 256), normed=True)
return hist[0]
...
1
vote
1answer
75 views
How to write text on a image in windows using python opencv2
I am a newbee to Python OpenCV.
I wanted to put some text on an Image.
I am writing the code as:
cv2.putText(image,"Hello World!!!", (x,y), cv2.CV_FONT_HERSHEY_SIMPLEX, 2, 255)
It gives ERROR, ...