Download as pdf or txt
Download as pdf or txt
You are on page 1of 38

INDUSTRIAL TRAINING REPORT

On

Fake Currency Detection


Done by

Alok Kumar Dubey


At

UCL Multimedia Anthropology Lab


(University College London, 14 Taiwan Street, London, UK)

Under the guidance of

Maven Cruise
(Mentor & Senior Developer, UCL Multimedia Anthropology lab)

Submitted to

Mrs. Pratiksha
(Lecturer Information Technology, Government Polytechnic Lucknow,
Uttar Pradesh, India)

1
DECLARATION

Certified that this Industrial Training Report is a work of Alok Kumar Dubey who

carried out the work at UCL Multimedia Anthropology Lab, 14 Taiwan Street, London,

United Kingdom. This report also gives the information about the organization and it’s

Working along with the project undertaken in the training and internship period. Here,

I follow the ISO guidelines to make it perfect.

~ Alok Kumar Dubey

2
ACKNOWLEDGEMENT

It is always a pleasure to remind the fine people in this training program for their

sincere guidance I received to uphold my practical as well as theoretical skills in

engineering.

Firstly, I would like to thank Mrs. Pratiksha (Lecturer Information Technology,

Government Polytechnic Lucknow), for meticulously planning academic curriculum in

such a way that students are not only academically sound but also industry ready by

including such industrial training patterns.

I would like to thank Miss. Maven Cruise (Mentor & Senior Developer, UCL

Multimedia Anthropology Lab), who gave me her full support and encouraged me to

work in an innovative and challenging project for machine learning field. Her wide

knowledge and logical thinking gave me right direction all the time. I am deeply

grateful my project coordinator for her help and support provided at every step of the

project.

Finally, I would like to thanks Miss. Raffaella Fryer-Moreira (Director & Co-

Founder, UCL Multimedia Anthropology Lab) for giving me this opportunity and guiding

me during the course of the training.

3
TABLE OF CONTENTS

DECLARATION……………………………………………………..ii

ACKNOWLEDGEMENT ………………………………………………………….iii

LIST OF CONTENTS …………………………………………………….iv

CHAPTER 1: INTRODUCTION

1.1 Introduction ……………………………………………………….1

1.2 Objects in View…………………………………………………..2

1.3 Methodology…………………………………………………….3

1.4 Software Specification………………………………………………....3

1.5 Security Features …………………………….…...4

1.4 Problem Statement…………………………………………………………….4

1.4.1 Objective…………………………………………………………5

1.5 Algorithm ………………………………………………………….6

CHAPTER 2: SCREENSHOTS

2.1 Importing libraries ……………………………………………………………10

2.2 Creating a function to store the dataset ………………………………………….11

2.3 Setting up the image window …………………………….………….12

CHAPTER 3: OUTPUT

3.1 Grayscale Image ……………………………… 13

3.2 Getting all the possible events ………………….14

3.2 Verification of total 10 events …………………………………15


4
CHAPTER 4: GUI SETUP

4.1 Importing Tkinter ………………………………16

4.2 Setting up frames ……………………17

CHAPTER 5: GUI MODEL SCREENSHOT

5.1 File uploading window …………………………...18

5.2 Selection of file ……………………19

5.3 Verifying the currency …………………………20

CHAPTER 6: REAL CURRENCY

CHAPTER 7: FAKE CURRENCY

CHAPTER 8: CONCLUSION

5
INTRODUCTION

The aim of this project is to test the authenticity of Indian currency notes by

preparing a system which takes the image of currency bill as input and gives the final

result by applying various image processing and computer vision techniques and

algorithms. This currency authentication system has been designed completely using

Python language in Jupyter Notebooks. OpenCV library has been used for image

processing, Matplotlib library for visualization in python for 2D plots of array and

Numpy library has been used for scientific computing in Python.

OBJECTS IN VIEW:

A fake currency detection system as the name suggests will find whether a note

given to you by any person is real or fake. This system will be very useful because the

