Skip to main content

Questions tagged [opencv]

OpenCV (Open Source Computer Vision) is a cross-platform library of programming functions for real time computer vision.

Filter by
Sorted by
Tagged with
4 votes
1 answer
406 views

I have questions regarding this code: As the cv::Mat copy constructor involves only pointer copying due to the reference counting mechanism, in the ...
sam's user avatar
  • 503
5 votes
2 answers
113 views

I am working on a sign language recognition system that processes pre-recorded video datasets to extract hand gesture features for AI training. I am using MediaPipe, OpenCV, and TensorFlow to extract ...
Juwan Carlos Casuco's user avatar
5 votes
1 answer
126 views

This is the third version of the photo size reduction tool for code review. The previous reviews are Resize 200 photos quickly in C++ using opencv and Photo Reduction Tool version 2 - Possible ...
pacmaninbw's user avatar
  • 26.2k
6 votes
2 answers
166 views

The code is a Linux command line photo size reduction tools. It reduces the size of all the photos in a directory. It may work on Windows 10, but it has not been built or tested on Windows. It takes ...
pacmaninbw's user avatar
  • 26.2k
6 votes
2 answers
228 views

I have about 200 photos that I need to up load to a WordPress website. When I tried up loading the second one I got an error message that the file was too wide. Apparently WordPress limits the width ...
pacmaninbw's user avatar
  • 26.2k
2 votes
3 answers
238 views

I tried to parallelize the loop, and I got a good result but still not enough. This post is a follow up to a recent one where I optimized other parts of the code using a lookup table and spacial and ...
Ja_cpp's user avatar
  • 433
9 votes
1 answer
248 views

Task I wrote a movie barcode generator in C++ using OpenCV. Self-described engineer, space lover and tea drinker Thomas Poulet defines a movie barcode as follows: A Movie Barcode is the color ...
Jay Gupta's user avatar
  • 151
6 votes
2 answers
691 views

I want to optimize the code to run faster, so I started with parallelizing the for loops, but the code still not very fast. I do get variable frames per second, ...
Ja_cpp's user avatar
  • 433
2 votes
0 answers
68 views

This is a follow-up question for An Updated Multi-dimensional Image Data Structure with Variadic Template Functions in C++. I am trying to build the bridge to perform the conversion between the ...
JimmyHu's user avatar
  • 7,575
3 votes
0 answers
75 views

I am working on a watermark removal project using OpenCV in C++. The goal is to recover the background from a composite image by separating it from the foreground (watermark). The code processes the ...
Lucas's user avatar
  • 31
1 vote
1 answer
169 views

I am using OpenCV’s findchessboardcornersSB function to find the corners in the image. I am using below code/ header file: ...
Dushyant Patil's user avatar
9 votes
1 answer
764 views

In the picture below there are some regions which are very bright (i.e. more white). Some bright regions are wide and some are narrow or thin. The red box covers one such wide bright spot, and blue ...
S. M.'s user avatar
  • 113
7 votes
1 answer
495 views

I have written a code to stitch 2 images using SIFT keypoint descriptor and homography matrix for perspective transform. Are there any areas where code an be improved or optimized? ...
Dushyant Patil's user avatar
2 votes
0 answers
207 views

This program uses webcam to track hand movements / gestures and sends corresponding mouse / keyboard events to the computer. I use it to switch spaces, move active window between desktops, scroll ...
TheCommentWriter's user avatar
1 vote
2 answers
540 views

I have found that a bottleneck of the OpenCV application I use is the bilinear interpolation, so I have tried to optimize it. The bilinear interpolation is in 8D space, so each "color" is an ...
rafoo's user avatar
  • 335
2 votes
1 answer
1k views

I am beginner for the openCV. I am using below codes to get four video in a file system and show to user. Like this: V1 | V2 V3 | V4 Video length does not match, ...
hobik's user avatar
  • 121
1 vote
1 answer
96 views

I made this script that takes 3 images taken with a polarising filter 45° apart as inputs and outputs an RGB preview and an image which encodes the polarization parameters as HSV. However it's way too ...
Omar Morales Rivera's user avatar
2 votes
1 answer
188 views

My code takes 3 images taken with a polarising filter rotated 45° between them and transform them into a single image encoding the polarization parameters as HSV. what can be improved? ...
Omar Morales Rivera's user avatar
1 vote
1 answer
153 views

I tried to implement the mcolor colormap in the paper at page 8 to 10. I developed the code to process a image file and it works ok. Now, I want to adopt this image processing method to the camera ...
David Lin's user avatar
5 votes
1 answer
1k views

I wrote a code to remove the background of 8000 images but that whole code is taking approximately 8 hours to give the result. How to improve its time complexity? As I have to work on a larger dataset ...
Hyphen's user avatar
  • 51
1 vote
1 answer
156 views

The code works perfectly. It looks for a certain parts of the screen where the terraria fishing particles would be appear, after which it, if the threshold is met, it fishes. I was wondering if it was ...
SpedEdRokay's user avatar
13 votes
3 answers
1k views

The code run perfectly fine, with no errors. However, the entirety of the code is in 1 function and is kind of hard to read. As well as that I'm not sure if and how the code could be more optimised/...
SpedEdRokay's user avatar
2 votes
0 answers
149 views

Working code for my image detection script. This is functional code. I'm loading a number of images into an array, and using two classes to generate the two main components I need for my detection; <...
mak47's user avatar
  • 121
6 votes
1 answer
2k views

