Skip to content

gaoyuanliang/bank_card_detection

Repository files navigation

Bank card image tagging by deep learning

Tagging images of bank cards, such as credit card, debit card, etc, based on Xception pretrained deep feature extraction and my own trained classification layers

Same image tagging examples:

Input Output
{
  'tag': 'bank_card', 
  'score': 0.9966258
}
{
  'tag': 'non_bank_card', 
  'score': 0.99998796
}

instillation

to install the bank card detector, you need Python 3.7.7

git clone https://github.com/liang6261515/bank_card_detection.git

cd bank_card_detection

pip3 install -r requirements.txt

wget https://github.com/fchollet/deep-learning-models/releases/download/v0.4/xception_weights_tf_dim_ordering_tf_kernels_notop.h5

download the pretrain model of bank card detection from the following url

https://drive.google.com/file/d/10H70SUi1C5R79cu-27u-bg9ytnZ8JV9F/view?usp=sharing

to use the model to tag the image, we have three cases

usage

Test case #1

the first image looks like

run the test code

from bank_card_detection import bank_card_detection

bank_card_detection('bank_card.jpg')

you will see the following output since the image itself is a credit card

{'tag': 'bank_card', 'score': 0.9966258}

Test case #2

the seconde image looks like

run the test code

bank_card_detection('bank_card1.jpg')

you will see the following output since the image has a group of visa cards

{'tag': 'bank_card', 'score': 0.9973912}

Test case #3

Then we will see one negative casese where the image have no bank card at all. The image looks like

Run the tagging codes

bank_card_detection('non_bank_card.jpeg')

You will see the output of non bank card because there is no bank card at all

{'tag': 'non_bank_card', 'score': 0.99998796}

I am looking for job

feel free to contact me if you have any problem with this package or you are hiring data scientist/AI engineer. I am actively looking for data science/AI related jobs

My email: yanliang2345@outlook.com

About

Tagging images of bank cards, such as credit card, debit card, etc, based on Xception pretrained deep feature extraction and my own trained classification layers

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages