SlideShare a Scribd company logo
1 of 26
Object Detection with
Tensorflow
Agend
a
▪ Intro
▪ What is Object Detection
▪ State of Object Detection
▪ Tensorflow Object Detection API
▪ Preparing Data
▪ Training & Evaluating
▪ Links
Use cases
What is Object
Detection
www.eliftech.com
Object detection =
Object Classification + Object
Localization
www.eliftech.com
One model for two
tasks?
Object detection - output is the one number (index) of a class
Object localization - output is the four numbers -
coordinates of bounding box.
Po
bx1
bx2
by1
by2
c1
c2
c3
…
cn
- is object exists
www.eliftech.com
- bounding box
coordinates
- object’s
variables
State of Object
Detection
www.eliftech.com
Approache
s
www.eliftech.com
▪ Classical approach (Haar features) - first OD real time framework (Viola-Jones)
▪ Deep learning approach - now state of the art in OD
▪ OverFeat
▪ R-CNN
▪ Fast R-CNN
▪ YOLO
▪ Faster R-CNN
▪ SSD and R-FCN
Deep learning
approach
OverFeat- published in 2013, multi-scale sliding
window algorithm using Convolutional Neural
Networks (CNNs).
l
C.NN - Regions with CNN features.Three stage
approach:
- Extract possible objects using a region proposa
method (the most popular one being Selective
Search).
- Extract features from each region using a CNN.
- Classify each region with SVM s.
www.eliftech.com
Fast R-CNN - Similar to R-CNN, it used Selective
Search to generate object proposals, but instead of
extractingall of them independently and using SVM
classifiers, it applied the CNN on the complete image
and then used both Region of Interest (RoI) Pooling
on the feature map with a final feed forward network
for classification and regression.
YOLO - You Only Look Once: a
simple convolutional neural
network approach which has
both great results and high
speed,allowing for the first time
real time object detection.
Deep learning
approach
www.eliftech.com
Faster R-CNN - Faster R-CNN added what
they called a Region Proposal Network (RPN),
in an attempt to get rid of the Selective Search
algorithm and make the model completely
trainable end-to-end.
SSDand R-FCN
Finally, there are two notable papers, Single Shot
Detector (SSD)which takes on YOLO by using multiple
sized convolutional feature maps achieving better
results and speed, and Region-based Fully
Convolutional Networks (R-FCN) which takes the
architecture of Faster R-CNN but with only
convolutional networks.
Deep learning
approach
www.eliftech.com
Tensorflow
Object
Detection API
www.eliftech.com
TF Object Detection
API
▪ Open Source from 2017-07-15
▪ Built on top of TensorFlow
▪ Contains trainable detection models
▪ Contains frozen weights
▪ Contains Jupyter Notebook
▪ Makes easy to construct, train and deploy
object detection models
www.eliftech.com
Getting
started
www.eliftech.com
Dependencies:
▪ Protobuf 2.6
▪ Python-tk
▪ Pillow 1.0
▪ lxml
▪ Tf Slim (included)
▪ Jupyter notebook
▪ Matplotlib
▪ Tensorflow (tensorflow-
gpu)
▪ Cython
▪cocoapi
Installation
instruction
If model will be trained locally - better
to install tensorflow-gpu.
Dependencies for tensorflow-gpu:
▪ NVIDIA GPU with CUDA Compute Capability 3.0
(list)
▪ Ubuntu 16.04 at least
▪ CUDA® Toolkit 9.0
▪ NVIDIA drivers associated with CUDA Toolkit 9.0.
▪ cuDNN v7.0
▪ libcupti-dev
Installation
instruction
Latest version of CUDA Toolkit - 9.1 not
compatible with tensorflow 1.6,need to
install 9.0
Creating a
dataset
www.eliftech.com
Datase
t
▪ Tensorflow Object Detection API uses the
TFRecord file format
▪ There is available third-party scripts to convert
PASCAL VOC and Oxford Pet Format
▪ In other case explanation of format available in
git repo.
▪ Input data to create TFRecord - annotated
image
www.eliftech.com
Getting
images
www.eliftech.com
Grab from internet
▪ Scrap images from google or
Pixabay or whatever
▪ For batch downloading-
Faktun Bulk Image
Downloader
▪ For data miningby multiplying
existingimages - ImageMagic
Create own images
▪ Record video with needed
object/objects (in 640x480)
▪ Process video and split on
screenshots - ffmpeg
Tips
▪ Create images with different
lights,background and so on.
▪ If object is able to have
different forms - better to
catch them all.
▪ Try to make 30%-50%of
images with overlaid object
▪ Tool for image augmentation
Labeling (Annotation) an
images
Tool
s
▪ LabelImg
▪ FIAT (Fast Image Data
Annotation Tool)
www.eliftech.com
▪ input:images
▪ output:.xml files with
boundingboxes coordinates
Creating
TFRecord
▪ Tensorflow object detection API repo contains folder dataset_tools with scripts to
coverts common structures of data in TFRecord.
▪ If output data has another structure - here is explanation how to convert it
www.eliftech.com
Trainin
g
www.eliftech.com
Preparing model
Tensorflow OD API provides a collection of
detection models pre-trained on the COCO
dataset, the Kitti dataset, and the Open Images
dataset.
- modelnamecorresponds to a config file that
was used to train this model.
- speed- runningtime in ms per 600x600
image
- mAPstands for mean average precision,
which indicates how well the model
performed on the COCO dataset.
- Outputstypes (Boxes,and Masks if
applicable)
www.eliftech.com
Configurin
g
● label.pbtx
● pipeline.config
www.eliftech.com
train_config: {
fine_tune_checkpoint: "<path_to_model.ckpt>"
num_steps: 200000
}
train_input_reader {
label_map_path: "<path_to_labels.pbtxt>"
tf_record_input_reader {
input_path: "<path_to_train.record>"
}
}
eval_config {
num_examples: 8000
max_evals: 10
use_moving_averages: false
}
eval_input_reader {
label_map_path: "<path_to_labels.pbtxt>"
shuffle: false
num_readers: 1
tf_record_input_reader {
input_path: "<path_to_test.record>"
}
}
● Folders structure instruction
Training &
Evaluating
www.eliftech.com
# From the tensorflow/models/research directory
python object_detection/eval.py 
--logtostderr 
--pipeline_config_path=${PATH_TO_YOUR_PIPELINE_CONFIG} 
--checkpoint_dir=${PATH_TO_TRAIN_DIR} 
--eval_dir=${PATH_TO_EVAL_DIR}
# From the tensorflow/models/research directory
python object_detection/train.py
--logtostderr
--
pipeline_config_path=/tensorflow/models/object_detection/samples/configs/ssd_mobilenet_v1_p
ets.config
--train_dir=${PATH_TO_ROOT_TRAIN_FOLDER}
Converting
www.eliftech.com
Link
s
www.eliftech.com
▪ https://towardsdatascience.com/how-to-train-your-own-object-detector-with-
tensorflows-object-detector-api-bec72ecfe1d9
▪ https://www.kdnuggets.com/2017/10/deep-learning-object-detection-
comprehensive-review.html
▪ http://www.machinelearninguru.com/deep_learning/tensorflow/basics/tfrecord/tfreco
rd.html
▪ https://www.coursera.org/learn/convolutional-neural-networks
▪ https://medium.com/comet-app/review-of-deep-learning-algorithms-for-object-
detection-c1f3d437b852
▪ https://towardsdatascience.com/evolution-of-object-detection-and-localization-
algorithms-e241021d8bad
▪ https://medium.freecodecamp.org/how-to-play-quidditch-using-the-tensorflow-
object-detection-api-b0742b99065d

