Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 4 years ago.
Improve this question
Which is the best way to compare two images from same domain, different features in python. Histogram or Image quality functions ?
I have two images for different scenes, the contents inside the images are different, but both of the images are taken during morning.
I want to compare how much these two images are related to each other ?, like my important metric, is to say that these two images were taken during morning for example, even if different contents.
Any idea or way how to do this ?
There is no easy answer to your question. It depends on how do you consider images similar or different. And this is a subjective measure that is totally dependable on what do you want to do with this information.
Anyway, for this kind of problems, opencv is your friend. Here I list some ideas:
use histograms: cv2.histogram https://docs.opencv.org/3.1.0/d1/db7/tutorial_py_histogram_begins.html
with histograms you can know how blueish, greenish or redish an image is. You can compare if 2 images are in the same range (bin) of a specific color. This is something very common when you want to detect skin color.
if you have an specific object that appears in different images, use SIFT or SURF.
Related
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed last year.
Improve this question
Hi I am a student doing research in my university. This is my first time using computer vision (openCV) and I am fairly new to image preprocessing. I have these images of License Plates and I would like to use easyOCR/pytesseract to read the plates. Currently all I have done is convert the image to grayscale, rotate it by a few degrees, but the reading results are very inconsistent. How do I improve that?
I have tried using kernels to sharpen the images but they seem to be fairly inconsistent too.
Here are some images I have to give you a general idea of what the images are like:
I would start with image enhancement. It's hard to tell what exactly is applicable but here are some possible manuevers:
As usual recognition algorithms are not invariant to rotation. And every image seems to be geometically distorted similarly. You can try to normalize the geometry by warpPerspective function from Opencv with appropriate transformation matrix. Rotation is a subset of all possible transformations covered by perspective transform.
You can try to use advanced deblurring techniques like wiener filter or deeplearning. It seems like point spread function is different from image to image that complecates the recovery.
There is some periodic signal in your images (vertical blue-white-blue stripes). That can possibly can be enhanced by doing FFT -> removing components of the specific wavelength -> iFFT.
Anyway looking on your images, I am not sure if it will be easy to achieve the desired result without diving into the OCR pipeline.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 3 years ago.
Improve this question
Well currently I'm working on a personal project which is the identification of products in a scanned image taken from a store catalog.
As you may see in the image there's no lines separation between products, so using Hough lines to locate the products won't really solve the problem!
Using Tesseract is really amazing to extract the image content, the only problem that I'm facing is finding the image products automatically, I mean not cropping the image manually but I want to detect the products, cropping them with their text description and price and then extract content using OCR.
I have tried many image processing techniques but still nothing (I'm using Python and OpenCV).
Thanks in advance :)
The problem you have is usually called background removal, or alternatively foreground extraction. In this example, it might actually be relatively easy, as the background is mostly in shades of the same color - my recommendation would be to look at the GrabCut algorithm which is described here: https://docs.opencv.org/3.4.3/d8/d83/tutorial_py_grabcut.html
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 4 years ago.
Improve this question
I have a set of images. I have to use them for training a network. I want to simulate a lens flare effect and chromatic aberration on the images. I have tried to find some function in OpenCV, scikit and other python image library but no help from there. How can i simulate these effect on my image? Rough idea or code will be useful. Images are in jpg format.
Depends on what kind of lens flare you are trying to achieve. Create e.g. hexagon mask and overlay multiple instances of it partially transparently between start and end point of the flare axis? Hexagons should be at least slightly bigger "in sun's direction" and spaced more or less in equal distance compared to each others. User should be able to click start and end points of said axis from the pic and use e.g. mouse to rotate, zoom in/out the axis and define number of flare elements to be added.
For chromatic aberration, I would split the RGB components, apply slightly different scaling factors, and merge back. Depending on whether you want to simulate a flint or crown effect, the factors will be increasing or decreasing.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I am working on the program to extract text from the image. For that I tried with Tessaract and Ocropus libraries and I am able to convert simple plain text (black and white with simple font) from image to text string. For example:
But I am not able to extract texts from complex image. Let's say for example from this image:
Does anyone know how to achieve this? Is there any library available for extract text from complex images (with unpredictable different backgrounds? I will prefer Python, but language is not a bar.
How all this word recognition work is machine learning algorithm is fed a lot of images with already interpreted corresponding text. It learns to understand letters from different fonts and appearances it is given.
However, logos are made with very specific font. Almost no two logos use similar one. That makes it very hard, if not impossible, to create a learning data to recognize what is written.
That is possible to train algorithm to recognize Sprite trademark everywhere it sees it. For that, you'd need to use OpenCV and train it on Sprite logos of different qualities, pictures of logos of Sprite on stores, bottles, etc. That way, it will be able to see this particular logo (you also will need a dataset of non-Sprite logos, like Coke logo or picture of something completely irrelevant, like cat).
The reasons humans, unlike computers, can learn to recognize these things is because human brain is so much more powerful that the neural network you can create to understand that kind of things in computer. When computers will be as powerful as humans are in terms of computational capacity, re-ask this question and you will receive automatic answer from human-like machine.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
I am trying to enhance blood vein part in forearm image shown below.
After grayscale conversion I got following image.
Then I followed histogram equalization and got better result as shown below
Based on the histogram equalized image, I need to enhance blood vein part in original image. For that purpose first I need to extract blood vein from histogram equalized image, but I am not getting any result. Can anyone suggest proper method to enhance blood vein in original infrared image. ?? I am using python+OpenCV for image processing
Area of interest to extract is shown below