circulation of inauthentic money is increasing day by day. So there needs to be a

system that will prevent this from happening.

This system can be used by banks and common people. This will help the bank identify

fake notes and real notes. This can also be used by common people to prevent them

from being thug.

6
METHODOLOGY:

1. Image Acquisition: The image is provided to the model. There should be two

images – a note which you want to detect and a corresponding real note.

2. RGB to GRAYSCALE: The RGB image is converted into a GRAYSCALE image.

3. Segmentation: The image is segmented to crop Mr. Gandhi Ji image and thin strip

image.

4. Feature Measurement: Feature measurement is done to measure the number of

lines on a thin strip. This is a really lengthy process.

5. Finding Correlation: We find a correlation between Mr. Gandhi Ji’s image on the

original note and a fake note. If the result is greater than 0.5 then we will consider

it legitimate otherwise the currency is fake.

6. Classification: Finally, we will classify the image as real or fake.

SOFTWARE SPECIFICATION:

Programming Language –

• Python Numpy

• Python OpenCV

• Python Matplotlib

Software and Objects –

7
• Jupyter Notebook

• Kaggle Dataset

• Indian Currency

SECURITY FEATURES:

1. Bleed lines: There are angular bleed lines on 500 and 2000 note on left and right

corner of note in raised print in 500Rs. note there are 5 bleed lines and In

2000Rs. note, 7 bleed lines.

2. Security Thread: A color-shifting security thread with the inscription Bharat (in

Hindi).RBI and 2000 (500 for 500 note). The color changes from green to blue

when it is tilted.

3. Latent Image : Latent images of number 2000 / 500 can be seen when note is

held at 45 degrees angle.

4. Water mark: Watermark of Mahatma Gandhi and electro type of numeral

2000/500.

5. Denominational Numeral: See-through register, with denominational numeral

2000, can be seen when you hold the note against the light.

6. Portrait of Mahatma Gandhi: Portrait of Mahatma Gandhi with RBI written on

his spectacle which can be read using a magnifying glass.

8
7. Number panel: Numerals growing from small to big size, is printed on the top

left side and bottom right side.

8. Denominational numeral: On left side of Mahatma Gandhi there is a 500/2000

in Devanagari script.

9. Ashoka Pillar: There is Ashoka Pillar on right bottom side.

10. Guarantee and promise clause: The guarantee and promise clause of RBI is

present in Devanagari as well as in English in the top left and top right corner of

the currency notes respectively.

11. RBI seal: The seal of RBI is present just below the Governor’s signature. This seal

as well as the guarantee clause, etc. are in intaglio printing.

12. Denominational value in words: The denominational value of the currency note

is written in Devanagari script in the top central region of the note.

PROBLEM STATEMENT:

To test the authenticity of Indian currency notes by preparing a system which

takes the image of currency bill as input and gives the final result by applying various

image processing and computer vision techniques and algorithms.

Objectives --
9
• The main objective of the project is to identify the fake Indian currency

notes through an automated system by using Image processing and

computer vision techniques.

• The system should have high accuracy.

• The system should be able to give the final results in a short time.

• The system should have a User-friendly interface, to make it convenient

to use and understand.

ALGORITHM:

1) Feature detection and matching using ORB: After completing the necessary

processing of the image, feature detection and matching is done using ORB. Our

dataset already contains the images of different security features present in a

currency note (total 10). Further, we have multiple images of varying brightness

and resolutions corresponding to each security feature (6 templates for each

feature). Using the ORB algorithm, each security feature is detected in the test

image. To make the searching of the security feature (template image) easier

and more accurate, a search area will be defined on the test currency image

where that template is most likely to be present. Then, ORB will be used to

detect the template in the test image and the result will be highlighted properly

with a marker. This process will be applied for every image of each security
10
feature present in the data-set and every time the detected part of the test

image will be highlighted properly using proper markers.

Fig, 1: ORB Feature detection and Matching

