There are a lot of new technology applications in the audio and video space, but in the industrial and IoT space, new technology applications are rarely heard of. At this LiveVideoStackCon 2021 Shanghai conference, we have invited Hong Xiaojian, the person in charge of YoMo framework of Xi Le Technology, to share with us what new blood Xi Le Technology and YoMo will bring to the industry and IoT.

By Hong Xiaojian

Organizing/LiveVideoStack

Hello everyone, today’s topic is programmable streaming computing framework. Everyone may be concerned about the audio and video field. The scenes we face in YoMo tend to be industrial, IoT and other fields. It’s a different scenario, but there’s still a lot of technology in common. You’ll get a lot out of it.

Today’s outline is divided into self-introduction, YoMo project background, YoMo typical use cases, YoMo technical highlights, understanding of edge computing and summary.

It’s about me and Xray Technologies

First, make a self-introduction.

I started technology research and development in 2007 and have been an e-commerce platform for European users for 12 years. I am interested in edge computing and industrial Internet, so I joined the current start-up company — Xile Technology in 2019. I am currently working on the YoMo project, the star of the day.

Xi le technology many friends are the first time to hear, the following to make a simple introduction. Xile Technology focuses on industrial Internet and edge computing, creating YoMo open source computing framework and YCloud cloud service. Since 2015, we have applied artificial intelligence technology to industrial manufacturing, such as the quality inspection of flooring by computer vision. At present, Xile technology continues to serve more than 40 industrial enterprises. In 2019, “China Light Industry Internet Co., LTD.” was jointly established with “China Light Industry Group”, mainly to implement edge computing and other industrial Internet technologies in the light industry.

02 YoMo Project Background

The project background and design principle of YoMo are introduced below.

The first is openness. With the spread of network infrastructure, such as 5G, low latency seems within reach. Five years from now, companies may be competing with QUIC protocols with open, User space-based algorithms that can do some flexible congestion control. The hardware and software of the future may be programmable and open.

If you look at some of the major technologies in the industry today, when you think of real-time streaming computing, you think of things like Flink, and message queues think of Kafka. Even when we deploy microservices, many people think of Docker, but these technologies were actually designed years ago and belong to the consumer Internet. The future will enter the era of IoT. Although the previous technology is still mainstream now, it may not be suitable for the future. When we make products, we want to create new opportunities through new technologies.

In recent years, many industrial accidents have been reported in the news, causing huge casualties and economic losses. In addition, the current national policy has been encouraging safe production, so our customers want to do safe production, such as digital detection and early warning system. The “Medium and Light Industry Internet” served a chemical company last year.

The highest level of safe production is the theory of realizing essential safety. Essential safety is whether equipment failure or improper operation, can predict the occurrence of accidents in advance. To achieve intrinsic security, it is necessary to calculate the change trend of continuous 3S data. At the same time, the AI algorithm will react to possible accidents in the near future. For example, there may be an explosion 30 seconds in the future, so you need to add flame retardants to the chemical reactor in advance. To do this, you need to do 30 more calculations within 1s, each of which is about 33ms. If the compute node is deployed in a cloud computing center, optical data transmission may already exceed this time limit. The 33ms mentioned above includes not only data transfer, but also AI computation time. Therefore, in order to achieve essential security, it is necessary to carry out real-time acquisition and calculation of sensor data.

In order to achieve real-time acquisition, low delay transmission is needed. One is to use a protocol similar to QUIC. The other is that with the popularity of 5G and WiFi6, it is of great help to ensure low delay transmission. In addition, we need to perform millisecond calculations on the collected data, which requires deployment at the edge. If deployed in the cloud, even the computing speed is very fast, but the transmission speed is insufficient, so the millisecond calculation cannot be realized. In addition to the above two points, an Edge AI needs to be deployed at the Edge end for full-dimensional calculation to achieve preload prediction.

Based on current trends, the proportion of real-time computing will increase in the future, with IDC predicting that real-time data computing will account for 30% by 2025.

These are some of the mainstream protocols in the IoT space today. TCP was born in 1983, nearly 40 years ago. Another mainstream MQTT protocol has been around for more than 20 years. With the spread of 5G, these old technologies are like green trains running on bullet train tracks. Google proposed the QUIC protocol in 2012 and carried out the international standardization of IETF in 2016. However, due to the huge upgrade cost, QUIC is not widely used in the industrial field at present, but it is widely used at home and abroad in the field of audio and video. Xile’s goal is to make QUIC technology easy to apply to the industrial sector.

