Skip to content

Instantly share code, notes, and snippets.

View henrysue's full-sized avatar
🏢
work

Henry Sue henrysue

🏢
work
View GitHub Profile
@henrysue
henrysue / ExtractBoundingBox
Last active March 9, 2020 17:38
Extract Bounding Box Coordinates from Image
import cv2
class ExtractImageWidget(object):
def __init__(self):
self.original_image = cv2.imread('test.png')
self.clone = self.original_image.copy()
cv2.namedWindow('image')
cv2.setMouseCallback('image', self.extract_coordinates)
@henrysue
henrysue / ExtractImageWidget
Created March 9, 2020 17:07
Extract Bounding Box Coordinates from Image
import cv2
class ExtractImageWidget(object):
def __init__(self):
self.original_image = cv2.imread('test.png')
self.clone = self.original_image.copy()
cv2.namedWindow('image')
cv2.setMouseCallback('image', self.extract_coordinates)