SlideShare a Scribd company logo
1 of 32
Page 1
Visual Based Product Identification
System
Page 2
Visual Based Product
Identification System
Project Supervisor-Mr.Mahanama Dharmawardhana
Project Group-P 16
Group Members-E/11/252 (Madushanka,W.F.R)
E/11/267 (Muthukumaranage,M.S.P)
Page 3
Title & Outlines
• Introduction
• Details of Our Solution
• Experimental Results
• Conclusion
• Back-up Slides
Page 4
Introduction(Overall Project)
Page 5
Solution Methodology
• Conveyor design
• Install operating system openCV and other necessary
packages to raspberry pi minicomputer
• Colour detection method
• Shape detection method
• Data send method
Page 6
Machine Vision System
 Computer
Hardware+Software
 Cameras
 lighting
Vision systems can be
thought of as
computers with eyes
that can identify,
inspect and
communicate critical
information.
 Eliminate Defects
 Improve Quality
 Automate Production
 Track & Identify Parts
 Reduce Cost
 Image Captured
 Stored In Memory
 Algorithmically
Compared
Visual Based
Product
Identification
System
Page 7
Project Objectives
 Build a system that can detect, recognize objects according to the
Colour
Shape
 The whole process should be done in real time
 Should be used ease & efficient algorithms
Page 8
Software Part & Hardware Part
Hardware
Lighting system
Web Camera
Raspberry-pi Computer
Monitor
Conveyor
Software
OpenCV
Python
Numpy
Page 9
OpenCV
OpenCV
 Speed
 Resource-saving
 Cost
 Portability
Open source
computer vision
library
 Core module.
 Imgproc module
 Highgui module
 Feature 2D module
 Calib 3D module
 Library is written in
C & C++
 Runs under
linux,windows
 Provides interfaces
Python,Ruby,Matlab
,etc
Page 10
Programing Software Development
Colour
Detection
Use contours methodShape
Detection
Use RGB to HSV conversion
method
Page 11
Colour Detection
STEPS
1. Capture image
2. Convert from BGR to HSV color-space
3. Threshold the HSV image for a range of color
4. Show the mask image.
Page 12
RGB to HSV Conversion Method
RGB
In terms of Hue ,Saturation and ValueHSV
In terms of the amount of RED,GREEN,BLUE present
Page 13
RGB to HSV Conversion Method
Hue –Represents colour type
Range 0 to 255
Saturation –Represents the vibrancy of the colour
Range 0 to 255
Value –Represents brightness of the colour
0 – Completely DARK
255 – Fully BRIGHT
Page 14
Experimental Result
Blue Colour Detection RedColour Detection
Green Colour Detection
Page 15
Shape Detection
STEPS
1. Capture the image
2. Get an image after 30 frames
3. Delete the camera
4. Threshold the image
5. Find contours
6. Approximate contours
7. Show correct shape
Page 16
Experimental Result
• Triangle Identification
Page 17
Square Identification
Page 18
Circle Identification
Page 19
Raspbery pi Circuit
Raspberry pi
Circuit
Monitor
Keyboard
Mouse
Small credit card
size single board
computer
Low cost
Simplicity
Easy to handle
 Rasbian Jessie used
as operating system
 OpenCV,
