Abstract: From AI development model, framework, tools, to improve the development efficiency of learning methods, for AI developers one by one.

This article is shared from huawei Cloud community “10 minutes to understand the basic process of AI development” by the author: Simple persistence.

1. What are AI developers working on?

The result of a hardware developer’s work is a server filled with integrated circuits that can be turned on to run certain software.

The result of a mobile developer’s work can be a mobile APP, containing a large amount of binary data, that can be run directly by the Kirin chip.

The result of an AI developer’s work is a model, which is essentially a function:

F (picture) = "How are you" F (picture) = "Cat"Copy the code

No matter how complex the function is, how many variables or parameters it has, AI development is trying to find an expression for the function.

2. How are AI models (functions) developed?

AI model is essentially a function, want to find the function of accurate expression, cannot be derived by logic, but is trained, we have now been feeding machine, the machine will from these data to find a can satisfy most (professional term called fitting) these data function, when there is new data to predict, The machine can use this function to predict what the new data is going to be.

For an intelligent capability, it generally has the following elements: data + algorithm + model. The development process is to constantly use data and algorithm to make the model more and more close to the real situation, pay attention to the approximation rather than derivation, this process is called training.

3. What is the training process of AI model?

To help understand the training process, let’s use a model that can distinguish between pictures of cats and dogs: “Data” means we need to prepare a large number of pictures labeled “cat” or “dog”; “Algorithm” refers to whether we are going to use a shallow network or a deep one when building the model, and if so, how many layers we are going to use, how many neurons are in each layer, what the function is, etc., which is the design of the network architecture, so we determine what the structure of our prediction function should be.

We represent this function by Y=f(W, X, b), where X is the existing data used for training (cat and dog picture), and Y is the label of the existing picture data (cat or dog picture). What do W and b mean? In the beginning, we really didn’t know that these two parameters had to be found by machine learning, and the process of finding was also the process of training.

“Model” means that we put the data into the algorithm for training, and the machine will continue to learn. When the machine finds the optimal W and B, we will say that the training of the model is successful, and then our function Y=f(W, X, b) will be completely determined

Then we can give the model a new picture of a cat or a dog outside of the data set that we already have, and the model can use the function Y=f(W, X, b) to figure out whether that picture is labeled cat or dog, and that’s inference.

To summarize: The essence of both the simplest linear regression model and the more complex deep neural network model with 100 million parameters is to find a function Y=f(W, X, b) that can fit the existing data well, and we hope that this function can also perform well on new unknown data.

4. Why does AI emphasize massive data?

Because only when the data volume is large enough, the model can learn enough and accurately distinguish the characteristics of cats and dogs, and can show high enough accuracy in the task of distinguishing cats and dogs. Of course, we can train the model with small amounts of data, but the prediction is often much worse on new data sets.

Identification model of cat’s suppose to be very accurate, you need a variety of light conditions, a variety of backgrounds, all sorts of design and color pictures of cats, not only to have a cat, but also have a Garfield, until the model contains we can think of all the characteristics of the cat, a facial recognition model, about need millions of photo, can achieve available, famous Imagenet data set, It contains about 14 million images, making it easier for developers.

5. What can a good development tool help developers do during AI development?

Assuming there is no existing development platform, first you need to learn python, the common AI development language, which is the easy part of the process. Second, you need to learn the traditional machine learning and deep learning algorithms, which is the part that takes the most effort and time. Then you need to understand and derive the algorithms as much as possible. Then use Python code to implement the algorithm retraining model, code ability is important, otherwise your model will not be built.

Then you find a development framework, like Huawei MindSpore or Google Tensorflow, and you’ll find that you don’t need a high mathematical threshold. It’s not that you need a deep understanding of the algorithm to train a good model. The model loss function optimization method is built in MindSpore/Tensorflow. If MindSpore/Tensorflow is a framework that can greatly reduce the amount of code in a model, then Keras is a framework that can significantly reduce the amount of code in a model. For example, the cat and dog classifier above can be solved in 15 lines of code. In a few dozen lines of code, a deep learning network architecture with a convolution layer, a pooling layer and a full connection layer is written with a more advanced optimization method.