More Related Content

Similar to odtslide-180529073940.pptx

Building a Knowledge Graph using NLP and Ontologies
Building a Knowledge Graph using NLP and OntologiesBuilding a Knowledge Graph using NLP and Ontologies
Building a Knowledge Graph using NLP and OntologiesNeo4j
 
Transfer learning, active learning using tensorflow object detection api
Transfer learning, active learning  using tensorflow object detection apiTransfer learning, active learning  using tensorflow object detection api
Transfer learning, active learning using tensorflow object detection api설기 김
 
Josh Patterson, Advisor, Skymind – Deep learning for Industry at MLconf ATL 2016
Josh Patterson, Advisor, Skymind – Deep learning for Industry at MLconf ATL 2016Josh Patterson, Advisor, Skymind – Deep learning for Industry at MLconf ATL 2016
Josh Patterson, Advisor, Skymind – Deep learning for Industry at MLconf ATL 2016MLconf
 
Deep Learning: DL4J and DataVec
Deep Learning: DL4J and DataVecDeep Learning: DL4J and DataVec
Deep Learning: DL4J and DataVecJosh Patterson
 
Mastering Terraform and the Provider for OCI
Mastering Terraform and the Provider for OCIMastering Terraform and the Provider for OCI
Mastering Terraform and the Provider for OCIGregory GUILLOU
 
