Questions tagged [roi]

Region Of Interest, a region of an image on which algorithms are executed on.

Region Of Interest (ROI) is a selected subset of a data set identified for a particular purpose and is commonly used in many application areas. The data set could be any of the following:

  • 1D data set: a time or frequency interval on a waveform
  • 2D data set: the boundaries of an object on an image
  • 3D data set: the contours or surfaces outlining an object (a.k.a. the Volume of Interest (VOI)) in a volume
  • 4D data set: the outline of an object at or during a particular time interval in a time-volume

Tag Usage:

An ROI on an image can be defined in different formats, like a , a or a set of . The tag is commonly used in question related to or . An ROI can be defined to:

  • Restrict the region of the data set that an algorithm is applied to and avoid unnecessary calculations. (e.g., in an )
  • Identify/Annotate a part of data set. (e.g., locate moving objects in )
  • Extract additional information from the data set. (e.g., measure size of a tumor on a medical image)

An Example:

ROI locates the boundaries of a registration plate (it's Persian), this area will be used for ANPR:

enter image description here

Additional Reading:

Region of Interest on Wikipedia

441 questions
0
votes
1 answer

get non zero ROI from numpy array

I want to extract a rectangular ROI from an image. The image contains a single connected non zero part. I need it to be efficient in run time. I was thinking maybe: Summing along each direction. Finding first non zero and last non zero. Slicing the…
user158881
  • 133
  • 8
0
votes
1 answer

Removing the pictures outside the contour area

I am trying to remove the image that is not contoured. Are there any suggestions on how to achieve them? Below is my code for the contour import numpy as np import cv2 im = cv2.imread('after.png') imgray = cv2.cvtColor(im, cv2.COLOR_BGR2GRAY) ret,…
0
votes
0 answers

OpenCV: Why am I getting assertion failed on original Mat but not on the cloned one?

I am trying to apply the Sobel filter to my Mat which has data from an external source. The simplified code looks like the following: // Create Mats cv::Mat src = cv::Mat( cv::Size( ACQ_WIDTH , ACQ_HEIGHT ) , CV_8U ); cv::Mat dx; // Point Mat to…
Giack
  • 1
  • 2
0
votes
1 answer

How to remove blurred background of images?

I am working on a project of leaf disease classification. I want to remove the blurred background of my entire dataset using an efficient machine learning segmentation algorithm. The output should be the colored version of ROI. And due to the huge…
0
votes
1 answer

Image processing on the drawcontours area

I’d like to convert only the drawcontours area to RGB images, then convert it to HSV again in order to update lower and upper values every frame over time. Note: I’d like to avoid using the ROI of the rectangle area because of drawcontours is the…
Redhwan
  • 927
  • 1
  • 9
  • 24
0
votes
0 answers

cv2.imshow won't work after running cv.2 SelectROI

I have a problem here during cropping and saving image by using opencv. I'm trying to crop by using cv2.SelectROI function but after I drag on the image, cv.2imshow won't work properly. Here's my code: import cv2, numpy as np img =…
gi3265
  • 1
  • 2
0
votes
0 answers

Create mask from ROI

My target is to make a mask from .roi files. What I currently have is a .roi file (read with read_roi_file with a list of coordinates for each corner: x = roi2['85']['x'] = [94, 95, 96, 97, 98, 99, 100, 101, 101, 102, 103, 104, 105, 106, 106, 107,…
Kuba K
  • 23
  • 4
0
votes
0 answers

How to use opencv functions on roi

My project is REM sleep detector, and the provided pictures show the contour of my eyelid. As my eye looks in directions, this contour moves in a distinct way. For lack of a better solution, my first attempt is to draw a grid of rois on my video…
volker
  • 1
0
votes
0 answers

Find boundary points of a set of coordinates

My objective is to get an ROI that is outlined in the black in image The ideal result. After using the below Convex Hull Graham code, we are able to get an ROI as shows in image Result of the convex hull graham (overlay in white). Convex Hull…
0
votes
0 answers

Emphasis level map with ffmpeg using NVENC

I am trying to have different compression levels, to different regions in the video. ffmpeg has something called "addroi", but it's just a recommendation and doesn't guarantee the absolute level of compression. Nvidia NVENC has something called…
0
votes
1 answer

How to find roi_corners based on lower and upper pink color range so it can be blurred in python with opencv

I am using hardcoded values in roi_corners to blur number plate of car which is in pink color. I want to find out roi_corners by detecting lower and upper pink color range so that it can be blurred automatically by detecting location of pink color.…
chetan cc
  • 17
  • 5
0
votes
1 answer

Python ROI not being croped properly from contour

Hello everybody before you close this question, i have already searched here, here too and also here I am using python code to detect the Leaf in an image, using contours finding and then find out the largest contour, the part works best, but then i…
Zain Ul Abidin
  • 2,467
  • 1
  • 17
  • 29
0
votes
2 answers

How to crop multiple ROI in image using Python and OpenCV

I have an image that converted from PDF to PNG. The converted image contains several keywords that I wanted to extracted using OCR Tesseract. Right now, I need to determine the ROI manually to crop the selected ROI. Since I have more than 5 ROI's to…
faizal_a
  • 93
  • 4
  • 15
0
votes
0 answers

What is the difference between cropping an image and applying an ROI (region of interest) on the image

I'm using opencv. Having a base image (640x640) I want to know if applying a rectangular white shape mask of (100x100), in another words, a ROI is more time consuming compared to cropping the image in the same rectangular shape (100x100). What I…
Cătălina Sîrbu
  • 1,253
  • 9
  • 30
0
votes
0 answers

Is there a way to create a region of interest (ROI) on image using IDL?

I am trying to analyze images using IDL, and I need to create an ROI. Specifically, I have hundreds of images, each containing 6 bands. Two of the bands contain the longitude and latitude information of each image. I want to create an ROI using set…
Bereket
  • 55
  • 8