更新时间:2021-06-24 13:34:20
coverpage
Title Page
Copyright and Credits
Machine Learning with Go Quick Start Guide
About Packt
Why subscribe?
Packt.com
Contributors
About the authors
About the reviewers
Packt is searching for authors like you
Preface
Who this book is for
What this book covers
To get the most out of this book
Download the example code files
Download the color images
Conventions used
Get in touch
Reviews
Introducing Machine Learning with Go
What is ML?
Types of ML algorithms
Supervised learning problems
Unsupervised learning problems
Why write ML applications in Go?
The advantages of Go
Go's mature ecosystem
Transfer knowledge and models created in other languages
ML development life cycle
Defining problem and objectives
Acquiring and exploring data
Selecting the algorithm
Preparing data
Training
Validating/testing
Integrating and deploying
Re-validating
Summary
Further readings
Setting Up the Development Environment
Installing Go
Linux macOS and FreeBSD
Windows
Running Go interactively with gophernotes
Example – the most common phrases in positive and negative reviews
Initializing the example directory and downloading the dataset
Loading the dataset files
Parsing contents into a Struct
Loading the data into a Gota dataframe
Finding the most common phrases
Example – exploring body mass index data with gonum/plot
Installing gonum and gonum/plot
Loading the data
Understanding the distributions of the data series
Example – preprocessing data with Gota
Loading the data into Gota
Removing and renaming columns
Converting a column into a different type
Filtering out unwanted data
Normalizing the Height Weight and Age columns
Sampling to obtain training/validation subsets
Encoding data with categorical variables
Supervised Learning
Classification
A simple model – the logistic classifier
Measuring performance
Precision and recall
ROC curves
Multi-class models
A non-linear model – the support vector machine
Overfitting and underfitting
Deep learning
Neural networks
A simple deep learning model architecture
Neural network training
Regression
Linear regression
Random forest regression
Other regression models
Unsupervised Learning
Clustering
Principal component analysis
Using Pretrained Models
How to restore a saved GoML model
Deciding when to adopt a polyglot approach
Example – invoking a Python model using os/exec
Example – invoking a Python model using HTTP
Example – deep learning using the TensorFlow API for Go
Installing TensorFlow
Import the pretrained TensorFlow model
Creating inputs to the TensorFlow model