Big Data and Machine Learning with FIWARE
Big Data and Machine Learning with FIWAREBig Data and Machine Learning with FIWARE
Big Data and Machine Learning with FIWAREFernando Lopez Aguilar
 
SensorThings API webinar-#4-Connect Your Sensor
SensorThings API webinar-#4-Connect Your SensorSensorThings API webinar-#4-Connect Your Sensor
SensorThings API webinar-#4-Connect Your SensorSensorUp
 
Large Scale Image Forensics using Tika and Tensorflow [ICMR MFSec 2017]
Large Scale Image Forensics using Tika and Tensorflow [ICMR MFSec 2017]Large Scale Image Forensics using Tika and Tensorflow [ICMR MFSec 2017]
Large Scale Image Forensics using Tika and Tensorflow [ICMR MFSec 2017]Thamme Gowda
 
OpenCV @ Droidcon 2012
OpenCV @ Droidcon 2012OpenCV @ Droidcon 2012
OpenCV @ Droidcon 2012Wingston
 
Object Detection with Transformers
Object Detection with TransformersObject Detection with Transformers
Object Detection with TransformersDatabricks
 
Build Large-Scale Data Analytics and AI Pipeline Using RayDP
Build Large-Scale Data Analytics and AI Pipeline Using RayDPBuild Large-Scale Data Analytics and AI Pipeline Using RayDP
Build Large-Scale Data Analytics and AI Pipeline Using RayDPDatabricks
 
Suneel Marthi - Deep Learning with Apache Flink and DL4J
Suneel Marthi - Deep Learning with Apache Flink and DL4JSuneel Marthi - Deep Learning with Apache Flink and DL4J
Suneel Marthi - Deep Learning with Apache Flink and DL4JFlink Forward
 
DAWN and Scientific Workflows
DAWN and Scientific WorkflowsDAWN and Scientific Workflows
DAWN and Scientific WorkflowsMatthew Gerring
 
Advanced windows debugging
Advanced windows debuggingAdvanced windows debugging
Advanced windows debuggingchrisortman
 
01 foundations
01 foundations01 foundations
01 foundationsankit_ppt
 
Aci programmability
Aci programmabilityAci programmability
Aci programmabilityCisco DevNet
 
Introduction to ACI APIs
Introduction to ACI APIsIntroduction to ACI APIs
Introduction to ACI APIsCisco DevNet
 
Object Detection Beyond Mask R-CNN and RetinaNet II
Object Detection Beyond Mask R-CNN and RetinaNet IIObject Detection Beyond Mask R-CNN and RetinaNet II
Object Detection Beyond Mask R-CNN and RetinaNet IIWanjin Yu
 
Large-scale Reasoning with a Complex Cultural Heritage Ontology (CIDOC CRM) ...
 Large-scale Reasoning with a Complex Cultural Heritage Ontology (CIDOC CRM) ... Large-scale Reasoning with a Complex Cultural Heritage Ontology (CIDOC CRM) ...
Large-scale Reasoning with a Complex Cultural Heritage Ontology (CIDOC CRM) ...Vladimir Alexiev, PhD, PMP
 

Similar to odtslide-180529073940.pptx (20)

Building a Knowledge Graph using NLP and Ontologies
Building a Knowledge Graph using NLP and OntologiesBuilding a Knowledge Graph using NLP and Ontologies
Building a Knowledge Graph using NLP and Ontologies
 
Transfer learning, active learning using tensorflow object detection api
Transfer learning, active learning  using tensorflow object detection apiTransfer learning, active learning  using tensorflow object detection api
Transfer learning, active learning using tensorflow object detection api
 