I have written a Python script that takes a list of filenames of pictures and generates a photo collage of them. This is my most complex project yet, and I have written it completely by myself (like I ...
Ξένη Γήινος's user avatar
2 votes
0 answers
66 views

Here's my code - I've a lot to learn so any advice, tips etc would be welcome! A few notes: I'm using OpenCV and numpy for other features in this code, not just for this snippet. The main readon for ...
user1714819's user avatar
3 votes
1 answer
1k views

I have created a C++ program that changes the color of a pixel to another color. But the main feature is that it not only changes 100% accurate colors; instead it matches two colors by using a method ...
Darth-CodeX's user avatar
2 votes
0 answers
65 views

I'm trying to learn python by building an image detection bot for a 2d game. The bot checks to see if it can find any one of a number of images within a cropped section of the game window. If it finds ...
L23P's user avatar
  • 123
8 votes
2 answers
1k views

This program loads a video, detects and tracks faces in the video and detects the estimated age and gender of each person. The objective is to collect data on the number of unique people in a video ...
rosall's user avatar
  • 81
3 votes
0 answers
89 views

I have (for example) the following license plate image: And I want to segment the characters. The code I have so far consists of me using cv2.MSER to detect ...
Michael Kročka's user avatar
2 votes
3 answers
569 views

I am attempting to extract the absolute differences image between two input images and then enhance the intensity (brightness) channel in HSV color space with the given times. The workflow is like ...
JimmyHu's user avatar
  • 7,575
1 vote
1 answer
104 views

Problem statement: Assume a high resolution (> 3000 x 3000) image is given as input. The image pixels can be classified into one of the three categories namely text, background and drawing. There ...
nkvns's user avatar
  • 399
5 votes
1 answer
103 views

This is an effect to augment juggling videos: The goal of this effect is to add a rainbow trail to a video using a tracked set of points. Link to source video Link to source data Link to complete ...
Stephen Meschke's user avatar
3 votes
1 answer
217 views

For academic purposes I want to reinvent Blue Green Red to Grayscale function in Python. I am new to Python so I believe my code below can still be optimized. ...
Display Name's user avatar
3 votes
1 answer
198 views

I am trying to learn how to correctly implement an iterator (and its corresponding const variant) using a single template, so I would appreciate any criticism to the following code. It's an forward ...
Black Arrow's user avatar
2 votes
1 answer
351 views

I have ~40,000 JPEG images from the Kaggle melanoma classification competition. I created the following functions to denoise the images: ...
Yehuda's user avatar
  • 121
1 vote
1 answer
274 views

I have a small bit of code and I wonder if I can make it more readable. I would appreciate it if some people could take a look at it and give me some feedback. I especially wonder if there is a beter ...
Jelle Vos's user avatar
3 votes
0 answers
761 views

I am analyzing videos from the popular social media platform, TikTok, and extracting the songs into a Spotify playlist. Here is a gif of one of these videos: https://i.imgur.com/I0dVoac.mp4. Full ...
Peter Stenger's user avatar
3 votes
0 answers
2k views

My goal is to make a class that wraps the complexity of OpenCvSharp implementation to show a webcam streaming into a WPF Image. ...
user avatar
1 vote
1 answer
162 views

Follow up question Image processing using Python OOP library I want to use multiprocessing to analyze several images in parallel: ...
snowflake's user avatar
  • 275
5 votes
0 answers
852 views

I'm really new to OpenCV. :) I have been working on this for almost an entire day. After hours of sleepless work I would like to know if I can further improve my code. I have written some code to ...
Avishka Dambawinna's user avatar
5 votes
2 answers
769 views

This script takes an image copied from the clipboard and analyzes the n darkest pixels of the image. It will loop through each found value, prints out the value information and the quantity, then ...
what the's user avatar
  • 151
2 votes
1 answer
1k views

I've made a sudoku solver which solves a sudoku, given user input, and can also extract digits from a picture of a sudoku to solve it. I've used OpenCV and GTK+ 2.0 to achieve the above. I am very ...
karan_zoh's user avatar
0 votes
1 answer
565 views

I was just wondering if there is a way to speed up the performances of this for loops in Python. I'm trying to process an image to get the color-moments without using libraries. It takes about 12sec ...
Enrico Mosca's user avatar
3 votes
1 answer
469 views

Here is an implementation of Conway's Game of Life. It is kind of a brute force but it works fine. I have a special question about the method cv::Mat render() const,...
curiouscupcake's user avatar
1 vote
1 answer
62 views

I've created an application to predict emotions. But I think the application is being over fitted. And I cannot figure out how to solve the overfitting. I'm using a small data set of 107 images spread ...
Jack Reilly's user avatar
3 votes
0 answers
504 views

I am working on an object detection API implemented in Tensorflow 1.14 and OpenCV 4.1, where my task is to recognize personal protection equipment (PPE) worn by workers at various construction site ...
Demeter Márton's user avatar
4 votes
1 answer
495 views

This is my first ever Python program; it uses Python version 3.7.3. It checks every frame of a video file with Tesseract then uses OCR to recognise numbers in that frame and prints it to the console. <...
Dev's user avatar
  • 41
3 votes
0 answers
145 views

I have been trying to find defects (brown/copper parts) on this sample using PyQt, OpenCV and Python: And I can find defects, too. My problem is, I have nobody to ask, get feedback etc. I need some ...
Mustafa's user avatar
  • 31
6 votes
1 answer
304 views

With some basic knowledge of Python and referring a lot of sources, I have written the code below. But it takes half an hour for execution. How can I reduce the time? I read about vectorization but ...
Ankit Jaiswal's user avatar
5 votes
1 answer
208 views

I have a live webcam windows which means there are six subdivided windows in a single window live. And show pictures in colored and black and white. Is there anyway I can make the code ...
mvr950's user avatar
  • 297