Ask Your Question

Finding the perfect algorithm for 2dFeatures real time feature detection/matching

asked 2019-02-13 09:45:41 -0600

joinity gravatar image

Hello OpenCV Community, I am relatively new to the world of opencv and try to do a project with following requirements:

My robot has to detect a picture in his fixed field of view out of a local database of 200 pictures The camera angle is in a 45° angle and has a fixed height. The images are all presented at a fixed distance but can be presented in a different rotation. The hardware resources are extremely limited and i would like to run it on a raspberry pi in real time at around 5 fps The goal would be to get even cheaper hardware like an Ingenic Chip or an Allwinner one.

My question therefore would be, if there is a perfectly lightweight and 100% failsafe algorithm for this!

I thank you for your help

edit retag flag offensive close merge delete


if there is a perfectly lightweight and 100% failsafe algorithm for this

lol, silver bullets, dream on.

berak gravatar imageberak ( 2019-02-13 09:57:58 -0600 )edit

1 answer

Sort by » oldest newest most voted

answered 2019-02-13 09:51:50 -0600

berak gravatar image

updated 2019-02-13 12:54:37 -0600


"out of a local database of 200 pictures" --

are you trying to do some arbitrary "object detection" like this ?

then you're most probably on the wrong bus.

(it won't ever work ! feature matching is for finding parts of a single, known scene only, it can never tell you, if it's NOT there, no matter, which features you choose, it's a constraint of the matching algorithms. it's main application is finding a homography between a part of the scene and the whole, NOT detection.)

are you also aware, that for 200 db images you would need 200 detectAndCompare() calls & matching ?

forget that idea immediately, please, it's a waste of time. instead do some research on depp learning, SSD nets, YOLO, etc. those can be re-trained with quite sparse data on your special problem set, and you can run the inference later from opencv again.

edit flag offensive delete link more


First of all thanks for your answer! Could you explain how this Video did this then? He said he uses ORB with a databse of 20.000 Images. For SSD nets and YOLO can i train it to detect various magic cards like in the video, with invariant rotation?

joinity gravatar imagejoinity ( 2019-02-14 02:51:44 -0600 )edit

sorry i never look at videos (waste of time)

you CAN use 2d features for CBIR like tasks, but that needs extensive (BoW) clustering, and a different type of matching (like a flann index, or SVM classification). it also won't work for detection (or say, localization).

berak gravatar imageberak ( 2019-02-14 02:56:47 -0600 )edit

Im sorry, i think my language barrier made you think that i want to detect the position. I just want to show the camera a printed card and it detects that i show card x and i have 200 cards.

joinity gravatar imagejoinity ( 2019-02-14 03:04:20 -0600 )edit

Question Tools

1 follower


Asked: 2019-02-13 09:45:41 -0600

Seen: 271 times

Last updated: Feb 13 '19