We put forward the concept of gRPC for IoT. GRPC is a very mainstream micro – service RPC framework. GRPC for IoT hopes to achieve full-link QUIC Transport at the edge end. For example, Client/Server services can be connected through QUIC to become P2P mode. The problem with traditional Client/Server is that the Server responds only after the Client requests it, which is one-way. After using QUIC to build a connection, it is a two-way connection Peer to Peer, but also a long link. Why long links? Because IoT device data is continuously available 24 hours a day, if each request is disconnected and reconnected, delay will be affected.

In addition, we launched our own Codec for IoT. Xi Le Technology attaches great importance to the efficiency of network transmission encoding and decoding in the field of IoT. IoT data is captured in real time and sent over long links much like live video.

IoT devices will reach 75 billion by 2025. This means that more devices will need to collect data, resulting in more apps.

Nowadays, the market requires the development of APP to be faster and faster. The faster time to market is, the better. Nowadays, many low code and no code are to shorten the development time. The YoMo framework places great emphasis on being developer friendly so that developers can save time when using it.

In order to save development time, we put forward the concept of Streaming Serverless. The advantages of Serverless are a few lines of core code to focus on, no DevOps to care about, automatic elastic scaling, and on-demand billing, low cost. IoT data is generated 24 hours a day without boundaries, which is a typical streaming scenario. Although there are many mature Serverless frameworks, most of the Serverless frameworks in the market are oriented to the traditional HTTP Request/Response mode. Therefore, we propose Streaming Serverless for this scenario.

This is an interesting tweet. This tweet was made by Docker’s founder in 2019, when he tweeted that if WebAssembly came out in 2008, they wouldn’t need to create Docker. WebAssembly used to be more on the browser side, but now it’s on the server side.

What advantages does WebAssembly have over Docker? WebAssembly’s Cold Start will be 100 times faster than Docker. Secondly, the former execution time is 10%-50% faster than the latter. WebAssembly also takes up less space. Finally, WebAssembly has a more flexible security policy that allows you to specify different permissions during instantiation for different modules.

Because node resources are limited at the edge, WebAssembly combines lightweight, better performance, higher security, and multiple languages. Multilingualism is especially important for Serverless, because many of the major development languages now support compiling programs to WebAssembly, and having this feature has many benefits.

Based on the above aspects, we made YoMo open source framework.

03 YoMo Application Cases

Let me share some typical cases.

We deployed a real-time noise sensor in the office to test whether the YoMo framework could achieve low latency. Since the MQTT protocol requires the installation of an MQTT Broker, we made an MQTT-compliant API on the data acquisition side to reduce the user’s burden of accessing YoMo without installing an MQTT Broker. To test the experiment, we deployed Serverless node in AWS of Ningxia to measure the time delay from Beijing to Ningxia and then back to Beijing from Ningxia. Our test results show that the delay can be basically stable within 30ms. In addition, as for the decibel value displayed on the screen, the traditional method is to save the sensor data to the database first, and then query and display, which will cause the loss of delay, so YoMo is directly displayed on the screen through WebSocket. The data is also grounded to DB with another Serverless service.

Liquor intelligent brewing platform is an industrial-level application. One of the characteristics of the liquor industry is that many of the winemaking techniques are taught through the experience of old masters, which is very subjective. We obtained the hardware and relevant industrial algorithms from China Food Fermentation Industry Research Institute, a professional research institute that has been studying baijiu for decades. Then we carried out real-time process acquisition and calculation of these equipment, digitized the experience of the old master, so as to obtain a stable process, improve the wine yield and efficiency.

There is an overseas user who wants to track user behavior and analyze what kind of user behavior on some websites will lead to the reduction of conversion rate and other problems. In view of this scenario, we made a geo-distributed solution, which split the traditional centralized architecture into multiple edge nodes close to users.

The final example is distributed crawlers. We serve an overseas SaaS company that provides logistics inquiries. Before, the query of this company was obtained through proxy, which would cause high delay and low stability. What’s more, data privacy may be leaked. Through the YoMo framework, we deployed a crawler service on nodes closer to the Courier company to return requests to users in the US via a long connection via the QUIC protocol. These servers are deployed on users’ own machines, ensuring data privacy and saving proxy costs.