Python,Numpy
should be installed
Page 20
Raspberry –pi Circuit
5v Micro usb
HDMI port
CSI Camera
connector Ethernet socket
Usb Ports
Micro SD card slot
Page 21
Software Installation
• Installing OpenCV 3 on Raspbian Jessie
Installing OpenCV 3 is a multi-step (and even time consuming) process requiring you to
install many dependencies and pre-requisites.
– Step #1: Install dependencies
– Step #2: Grab the OpenCV source code
– Step #3: Setup Python
– Step #4: Compile and install OpenCV
– Step #5: Finishing the install
– Step #6: Verifying your OpenCV 3 install
Page 22
SSH via direct Ethernet cable
• What is the meaning of SSH?
Secure Shell (SSH) is a UNIX-based command
interface and protocol for securely getting access to
a remote computer.
• What is the use of SSH server?
An SSH server is a software program which uses
the secure shell protocol to accept connections from
remote computers. SFTP/SCP file transfers and
remote terminal connections are popular use cases
for an SSH server.
Page 23
Conveyor Designing
Page 24
Page 25
Backup Slides
Page 26
OpenCV
Since Version 2.2, the OpenCV library is divided into several modules.
1.The opencv_core module that contains the core functionalities of the library, in
particular, basic data structures and arithmetic functions
2.The opencv_imgproc module that contains the main image processing functions
3.The opencv_highgui module that contains the image and video reading and writing
functions along with some user interface functions
4.The opencv_features2d module that contains the feature point detectors and
descriptors and the feature point matching framework
5.The opencv_calib3d module that contains the camera calibration, two-view
geometry estimation, and stereo function
Page 27
6.The opencv_video module that contains the motion estimation, feature
tracking, and
foreground extraction functions and classes
7.The opencv_obj detect module that contains the object detection functions
such as
the face and people detectors
Page 28
Colour Detectionimport cv2
import numpy as np
cap= cv2.VideoCapture(0)
while True :
_,frame =cap.read()
hsv = cv2.cvtColor(frame, cv2.COLOR_BGR2HSV)
lower_blue = np.array([0 , 100, 100])
upper_blue = np.array([ 130,255, 255])
lower_red =np.array([100,150,0])
upper_red =np.array([255,255,150])
lower_green =np.array([100,0,100])
upper_green=np.array([255,150,255])
mask = cv2.inRange(hsv,lower_blue, upper_blue)
mask2= cv2.inRange(hsv,lower_red,upper_red)
mask3=cv2.inRange(hsv,lower_green,upper_green)
output = cv2.bitwise_and(frame,frame,mask =
mask)
cv2.imshow('frame',frame)
cv2.imshow('mask',mask)
cv2.imshow('mask2',mask2)
cv2.imshow('mask3',mask3)
k = cv2.waitKey(5) & 0xFF
if k== 27:
break
Page 29
Shape Detection
• import numpy as np
import cv2
#import cv2.cv as cv
cap = cv2.VideoCapture(0)
#Capture the image
def get_image():
retval, img = cap.read()
return img
#Get an image after 30 frames
for i in xrange(30):
img = get_image()
print("Takingggg....")
#Save the image
file = "D:/tttt/test.png"
cv2.imwrite(file, img)
#Delete the camera
del(cap)
final_img = cv2.imread("D:/tttt/test.png")
cv2.imshow("final", final_img)
gray = cv2.imread("D:/tttt/test.png",0)
Page 30
#identifying the object sandaru.ny@gmail.com
ret,thresh=cv2.threshold(gray,127,255,1)
img,contours,h=cv2.findContours(thresh,1,2)
for cnt in contours:
apporx=cv2.approxPolyDP(cnt,0.01*cv2.arcLength(cnt,True),True)
print len(apporx)
if len(apporx)==3:
print"Triangle"
cv2.drawContours(img,[cnt],0,255,-1)
cv2.imshow('Triangle',img)
elif len(apporx)==4:
print"Square"
cv2.drawContours(img,[cnt],0,(0,255,0),-1)
cv2.imshow('Square',img)
elif len(apporx)>15:
print"Circle"
cv2.drawContours(img,[cnt],0,(0,0,255),-1)
cv2.imshow('Circle',img)
cv2.waitKey(0)
cv2.destroyAllWindows()
Page 31
Raspberry-pi Circuit Description
Page 32
Alternative Methods
Colour detection -Colour based blob detection
Shape detection –Shape based block detection

More Related Content

Viewers also liked

HUD Open House - 3051 Albret Street Lancaster CA 93536
HUD Open House - 3051 Albret Street Lancaster CA 93536HUD Open House - 3051 Albret Street Lancaster CA 93536
HUD Open House - 3051 Albret Street Lancaster CA 93536Select Service Realty
 
Leadership and management of schools
Leadership and management of schoolsLeadership and management of schools
Leadership and management of schoolsJamlick Bosire
 
Amr Training Certificate - E41-01
Amr Training Certificate - E41-01Amr Training Certificate - E41-01
Amr Training Certificate - E41-01Amr Sakran
 
Ppt diplomado tit@ en normal farallones
Ppt   diplomado tit@ en normal farallonesPpt   diplomado tit@ en normal farallones
Ppt diplomado tit@ en normal faralloneshumhistoriador51
 
Tot in welke fase zullen de Rode Duivels het volgens u schoppen op het komend...
Tot in welke fase zullen de Rode Duivels het volgens u schoppen op het komend...Tot in welke fase zullen de Rode Duivels het volgens u schoppen op het komend...
Tot in welke fase zullen de Rode Duivels het volgens u schoppen op het komend...Nielsen Sports France
 
Alexander Alexeev Interview
Alexander Alexeev InterviewAlexander Alexeev Interview
Alexander Alexeev InterviewPublicis Russia
 
DEMOKRATI DEL 1
DEMOKRATI DEL 1DEMOKRATI DEL 1
DEMOKRATI DEL 1tarzanol
 
Guía impresa cronica_para_me
Guía impresa cronica_para_meGuía impresa cronica_para_me
Guía impresa cronica_para_meJOSE RAMIRO HOYOS
 
Machine vision systems ppt
Machine vision systems pptMachine vision systems ppt
Machine vision systems pptAkash Maurya
 
Machine vision
Machine visionMachine vision
Machine visiondjehlke
 

Viewers also liked (16)

Prova per scribd
Prova per scribdProva per scribd
Prova per scribd
 
Tahis
TahisTahis
Tahis
 
Presentation1.PPTX
Presentation1.PPTXPresentation1.PPTX
Presentation1.PPTX
 
HUD Open House - 3051 Albret Street Lancaster CA 93536
HUD Open House - 3051 Albret Street Lancaster CA 93536HUD Open House - 3051 Albret Street Lancaster CA 93536
HUD Open House - 3051 Albret Street Lancaster CA 93536
 
Leadership and management of schools
Leadership and management of schoolsLeadership and management of schools
Leadership and management of schools
 
Adsassasa
AdsassasaAdsassasa
Adsassasa
 
Amr Training Certificate - E41-01
Amr Training Certificate - E41-01Amr Training Certificate - E41-01
Amr Training Certificate - E41-01
 
Argumentasjon
ArgumentasjonArgumentasjon
Argumentasjon
 
Ppt diplomado tit@ en normal farallones
Ppt   diplomado tit@ en normal farallonesPpt   diplomado tit@ en normal farallones
Ppt diplomado tit@ en normal farallones
 
Tot in welke fase zullen de Rode Duivels het volgens u schoppen op het komend...
Tot in welke fase zullen de Rode Duivels het volgens u schoppen op het komend...Tot in welke fase zullen de Rode Duivels het volgens u schoppen op het komend...
Tot in welke fase zullen de Rode Duivels het volgens u schoppen op het komend...
 
Alexander Alexeev Interview
Alexander Alexeev InterviewAlexander Alexeev Interview
Alexander Alexeev Interview
 
DEMOKRATI DEL 1
DEMOKRATI DEL 1DEMOKRATI DEL 1
DEMOKRATI DEL 1
 
Guía impresa cronica_para_me
Guía impresa cronica_para_meGuía impresa cronica_para_me
Guía impresa cronica_para_me
 
Priručnik 4
Priručnik 4Priručnik 4
Priručnik 4
 
Machine vision systems ppt
Machine vision systems pptMachine vision systems ppt
Machine vision systems ppt
 
Machine vision
Machine visionMachine vision
Machine vision
 

Similar to Law cost portable machine vision system

Law cost portable machine vision system
Law cost portable machine vision systemLaw cost portable machine vision system
Law cost portable machine vision systemSagarika Muthukumarana
 
Machine Vision On Embedded Platform
Machine Vision On Embedded Platform Machine Vision On Embedded Platform
Machine Vision On Embedded Platform Omkar Rane
 
Machine vision Application
Machine vision ApplicationMachine vision Application
Machine vision ApplicationAbhishek Sainkar
 
Automatic License Plate Recognition using OpenCV
Automatic License Plate Recognition using OpenCVAutomatic License Plate Recognition using OpenCV
Automatic License Plate Recognition using OpenCVEditor IJCATR
 
Automatic License Plate Recognition using OpenCV
Automatic License Plate Recognition using OpenCV Automatic License Plate Recognition using OpenCV
Automatic License Plate Recognition using OpenCV Editor IJCATR
 
Implementation of embedded arm9 platform using qt and open cv for human upper...
Implementation of embedded arm9 platform using qt and open cv for human upper...Implementation of embedded arm9 platform using qt and open cv for human upper...
Implementation of embedded arm9 platform using qt and open cv for human upper...Krunal Patel
 