Josh Patterson, Advisor, Skymind – Deep learning for Industry at MLconf ATL 2016
Josh Patterson, Advisor, Skymind – Deep learning for Industry at MLconf ATL 2016Josh Patterson, Advisor, Skymind – Deep learning for Industry at MLconf ATL 2016
Josh Patterson, Advisor, Skymind – Deep learning for Industry at MLconf ATL 2016
 
Deep Learning: DL4J and DataVec
Deep Learning: DL4J and DataVecDeep Learning: DL4J and DataVec
Deep Learning: DL4J and DataVec
 
Mastering Terraform and the Provider for OCI
Mastering Terraform and the Provider for OCIMastering Terraform and the Provider for OCI
Mastering Terraform and the Provider for OCI
 
Big Data and Machine Learning with FIWARE
Big Data and Machine Learning with FIWAREBig Data and Machine Learning with FIWARE
Big Data and Machine Learning with FIWARE
 
Icpp power ai-workshop 2018
Icpp power ai-workshop 2018Icpp power ai-workshop 2018
Icpp power ai-workshop 2018
 
SensorThings API webinar-#4-Connect Your Sensor
SensorThings API webinar-#4-Connect Your SensorSensorThings API webinar-#4-Connect Your Sensor
SensorThings API webinar-#4-Connect Your Sensor
 
Large Scale Image Forensics using Tika and Tensorflow [ICMR MFSec 2017]
Large Scale Image Forensics using Tika and Tensorflow [ICMR MFSec 2017]Large Scale Image Forensics using Tika and Tensorflow [ICMR MFSec 2017]
Large Scale Image Forensics using Tika and Tensorflow [ICMR MFSec 2017]
 
OpenCV @ Droidcon 2012
OpenCV @ Droidcon 2012OpenCV @ Droidcon 2012
OpenCV @ Droidcon 2012
 
Object Detection with Transformers
Object Detection with TransformersObject Detection with Transformers
Object Detection with Transformers
 
Build Large-Scale Data Analytics and AI Pipeline Using RayDP
Build Large-Scale Data Analytics and AI Pipeline Using RayDPBuild Large-Scale Data Analytics and AI Pipeline Using RayDP
Build Large-Scale Data Analytics and AI Pipeline Using RayDP
 
Suneel Marthi - Deep Learning with Apache Flink and DL4J
Suneel Marthi - Deep Learning with Apache Flink and DL4JSuneel Marthi - Deep Learning with Apache Flink and DL4J
Suneel Marthi - Deep Learning with Apache Flink and DL4J
 
DAWN and Scientific Workflows
DAWN and Scientific WorkflowsDAWN and Scientific Workflows
DAWN and Scientific Workflows
 
Advanced windows debugging
Advanced windows debuggingAdvanced windows debugging
Advanced windows debugging
 
01 foundations
01 foundations01 foundations
01 foundations
 
Aci programmability
Aci programmabilityAci programmability
Aci programmability
 
Introduction to ACI APIs
Introduction to ACI APIsIntroduction to ACI APIs
Introduction to ACI APIs
 
Object Detection Beyond Mask R-CNN and RetinaNet II
Object Detection Beyond Mask R-CNN and RetinaNet IIObject Detection Beyond Mask R-CNN and RetinaNet II
Object Detection Beyond Mask R-CNN and RetinaNet II
 
Large-scale Reasoning with a Complex Cultural Heritage Ontology (CIDOC CRM) ...
 Large-scale Reasoning with a Complex Cultural Heritage Ontology (CIDOC CRM) ... Large-scale Reasoning with a Complex Cultural Heritage Ontology (CIDOC CRM) ...
Large-scale Reasoning with a Complex Cultural Heritage Ontology (CIDOC CRM) ...
 

Recently uploaded

Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxupamatechverse
 
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Dr.Costas Sachpazis
 
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...ranjana rawat
 
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...Dr.Costas Sachpazis
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Christo Ananth
 
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...ranjana rawat
 
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130Suhani Kapoor
 
Processing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxProcessing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxpranjaldaimarysona
 
Call Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile serviceCall Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile servicerehmti665
 
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSMANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSSIVASHANKAR N
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...Soham Mondal
 
SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )Tsuyoshi Horigome
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...ranjana rawat
 
chaitra-1.pptx fake news detection using machine learning
chaitra-1.pptx  fake news detection using machine learningchaitra-1.pptx  fake news detection using machine learning
chaitra-1.pptx fake news detection using machine learningmisbanausheenparvam
 

Recently uploaded (20)

Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptx
 
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
 
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
 
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINEDJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
 
Roadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and RoutesRoadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and Routes
 
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
 
Exploring_Network_Security_with_JA3_by_Rakesh Seal.pptx
Exploring_Network_Security_with_JA3_by_Rakesh Seal.pptxExploring_Network_Security_with_JA3_by_Rakesh Seal.pptx
Exploring_Network_Security_with_JA3_by_Rakesh Seal.pptx
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
 
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
 
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
 
Processing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxProcessing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptx
 
Call Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCR
Call Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCRCall Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCR
Call Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCR
 
Call Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile serviceCall Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile service
 
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSMANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
 
SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
 
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
chaitra-1.pptx fake news detection using machine learning
chaitra-1.pptx  fake news detection using machine learningchaitra-1.pptx  fake news detection using machine learning
chaitra-1.pptx fake news detection using machine learning
 

odtslide-180529073940.pptx

  • 2. Agend a ▪ Intro ▪ What is Object Detection ▪ State of Object Detection ▪ Tensorflow Object Detection API ▪ Preparing Data ▪ Training & Evaluating ▪ Links
  • 4.
  • 6. Object detection = Object Classification + Object Localization www.eliftech.com
  • 7. One model for two tasks? Object detection - output is the one number (index) of a class Object localization - output is the four numbers - coordinates of bounding box. Po bx1 bx2 by1 by2 c1 c2 c3 … cn - is object exists www.eliftech.com - bounding box coordinates - object’s variables
  • 9. Approache s www.eliftech.com ▪ Classical approach (Haar features) - first OD real time framework (Viola-Jones) ▪ Deep learning approach - now state of the art in OD ▪ OverFeat ▪ R-CNN ▪ Fast R-CNN ▪ YOLO ▪ Faster R-CNN ▪ SSD and R-FCN
  • 10. Deep learning approach OverFeat- published in 2013, multi-scale sliding window algorithm using Convolutional Neural Networks (CNNs). l C.NN - Regions with CNN features.Three stage approach: - Extract possible objects using a region proposa method (the most popular one being Selective Search). - Extract features from each region using a CNN. - Classify each region with SVM s. www.eliftech.com
  • 11. Fast R-CNN - Similar to R-CNN, it used Selective Search to generate object proposals, but instead of extractingall of them independently and using SVM classifiers, it applied the CNN on the complete image and then used both Region of Interest (RoI) Pooling on the feature map with a final feed forward network for classification and regression. YOLO - You Only Look Once: a simple convolutional neural network approach which has both great results and high speed,allowing for the first time real time object detection. Deep learning approach www.eliftech.com
  • 12. Faster R-CNN - Faster R-CNN added what they called a Region Proposal Network (RPN), in an attempt to get rid of the Selective Search algorithm and make the model completely trainable end-to-end. SSDand R-FCN Finally, there are two notable papers, Single Shot Detector (SSD)which takes on YOLO by using multiple sized convolutional feature maps achieving better results and speed, and Region-based Fully Convolutional Networks (R-FCN) which takes the architecture of Faster R-CNN but with only convolutional networks. Deep learning approach www.eliftech.com
  • 14. TF Object Detection API ▪ Open Source from 2017-07-15 ▪ Built on top of TensorFlow ▪ Contains trainable detection models ▪ Contains frozen weights ▪ Contains Jupyter Notebook ▪ Makes easy to construct, train and deploy object detection models www.eliftech.com
  • 15. Getting started www.eliftech.com Dependencies: ▪ Protobuf 2.6 ▪ Python-tk ▪ Pillow 1.0 ▪ lxml ▪ Tf Slim (included) ▪ Jupyter notebook ▪ Matplotlib ▪ Tensorflow (tensorflow- gpu) ▪ Cython ▪cocoapi Installation instruction If model will be trained locally - better to install tensorflow-gpu. Dependencies for tensorflow-gpu: ▪ NVIDIA GPU with CUDA Compute Capability 3.0 (list) ▪ Ubuntu 16.04 at least ▪ CUDA® Toolkit 9.0 ▪ NVIDIA drivers associated with CUDA Toolkit 9.0. ▪ cuDNN v7.0 ▪ libcupti-dev Installation instruction Latest version of CUDA Toolkit - 9.1 not compatible with tensorflow 1.6,need to install 9.0
  • 17. Datase t ▪ Tensorflow Object Detection API uses the TFRecord file format ▪ There is available third-party scripts to convert PASCAL VOC and Oxford Pet Format ▪ In other case explanation of format available in git repo. ▪ Input data to create TFRecord - annotated image www.eliftech.com
  • 18. Getting images www.eliftech.com Grab from internet ▪ Scrap images from google or Pixabay or whatever ▪ For batch downloading- Faktun Bulk Image Downloader ▪ For data miningby multiplying existingimages - ImageMagic Create own images ▪ Record video with needed object/objects (in 640x480) ▪ Process video and split on screenshots - ffmpeg Tips ▪ Create images with different lights,background and so on. ▪ If object is able to have different forms - better to catch them all. ▪ Try to make 30%-50%of images with overlaid object ▪ Tool for image augmentation
  • 19. Labeling (Annotation) an images Tool s ▪ LabelImg ▪ FIAT (Fast Image Data Annotation Tool) www.eliftech.com ▪ input:images ▪ output:.xml files with boundingboxes coordinates
  • 20. Creating TFRecord ▪ Tensorflow object detection API repo contains folder dataset_tools with scripts to coverts common structures of data in TFRecord. ▪ If output data has another structure - here is explanation how to convert it www.eliftech.com
  • 22. Preparing model Tensorflow OD API provides a collection of detection models pre-trained on the COCO dataset, the Kitti dataset, and the Open Images dataset. - modelnamecorresponds to a config file that was used to train this model. - speed- runningtime in ms per 600x600 image - mAPstands for mean average precision, which indicates how well the model performed on the COCO dataset. - Outputstypes (Boxes,and Masks if applicable) www.eliftech.com
  • 23. Configurin g ● label.pbtx ● pipeline.config www.eliftech.com train_config: { fine_tune_checkpoint: "<path_to_model.ckpt>" num_steps: 200000 } train_input_reader { label_map_path: "<path_to_labels.pbtxt>" tf_record_input_reader { input_path: "<path_to_train.record>" } } eval_config { num_examples: 8000 max_evals: 10 use_moving_averages: false } eval_input_reader { label_map_path: "<path_to_labels.pbtxt>" shuffle: false num_readers: 1 tf_record_input_reader { input_path: "<path_to_test.record>" } } ● Folders structure instruction
  • 24. Training & Evaluating www.eliftech.com # From the tensorflow/models/research directory python object_detection/eval.py --logtostderr --pipeline_config_path=${PATH_TO_YOUR_PIPELINE_CONFIG} --checkpoint_dir=${PATH_TO_TRAIN_DIR} --eval_dir=${PATH_TO_EVAL_DIR} # From the tensorflow/models/research directory python object_detection/train.py --logtostderr -- pipeline_config_path=/tensorflow/models/object_detection/samples/configs/ssd_mobilenet_v1_p ets.config --train_dir=${PATH_TO_ROOT_TRAIN_FOLDER}
  • 26. Link s www.eliftech.com ▪ https://towardsdatascience.com/how-to-train-your-own-object-detector-with- tensorflows-object-detector-api-bec72ecfe1d9 ▪ https://www.kdnuggets.com/2017/10/deep-learning-object-detection- comprehensive-review.html ▪ http://www.machinelearninguru.com/deep_learning/tensorflow/basics/tfrecord/tfreco rd.html ▪ https://www.coursera.org/learn/convolutional-neural-networks ▪ https://medium.com/comet-app/review-of-deep-learning-algorithms-for-object- detection-c1f3d437b852 ▪ https://towardsdatascience.com/evolution-of-object-detection-and-localization- algorithms-e241021d8bad ▪ https://medium.freecodecamp.org/how-to-play-quidditch-using-the-tensorflow- object-detection-api-b0742b99065d