Ask Your Question

Recognize play card

asked 2013-10-04 09:49:43 -0500

MaxiPigna gravatar image

Hello, I want to implement an application for Android able to recognize play cards. In particular, my problem is that cards are arranged as here. So, I guess that the best way to recognize them is trying to read the number/letter (and symbol for the joker) on the corner, since I do not care about the suit of the cards. How can I do that? Sorry, but I am not an expert so please I need of your help.

edit retag flag offensive close merge delete


I'm not sure, but I think template matching can help you identify number/suits.

GilLevi gravatar imageGilLevi ( 2013-10-04 12:29:49 -0500 )edit

1 answer

Sort by ยป oldest newest most voted

answered 2013-10-04 11:03:22 -0500

Maxim Galushka gravatar image


You can try to train Haar classifiers to recognize the suit for cards, here is article with detailed explanations how this can be done:

However this is not simple task as you will require a lot of positive/negative samples for this.

To recognize the numbers - I think there should be existing solutions, here is good source on OCR:

Also you can use findContours to separate cards from each other.

This is not a simple task, if you are really interested - post here your findings and code and I can help to get you tight direction.

edit flag offensive delete link more


Thanks for your answer. As I said I do not care about the suit of the card, so why should I implement that classifier to do that? I need only to recognize letters and numbers, because what I want to get is counting how many cards there are for each number/letter. For instance, looking the previous example the first player has six Ks, one 7, five 8s, one 9, three Js and one joker.

MaxiPigna gravatar imageMaxiPigna ( 2013-10-04 11:49:12 -0500 )edit
Login/Signup to Answer

Question Tools


Asked: 2013-10-04 09:49:43 -0500

Seen: 4,122 times

Last updated: Oct 04 '13