Skip to Main Content
Programming Machine Learning
book

Programming Machine Learning

by Paolo Perrotta
March 2020
Beginner to intermediate content levelBeginner to intermediate
342 pages
8h 38m
English
Pragmatic Bookshelf
Content preview from Programming Machine Learning

Tracing a Boundary

If we hope to understand classification intuitively, then we need a dataset that we can visualize easily. MNIST, with its mind-boggling hundreds of dimensions, is way too complex for that. Instead, we’ll use a simpler, brain-friendly dataset:

 Input_A Input_B Label
 -0.470680718301 -1.905835436960 1
 0.9952553595720 1.4019246363100 0
 -0.903484238413 -1.233058043620 1
 -1.775876322450 -0.436802254656 1

Those are just the first few lines. The file contains 300 examples in total, each with two input variables and a binary label. I wrote a program to plot these data, that you can find in the book’s source code as usual. (It’s called plot_data.py.) It uses the two input variables as coordinates, ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Mastering Machine Learning Algorithms - Second Edition

Mastering Machine Learning Algorithms - Second Edition

Giuseppe Bonaccorso
Practical Machine Learning for Computer Vision

Practical Machine Learning for Computer Vision

Valliappa Lakshmanan, Martin Görner, Ryan Gillard

Publisher Resources

ISBN: 9781680507706Errata Page