2) Feature Extraction: Now, using ORB location of each template has been

detected in the input image within the highlighted area. The highlighted area is

then cropped by slicing the 3D pixel matrix of the image. Next, we apply Gray

scaling and Gaussian blur to further smoothen the image and now our feature is

ready to be compared with the corresponding feature in our trained model.

11
Fig. 2: Features in 500

3) Feature comparison using SSIM: From the previous step, the part of the test

currency image which matches with each of the templates will be generated.

12
SCREENSHOTS

13
14
15
16
17
18
19
20
OUTPUT

ANALYSIS OF
FEATURE 1
---> Template 1 :
SSIM score: 0.8334965111329322

---> Template 6 :

21
SSIM score: 0.70525320950985
44

SSIM score set of Feature 1: [0.8768639144981325, 0.7292631586285556, 0.750865657


0701558, 0.7322303337864629, 0.8334965111329322, 0.7052532095098544]

Average SSIM of Feature 1: 0.7713287974376822

ANALYSIS OF FEATURE 2
---> Template 1 :
SSIM score: 0.7279643584766854

---> Template 2 :

22
M score: 0.24857131667920093

---> Template 3 :
6506124310216

---> Template 6 :

SSIM score: 0.31136791471179


8

SSIM score set of Feature 2: [0.7279643584766854, 0.24857131667920093, 0.54249988


26541236, 0.2024159064261172, 0.4766506124310216, 0.311367914711798]

Average SSIM of Feature 2: 0.4182449985631578

ANALYSIS OF FEATURE 3
---> Template 1 :
4

---> Template 4 :

23
SSIM score: 0.397711919504596
17

SSIM score set of Feature 4: [0.9138426978521372, 0.8184054440154294, 0.681507759


8517413, 0.45465507658774906, 0.39771191950459617]

Average SSIM of Feature 4: 0.6532245795623306

ANALYSIS OF FEATURE 5
---> Template 1 :

SSIM score: 0.809492255920155


4

24
.546661260824316

SSIM score set of Feature 5: [0.8094922559201554, 0.5342628991072657, 0.797266186


7106916, 0.5879375678629434, 0.6718042505188937, 0.546661260824316]

Average SSIM of Feature 5: 0.6579040701573776

ANALYSIS OF FEATURE 6
---> Template 1 :

---> Template 6 :

SSIM score: 0.728808846038556


2

SSIM score set of Feature 6: [0.8586384414625262, 0.45189214955995843, 0.32986368


7167565, 0.5524421518036705, 0.5361709404608963, 0.7288088460385562]

Average SSIM of Feature 6: 0.5763027027488622

ANALYSIS OF FEATURE 7
---> Template 1 :
SSIM score: 0.5398981198205617

25
SSIM score: 0.560992580139911
6

SSIM score set of Feature 7: [0.8134974042374281, 0.2726587468800321, 0.545253756


7066095, 0.3768855549151073, 0.5398981198205617, 0.5609925801399116]

Average SSIM of Feature 7: 0.5181976937832751

Final Score- set list:

Feature 1 : [0.8768639144981325, 0.7292631586285556, 0.7508656570701558, 0.7322303


337864629, 0.8334965111329322, 0.7052532095098544]
Feature 2 : [0.7279643584766854, 0.24857131667920093, 0.5424998826541236, 0.202415
9064261172, 0.4766506124310216, 0.311367914711798]
Feature 3 : [0.9339527104073755, 0.5149441631132722, 0.4528280871132562, 0.5581367
295383562, 0.5579608097831591, 0.6437104155105735]
Feature 4 : [0.9138426978521372, 0.8184054440154294, 0.6815077598517413, 0.4546550
7658774906, 0.39771191950459617]
Feature 5 : [0.8094922559201554, 0.5342628991072657, 0.7972661867106916, 0.5879375
678629434, 0.6718042505188937, 0.546661260824316]
Feature 6 : [0.8586384414625262, 0.45189214955995843, 0.329863687167565, 0.5524421
518036705, 0.5361709404608963, 0.7288088460385562]
Feature 7 : [0.8134974042374281, 0.2726587468800321, 0.5452537567066095, 0.3768855
549151073, 0.5398981198205617, 0.5609925801399116]

