Skip to main content

Questions tagged [opencv]

OpenCV (Open Source Computer Vision) is a library for real time computer vision. When using this tag, please add a language specific tag (python, c++, ...), if relevant.

0 votes
0 answers
12 views

Change color background of chat screenshot with multicoloured background

I have a screenshot taken from a chat platform and want to change the background of the chat to white, including profile pictures of participants. The code from this Question works fine if the name of ...
0 votes
0 answers
31 views

How to identify the similarity(in %) between 2 "Black & White" only images / similarity between shapes ignoring colors?

I've searched all possible related keywords that I can think of, but the results are not really what I'm looking for, as most algorithm I found puts high concern on COLOR. The idea of my application ...
0 votes
0 answers
17 views

How to get centers of circles arranged in a grid in specific order in opencv

I have some approximate circles in an approximate grid shape, but there is distortion. How can I get the centers in the order of left to right, top to bottom? I tried findCirclesGrid, but I don't ...
2 votes
1 answer
500 views

Find or detect a single tile from a tiled image

Given a tiled image, is there an algorithm or library like OpenCV or some other python library that can detect the bounds of a single repetition or tile and export it. Example Given this image ...
-1 votes
1 answer
39 views

Python - errors when calling cv2.ml.TrainData_create(): - responses data type = 19 is not supported - Expected Ptr<cv::UMat> for argument 'responses'

I am following the following tutorial: https://www.opencvhelp.org/tutorials/deep-learning/training-models/ Following the instructions using the Caltech-101 dataset, I preprocessed the images (...
4 votes
3 answers
166 views

Compromise between quality and file size, how to save a very detailed image into a file with reasonable size (<1MB)?

I am facing a small (big) problem: I want to generate a high resolution speckle pattern and save it as a file that I can import into a laser engraver. Can be PNG, JPEG, PDF, SVG, or TIFF. My script ...
-2 votes
0 answers
25 views

I get this error: (-215:Assertion failed) npoints >= 0 && (depth == CV_32F || depth == CV_32S) in function 'contourArea'

when I run the ros2 run self_driving_car_pkg computer_vision_node this I get this error from termiinal = area = cv2.contourArea(cnt) cv2.error: OpenCV(4.10.0) /io/opencv/modules/imgproc/src/...
0 votes
0 answers
28 views

Why is OpenCV's matrix addition function not clipping when I add a uint8 variable with a value of 200 to a uint8 variable with a value of 100? [duplicate]

I am working my way through PyImageUniversity and am familiarizing myself with matrix addition and subtraction in Python using NumPy and the OpenCV library. I have Python 3.11.4, OpenCV 4.10.0-dev, ...
1 vote
0 answers
21 views

Opencv module dnn inference with batch greater than 1

I want to perform inference using the dnn module of opencv. This is my code: static cv::Mat inputBlob2; static std::vector<cv::Mat> outputs2; cv::dnn::blobFromImages(images, inputBlob2, 1.0 / ...
-1 votes
0 answers
25 views

Find the best convergence point of multiple particules trajectories? [closed]

In my project, I would like to find the best convergence point of trajectories of tracked points (done with cv2.calcOpticalFlowPyrLK...). I know all the points of each trajectory. My goal is to find ...
-3 votes
0 answers
48 views

How to add horizontal lines to the table in image opencv

I want to add horizontal lines to the below image resultant output should be like: Any methods on how to work it out, even if there are diff images which don't have horizontal lines. I've tried ...
-1 votes
0 answers
37 views

Improve signature quality extracted using OpenCV from scanned sheet paper

I extracted a signature from a scanned sheet of paper. Users know there should be only the signature on a white sheet of paper. I implemented the signature cropping from the uploaded image using the ...
0 votes
3 answers
69 views

Extract Shapes from an image with black background

I have a task to bulk extract shapes from an image. The image is with black background and the shapes are with white border. The main goal is to extract the fruits from the image. How do you that ...
1 vote
0 answers
43 views

How to extract a rectangle in an image from identified lines

I have thousands of images that look like this: I need to run an OCR algorithm on the "1930 E.D." column. I find that when I crop the image down to just that column, I get much better ...
-5 votes
1 answer
72 views

Conway's GOL rules not implemented correctly [closed]

I am using OpenCV and a kernel to count neighbors of each pixel, the pixel's value then becomes the number of neighbors that it has, and then I apply Conway's rules, but the output is not as expected, ...

15 30 50 per page
1
2 3 4 5
4904