502021435-12345678Minor-Project-Ppt.pptx
502021435-12345678Minor-Project-Ppt.pptx502021435-12345678Minor-Project-Ppt.pptx
502021435-12345678Minor-Project-Ppt.pptxshrey4922
 
Install, Compile, Setup, Setting OpenCV 3.2, Visual C++ 2015, Win 64bit,
Install, Compile, Setup, Setting OpenCV 3.2, Visual C++ 2015, Win 64bit, Install, Compile, Setup, Setting OpenCV 3.2, Visual C++ 2015, Win 64bit,
Install, Compile, Setup, Setting OpenCV 3.2, Visual C++ 2015, Win 64bit, Farshid Pirahansiah
 
Computer Vision Technology and Expertise
Computer Vision Technology and ExpertiseComputer Vision Technology and Expertise
Computer Vision Technology and ExpertiseRhonda Software
 
Ijsrdv1 i4049
Ijsrdv1 i4049Ijsrdv1 i4049
Ijsrdv1 i4049ijsrd.com
 
DMC NI Week 2014 High Speed Vision
DMC NI Week 2014 High Speed VisionDMC NI Week 2014 High Speed Vision
DMC NI Week 2014 High Speed VisionDMC, Inc.
 
OpenCV @ Droidcon 2012
OpenCV @ Droidcon 2012OpenCV @ Droidcon 2012
OpenCV @ Droidcon 2012Wingston
 
IRJET- Face Detection based on Image Processing using Raspberry Pi 4
IRJET-  	  Face Detection based on Image Processing using Raspberry Pi 4IRJET-  	  Face Detection based on Image Processing using Raspberry Pi 4
IRJET- Face Detection based on Image Processing using Raspberry Pi 4IRJET Journal
 
01 foundations
01 foundations01 foundations
01 foundationsankit_ppt
 
Image Detection and Count Using Open Computer Vision (Opencv)
Image Detection and Count Using Open Computer Vision (Opencv)Image Detection and Count Using Open Computer Vision (Opencv)
Image Detection and Count Using Open Computer Vision (Opencv)IJERA Editor
 

Similar to Law cost portable machine vision system (20)

Law cost portable machine vision system
Law cost portable machine vision systemLaw cost portable machine vision system
Law cost portable machine vision system
 
OpenCV+Android.pptx
OpenCV+Android.pptxOpenCV+Android.pptx
OpenCV+Android.pptx
 
Machine Vision On Embedded Platform
Machine Vision On Embedded Platform Machine Vision On Embedded Platform
Machine Vision On Embedded Platform
 
Machine vision Application
Machine vision ApplicationMachine vision Application
Machine vision Application
 
Automatic License Plate Recognition using OpenCV
Automatic License Plate Recognition using OpenCVAutomatic License Plate Recognition using OpenCV
Automatic License Plate Recognition using OpenCV
 
Automatic License Plate Recognition using OpenCV
Automatic License Plate Recognition using OpenCV Automatic License Plate Recognition using OpenCV
Automatic License Plate Recognition using OpenCV
 
Implementation of embedded arm9 platform using qt and open cv for human upper...
Implementation of embedded arm9 platform using qt and open cv for human upper...Implementation of embedded arm9 platform using qt and open cv for human upper...
Implementation of embedded arm9 platform using qt and open cv for human upper...
 
502021435-12345678Minor-Project-Ppt.pptx
502021435-12345678Minor-Project-Ppt.pptx502021435-12345678Minor-Project-Ppt.pptx
502021435-12345678Minor-Project-Ppt.pptx
 
Install, Compile, Setup, Setting OpenCV 3.2, Visual C++ 2015, Win 64bit,
Install, Compile, Setup, Setting OpenCV 3.2, Visual C++ 2015, Win 64bit, Install, Compile, Setup, Setting OpenCV 3.2, Visual C++ 2015, Win 64bit,
Install, Compile, Setup, Setting OpenCV 3.2, Visual C++ 2015, Win 64bit,
 
Computer Vision Technology and Expertise
Computer Vision Technology and ExpertiseComputer Vision Technology and Expertise
Computer Vision Technology and Expertise
 
Ijsrdv1 i4049
Ijsrdv1 i4049Ijsrdv1 i4049
Ijsrdv1 i4049
 
