Regulated machine learning

Machine Learning and Deep Learning in Machine Vision Systems

Machine vision systems are increasingly making use of Machine Learning, Deep Learning and Neural Network technologies. The meaning of these terms is not always clear to everyone. However, do not make the mistake of considering these technologies as the solution to solve any problem of vision. It is better to know the limits to be able to use these technologies in the best way.

by Fabio Rosi

Artificial intelligence in vision systems

First I would do a quick explanation of the terms and principles of operation. I'll preface this by saying that what follows is a big simplification of this complex science, with terms that are not always scientifically appropriate.

Machine Learning, Deep Learning and Neural Networks are all part of the great family ofArtificial Intelligence.

The Machine Learning (in Italian Automatic Learning) are a set of algorithms for learning information and generating decisions from a set of learning data without using predetermined mathematical or statistical models.

In practice, in machine vision systems using machine learning, you usually provide the algorithm with a series of images of defects so that they are later recognized as such.

This action is called Supervised Learning and it is the most used type of learning in machine vision systems of this type. The input learning data (the images of the defects and the information related to their characterization) are manually selected, i.e. supervised. All this information is "digested" by the algorithm in such a way that it identifies a general rule that allows it to find the defects catalogued in the images it will see from time to time.

A kind of magic box that learns from the images of flaws and provides a judgment on the image you are seeing at that moment.

In our magic box are some neural networks, i.e. algorithms capable of learning, a bit like the human mind. In 2019, as many as 29 basic types of neural networks5 of these are defined as Deep. The main difference between a simple neural network and one deep neural network is in the number of hidden intermediate layers. The simple neural network has only one intermediate layer, unlike the deep neural network that has more than one, each layer corresponds to a different level of abstraction of the "reasoning".

deep learning

The Deep Learning, i.e. the elaboration of the information carried out by a deep neural network, gives often more reliable results than those carried out by a monolayer neural network.

Advantages and disadvantages of Machine Learning in machine vision systems

Machine Learning and Deep Learning are two words that have been used a lot lately in the Industry 4.0 environment. Regardless of the "fashionable" aspects of the two terms, we should understand if these technologies can be used in a profitable way.

The answer to this question is dependent on the type of application of the vision system.

Let's look at the main advantages.

  • The simplicity of implementation at the operational level is the main advantage. In fact, it is sufficient to insert the images of the defects each time they occur.
  • After a conspicuous learning, the "deep" network allows to have quite accurate results even in conditions of information noise, which in the case of computer vision systems means reflections, dirty pieces, light variation of the environment, etc..
  • Always after a learning formed by numerous cases, the "deep learning" is able to recognize a generalized defect also without having previously acquired the sample.

Now let's look at the disadvantages.

  • What we previously referred to as a magic box, is slang for Black Box. The problem of the Black Box resides in the fact that it does not allow us to know the rule that involves the choice between good and bad. This is often a big problem that makes the "deep learning" not very reliable in many cases, so it is preferable to use it in applications where the security of the result is not required.
  • For Deep Learning logic to work well you need a significant amount of information. On some applications more than 1000 images are often not enough to create a reliable enough rule.
  • Not having an objective logic of elaboration based on a mathematical or statistical model, the only way to ensure a good probability of the recognition of the defect is to supply to the neural network all the possible cases of defect in all the possible positions, depths, forms and colourings, and in some cases the combination of this information is gigantic. If in fact a particular shape is not catalogued, it is easy that the system does not recognize it. It may happen, for example, that huge defects are not detected simply because a series of small or medium defects have been cataloged.
  • These logics do not allow to guarantee the reliability in the time even on defects that before were recognized as such. This is because the neural logics do not accumulate the information, but they "absorb" it, in fact it is said that they "accumulate the experience" not the data. So as we give new information, old information tends to be "diluted" in the process. This "dilution" is not a purely negative feature because it refines learning. Unfortunately, however, one cannot be sure of the repeatability of the evaluation of the vision system except by blocking the learning process.
  • One of the main problems comes from the process of supervised learning. In fact, considering the amount of information to be supplied to the "deep" network, the human error of supplying a wrong data, i.e. a defect that is not a defect or vice versa, can happen. The neural network has the capacity to hide this wrong acquisition, making difficult if not impossible the research of this anomaly. The result is an increase in the unreliability of the system.
  • Sufficient supervised learning to make the neural network work properly often has costs that do not justify the operation especially in relation to the degree of reliability achieved.

VEA Solution for Machine Learning in Vision Systems

Tests carried out at some of our customers have shown that the Deep Learning technologies are very good because they are able to effectively catalogue a good number of faults, but they are expensive to manage and they are not able to overcome the level of reliability that the current proprietary algorithms in "hybrid logic" have. In fact, the current algorithms VEA in "hybrid logic" are today more functional, faster to implement and above all more reliable and controllable than a "deep" neural network.

Algorithms in "hybrid logic", developed since 2007 by VEA, already adopt a preset supervised learning partially based on neural network, but adopting statistical and mathematical logics to strengthen its stability.

The last types of deep neural networks, together with the growing elaboration capacity of the processors, present however several advantages. The solution therefore is to minimize the disadvantages.

Hence the proprietary technology Regulated Machine Learning. It is a set of hybrid algorithms formed by two distinct sets of logic.

The first "learning" group is formed by Deep Learning logics that learn the case history of defects, abstracting the concepts.

The second group "supervision" is formed by hybrid logics able to evaluate if the result of the "learning" group is sufficiently reliable, in the opposite case the results of the "supervision" logics are taken as reference.

The complementary use of the two logics has so far given excellent results without losing reliability.

Moreover, the level of abstraction of Deep Learning logics is so high as to allow the construction of pre-constituted learning "packages", avoiding long and expensive learning sessions at the expense of the client.