Javatpoint Logo
Javatpoint Logo

Implementation of Neural Network in TensorFlow

Neural Network is a fundamental type of machine learning. It follows the manual Ml workflow of data preprocessing, model building, and model evaluation.

We will be going to start object-oriented programming and the super keyword in Python.

Now let's launch Jupiter notebook in our system through Anaconda Navigator.

Firstly, we have to open Anaconda Navigator, and from there we have to launch the Jupyter Notebook.

Implementation of Neural Network in TensorFlow

After that, a command will run in our system automatically like below.

Implementation of Neural Network in TensorFlow

Then, the below page will open where we have to code.

Implementation of Neural Network in TensorFlow

Then click on the files and start the editor.

Implementation of Neural Network in TensorFlow

Now, it will successfully open in our system.

Then we have to understand simple functions in our coding section below:

Implementation of Neural Network in TensorFlow Implementation of Neural Network in TensorFlow Implementation of Neural Network in TensorFlow

Operators

Following are the basic concept of operators:

  • Operation Class
    • Input Nodes
    • Output Nodes
    • Global Default Graph Variable
    • Compute
      • Overwritten by extended classes
Implementation of Neural Network in TensorFlow Implementation of Neural Network in TensorFlow

Graph

A graph is a global variable. We are using this term graph is because tensor flow runs off graphs and we will reiterate it when we learn about the TensorFlow basics in the next section. We can imagine a graph as kind of the list of nodes. And in this case, we have this simple graph where we have two constants are two nodes n1 and n2 and each of those is a constant 1 and 2 respectively and then it is feeding into some operation. So in our case, we have kind of this selection operation class, and then this operation class is going to be inherited by other classes.

So, for example, we can add a class that inherits operation class, and in that case, it takes in those two inputs 1 and 2 and then outputs three because of 1+2=3. We have a multiply operation so that multiply operation is saying one time two, so the output is 2. Below is the graph.

Implementation of Neural Network in TensorFlow

Placeholder- An "empty" node that needs a value to be provided to compute output.

Variables- It is a changeable parameter of the graph.

Graph- Global Variable connecting variables and placeholders for operations.

Implementation of Neural Network in TensorFlow Implementation of Neural Network in TensorFlow

Session: We need to execute all the operations in a meeting. We will make sure we should implement the nodes in the correct order.

Implementation of Neural Network in TensorFlow Implementation of Neural Network in TensorFlow Implementation of Neural Network in TensorFlow Implementation of Neural Network in TensorFlow Implementation of Neural Network in TensorFlow

Here, we are done with our operators and graph section.






Please Share

facebook twitter google plus pinterest

Learn Latest Tutorials


Preparation


Trending Technologies


B.Tech / MCA