Make a neural network and Train it
Using Jupyter Notebook
An artificial neural network (ANN) is the piece of a computing system designed to simulate the way the human brain analyzes and processes information. It is the foundation of artificial intelligence (AI) and solves problems that would prove impossible or difficult by human or statistical standards.
ANNs have the ability to learn and model non-linear and complex relationships , which is really important because in real-life, many of the relationships between inputs and outputs are non-linear as well as complex.
Here, we’re going to create an artificial neural network and train it. So, let’s start.
Firstly, we’ve to import libraries.
Now, we create a neural network that will be used further for training.
Here is its output (artificial neural network).
To see input shape:
To see output shape:
We’ll train our neural network against random numbers. So for that, we’ve to import libraries.
Now, generate random numbers and train our neural network according to this.
To find length of input_train:
Now, we’ll train it providing 10 epochs. You can have any number for epochs.
Now, let’s have a look on predict method. The predict() function takes an array of one or more data instances. The example below demonstrates how to make regression predictions on multiple data instances with an unknown expected outcome.
Here project ends. So readers! if you like it, don’t forget to clap.
Thank You.