A development framework is like the Android framework for mobile APP developers to provide a lot of basic functions, without the framework, a simple send pictures to friends function, you need to directly deal with the operating system’s various underlying functional modules.

6, AI development, development framework is enough?

Of course not, a development framework, just made some developers don’t have to help developers implement part, or to implement cost too much of a part, a complete AI development process, from data preparation, data preprocessing, data annotation, selection algorithm, training, and deployment, and that a normal APP development process. Just like the production of a car, an automatic and high-tech final assembly workshop is essential, but stamping and painting workshops also restrict the production efficiency of the car, so what is the most headache that restricts the AI development efficiency? Please see the next question. What is the biggest difficulty in AI development?

7. What is the biggest difficulty in AI development?

  • There’s a lot of data to prepare for, as mentioned earlier, but what’s even scarier is data annotation, which accounts for about 70% of the entire development cycle. The so-called labeling is to label the data and tell the machine whether a picture is a cat or a dog. Labeling is a very low-tech job in the view of AI developers. It is already a labor-intensive industry, and there are a large number of third-party companies in the industry specializing in data labeling. Taking autonomous driving as an example, the camera on the front of the car is shooting all the pictures in front of the car in real time. The marking process of autonomous driving requires marking the car in front, obstacles, pedestrians, signal lights, signs, lines and so on. If this process is completely dependent on manual marking, it will never be possible for the commercial use of autonomous driving.

  • To iterative training, the training is not achieved overnight, want to modify various parameters repeatedly, the accuracy of the modeling, stepping up the process, the need to rich experience, if do not have enough force, training time, waiting for three days, then the ginseng, to wait for three days, if you want to iterate 20 times, this process is very consumption of man’s will. So, even without taking into account cost, computing power is the biggest constraint on AI adoption.

How to solve the PROBLEM of AI developers?

You need an INTEGRATED development environment like Visual Studio and a code management tool like Git. Similarly, you need an integrated development environment to develop an AI model. And you need a version management tool.

For developers to code the function such as editing, syntax checking, the compiler environment, a development platform, AI also need to be able to help developers annotation data, creating the model training, and deployment model functions, such as a development platform, development platform to help developers to put all the dirty work himself had done, let developers focus on the core code and the algorithm.

Of course, developers should be provided with easy access, strong performance, low price of computing power, improve the iterative speed of model training.

9. Is there a way to speed up AI development faster?

B: of course. There are only two ways to fundamentally improve the efficiency of development and dig to the essence: reuse and automation, otherwise you can only do it line by line.

To develop an APP, you can start from the most basic code, and reuse development packages and functions shared by developers. Huawei Cloud open-source image station has a large number of Java development packages, which means that you can also reuse a complete APP, modify the interface color, and become your own APP. This is reuse. To ensure the quality of the APP, you can use manual testing or automated testing tools. If you don’t want to do any of this, you can or can use an off-the-shelf tool to visually generate an APP, but the style of the APP can only be selected from the template that the tool already has. Developers have been trying to use various ways to reduce the workload of development.

The same goes for AI development. You can take off-the-shelf data sets, off-the-shelf annotated data sets, off-the-shelf algorithms and models, and deploy them to the end-to-end cloud using automated deployment tools. Of course, automatic learning can also be used. As long as the original data is provided, the system helps the developer to complete the model building, algorithm selection and automatic training, and the developer can see the results directly. The easiest way is to find a trained model and call it directly in the software.

Based on this, a good AI development platform needs to improve the development efficiency from all dimensions. These functions are often a lot of small details, strong computing power and fast training, but only the most basic functions must be completed.

10. What development tools will Huawei provide to developers?

ModelArts, an AI development platform for AI model development

HiLens, a visual AI application development platform for AI application development, the models in the application are provided by ModelArts.

The above two products provide services in the form of cloud services in Huawei Cloud EI.

Atlas 200 Developer Kit is ModelArts’ offline development kit.

Click follow to learn about the fresh technologies of Huawei Cloud