04 YoMo features

Through the previous lecture, the guests here have some understanding of the QUIC agreement, these content quickly passed.

QUIC has many advantages. The best part is the bottom two points. One is User space. I also mentioned User space in the opening section, which makes it easier to upgrade software. The TCP kernel upgrade is not so convenient. The second is congestion control algorithm. Flexible control according to different scenarios, with higher programmability.

QUIC has a lot of application practice in audio and video industry. Many large domestic factories began to study the application of audio and video two or three years ago. QUIC can greatly improve performance, including stall rate and so on. Because we are optimistic about the prospects of QUIC and few industrial applications, we want to promote the application of QUIC in industrial and IoT fields.

The video here is borrowed from the video of Alibaba mobile Taobao. The multi-channel QUIC is used on the left, but not on the right. If the WiFi is jitter, the left side can run smoothly over the cellular network, while the right side will be stuck using only WiFi.

Our Y3 Codec we call it Faster than real-time. If it’s traditional JSON, you need to get the full data and decode it. For IoT, such as noise mentioned earlier, just get the field of noise decibels. For this, we use the TLV structure. A Tag in a structure is equivalent to a JSON key. By monitoring whether the Tag is concerned by the user, if yes, the Tag can be directly obtained; if not, skip, and then determine the number of skip bytes according to Length.

In performance tests, Y3 Codec is over 10 times better than JSON and a significant improvement over Protobuf. The following table shows some of the performance reports.

Responsive programming is illustrated graphically with excel applications. Assuming that a= B + C, a will also respond dynamically when B and C are modified. This mode is very suitable for scenarios where data changes over time.

ReactiveX also provides a good programming model for asynchronous data. ReactiveX was first proposed by Microsoft. There are some general methods that can be used to manipulate asynchronous data just as easily as synchronous data, by combining a few common functions to manipulate asynchronous data flows.

It is assumed that data is transmitted every 30ms. However, the actual scenario may be that there is no data for two consecutive 30ms and three data suddenly appear in the third 30ms. For this scenario we really just need to get the latest data. Using Rx simplifies this problem by using debounce to get the latest piece of data every 30ms.

Streaming Serverless allows users to operate Rx streams without having to operate QUIC Streams. You can combine Operator methods based on service requirements. In addition, local debugging of many Serverless services in the market is troublesome, so YoMo supports local running and debugging by CLI.

05 Edge Calculation

Edge computing you more or less also have a certain understanding

The industry is moving away from the mainframe via terminal connectivity to a decentralized PC scenario. In the era of mobile Internet, it has returned to the centralized cloud computing center. In the era of IoT, due to the huge amount of data, edge distribution is needed to relieve the pressure of cloud computing center. Although edge computing is becoming more and more important, edge computing will not replace cloud computing, they will co-exist.

One advantage of edge computing is to reduce transmission distance. The second is the faster response of the nearest calculation. Third, and more importantly, edge computing can protect security and privacy. Many industrial companies are reluctant to transfer data to public cloud services, so privacy protection is especially important. The last point is low cost. Edge computing can reduce the cost of bandwidth transfer.

The comparison between cloud computing and edge computing shows that cloud computing has stronger performance but higher cost of delay and bandwidth, while edge computing is just the opposite. Cloud and edge computing complement each other in usage to meet the needs of different scenarios.

We made geo-distributed Edge Cloud for this. Users can deploy in different locations according to their latency requirements. Low latency can be deployed at city-level nodes. It can be deployed in a private cloud if data policing is required. It is also possible to deploy in a cloud computing center.

06 summary

Finally, make a summary of today’s report.

The background of YoMo’s project is programmable openness towards the future. GRPC for IoT is proposed for network transmission — QUIC and Y3 Codec are used in the whole link. In order to speed up APP development, a framework of Streaming Serverless is proposed. For YoMo usage scenarios, running on WebAssembly has advantages over Docker. Finally, edge computing YoMo can be deployed locally based on geo-distributed Cloud.

The above is the open source plan of YoMo. I hope friends who are interested in YoMo can pay more attention to it.

Thank you!