From the course: Learning TensorFlow with JavaScript

Introduction to TensorFlow

From the course: Learning TensorFlow with JavaScript

Start my 1-month free trial

Introduction to TensorFlow

- [Narrator] If you've never heard about TensorFlow.js, it's basically an OpenSource WebGL JavaScript library for machine learning. It allows to train neural networks, therefore, also deep learning in your browser. It is based off the regular TensorFlow library built in Python, and borrows all the concepts form its parent library. Although covered in more details later in this course, we'll briefly take a look at the main components of this library. First, you have tensors, which is the central unit of numerical values where we shape our data into one or many arrays. Tensors are immutable, therefore, the values we assign to a tensor can't be changed. Then you have variables, which are a set of values that you can assign and can be changed. And if you need to set values that will be changed as you train your models, variables are best. Operations, or ops, are functions that allow you to manipulate data stored by tensors or variables. It provides all kinds of machine learning and linear algebra operations to explore your data. As mentioned before, if applied to tensors, you can't change this data. Models allow you to use operations to create an output. In other words, this is where you manage to come up with your machine learning or deep learning results. You grab the data off your tensors, and through a function get an output, which is the result of your machine learning or deep learning model. In this case, we output 24 with an input of two. So to summarize all these terms, you feed data to your tensors or variables, and then build a model with operations to come up with a machine learning or deep learning result. This is when it all comes together.

Contents