Final Average SSIM list for each feature:

Feature 1 : 0.7713287974376822
26
Feature 2 : 0.4182449985631578
Feature 3 : 0.6102554859109989
Feature 4 : 0.6532245795623306
Feature 5 : 0.6579040701573776
Feature 6 : 0.5763027027488622
Feature 7 : 0.5181976937832751

ANALYSIS OF FEATURE 8 : LEFT BLEED LINES

ANALYSIS OF FEATURE 9 : RIGHT BLEED LINES

Number of black regions found in each column:


7
7
7
7
7
7
7
7
7
7
7
7
7
7
7
27
7
7
7
7
7

Number of columns examined: 20


Number of non- erroneous columns found: 20

Average number of black regions is: 7.0

ANALYSIS OF FEATURE 10 : NUMBER PANEL

---> Threshold 1 with Threshold value 90 :


Unsuccessful!
---> Threshold 2 with Threshold value 95 :
Unsuccessful!
---> Threshold 3 with Threshold value 100 :
Unsuccessful!
---> Threshold 4 with Threshold value 105 :
Test Successful: 9 letters found!
---> Threshold 5 with Threshold value 110 :
Test Successful: 9 letters found!
---> Threshold 6 with Threshold value 115 :
Test Successful: 9 letters found!
Test Passed!- 9 characters were detected in the serial number panel.

RESULT ANALYSIS

Feature 1: Successful
Feature 2: Successful
28
Feature 3: Successful
Feature 4: Successful
Feature 5: Successful
Feature 6: Successful
Feature 7: Successful
Feature 8: Successful- 7 bleed lines found in left part of currency note
Feature 9: Successful- 7 bleed lines found in right part of currency note
Feature 10: Successful- 9 characters found in number panel of currency note

Result Summary:
10 out of 10 features are VERIFIED!

29
GUI SETUP

30
31
32
GUI MODEL SCREENSHOTS

33
34
REAL CURRENCY

35
FAKE CURRENCY

36
RESULT AND ANALYSIS

The proposed system authenticates the input image of currency note through image

processing. The input image passes through various algorithms in which the image is

processed and each extracted feature is thoroughly examined. The results are

calculated in the following manner:

• Algorithm 1 (Feature 1-7): This algorithm finally collects the average SSIM score

and the max. SSIM score for each feature. A feature passes the test and is real if the

average SSIM score is greater than a minimum value (this value has to be decided

after proper testing). A feature also passes the test if the max. SSIM score is too

high (probably greater than 0.8).

• Algorithm 2 (Feature 8-9): This algorithm finally returns the average number of

bleed lines present in the left and right sides of a currency note. Each feature passes

the test if the average number of bleed lines is closer to 5, in case of Rs 500

currency note, and 7, in case of 2000 currency note.

• Algorithm 3 (Feature 10): This algorithm finally returns the number of characters

present in the number panel of the currency note. This feature passes the test if the

number of characters detected is equal to 9 (for at least one threshold value).

37
CONCLUSION

In this paper, a fake currency detection model has been proposed for authentication of

Indian currency notes of denomination 500 and 2000 and implemented using OpenCV

image processing library in Python3. In this model, 10 features of the input currency

note are considered and then analyzed using 3 different algorithms. The input image is

taken through a GUI which allows the user to browse the image in his/ her system.

Then the results of the implemented model are computed and the analysis of each

feature is displayed in detail through a graphical user interface (GUI) created using

Tkinter GUI library. The model takes less time (about 5 sec- when only final results are

shown leaving unnecessary details) for processing an input image. The results are also

quite decent giving almost 79% accuracy in detecting genuine currency and 83%

accuracy in detecting counterfeit currency.

38

You might also like