We’re getting better at training deep neural networks to learn very accurate mappings from input to output from large amounts of labeled data, whether they’re images, sentences, tag predictions, etc.

What our model lacks, however, is the ability to generalize about situations that are different from those encountered during training. When you apply a model to a carefully constructed dataset, it always works well. However, the real world is messy and contains countless new scenarios, many of which your model has not encountered during training. The ability to transfer knowledge to new situations is often referred to as transfer learning, and this is what we will discuss in the rest of this article.

In this post, I’ll start by contrasting transformational learning with supervised learning, the most common and successful paradigm of machine learning. Later, I will give a more technical definition and detail the different migration learning scenarios. I will then provide examples of the application of transfer learning and delve into practical approaches that can be used to impart knowledge. Finally, I will give an overview of the relevant directions and propose to look into the future.

What is transfer learning?

In the supervised learning scenario of machine learning, if we intend to train A model for A task and domain A, we assume that we provide label data for the same task and domain. We can see this clearly in Figure 1, where the tasks and domains of training and test data for our models A and B are the same. Let’s assume that one task is the goal our model is designed to perform, such as identifying objects in an image, and one domain is our data from images taken in a San Francisco coffee shop.



The traditional method is that we have to train model A and model B separately, which is bound to waste A lot of resources and time.

And traditional supervised learning paradigms break down when we don’t have enough marker data for tasks or domains for us to train reliable models for.

If we want to train a model to detect pedestrians in nighttime images, we can apply a model that has already been trained in a similar area, such as daytime images. In practice, however, since the model inherits the bias of training data, we need to change some of the parameters or find some new models.

If we want to train a model to perform a new task, such as detecting a cyclist, we can’t even reuse an existing model because the labels are different between tasks.



Transfer learning enables us to process these scenarios using markup data from some of the related tasks that already exist, and the new model inherits the related capabilities of the old model.

In practice, we try to migrate as much knowledge as possible from source to target task or domain. This knowledge can take many forms based on data: it can involve how objects are composed, making it easier for us to identify new objects, and so on.

Why transfer learning?

Stanford University professor Andrew Ng, in his widely popular NIPS 2016 tutorial, says that transfer learning will be the next driver of ML’s business success after supervised learning.



He drew a chart on a whiteboard, and according to Ng, transfer learning will be a key factor in machine learning’s success in the industry.

There is no doubt that the use and success of ML in industry to date has been largely driven by supervised learning. Driven by deep learning, powerful algorithms, and massive labeled datasets, supervised learning has led to a surge of interest in ARTIFICIAL intelligence, especially as we’ve seen the application of machine learning become part of our daily lives in recent years.



Why, however, has transfer learning been around for decades and is currently little utilized in industry, and why is it seeing the explosive growth That Ng predicts? Transfer learning currently receives less attention than other areas of machine learning, such as unsupervised and reinforcement learning. Reinforcement learning is led by Google DeepMind, such as the success of AlphaGo, and by reducing Google’s data center cooling costs by 40%. These two areas, while promising, are likely to have only a relatively small commercial impact in the foreseeable future and remain largely within the scope of cutting-edge research reports as they still face many challenges.

The current use of machine learning in industry is characterized by a dichotomy: On the one hand, over the past few years, we have gained the ability to train more and more accurate models. The most advanced models perform very well and meet the needs of users. How good is it? The latest residual network on ImageNet achieves superhuman performance in object recognition; The intelligent reply of Tmall Xiaomi is widely used, and voice recognition errors have been reduced; We can automatically recognize skin cancer and other symptoms. This maturity enables these models to be deployed to millions of users on a large scale.

The flip side: These successful models are data-hungry and rely on large amounts of markup data to achieve their performance. For some tasks and areas, these data have been painstakingly developed over the years. In some cases, it is public, such as ImageNet, but large amounts of tag data are often proprietary or expensive, like voice or MT data sets, and thus have a competitive advantage in data, where competing machine learning can be better commercialized.

At the same time, when applying the machine learning model, there are a lot of problems, such as: the model has never seen before, I do not know how to deal with many conditions, each customer and each user has their own preferences, and have different data from the data used for training; A model is asked to perform many tasks for which it has not been trained. In all of these cases, our most advanced models sometimes break down.

Transfer learning can help us deal with this, first we must learn to transfer the knowledge we have acquired to new tasks and domains. In order to do this, we need to understand the concepts involved in transfer learning. Then we will introduce some applications of transfer learning.

Application of transfer learning

A particularly important application of transfer learning is analog learning, where gathering data and training models in the real world is expensive and time consuming for many machine learning applications that rely on hardware to interact. So it makes sense to collect data in other, less risky ways.



Simulation is the preferred approach for this, and it has been used in many advanced ML systems in the real world. Learning from the simulation and apply knowledge to the real world is an instance of the migration study scene, because the feature space between the source domain and target domain is the same (both are generally depends on the pixels), but the simulated probability distribution and boundary reality is in different simulation and source, namely the appearance of the object is different, although the difference with simulation become more realistic and reduce. At the same time, the conditional probability distribution between the simulation and the real world may be different because the simulation cannot fully replicate all reactions in the real world, such as physics engines that cannot fully simulate the complex interactions of real world objects.

The benefits of emulation are that data can be easily collected because objects can be easily bound and analyzed, while training is fast because learning can be parallelized across multiple instances. As such, it is a prerequisite for large-scale machine learning projects that need to interact with the real world, such as self-driving cars. “If you really want to build a self-driving car, simulation is essential,” said Zhao Yinjia, Google’s head of self-driving technology. Udacity has opened source simulators that teach nanodegree, an automotive engineer, to drive themselves, and the OpenAI world may allow training to drive themselves using GTA 5 or other video games.



Other applications include adapting to new domains and transferring knowledge across languages. These apps are fun and have a high business value.

Conclusion: Transfer learning will definitely become a hot topic in supervised learning research in the future, because it can create enough economic value. With a clearer business case, tech giants will pay more attention to the technology.

The above is translated by Ali Cloud Habitat Community Organization.

This article was originally titled transfer-learning Machine Learning’s Next Frontier by Sebastian Ruder.

The article is a brief translation. For more details, please refer to the original text