Mastering Predictive Analytics with scikit-learn and TensorFlow

Book description

Learn advanced techniques to improve the performance and quality of your predictive models

Key Features

  • Use ensemble methods to improve the performance of predictive analytics models
  • Implement feature selection, dimensionality reduction, and cross-validation techniques
  • Develop neural network models and master the basics of deep learning

Book Description

Python is a programming language that provides a wide range of features that can be used in the field of data science. Mastering Predictive Analytics with scikit-learn and TensorFlow covers various implementations of ensemble methods, how they are used with real-world datasets, and how they improve prediction accuracy in classification and regression problems.

This book starts with ensemble methods and their features. You will see that scikit-learn provides tools for choosing hyperparameters for models. As you make your way through the book, you will cover the nitty-gritty of predictive analytics and explore its features and characteristics. You will also be introduced to artificial neural networks and TensorFlow, and how it is used to create neural networks. In the final chapter, you will explore factors such as computational power, along with improvement methods and software enhancements for efficient predictive analytics.

By the end of this book, you will be well-versed in using deep neural networks to solve common problems in big data analysis.

What you will learn

  • Use ensemble algorithms to obtain accurate predictions
  • Apply dimensionality reduction techniques to combine features and build better models
  • Choose the optimal hyperparameters using cross-validation
  • Implement different techniques to solve current challenges in the predictive analytics domain
  • Understand various elements of deep neural network (DNN) models
  • Implement neural networks to solve both classification and regression problems

Who this book is for

Mastering Predictive Analytics with scikit-learn and TensorFlow is for data analysts, software engineers, and machine learning developers who are interested in implementing advanced predictive analytics using Python. Business intelligence experts will also find this book indispensable as it will teach them how to progress from basic predictive models to building advanced models and producing more accurate predictions. Prior knowledge of Python and familiarity with predictive analytics concepts are assumed.

Table of contents

  1. Title Page
  2. Copyright and Credits
    1. Mastering Predictive Analytics with scikit-learn and TensorFlow
  3. Packt Upsell
    1. Why subscribe?
    2. Packt.com
  4. Contributor
    1. About the author
    2. Packt is searching for authors like you
  5. Preface
    1. Who this book is for
    2. What this book covers
    3. To get the most out of this book
      1. Download the example code files
      2. Download the color images
      3. Conventions used
    4. Get in touch
      1. Reviews
  6. Ensemble Methods for Regression and Classification
    1. Ensemble methods and their working
      1. Bootstrap sampling
      2. Bagging
      3. Random forests
      4. Boosting
    2. Ensemble methods for regression
      1. The diamond dataset
      2. Training different regression models
        1. KNN model
        2. Bagging model
        3. Random forests model
        4. Boosting model
    3. Using ensemble methods for classification
      1. Predicting a credit card dataset 
      2. Training different regression models
        1. Logistic regression model
        2. Bagging model
        3. Random forest model
        4. Boosting model
    4. Summary
  7. Cross-validation and Parameter Tuning
    1. Holdout cross-validation
    2. K-fold cross-validation
      1. Implementing k-fold cross-validation
    3. Comparing models with k-fold cross-validation
    4. Introduction to hyperparameter tuning
      1. Exhaustive grid search
      2. Hyperparameter tuning in scikit-learn
      3. Comparing tuned and untuned models
    5. Summary
  8. Working with Features
    1. Feature selection methods 
      1. Removing dummy features with low variance
      2. Identifying important features statistically
      3. Recursive feature elimination
    2. Dimensionality reduction and PCA
    3. Feature engineering
      1. Creating new features
    4. Improving models with feature engineering
      1. Training your model
    5. Reducible and irreducible error
    6. Summary
  9. Introduction to Artificial Neural Networks and TensorFlow
    1. Introduction to ANNs
      1. Perceptrons
      2. Multilayer perceptron
    2. Elements of a deep neural network model
      1. Deep learning
      2. Elements of an MLP model
    3. Introduction to TensorFlow
      1. TensorFlow installation
    4. Core concepts in TensorFlow
      1. Tensors
      2. Computational graph
    5. Summary
  10. Predictive Analytics with TensorFlow and Deep Neural Networks
    1. Predictions with TensorFlow
      1. Introduction to the MNIST dataset
      2. Building classification models using MNIST dataset
      3. Elements of the DNN model
      4. Building the DNN
        1. Reading the data
        2. Defining the architecture
        3. Placeholders for inputs and labels
        4. Building the neural network
        5. The loss function
        6. Defining optimizer and training operations
        7. Training strategy and valuation of accuracy of the classification
        8. Running the computational graph
    2. Regression with Deep Neural Networks (DNN)
      1. Elements of the DNN model
      2. Building the DNN
        1. Reading the data
        2. Objects for modeling
        3. Training strategy
        4. Input pipeline for the DNN
        5. Defining the architecture
        6. Placeholders for input values and labels
        7. Building the DNN
        8. The loss function
        9. Defining optimizer and training operations
        10. Running the computational graph
    3. Classification with DNNs
      1. Exponential linear unit activation function
      2. Classification with DNNs
      3. Elements of the DNN model
      4. Building the DNN
        1. Reading the data
        2. Producing the objects for modeling
        3. Training strategy
        4. Input pipeline for DNN
        5. Defining the architecture
        6. Placeholders for inputs and labels
        7. Building the neural network
        8. The loss function
        9. Evaluation nodes
        10. Optimizer and the training operation
        11. Run the computational graph
      5. Evaluating the model with a set threshold
    4. Summary
  11. Other Books You May Enjoy
    1. Leave a review - let other readers know what you think

Product information

  • Title: Mastering Predictive Analytics with scikit-learn and TensorFlow
  • Author(s): Alan Fontaine
  • Release date: September 2018
  • Publisher(s): Packt Publishing
  • ISBN: 9781789617740