当前位置:网站首页>Technical dry goods | top speed, top intelligence and minimalist mindspore Lite: help Huawei watch become more intelligent

Technical dry goods | top speed, top intelligence and minimalist mindspore Lite: help Huawei watch become more intelligent

2022-06-26 23:50:00 Shengsi mindspire

Shengsi MindSpore Lite yes MindSpore The whole scene AI The end side engine of the frame , at present MindSpore Lite As Huawei HMS Core、 Hongmeng 、 Operator, 、 The reasoning engine base of machine learning service for embedded devices in the energy field , For the world 4000+ Applications provide inference engine services , Daily average adjustment amount exceeds 7 Billion , At the same time in all kinds of mobile phones 、 Wearability perception 、 Wisdom screen 、 Smart watches and others IoT The equipment AI Features have been widely used . In this paper, MindSpore Lite In Huawei smart watches WATCH Application on , You are also welcome to publish a website based on MindSpore Lite Application .

Use MindSpore Lite The advantages of

  1. Ultimate performance

    Efficient kernel algorithm and assembly level optimization , Support CPU、GPU、NPU Heterogeneous scheduling , Maximize hardware computing power , Minimize reasoning delay and power consumption .

  2. Lightweight

    Provide ultra lightweight solutions , Support model Quantization Compression , The model is smaller and faster , Can make AI Deployment execution under the extreme environment of the model .

  3. Full scene support

    Support iOS、Android And other mobile operating systems LiteOS Embedded operating system , Support for mobile phones 、 screen 、 Flat 、IoT And other intelligent devices AI application .

  4. Efficient deployment

    Support MindSpore/TensorFlow Lite/Caffe/Onnx Model , Provide model compression 、 Data processing and other capabilities , Unified training and reasoning IR, Convenient for users to deploy quickly .

Use MindSpore Lite workflow

  1. Choose a model : Select a new model or retrain an existing model

  2. Transformation model : Use tools to transform models into end-to-end models that are easy to deploy

  3. Deploy the application : Introduce the model into the application , And load it into mobile or embedded devices

  4. Learning links https://www.mindspore.cn/lite/docs/zh-CN/master/quick_start/quick_start.html#id2

obtain MindSpore Lite The latest version :

Learn about and download MindSpore Lite:

https://www.mindspore.cn/lite/docs/zh-CN/r1.5/use/downloads.html

●  In life AI ● 

MCU The full name is Microcontroller Unit, In Chinese, it can be called micro controller or single chip microcomputer .MCU It can be used in automotive electronics 、 Industrial control and other fields , It can also be used in small and low-power devices . There are billions of Internet of things in the world (IOT) equipment , As big as a sweeping robot 、 The microwave oven 、 Loudspeaker box , As small as a watch 、 Bracelet 、 Electric toothbrush, etc , Cannot leave MCU.MCU Not only undertake computing tasks , It can also be extended to access many peripherals , For example, keys 、 Microphone 、 The speaker 、 Cameras and sensors, etc , Realize the interaction with the surrounding environment . Even five years ago , Most of the MCU Small devices don't have intelligence . In recent years , With Deep neural network technology Rapid development of , There is TinyML Subdivision of .TinyML( Micro machine learning ) It means machine learning or Deep learning Scenarios applied to micro devices . Simply speaking , It means in MCU On the equipment AI Model training and reasoning . With TinyML, Even a small device can be intelligent , No need to rely on expensive hardware or reliable internet transmission .TinyML Another advantage of is privacy protection , All operations are done locally , No need to send any data to the cloud side .

●  Practical problems  ●

Smart watches are another important product of Huawei's consumer business besides mobile phones , It's also typical MCU equipment . Huawei in 2015 The first smart watch was released in . Since the first two generations of watches were released , I often receive feedback from users that I don't have a good experience with the function of raising my wrist and brightening the screen , For example, there is a large time delay when the screen is on 、 Probability of non illumination and false illumination , These problems also indirectly lead to the reduction of the watch's endurance time , Impact on Huawei brand reputation . There are many reasons for the long-term existence of this problem , For example, traditional algorithms were used in the early days ( Not deep learning ); It uses the reasoning framework of friends , Because the framework does not MCU Optimize the equipment , Cause program ROM and RAM High occupancy , This is for resource constrained MCU For equipment , There's no doubt that it's worse . in addition , The computational performance of the framework operator is poor , The reasoning delay is also large , Finally, the time delay of screen lightening is large .

●  Solution  ●

2020 year , Huawei's self-developed in-depth learning framework MindSpore Official open source . As an excellent full scene AI frame , Shengsi MindSpore It also provides for TinyML Model end-to-end deployment capability . Shengsi MindSpore The training framework allows users to get started quickly AI application , Simply and efficiently train your own AI Model . and MindSpore Lite for Micro As an ultra lightweight AI Inference engine , Let users easily deploy their own TinyML Model .MindSpore Lite for Micro The core idea is “ Model is code ”, According to the target hardware CPU Architecture 、 Memory condition , With low power consumption 、 High performance and no third-party dependency are the optimization objectives , Generate exclusive and efficient reasoning code for each model .

The program is divided into Host and Device Two phases . stay Host Stage , We will be right. AI The model performs various operator transformations and graph optimization operations , Significantly reduce redundant computing , Strive to achieve the optimal reasoning performance on the target hardware . The model here doesn't just mean MindSpore Model of , It also supports other mainstream model formats , such as TF、TFLITE、ONNX and CAFFE etc. . We also support quantification after training , The implementation model is smaller 、 Reasoning is faster .Device Stage , Users need to cross compile the generated object source code , Deploy to target hardware . While we generate the code , Supplied with CMake The construction of , It greatly facilitates user integration ; about IDE Integrated users , We also provide operating instructions on the official website .

●  help Watch3 Endurance improvement  ●

2021 year 6 month 2 Japan ,HarmonyOS And Huawei's all scene new product launch , As Huawei's flagship smart watch WATCH 3 Official release . This product has built-in us MindSpore Lite for Micro Ultra light weight AI engine , The false screen lightening is reduced 50%、 The endurance is improved in the super long endurance mode 1.2 God 、ROM and RAM Excellent results with significantly reduced occupancy , It has achieved good market evaluation and user reputation . Behind the solution to the long-term problem of wrist lifting and bright screen for watch users , yes MindSpore Lite for Micro in the light of MCU Accurate positioning of equipment . First , It is the ultimate in model miniaturization , Greatly reduce the amount of code through model optimization and code tailoring , To reduce ROM The space occupied by . secondly , It improves memory block reuse through code optimization , Thereby reducing RAM Space occupation . Last , Based on open source CMSIS-NN Operator library for convolution operator optimization , Further improve performance , Reduce delay .

●  Conclusion  ●

MindSpore Lite Ultra light weight AI The engine not only helps Huawei Watch3, On the smart screen 、 Intelligent speakers 、 Bluetooth headset 、 Many Huawei, such as printers IOT It can be found on the equipment . future , We will also help the Internet of things and AI The industry is moving towards success , Use MindSpore Lite for Micro Ultra light weight AI Engine Implementation “ Model is code ”, Can make IOT The equipment AI Ability , Give Way AI Wisdom is everywhere .

If you need to know more about this MCU Model deployment tool , Please visit the official website :

https://www.MindSpore.cn/Lite/docs/zh-CN/r1.5/use/Micro.html

原网站

版权声明
本文为[Shengsi mindspire]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/177/202206262330563769.html