DMC NI Week 2014 High Speed Vision
DMC NI Week 2014 High Speed VisionDMC NI Week 2014 High Speed Vision
DMC NI Week 2014 High Speed Vision
 
Opencv
OpencvOpencv
Opencv
 
OpenCV @ Droidcon 2012
OpenCV @ Droidcon 2012OpenCV @ Droidcon 2012
OpenCV @ Droidcon 2012
 
IRJET- Face Detection based on Image Processing using Raspberry Pi 4
IRJET-  	  Face Detection based on Image Processing using Raspberry Pi 4IRJET-  	  Face Detection based on Image Processing using Raspberry Pi 4
IRJET- Face Detection based on Image Processing using Raspberry Pi 4
 
01 foundations
01 foundations01 foundations
01 foundations
 
201001162_report
201001162_report201001162_report
201001162_report
 
Colour tracking robot.pdf
Colour tracking robot.pdfColour tracking robot.pdf
Colour tracking robot.pdf
 
Image Detection and Count Using Open Computer Vision (Opencv)
Image Detection and Count Using Open Computer Vision (Opencv)Image Detection and Count Using Open Computer Vision (Opencv)
Image Detection and Count Using Open Computer Vision (Opencv)
 
MAJOR PROJECT
MAJOR PROJECT MAJOR PROJECT
MAJOR PROJECT
 

