Practical Computer Vision Applications Using Deep Learning with CNNs : With Detailed Examples in Python Using TensorFlow and Kivy
معرفی کتاب «Practical Computer Vision Applications Using Deep Learning with CNNs : With Detailed Examples in Python Using TensorFlow and Kivy» نوشتهٔ Robert Cialdini، Noah Goldstein، Steve Martin، Jorge Rizzo Tortuero و Ahmed Fawzy Gad، منتشرشده توسط نشر Apress L. P. Springer [Distributor در سال 2018. این کتاب در فرمت pdf، زبان انگلیسی ارائه شده است.
Deploy deep learning applications into production across multiple platforms. You will work on computer vision applications that use the convolutional neural network (CNN) deep learning model and Python. This book starts by explaining the traditional machine-learning pipeline, where you will analyze an image dataset. Along the way you will cover artificial neural networks (ANNs), building one from scratch in Python, before optimizing it using genetic algorithms. For automating the process, the book highlights the limitations of traditional hand-crafted features for computer vision and why the CNN deep-learning model is the state-of-art solution. CNNs are discussed from scratch to demonstrate how they are different and more efficient than the fully connected ANN (FCNN). You will implement a CNN in Python to give you a full understanding of the model. After consolidating the basics, you will use TensorFlow to build a practical image-recognition model that you will deploy to a web server using Flask, making it accessible over the Internet. Using Kivy and NumPy, you will create cross-platform data science applications with low overheads. This book will help you apply deep learning and computer vision concepts from scratch, step-by-step from conception to production. What You Will Learn Understand how ANNs and CNNs work Create computer vision applications and CNNs from scratch using Python Follow a deep learning project from conception to production using TensorFlow Use NumPy with Kivy to build cross-platform data science applications Who This Book Is For Data scientists, machine learning and deep learning engineers, software developers. Table of Contents 5 About the Author 10 About the Technical Reviewers 11 Acknowledgments 12 Introduction 13 Chapter 1: Recognition in Computer Vision 19 Image Recognition Pipeline 20 Feature Extraction 22 Color Histogram 23 Histogram of a Real-World Image 25 HSV Color Space 26 GLCM 29 D Values 30 θ Values 30 GLCM Normalization 32 HOG 35 Image Gradients 36 Gradient Direction 37 Contributing to Histogram Bins 37 HOG Steps 39 LBP 54 Feature Selection & Reduction 57 Filter 58 Wrapper 59 Embedded 61 Regularization 61 Chapter 2: Artificial Neural Networks 63 Introduction to ANNs 64 Linear Models Are the Base of ANNs 65 Graphing ANNs 70 Adjusting Learning Rate for Training ANN 75 Filter Example 75 ANN Architecture 76 Activation Function 77 Python Implementation 77 Learning Rate 80 Testing the Network 81 Weight Optimization Using Backpropagation 82 Backpropagation for NN Without Hidden Layer 82 Weights Update Equation 85 Why Is the Backpropagation Algorithm Important? 87 Forward vs. Backward Passes 87 Partial Derivative 88 Change in Prediction Error wrt Weights 89 Prediction Error to Weights Chain 89 Calculating Chain Partial Derivatives 91 Interpreting Results of Backpropagation 94 Updating Weights 94 Backpropagation for NN with Hidden Layer 95 Partial Derivatives 98 Updating Weights 106 Overfitting 107 Understand Regularization Based on a Regression Example 109 Model Capacity/Complexity 112 L1 Regularization 113 Designing ANN 115 Example 1: ANN Without Hidden Layer 116 Example 2: ANN with a Single Hidden Layer 120 Chapter 3: Recognition Using ANN with Engineered Features 125 Fruits 360 Dataset Feature Mining 125 Feature Mining 126 Feature Reduction 133 Filtering Using ANN 136 ANN Implementation 138 Engineered Feature Limitations 144 Not the End of Engineered Features 145 Chapter 4: ANN Optimization 147 Introduction to Optimization 148 Single- vs. Multiobjective Optimization 148 GA 152 Best-Parents Selection 155 Variation Operators 156 Crossover 156 Mutation 157 Python Implementation of an Example 158 Complete Implementation 166 NSGA-II 169 NSGA-II Steps 170 Dominance 172 Crowding Distance 180 Tournament Selection 183 Crossover 184 Mutation 185 Optimizing ANN Using GA 186 Complete Python Implementation 191 Chapter 5: Convolutional Neural Networks 200 From ANN to CNN 200 The Intuition Behind DL 201 Derivation of Convolution 205 Image Analysis Using FC Network 206 Large Number of Parameters 208 Neuron Grouping 209 Pixel Spatial Correlation 212 Convolution in CNN 213 Designing a CNN 215 Pooling Operation for Parameter Reduction 219 Convolution Operation Example 221 Max Pooling Operation Example 223 Building a CNN Using NumPy from Scratch 224 Reading the Input Image 225 Preparing Filters 226 Conv Layer 226 ReLU Layer 232 Max Pooling Layer 233 Stacking Layers 235 Complete Code 237 Chapter 6: TensorFlow Recognition Application 245 Introduction to TF 245 Tensor 247 TF Core 247 Dataflow Graph 248 Tensor Names 249 Creating a TF Session 251 Parameterized Graph Using Placeholder 255 TF Variables 258 Variable Initialization 260 Graph Visualization Using TB 261 Linear Model 264 GD Optimizer from TF Train API 268 Locating Parameters to Optimize 270 Building FFNN 271 Linear Classification 272 Nonlinear Classification 281 CIFAR10 Recognition Using CNN 286 Preparing Training Data 287 Building the CNN 289 Training CNN 294 Saving the Trained Model 297 Complete Code to Build and Train CNN 298 Preparing Test Data 308 Testing the Trained CNN Model 309 Chapter 7: Deploying Pretrained Models 311 Application Overview 311 Introduction to Flask 312 route() Decorator 314 add_rule_url Method 317 Variable Rules 317 Endpoint 319 HTML Form 321 File Upload 323 HTML Inside Flask Application 325 Flask Templates 326 Dynamic Templates 327 Static Files 330 Deploying Trained Model Using Fruits 360 Dataset 333 Deploying Trained Model Using CIFAR10 Dataset 342 Chapter 8: Cross-Platform Data Science Applications 355 Introduction to Kivy 356 Basic Application Using BoxLayout 357 Kivy Application Life Cycle 358 Widget Size 362 GridLayout 364 More Widgets 366 Widget Tree 367 Handling Events 370 KV Language 372 P4A 377 Installing Buildozer 377 Preparing buildozer.spec File 378 Building Android Application Using Buildozer 381 Image Recognition on Android 383 CNN on Android 389 Appendix A: Installing Your Own Projects Using pip Installer 397 Creating a Simple Python Project 398 Project Structure 398 Project Implementation 398 Running the Project 399 Importing the Module into a File Inside Its Directory 400 Importing the Module into a File Outside Its Directory 400 How Does Python Locate Libraries? 402 Manual Installation by Copying Project Files to Site-Packages 403 How Do Python Installers Locate Libraries? 404 Preparing the Package and Its Files (__init__.py and setup.py) 404 __init__.py 405 setup.py 406 Distributing the Package 407 Uploading the Distribution Files Online to Test PyPI 409 Installing the Distributed Package from Test PyPI 411 Importing and Using the Installed Package 412 Using PyPI Rather Than Test PyPI 412 Index 413 Deploy deep learning applications into production across multiple platforms. You will work on computer vision applications that use the convolutional neural network (CNN) deep learning model and Python. This book starts by explaining the traditional machine-learning pipeline, where you will analyze an image dataset. Along the way you will cover artificial neural networks (ANNs), building one from scratch in Python, before optimizing it using genetic algorithms. For automating the process, the book highlights the limitations of traditional hand-crafted features for computer vision and why the CNN deep-learning model is the state-of-art solution. CNNs are discussed from scratch to demonstrate how they are different and more efficient than fully connected networks. You will implement a CNN in Python to give you a full understanding of the model. After consolidating the basics, you will use TensorFlow to build a practical image-recognition application and make the pre-trained models accessible over the Internet using Flask. Using Kivy and NumPy, you will create cross-platform data science applications with low overheads. This book will help you apply deep learning and computer vision concepts from scratch, step-by-step from conception to production. You will: Understand how ANNs and CNNs work Create computer vision applications and CNNs from scratch using Python Follow a deep learning project from conception to production using TensorFlow Use NumPy with Kivy to build cross-platform data science applications Front Matter ....Pages i-xxii Recognition in Computer Vision (Ahmed Fawzy Gad)....Pages 1-44 Artificial Neural Networks (Ahmed Fawzy Gad)....Pages 45-106 Recognition Using ANN with Engineered Features (Ahmed Fawzy Gad)....Pages 107-128 ANN Optimization (Ahmed Fawzy Gad)....Pages 129-181 Convolutional Neural Networks (Ahmed Fawzy Gad)....Pages 183-227 TensorFlow Recognition Application (Ahmed Fawzy Gad)....Pages 229-294 Deploying Pretrained Models (Ahmed Fawzy Gad)....Pages 295-338 Cross-Platform Data Science Applications (Ahmed Fawzy Gad)....Pages 339-380 Back Matter ....Pages 381-405
دانلود کتاب Practical Computer Vision Applications Using Deep Learning with CNNs : With Detailed Examples in Python Using TensorFlow and Kivy