How to Build and Use Neural Networks

Written by sophia.m.brooke | Published 2018/09/15
Tech Story Tags: artificial-intelligence | neural-networks | nlp | use-neural-networks | build-neural-networks

TLDRvia the TL;DR App

Creating a neural network means creating a one-track mind system, trained to solve a single problem, or at most, related issues. It gets input data which it slices and dices through the network of artificial neurons in the hope of classifying it by looking at the characteristics of each piece and comparing it to known resources.

The applications are endless, from selecting the right candidates for a job, to assessing crash risks or even predicting climate changes. Almost any activity sector has a problem which could be solved by neural networks. Therefore, it makes sense to take a more detailed look.

Building a Neural Network

The process is a bit like making a cake. You gather the ingredients (artificial neurons), you mix them in the bowl (create the first layer which you can see), and then put everything in the oven (hidden layers) and hope for the best result (output layer).

To get a little more technical, let’s walk through the necessary steps of actually building a functional neural network. Since no-one wants to reinvent the wheel, you start by importing some useful libraries and of course, the data sets.

Next, since there are no predefined weights (importance) for each of the neurons in the first layer, they get assigned random numbers between 0 and 1. Once this is set up, you can go to the fun part of actually teaching the network.

In the forward propagation step, you walk through the network and compare the results you receive with those you expected, to see how far off you were. This essentially proves how good the model is.

In the backpropagation phase, you aim to make the network learn from its mistake by starting with the end in mind and working through the system in reverse. This feedback process gives new, more accurate weights to the initial layer of artificial neurons.

Repeating the cycle back and forth hundreds of times (these are called epochs), makes the prediction accurate enough that it can’t be improved any further. When this is observed it is time to stop, or the network becomes overtrained. Overtraining means that it pays so much attention to the training dataset, that it is no longer able to see the big picture and it will be useless on other data sets.

Neural Network Applications

As previously mentioned in the opening, the neural networks have countless applications in a wide range of sectors, from healthcare to military defense or risk management. Let’s go through a list of the most exciting current uses and make a few suggestions for the future.

Trading Platforms

If the right prediction models had been used before 2008, there is a chance the financial crisis would never have happened or not at the magnitude experienced. It is only a matter of time before brokers are replaced by machines. This trend is dictated by high-frequency trading, which operates with low values but huge volumes. Since it’s impossible for humans to take the right investment decisions every 15–20 seconds, this is an excellent case for AI powered by neural networks.

Recommendation Engines

Marketing has evolved from mass appeal to individual customization. The more personal you can get with your suggestions, message, and recommendations, the more likely that you will sell and sell a lot. Neural networks can learn about preferences and then generate similar or related product recommendations. Through associated technologies, like image recognition, the system can be so sophisticated that it can get a picture of a star’s outfit as input and return a list of shops where similar items are available for sale.

Healthcare

The success of cancer detection by neural networks is already an accepted breakthrough. It can spot various types of malign formations way before trained physicians could offer the same diagnosis. But this is not the only way AI can improve our health. Even less life-threatening issues like menstrual cycle prediction can benefit from pattern recognition done by artificial neurons, offering a more accurate calendar to people aiming to become parents. Another use includes predicting hospitalization days.

Natural Language Processing

This is one of the high-stakes of neural networks, as it can be used to create a secure communication bridge between man and machine. When NLP is fully functional, only then will chatbots be able to replace call center agents and other public-facing jobs satisfactorily. It will be of great help for instruction manuals, troubleshooters or even teaching.

Risk Management and Fraud Detection

As creatures of habit, people have the tendency to replicate their behavior. Changing the ways we act requires massive amounts of willpower, focus, and determination. Even so, most of the times we revert to old habits. This psychological observation is the foundation of using neural networks for risk assessment for loans and mortgages. Although FICO scores can be enhanced in a year or so, looking at the patterns behind the numbers can reveal if the intentions are good and the money management is sound or if it’s just a matter of tricking the system.

Based on the same idea of habits, fraud detection built on artificial neurons triggers red flags every time an uncommon transaction is made. You might already be familiar with the “is this really you?” verification when you access your e-mail from a different device. It’s the same when you first use your credit card abroad, or for a large purchase, the system will see this as out of the ordinary.

From Self-Driving Cars to a Safer World

These are just a few of the ways neural networks can be used. Of course, the autonomous car will remain one of the flagship applications and a dream of AI fans. The development of such a project is not only important by its end result, the autonomous car which will opefully make traffic jams obsolete, but the intermediary developments to get all they systems in place. These intermediary research steps, will help enhance safety in other areas like airports, schools, and hospitals.


Published by HackerNoon on 2018/09/15