Matthew Scarpino

Matthew Scarpino has been a programmer and engineer for more than 20 years. He has worked extensively with machine learning applications, especially those involving financial analysis, cognitive modeling, and image recognition. Matthew is a Google Certified Data Engineer and blogs about TensorFlow at tfblog.com.

Articles & Books From Matthew Scarpino

Article / Updated 06-09-2023
After you install TensorFlow, you're ready to start creating and executing applications. This section walks through the process of running an application that prints a simple message. Exploring the example code You can download this example code from the "Downloads" link on Wiley.com. The archive’s name is tf_dummies.
Cheat Sheet / Updated 03-02-2022
TensorFlow is Google’s premier framework for machine learning, and each new version brings a wide range of capabilities and features. After you’ve ascended the learning curve, you can write sophisticated machine-learning applications and execute them at high speed.But rising up the learning curve isn’t easy — with great power comes great complexity.
Article / Updated 06-19-2018
If you succeeded in launching jobs locally, deploying your applications to the cloud shouldn't present any difficulty. But be mindful of two issues: You need to upload training/evaluation data to Cloud Storage. The ML Engine may not support the versions of the packages you need. Before you execute either of the applications in the ch13 directory of the TensorFlow For Dummies downloadable code, you’ll need to upload the mnist_test.
Article / Updated 06-19-2018
Just as most programs start by declaring variables, most TensorFlow applications start by creating tensors. A tensor is an array with zero or more dimensions. A zero-dimensional tensor is called a scalar, a one-dimensional tensor is called a vector, and a two-dimensional tensor is called a matrix. Keep in mind these three points about tensors: Every tensor is an instance of the Tensor class.
Article / Updated 06-19-2018
The gsutil utility lets you create, access, and modify buckets and objects. For the most part, gsutil commands have the same names and purposes as common *nix commands.This table lists 13 of gsutil's commands. For a more thorough discussion, visit Google's documentation.gsutil Commands Command Description mb [-c class] [-l location].
Article / Updated 06-19-2018
Machine learning applications are fundamentally mathematical, and TensorFlow provides a wealth of routines for performing mathematical operations on tensors. Each routine is represented by a function of the tf package, and each function returns a tensor. When it comes to TensorFlow operations, its best to start simple.
Article / Updated 06-19-2018
It may seem strange to use the Cloud SDK to launch jobs locally. But the ML Engine is neither simple nor free, so you should test your applications locally before deploying them to the cloud. Another reason to execute your code locally is that you can view printed text on the command line instead of having to download and read logs.
Article / Updated 06-19-2018
You can launch a training operation with the command gcloud ml-engine jobs submit training. When you execute this, you can identify your source code with the --package-path and --module-name flags. The --package-path flag identifies the directory that contains your code, and this directory must meet the following requirements: The directory must contain the module identified by --module-name.
Article / Updated 06-19-2018
The ls and stat commands of the gsutil utility provide information about buckets and objects in Cloud Storage. The simplest usage of ls is gsutil ls, which lists all of the buckets associated with the current GCP project.One interesting feature of ls is that it recognizes the virtual hierarchy of objects. For example, suppose that gs://mybucket contains /mydir/a.
Article / Updated 06-19-2018
Machine learning applications store a great deal of data in vectors (one-dimensional tensors) and matrices (two-dimensional tensors). To process this data, TensorFlow provides many functions that operate on vectors and matrices. The following table lists these functions and provides a description of each.Vector and Matrix Operations Function Description tensordot(a, b, axes, name=None) Returns the sum of products for the elements in the given axes cross(a, b, name=None) Returns the element-wise cross product diag(diagonal, name=None) Returns a matrix with the given diagonal values, other values set to zero trace(x, name=None) Returns the sum of the diagonal elements transpose(x, perm=None,name='transpose') Switches rows and columns eye(num_rows, num_columns=None,batch_shape=None,dtype=tf.