Law cost portable machine vision system

  • 1. Page 1 Visual Based Product Identification System
  • 2. Page 2 Visual Based Product Identification System Project Supervisor-Mr.Mahanama Dharmawardhana Project Group-P 16 Group Members-E/11/252 (Madushanka,W.F.R) E/11/267 (Muthukumaranage,M.S.P)
  • 3. Page 3 Title & Outlines • Introduction • Details of Our Solution • Experimental Results • Conclusion • Back-up Slides
  • 5. Page 5 Solution Methodology • Conveyor design • Install operating system openCV and other necessary packages to raspberry pi minicomputer • Colour detection method • Shape detection method • Data send method
  • 6. Page 6 Machine Vision System  Computer Hardware+Software  Cameras  lighting Vision systems can be thought of as computers with eyes that can identify, inspect and communicate critical information.  Eliminate Defects  Improve Quality  Automate Production  Track & Identify Parts  Reduce Cost  Image Captured  Stored In Memory  Algorithmically Compared Visual Based Product Identification System
  • 7. Page 7 Project Objectives  Build a system that can detect, recognize objects according to the Colour Shape  The whole process should be done in real time  Should be used ease & efficient algorithms
  • 8. Page 8 Software Part & Hardware Part Hardware Lighting system Web Camera Raspberry-pi Computer Monitor Conveyor Software OpenCV Python Numpy
  • 9. Page 9 OpenCV OpenCV  Speed  Resource-saving  Cost  Portability Open source computer vision library  Core module.  Imgproc module  Highgui module  Feature 2D module  Calib 3D module  Library is written in C & C++  Runs under linux,windows  Provides interfaces Python,Ruby,Matlab ,etc
  • 10. Page 10 Programing Software Development Colour Detection Use contours methodShape Detection Use RGB to HSV conversion method
  • 11. Page 11 Colour Detection STEPS 1. Capture image 2. Convert from BGR to HSV color-space 3. Threshold the HSV image for a range of color 4. Show the mask image.
  • 12. Page 12 RGB to HSV Conversion Method RGB In terms of Hue ,Saturation and ValueHSV In terms of the amount of RED,GREEN,BLUE present
  • 13. Page 13 RGB to HSV Conversion Method Hue –Represents colour type Range 0 to 255 Saturation –Represents the vibrancy of the colour Range 0 to 255 Value –Represents brightness of the colour 0 – Completely DARK 255 – Fully BRIGHT
  • 14. Page 14 Experimental Result Blue Colour Detection RedColour Detection Green Colour Detection
  • 15. Page 15 Shape Detection STEPS 1. Capture the image 2. Get an image after 30 frames 3. Delete the camera 4. Threshold the image 5. Find contours 6. Approximate contours 7. Show correct shape
  • 16. Page 16 Experimental Result • Triangle Identification
  • 19. Page 19 Raspbery pi Circuit Raspberry pi Circuit Monitor Keyboard Mouse Small credit card size single board computer Low cost Simplicity Easy to handle  Rasbian Jessie used as operating system  OpenCV, Python,Numpy should be installed
  • 20. Page 20 Raspberry –pi Circuit 5v Micro usb HDMI port CSI Camera connector Ethernet socket Usb Ports Micro SD card slot
  • 21. Page 21 Software Installation • Installing OpenCV 3 on Raspbian Jessie Installing OpenCV 3 is a multi-step (and even time consuming) process requiring you to install many dependencies and pre-requisites. – Step #1: Install dependencies – Step #2: Grab the OpenCV source code – Step #3: Setup Python – Step #4: Compile and install OpenCV – Step #5: Finishing the install – Step #6: Verifying your OpenCV 3 install
  • 22. Page 22 SSH via direct Ethernet cable • What is the meaning of SSH? Secure Shell (SSH) is a UNIX-based command interface and protocol for securely getting access to a remote computer. • What is the use of SSH server? An SSH server is a software program which uses the secure shell protocol to accept connections from remote computers. SFTP/SCP file transfers and remote terminal connections are popular use cases for an SSH server.
  • 26. Page 26 OpenCV Since Version 2.2, the OpenCV library is divided into several modules. 1.The opencv_core module that contains the core functionalities of the library, in particular, basic data structures and arithmetic functions 2.The opencv_imgproc module that contains the main image processing functions 3.The opencv_highgui module that contains the image and video reading and writing functions along with some user interface functions 4.The opencv_features2d module that contains the feature point detectors and descriptors and the feature point matching framework 5.The opencv_calib3d module that contains the camera calibration, two-view geometry estimation, and stereo function
  • 27. Page 27 6.The opencv_video module that contains the motion estimation, feature tracking, and foreground extraction functions and classes 7.The opencv_obj detect module that contains the object detection functions such as the face and people detectors
  • 28. Page 28 Colour Detectionimport cv2 import numpy as np cap= cv2.VideoCapture(0) while True : _,frame =cap.read() hsv = cv2.cvtColor(frame, cv2.COLOR_BGR2HSV) lower_blue = np.array([0 , 100, 100]) upper_blue = np.array([ 130,255, 255]) lower_red =np.array([100,150,0]) upper_red =np.array([255,255,150]) lower_green =np.array([100,0,100]) upper_green=np.array([255,150,255]) mask = cv2.inRange(hsv,lower_blue, upper_blue) mask2= cv2.inRange(hsv,lower_red,upper_red) mask3=cv2.inRange(hsv,lower_green,upper_green) output = cv2.bitwise_and(frame,frame,mask = mask) cv2.imshow('frame',frame) cv2.imshow('mask',mask) cv2.imshow('mask2',mask2) cv2.imshow('mask3',mask3) k = cv2.waitKey(5) & 0xFF if k== 27: break
  • 29. Page 29 Shape Detection • import numpy as np import cv2 #import cv2.cv as cv cap = cv2.VideoCapture(0) #Capture the image def get_image(): retval, img = cap.read() return img #Get an image after 30 frames for i in xrange(30): img = get_image() print("Takingggg....") #Save the image file = "D:/tttt/test.png" cv2.imwrite(file, img) #Delete the camera del(cap) final_img = cv2.imread("D:/tttt/test.png") cv2.imshow("final", final_img) gray = cv2.imread("D:/tttt/test.png",0)
  • 30. Page 30 #identifying the object sandaru.ny@gmail.com ret,thresh=cv2.threshold(gray,127,255,1) img,contours,h=cv2.findContours(thresh,1,2) for cnt in contours: apporx=cv2.approxPolyDP(cnt,0.01*cv2.arcLength(cnt,True),True) print len(apporx) if len(apporx)==3: print"Triangle" cv2.drawContours(img,[cnt],0,255,-1) cv2.imshow('Triangle',img) elif len(apporx)==4: print"Square" cv2.drawContours(img,[cnt],0,(0,255,0),-1) cv2.imshow('Square',img) elif len(apporx)>15: print"Circle" cv2.drawContours(img,[cnt],0,(0,0,255),-1) cv2.imshow('Circle',img) cv2.waitKey(0) cv2.destroyAllWindows()
  • 32. Page 32 Alternative Methods Colour detection -Colour based blob detection Shape detection –Shape based block detection