Data transmission method, electronic device, storage medium, and chip system

By filtering data streams and using multi-channel transmission, the problem of low efficiency when electronic devices transfer large files is solved, improving transmission efficiency and reducing the risk of interruption.

WO2026026129A1PCT designated stage Publication Date: 2026-02-05HONOR DEVICE CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2025/095249
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2024-07-31
Filing Date
2025-05-15
Publication Date
2026-02-05

AI Technical Summary

Technical Problem

When electronic devices transfer large files, existing technologies require a considerable amount of time, which affects the user experience.

Method used

By analyzing the data stream, suitable data streams for multi-channel transmission can be selected, reducing data stream interruptions during multi-channel switching and improving data transmission efficiency.

Benefits of technology

It improves data transmission efficiency and reduces issues such as account logout or audio/video interruption during file transfer.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2025095249_05022026_PF_FP_ABST
    Figure CN2025095249_05022026_PF_FP_ABST
Patent Text Reader

Abstract

Embodiments of the present application relate to the technical field of terminals, and provide a data transmission method, an electronic device, a storage medium, and a chip system. The method comprises: using a first channel to transmit a data stream; acquiring transmission information of the data stream, the transmission information comprising one or more of the following: an uplink rate, a downlink rate, the number of uplink data packets, the number of downlink data packets, an uplink data packet length, and a downlink data packet length; and, when the transmission information of the data stream meets a first preset condition, using the first channel and a second channel to transmit the data stream, the first channel being different from the second channel, the first preset condition being used for determining a data stream of a file transmission type, and the data stream of the file transmission type being a data stream transmitted in a non-real-time manner. In this way, an electronic device can obtain, by means of screening, a data stream suitable for multi-channel transmission, thereby reducing problematic scenarios caused by data stream interruption during multi-channel switching, and improving data transmission efficiency by using multi-channel transmission.
Need to check novelty before this filing date? Find Prior Art

Description

Data transmission method, electronic device, storage medium and chip system

[0001] The present application claims priority from the Chinese patent application No. 202411048214.6 filed on July 31, 2024, and entitled "Data transmission method, electronic device, storage medium and chip system", the whole content of which is incorporated herein by reference. TECHNICAL FIELD

[0002] The present application relates to the technical field of terminal, in particular to a data transmission method, an electronic device, a storage medium and a chip system. BACKGROUND

[0003] The electronic device supports interaction with other devices, for example, the electronic device can upload or download file data, such as application installation package, game data, video, etc.

[0004] However, in a possible implementation, when the file data is large, the electronic device needs to spend a long time to download or upload the file data, which affects the user experience. SUMMARY

[0005] Embodiments of the present application provide a data transmission method, an electronic device, a storage medium and a chip system, applied to the technical field of terminal, by analyzing the data stream, screening out the data stream suitable for multi-channel transmission, reducing the problem scene caused by the interruption of the data stream in the process of switching multi-channel, and improving the data transmission efficiency.

[0006] In a first aspect, an embodiment of the present application provides a data transmission method. The method comprises: transmitting a data stream using a first channel (e.g., channel 1); obtaining transmission information of the data stream; the transmission information comprises one or more of: an uplink rate, a downlink rate, a number of uplink data packets, a number of downlink data packets, a length of uplink data packets, and a length of downlink data packets; in a case where the transmission information of the data stream satisfies a first preset condition (e.g., preset condition 3), transmitting the data stream using the first channel (e.g., channel 1) and a second channel (e.g., channel 2); the first channel is different from the second channel; the first preset condition is used to determine a file transmission type data stream; the file transmission type data stream is a non-real-time transmission data stream; wherein the first preset condition comprises: in a case where the uplink rate is greater than the downlink rate (transmitting data), a ratio of the downlink rate to the uplink rate is less than a first threshold (e.g., a ratio threshold 1, 30%, which indicates that the uplink rate and the downlink rate are asymmetric); the uplink rate is greater than a second threshold (e.g., a rate threshold 1, 100 KB), and the downlink rate is less than a third threshold (e.g., a rate threshold 2, 2 messages); in the uplink data packets, a proportion of the number of uplink data packets with a length of MTU to the total number of uplink data packets is greater than a fourth threshold (e.g., a ratio threshold 2, 80%); and a mean square error of the uplink rate is greater than a fifth threshold (e.g., a mean square error threshold, which indicates that the uplink rate and the downlink rate are unstable and fluctuate greatly); or the first preset condition comprises: in a case where the downlink rate is greater than the uplink rate (receiving data, similar to the condition of transmitting data), a ratio of the uplink rate to the downlink rate is less than a first threshold; the downlink rate is greater than a second threshold, and the uplink rate is less than a third threshold; in the downlink data packets, a proportion of the number of downlink data packets with a length of MTU to the total number of downlink data packets is greater than a fourth threshold; and a mean square error of the downlink rate is greater than a fifth threshold.

[0007] In this way, the electronic device can screen out data streams suitable for multi-channel transmission, reduce the problem scenarios caused by data stream interruption in the process of switching multi-channels, and improve data transmission efficiency by using multi-channel transmission.

[0008] Optionally, before transmitting the data stream using the first channel, the method comprises: in response to a trigger operation for transmitting file data, establishing a plurality of data streams, and obtaining communication information of any data stream in the plurality of data streams; wherein the communication information comprises one or more of: an application name, a local address, a local port, a remote address, a remote port, a protocol type, and a process identifier; after transmitting the data stream using the first channel, the method further comprises: determining whether the plurality of data streams are used to transmit the same file data based on the communication information; and obtaining the transmission information of the data stream comprises: in a case where the plurality of data streams are used to transmit the same file data, obtaining the transmission information of the data stream.

[0009] In this way, the electronic device can preliminarily determine the specification of the file data based on the data stream of the same file data, so as to subsequently split the large-specification file data.

[0010] Optionally, within the preset time, if the number of data streams satisfying the second preset condition (for example, the preset condition 1) is greater than a sixth threshold (for example, the number threshold, 2), the plurality of data streams are used to transmit the same file data; wherein the second preset condition includes that the application program names of the plurality of data streams are the same, the remote addresses are the same, the remote ports are all preset ports, and the protocol types are all preset protocol types.

[0011] In this way, the electronic device can more accurately determine whether the plurality of data streams are used to transmit the same file data.

[0012] Optionally, before obtaining the transmission information of the data stream, the method further includes: obtaining disk I / O data corresponding to the data stream according to a process identifier of the data stream, the disk I / O data being used to identify the size of the file data, and the disk I / O data including one or more of the following: a read operation number, a write operation number, a read byte number, and a write byte number; and obtaining the transmission information of the data stream includes: obtaining the transmission information of the data stream in a case where the disk I / O data satisfies a third preset condition (for example, the preset condition 2).

[0013] In this way, the electronic device can determine the specification of the file data based on the disk I / O data, and determine the splitting time of the file data when the disk I / O data changes.

[0014] Optionally, the third preset condition includes that the read operation number is greater than a seventh threshold, and / or the read byte number is greater than an eighth threshold; or, the third preset condition includes that the write operation number is greater than the seventh threshold, and / or the write byte number is greater than the eighth threshold; or, the third preset condition includes that a read data amount is greater than a ninth threshold, or a write data amount is greater than the ninth threshold; the read data amount is positively correlated with the read operation number and the read byte number, respectively, and the write data amount is positively correlated with the write operation number and the write byte number, respectively.

[0015] In this way, the electronic device can determine the specification of the file data based on the disk I / O data, and determine the splitting time of the file data when the disk I / O data changes.

[0016] Optionally, the electronic device stores a white list, the white list including a preset application program name, and after obtaining the communication information of any data stream of the plurality of data streams, the method further includes: searching for the application program name of the data stream in the white list; and obtaining the transmission information of the data stream further includes: obtaining the transmission information of the data stream in a case where the white list includes the application program name.

[0017] In this way, data that is not suitable for multi-channel transmission can be filtered out through the application level by using the whitelist, and the accuracy of determining file transmission data is improved. For example, the characteristics of video live streaming data are similar to those of file transmission data, and the video live streaming data can be filtered out through the whitelist.

[0018] Optionally, in a case where the transmission information of the data stream satisfies the first preset condition, the data stream is transmitted using the first channel and the second channel, including: inputting the transmission information of the data stream into a deep / dynamic flow inspection (DFI) model to obtain a type of the data stream; in a case where the type of the data stream is file transmission, outputting an identifier of the data stream; the identifier of the data stream includes a local address and a local port; stopping using the first channel to transmit the data stream according to the identifier of the data stream; and after the data stream is split, the data stream is transmitted using the first channel and the second channel.

[0019] In this way, the electronic device can use multiple channels to transmit file data, and the efficiency of data transmission is improved.

[0020] Optionally, the preset port includes a 443 port or an 80 port, and the preset protocol type is a TCP protocol.

[0021] Optionally, the application program related to the file transmission type includes one or more of the following: a communication application, a cloud storage application, and a download application.

[0022] Optionally, when the electronic device supports remote control, the transmission information of the data stream further includes a data packet interval, and the first preset condition further includes: an uplink data packet interval is greater than a tenth threshold (for example, an interval threshold); or a downlink data packet interval is greater than the tenth threshold.

[0023] In a second aspect, an embodiment of the present application provides an electronic device, which can also be referred to as a terminal device, a terminal, a user equipment (UE), a mobile station (MS), a mobile terminal (MT), etc. The terminal device can be a mobile phone, a smart television, a wearable device, a tablet computer (Pad), a computer with wireless transceiver function, a virtual reality (VR) terminal device, an augmented reality (AR) terminal device, a wireless terminal in industrial control, a wireless terminal in self-driving, a wireless terminal in remote medical surgery, a wireless terminal in smart grid, a wireless terminal in transportation safety, a wireless terminal in smart city, a wireless terminal in smart home, etc.

[0024] The electronic device includes a processor and a memory. The memory stores computer-executable instructions. The processor executes the computer-executable instructions stored in the memory, so that the electronic device performs the method of the first aspect.

[0025] In a third aspect, an embodiment of the present application provides a computer-readable storage medium, which stores a computer program. The computer program is executed by a processor to implement the method of the first aspect.

[0026] In a fourth aspect, an embodiment of the present application provides a computer program product, which includes a computer program. When the computer program is executed, the computer program causes a computer to perform the method of the first aspect.

[0027] An embodiment of the present application provides a chip system, which includes at least one processor and a communication interface. The communication interface and the at least one processor are interconnected through a line. The at least one processor is configured to execute a computer program or instructions to perform the method of the first aspect.

[0028] It should be understood that the second aspect to the fifth aspect of the present application correspond to the technical solution of the first aspect of the present application. The beneficial effects achieved by each aspect and the corresponding feasible implementation manners are similar, and will not be described again. BRIEF DESCRIPTION OF DRAWINGS

[0029] FIG. 1 is a schematic diagram of a single-channel data transmission scenario in a possible implementation;

[0030] Fig. 2 is a schematic diagram of a multi-channel data transmission scenario according to an embodiment of the present application;

[0031] Fig. 3 is a schematic diagram of a hardware structure of an electronic device 100 according to an embodiment of the present application;

[0032] Fig. 4 is a schematic diagram of a data transmission method according to an embodiment of the present application;

[0033] Fig. 5 is a schematic diagram of a data transmission method according to an embodiment of the present application;

[0034] Fig. 6 is a schematic diagram of a software structure of an electronic device 100 according to an embodiment of the present application;

[0035] Fig. 7 is a schematic diagram of a data transmission method according to an embodiment of the present application;

[0036] Fig. 8 is a schematic diagram of a data transmission apparatus according to an embodiment of the present application. DETAILED DESCRIPTION

[0037] In order to clearly describe the technical solutions of the embodiments of the present application, the following briefly introduces some terms and technologies involved in the embodiments of the present application:

[0038] 1. Electronic device

[0039] The electronic device of the embodiments of the present application can include a handheld device with image processing function, a vehicle-mounted device, etc. For example, some electronic devices are: a mobile phone, a tablet computer, a palm computer, a notebook computer, a mobile internet device (MID), a wearable device, a virtual reality (VR) device, an augmented reality (AR) device, a wireless terminal in industrial control, a wireless terminal in self driving, a wireless terminal in remote medical surgery, a wireless terminal in smart grid, a wireless terminal in transportation safety, a wireless terminal in smart city, a wireless terminal in smart home, a cellular phone, a cordless phone, a session initiation protocol (SIP) phone, a wireless local loop (WLL) station, a personal digital assistant (PDA), a handheld device with wireless communication function, a computing device or other processing device connected to a wireless modem, a vehicle-mounted device (such as a car machine), a wearable device, an electronic device in 5G, or an electronic device in a future evolved public land mobile network (PLMN), etc. The embodiments of the present application are not limited thereto.

[0040] By way of example and not limitation, in the embodiments of the present application, the electronic device can also be a wearable device. The wearable device can also be referred to as a wearable smart device, which is a general term for devices that are designed and developed by applying wearable technology to daily wear, such as hearing aids, glasses, gloves, watches, clothing, and shoes. The wearable device is a portable device that is directly worn on the body or integrated into the user's clothes or accessories. The wearable device is not only a hardware device, but also a device that realizes powerful functions through software support and data interaction and cloud interaction. The general wearable smart device includes a device with full function and large size, which can realize complete or partial functions without relying on a smart phone, such as a smart watch or smart glasses, and a device that focuses on a certain application function and needs to cooperate with other devices such as a smart phone, such as various smart wristbands and smart jewelry for monitoring vital signs.

[0041] In addition, in the embodiments of the present application, the electronic device can also be an electronic device in an Internet of Things (IoT) system. The IoT is an important part of future information technology development, and its main technical feature is to connect things through communication technology, so as to realize the interconnection of man and machine and the interconnection of things.

[0042] The electronic device in the embodiments of the present application can also be referred to as a terminal device, user equipment (UE), a mobile station (MS), a mobile terminal (MT), an access terminal, a subscriber unit, a subscriber station, a mobile station, a mobile terminal, a remote station, a remote terminal, a mobile device, a user terminal, a terminal, a wireless communication device, a user agent, or a user device, etc.

[0043] 2. Other terms

[0044] In the embodiments of the present application, the words "exemplary" or "for example" are used to mean serving as an example, instance, or illustration. Any embodiment or design scheme described in the present application as "exemplary" or "for example" should not be construed as being more preferred or advantageous than other embodiments or design schemes. Rather, the use of the words "exemplary" or "for example" is intended to present concepts in a concrete manner.

[0045] In the embodiments of the present application, "at least one" means one or more, and "multiple" means two or more. The "and / or" describes the association relationship of the associated objects, which means that there can be three relationships, for example, A and / or B, which can represent the following three cases: A exists alone, A and B exist together, and B exists alone, where A and B can be singular or plural. The character " / " generally represents an "or" relationship between the associated objects before and after it. "At least one of the following" or similar expressions means any combination of these items, including any combination of single item or multiple items. For example, at least one of a, b, or c can represent a, b, c, a-b, a-c, b-c, or a-b-c, where a, b, and c can be single or multiple.

[0046] It should be noted that "at the time of" in the embodiments of the present application can be at the moment when a certain condition occurs, or within a certain period of time after the occurrence of a certain condition, which is not limited in the embodiments of the present application. In addition, the display interface provided in the embodiments of the present application is only an example, and the display interface can also include more or less content.

[0047] The electronic device supports interaction with other devices, for example, the electronic device can upload or download file data, such as application installation packages, game data, videos, etc.

[0048] Taking the electronic device 100 as a personal computer (PC) and the other device 300 as a server as an example, in a possible implementation, a process in which the PC transmits file data to the other device can be as shown in FIG. 1:

[0049] The electronic device 100 supports a wireless local area network (WLAN), and after the electronic device 100 accesses the WLAN network, the electronic device 100 can be connected to the server 300 through the wireless network device 200 (for example, an access point (AP), a router, or the like).

[0050] Taking the electronic device 100 as an example, the electronic device 100 can upload file data to the wireless network device 200 through the WLAN network, and then upload the file data to the server 300 by the wireless network device 200, thereby realizing uploading of the file data. Similarly, a process in which the electronic device 100 receives file data from the server 300 is, for example, the server 300 transmits file data to the wireless network device, and then the wireless network device 200 transmits the file data to the electronic device 100, thereby realizing downloading of the file data.

[0051] However, in a possible implementation, when the file data is large, the electronic device needs to spend a long time to download or upload the file data, thereby affecting the user experience.

[0052] In an embodiment of the present application, the electronic device can transmit file data through multiple channels concurrently, to improve transmission efficiency. FIG. 2 shows a flowchart of concurrently transmitting file data according to an embodiment of the present application, as shown in FIG. 2:

[0053] The multiple channels can be, for example, two groups of data transmission channels. One group of data transmission channels can be, for example, the electronic device 100, the wireless network device 200, and the server 300. Another group of data transmission channels can be, for example, the electronic device 100, the electronic device 400 (for example, a mobile phone), the wireless network device 500 (for example, a base station), and the server 300.

[0054] Specifically, taking the electronic device 100 sending file data to the server 300 as an example, the electronic device 100 can upload the file data to the wireless network device 200 through the WLAN network, and then the wireless network device 200 uploads the file data to the server 300. Meanwhile, the electronic device 100 and the electronic device 400 can establish a peer-to-peer (P2P) channel, and the electronic device 400 can support the WLAN network and / or the cellular network. The electronic device 100 transmits the file data to the electronic device 400, and the electronic device 400 can deliver the file data to the wireless network device 500 based on the WLAN network and / or the cellular network. The wireless network device 500 can transmit the file data to the server 300. In this way, the electronic device 100 can upload the file data through two groups of data transmission channels.

[0055] Taking the electronic device 100 receiving file data from the server 300 as an example, the server 300 can deliver the file data to the wireless network device 200 through the WLAN network, and then the wireless network device 200 delivers the file data to the electronic device 100. Meanwhile, the electronic device 100 and the electronic device 400 can establish a P2P channel, the server 300 transmits the file data to the wireless network device 500, the wireless network device 500 can deliver the file data to the electronic device 400 based on the WLAN network and / or the cellular network, and the electronic device 400 can transmit the file data to the electronic device 100. In this way, the electronic device 100 can download the file data through two groups of data transmission channels.

[0056] Multi-channel data transmission can accelerate data transmission efficiency, but in actual application scenarios, the electronic device 100 can distinguish file data. For example, in the case of small file data, the difference between using multi-channel data transmission and using single-channel data transmission by the electronic device is small, multi-channel data transmission increases the complexity of system management, but the effect of improving data transmission efficiency is not obvious. Therefore, the embodiments of the present application can distinguish the size of the file data, for file data with large specifications, the electronic device can use multi-channel data transmission, and for file data with small specifications, the electronic device can use single-channel data transmission.

[0057] In the data transmission process, due to the complex application business scenarios of file data, the electronic device can not be able to perform multi-channel data transmission on all file data with large specifications. For example, after receiving an operation for triggering data transmission, the electronic device first obtains the size of the file data through single-channel data transmission, and determines whether to use multi-channel data transmission based on the size of the file data. In the case where the size of the file data is greater than or equal to the requirement of multi-channel data transmission, the electronic device can disconnect the link of single-channel data transmission and establish the link of multi-channel data transmission.

[0058] However, part of the file data may be incorrect during the process of disconnecting the data connection. For example, part of the file data of an application is related to account keep-alive, and after the data connection is disconnected, the electronic device may display that the application has exited the account. For another example, part of the application can upload and download video data during a video call, and after the data connection is disconnected, the video call may be interrupted, and the like. Therefore, part of the large-specification file data supports multi-channel data transmission, and part of the large-specification file data does not support multi-channel data transmission. Therefore, before the file is transmitted in multiple channels, the electronic device needs to identify the data stream to determine which data stream to split and use multiple channels for data transmission, and needs to determine the timing of splitting. The data splitting can be understood as the process of splitting the file data stream into multiple sub-streams, and the multiple sub-streams can be transmitted by using multiple groups of data channels.

[0059] Therefore, the embodiments of the present application provide a data transmission method, which detects the parameters of file data during file data transmission, and performs multi-channel data transmission on the file data when the parameters of the file data meet the preset conditions of multi-channel data transmission, so as to improve the data transmission efficiency. The preset conditions of multi-channel data transmission can be related to the size of the file data, the characteristics of the file data (for example, the protocol type, the port, the transmission parameters of uploading and / or downloading, and the like), and the like. Specifically, the electronic device can determine whether to split based on the protocol type, the port, and the size of the data file. After determining to split, whether the file data is suitable for multi-channel data transmission is judged based on the transmission information of the file data during uploading and / or downloading. After meeting the requirements of multi-channel data transmission, the electronic device can transmit the file data by using multiple channels. In this way, the accuracy of file data identification can be improved, and on the basis of improving the file transmission efficiency, the problem scenarios of account exit or audio / video interruption during the data stream reconstruction process can be reduced.

[0060] In order to better understand the embodiments of the present application, the structure of the electronic device of the embodiments of the present application is introduced as follows:

[0061] FIG. 3 shows a structural schematic diagram of the electronic device 100. The electronic device 100 can include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, a headphone jack 170D, a sensor module 180, a key 190, a motor 191, an indicator 192, a camera 193, a display screen 194, a subscriber identification module (SIM) card interface 195, and an embedded secure element (eSE) 196, and the like. The sensor module 180 can include a pressure sensor 180A, a gyroscope sensor 180B, a barometric pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, and the like.

[0062] It can be understood that the structure shown in the embodiments of the present application does not constitute a specific limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 can include more or fewer components than shown, or combine certain components, or split certain components, or different component arrangements. The components shown can be implemented in hardware, software, or a combination of software and hardware.

[0063] The processor 110 can include one or more processing units, for example: the processor 110 can include an application processor (AP), a modem processor, a graphics processing unit (GPU), an image signal processor (ISP), a controller, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU), and the like. Different processing units can be independent devices, or can be integrated in one or more processors.

[0064] The wireless communication function of the electronic device 100 can be implemented by the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, the modem processor, the baseband processor, and the like.

[0065] The antenna 1 and the antenna 2 are used to transmit and receive electromagnetic wave signals.

[0066] The mobile communication module 150 can provide a solution for wireless communication including 2G / 3G / 4G / 5G and the like applied to the electronic device 100. The mobile communication module 150 can include at least one filter, a switch, a power amplifier, a low noise amplifier (LNA), and the like. The mobile communication module 150 can receive electromagnetic waves from the antenna 1, and perform filtering, amplification, and the like on the received electromagnetic waves, and transfer the processed signals to the modem processor for demodulation. The mobile communication module 150 can also amplify signals modulated by the modem processor, and radiate the signals as electromagnetic waves through the antenna 1. In some embodiments, at least part of the function modules of the mobile communication module 150 can be disposed in the processor 110. In some embodiments, at least part of the function modules of the mobile communication module 150 can be disposed in the same device as at least part of the modules of the processor 110.

[0067] The wireless communication module 160 can provide a solution for wireless communication including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared (IR) technology, and the like, applied to the electronic device 100. The wireless communication module 160 can be one or more devices integrated with at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via the antenna 2, performs frequency modulation and filtering on the electromagnetic wave signals, and transmits the processed signals to the processor 110. The wireless communication module 160 can also receive signals to be transmitted from the processor 110, perform frequency modulation and amplification on the signals, and radiate the signals as electromagnetic waves through the antenna 2.

[0068] In the embodiments of the present application, the electronic device 100 can transmit data to or receive data from the wireless network device 200 or the electronic device 400 based on the antenna 1, the antenna 2, the mobile communication module 150, and / or the wireless communication module 160.

[0069] It can be understood that the electronic device 100 in the embodiments of the present application can be a mobile phone and a PC. When the electronic device 100 is a PC, part of the PC end can not include the mobile communication module 150, and data transmission can not be based on a cellular network.

[0070] The internal memory 121 can be used to store computer executable program codes, and the executable program codes include instructions. The internal memory 121 can include a program storage area and a data storage area. The program storage area can store an operating system, at least one application program required by a function (such as a sound playing function, an image playing function, etc.), and the like. The data storage area can store data (such as audio data, a phone book, etc.) created during use of the electronic device 100, and the like. In addition, the internal memory 121 can include a high-speed random access memory, and can also include a non-volatile memory, for example, at least one magnetic disk storage device, a flash memory device, a universal flash memory (UFS), and the like. The processor 110 executes various function applications and data processing of the electronic device 100 by running instructions stored in the internal memory 121 and / or instructions stored in a memory disposed in the processor.

[0071] In the embodiments of the present application, the internal memory 121 can include a disk, and in the case that the electronic device 100 transmits or receives data, the electronic device can read data from the disk or write data into the disk. The electronic device 100 can determine the timing of data splitting based on the change of disk I / O.

[0072] The data transmission method provided by the embodiments of the present application will be described below in combination with FIG. 4. As shown in FIG. 4:

[0073] S401, the electronic device monitors the connection of the data stream; the connection of any data stream includes one or more of the following: an application name (app name), a local address (local address), a local port (local port), a remote address (remote address), a remote port (remote port), a protocol type (protocol), a process identifier (pid), and the like.

[0074] The connection of the data stream can be in the following format: the application name, the local address, the local port, the remote address, the remote port, the protocol type, and the process identifier, and the like.

[0075] For example: application 1.exe 192.168.155.200 52875 59.82.29.194 443 TCP 22924.

[0076] It should be noted that in step S401, the data stream can be transmitted using a single channel.

[0077] S402, the electronic device monitors a plurality of newly added data streams within a preset time, and the number of data streams in which the communication information satisfies the preset condition 1 is greater than the number threshold.

[0078] The preset time can be used as a basis for determining whether the plurality of newly added data streams belong to the same file data. If within the preset time, it means that a plurality of data streams are generated in a short time, and the probability that the plurality of data streams are data streams of the same file data is relatively large; if not within the preset time, the plurality of data streams may be data streams from different file data. The preset time may be, for example, 3s.

[0079] The preset condition 1 can be used as a basis for further determining whether the plurality of newly added data streams belong to the same file data. The preset condition 1 can be, for example, that the application names of the plurality of data streams are the same, the remote addresses are the same, the protocol types are the same, the remote ports are the same, the remote port is a preset port, and the protocol type is TCP.

[0080] The electronic device can monitor the communication information of the data stream in real time. In the case of receiving an operation for sending or receiving file data, the electronic device can monitor that the data stream changes, for example, a new data stream appears, and the application name, address, port, and the like of the newly added data stream are different from the communication information of the previous historical data stream.

[0081] For a plurality of data streams of the same file data, the application names, local addresses, remote addresses, remote ports, and protocol types of the plurality of data streams are the same. Therefore, the same application name, the same address, the same protocol type, and the same remote port can be used as a basis for determining the data stream of the same file data. It can be understood that the local address refers to the IP address of the local device used to identify different data streams, and the local port refers to the port of the local device used to identify different data streams. Therefore, other information of the plurality of data streams of the same file data can be the same, and the local address and the local port can be different.

[0082] The preset port can be a web port used to identify web communication. For example, the web port includes a port 80 and a port 443. The port 80 is a default port for hypertext transfer protocol (HTTP) communication, and is used to transmit web content (such as a webpage, an image, a document, and the like). The port 443 is a default port for hypertext transfer protocol secure (HTTPS) communication, and is used for encrypted HTTP communication. In the process of file transmission with other devices, the electronic device needs to communicate with the remote port of the other device, and the remote port is related to the preset port.

[0083] The quantity threshold can be used to measure the size of the file data, and the quantity of the data stream is positively correlated with the size of the file data. In the embodiment of the present application, the quantity threshold can be 2, and the electronic device can execute the subsequent steps when the quantity of the newly added data stream is greater than 2.

[0084] It should be noted that in the embodiment of the present application, the quantity of the data stream that meets the conditions of the same application program name, the same remote address, the TCP protocol type, and the preset remote port in the plurality of newly added data streams is greater than the quantity threshold. This is because: in actual application, there can be a scenario of transmitting multiple file data in a short time, for example, file 1 and file 2. File 1 and file 2 are small file data, and after determination, it can be determined that the quantity of the data stream of file 1 and file 2 is less than the quantity threshold, and the electronic device no longer executes the subsequent steps, and the electronic device transmits file 1 and file 2 using a single channel. In this way, the above-mentioned preset condition 1, the quantity threshold and the preset time can be used to exclude this interference scenario.

[0085] The determination process of the data stream will be described below with reference to an example. The communication information of the data stream can be, for example:

[0086] Application program 1.exe 192.168.155.200 52875 59.82.29.194 443 TCP 22924 (1)

[0087] Application program 1.exe 192.168.142.202 58530 116.132.222.131 443 TCP 6120 (2)

[0088] Application program 1.exe 192.168.155.200 58534 116.132.222.131 443 TCP 6120 (3)

[0089] Application1.exe 192.168.142.200 58535 116.132.222.131 443 TCP 6120 (4)

[0090] Application2.exe 192.168.142.202 61799 122.97.71.97 443 TCP 33984 (5)

[0091] Application2.exe 192.168.155.200 61800 122.97.71.97 443 TCP 33984 (6)

[0092] Application2.exe 192.168.142.202 61801 122.97.71.97 443 TCP 33984 (7)

[0093] The data stream (1) to the data stream (4) are data streams of an application 1. Among them, in a preset time, the remote address, the remote port and the protocol type of the data stream (2) to the data stream (4) are same, the remote port is 443 port, the protocol type is TCP, the number of data streams is greater than a number threshold, and the data stream (2) to the data stream (4) are multiple data streams of same file data. The remote address of the data stream (1) is different from that of the data stream (2), and the two data streams are not same file data.

[0094] The data stream (5) to the data stream (7) are data streams of an application 2. Among them, in a preset time, the remote address, the remote port and the protocol type of the data stream (5) to the data stream (7) are same, the remote port is 443 port, the protocol type is TCP, the number of data streams is greater than a number threshold, and the data stream (5) to the data stream (7) are multiple data streams of same file data.

[0095] It can be understood that the operation for sending or receiving file data (which can also be referred to as a trigger operation for transmitting file data) may, for example, be an operation of dragging and sending file data from another folder to a chat box in a communication application (such as WeChat, QQ, DingTalk, etc.) interface. An operation of adding and sending file data to a chat box based on a picture control and / or a document control in a communication application interface. An operation of sending a video or a document to a communication application in a gallery application or a document application interface. An operation of downloading an application installation package in a download application (such as an application store, a steam application, etc.) interface. An operation of uploading or downloading a file in a cloud storage application (such as Baidu Netdisk, Ali Netdisk) interface, and the like. Embodiments of the present application do not enumerate them one by one.

[0096] After the data stream meets the above conditions, the electronic device can continue to perform step S403. Otherwise, the electronic device performs step S401 to continue monitoring the data stream, and the electronic device can perform step S407 to continue transmitting using a single channel.

[0097] S403, the electronic device determines whether the application name of the plurality of data streams is located in the white list.

[0098] The white list is preconfigured with application names capable of transmitting file data through multiple channels, for example, the name of a communication application, the name of a download application, and / or the name of a cloud storage application.

[0099] When the application name in the data stream can be found in the white list, the electronic device can continue to perform step S404. Otherwise, the electronic device performs step S401 to continue monitoring the data stream, and the electronic device can perform step S407 to continue transmitting using a single channel.

[0100] It should be noted that in the embodiments of the present application, the electronic device can determine whether the application name corresponding to the data stream is in the white list after monitoring the data stream, such as steps S401-S403. In another implementation manner, the electronic device can also monitor the data stream under the application in the white list, for example, the electronic device first performs step S403 and then performs step S402. The embodiments of the present application do not limit this.

[0101] S404, in the case where the application name is located in the white list, monitoring disk input / output (I / O) information.

[0102] The disk I / O information can be used to reflect the read / write situation in the disk, for example, in the case where the electronic device sends a file, the disk I / O information can reflect that the file data is currently being read from the disk; in the case where the electronic device sends a file, the disk I / O information can reflect that the file data is currently being written to the disk.

[0103] Specifically, the disk I / O information can include a read operation count (ReadOperationCount), a read byte count (Write OperationCount), a write operation count (ReadTransferCount), and a write byte count (WriteTransferCount), etc. Among them, the read operation count can be used to represent the number of times of read operation performed by the process, the write operation count can be used to represent the number of times of write operation performed by the process; the read byte count can be used to represent the number of bytes corresponding to a single read operation; and the write byte count can be used to represent the number of bytes corresponding to a single write operation.

[0104] In some embodiments, the electronic device can invoke a system API to monitor the disk I / O information. The system API can be, for example, a Windows API. The Windows API can invoke a GetProcessIoCounters function to retrieve information of I / O operations performed by a process, such as a number of read operations, a number of write operations, a number of read bytes, and / or a number of write bytes of a disk associated with the process. The process can be determined by a process identifier in the communication information of the data stream.

[0105] S405, when the disk I / O information changes and the disk I / O information satisfies a preset condition 2, obtaining transmission information of the data stream.

[0106] The transmission information of the data stream can be used to analyze characteristics of the data stream. The transmission information of the data stream can include one or more of an uplink rate, a downlink rate, a number of uplink data packets, a number of downlink data packets, a length of uplink data packets, a length of downlink data packets, and a data packet interval.

[0107] The disk I / O information changing can be understood as a number of read operations, a number of read bytes, a number of write operations, and / or a number of write bytes changing.

[0108] The preset condition 2 can be used to determine whether a size of the file data satisfies a requirement of multi-channel data transmission. For example, the preset condition 2 can be that the number of read operations and / or the number of write operations is greater than a number threshold.

[0109] Or, the number of read bytes and / or the number of write bytes is greater than a byte threshold.

[0110] Or, the number of read operations and / or the number of write operations is greater than the number threshold, and the number of read bytes and / or the number of write bytes is greater than the byte threshold.

[0111] Or, a total transmission data amount is greater than a data amount threshold. The total transmission data amount includes a read data amount and a write data amount. The read data amount is positively correlated with the number of read operations and the number of read bytes, and the write data amount is positively correlated with the number of write operations and the number of write bytes.

[0112] It can be understood that the read operand, the write operand, the read byte number, and the write byte number can be positively correlated with the size of the file data. Therefore, the preset condition 2 can determine the size of the file data by the operand, for example, in the case that the read / write byte number of a single operation is certain, the larger the file data is, the more times the process needs to perform the read / write. The preset condition 2 can determine the size of the file data by the byte number, for example, in the case that the operand is certain, the larger the file data is, the more byte number of a single read and / or write of the process is. The preset condition 2 can also be determined by the operand and the byte number together, for example, the operand needs to be greater than an operand threshold value, and the byte number needs to be greater than a byte number threshold value; or, the total transmission data amount is calculated based on the operand and the byte number, and the total transmission data amount is greater than a data amount threshold value. The embodiments of the present application do not limit this.

[0113] S406, in the case that the transmission information of the data stream satisfies a preset condition 3, the data stream is transmitted using multiple channels.

[0114] The preset condition 3 can be used to determine whether the data stream is suitable for multi-channel transmission based on the transmission information. For example, the preset condition 3 can be: in the process of sending the file data, the ratio of the downlink rate to the uplink rate is less than a ratio threshold value 1, the uplink rate is greater than a rate threshold value 1, the downlink rate is less than a rate threshold value 2, the mean square error of the uplink rate is greater than a mean square error threshold value, and in the uplink data packet, the proportion of the number of uplink data packets with a maximum transmission unit (MTU) length to the total number of uplink data packets is greater than a ratio threshold value 2. The rate threshold value 1 is greater than the rate threshold value 2.

[0115] In the process of receiving the file data, the ratio of the uplink rate to the downlink rate is less than the ratio threshold value 1, the uplink rate is less than the rate threshold value 2, the downlink rate is greater than the rate threshold value 1, the mean square error of the downlink rate is greater than the mean square error threshold value, and in the downlink data packet, the proportion of the number of downlink data packets with the MTU length to the total number of downlink data packets is greater than the ratio threshold value 2.

[0116] The transmission information of the data stream satisfies the preset condition 3, which indicates that the type of the file data (which can also be referred to as the application type) is a file transmission type and is suitable for multi-channel transmission. In addition, the type of the file data can also include: a voice over IP (VoIP) type, a video live broadcast type, a video conference type, a long video on demand type, a short video on demand type, a game type, a remote desktop type, a Web type, an online collaborative office type, etc. The correspondence between the preset condition 3 and the file data of the file transmission type will be described later, and will not be described here.

[0117] Among them, the file transmission type data can be non-real-time transmission data, which can be applicable to multi-channel transmission. The voice call (VoIP) type, video live broadcast type, video conference type, game type, remote desktop type, and online collaborative office type data are real-time transmission data, and the real-time data may have a problem scenario after the data connection is disconnected.

[0118] The long video on-demand type and short video on-demand type data also belong to non-real-time transmission data. However, for long video on-demand type and short video on-demand type data, the benefit of accelerating data transmission is not great. For example, after the user on-demand video, the electronic device can play and preload a certain amount of data; the preloaded data can ensure smooth video playback to a certain extent, so the demand for accelerating transmission of file data is small, and the embodiment of the application can not perform multi-channel processing on the on-demand type data.

[0119] In the embodiment of the application, the electronic device can use a deep / dynamic flow inspection (DFI) model to predict the type of file data. The DFI model has the ability to identify different types of file data by analyzing the behavior characteristics of the data flow. The electronic device can determine the type of file data according to the output result of the DFI model. The DFI model can be a model trained based on transmission information of sample file data and file data type corresponding to the sample file data.

[0120] After determining that the file data is of the file transmission type, the data flow can be transmitted using multi-channel.

[0121] Optionally, after step S405, it further includes:

[0122] Alternatively, S407, in a case where the transmission information of the data flow does not meet the preset condition 3, the file data continues to be transmitted using single channel.

[0123] It can be understood that after the DFI detection determines that the data flow is not file transmission type data, if the transmission of the data flow is disconnected, there may be a problem scenario, for example, if the data flow is VoIP, disconnecting the VoIP data flow will cause the video call to be interrupted. Therefore, in a case where the transmission information of the data flow does not meet the preset condition 3, the electronic device does not change the transmission channel of the data flow, and the electronic device continues to use the previous single channel to transmit it.

[0124] Optionally, in a case where the transmission information of the data flow meets the preset condition 3, the data flow is transmitted using multi-channel, which can include the following steps, as shown in FIG. 5:

[0125] S501, input the transmission information of any data flow into the DFI model to obtain an output result; the output result can include the type of file data.

[0126] The transmission information of any data stream can include uplink rate, downlink rate, uplink data packet number, downlink data packet number, uplink data packet length, downlink data packet length, and data packet interval, etc. The output result can be a file data type, or a numerical value or other identifier representing the file data type.

[0127] It should be noted that after determining that the plurality of data streams are data streams of the same file data (for example, after step S403), the attributes of the plurality of data streams are similar, and the electronic device can use any data stream in the plurality of data streams to perform subsequent steps S404-S406, so as to reduce the calculation pressure in the file data transmission process. Alternatively, in order to improve the accuracy of data detection, the electronic device can also use the plurality of data streams to perform steps S404-S406. Embodiments of the present application do not limit this.

[0128] Taking the data streams (1) to (4) newly added in a short time as examples, after processing through steps S401-S405, the electronic device can determine that the data streams (2) to (4) are data streams of the same file data, and perform DFI detection on any data stream in the data streams (2) to (4).

[0129] Alternatively, the data streams (2) to (4) can also be input into the DFI model for detection, and embodiments of the present application do not limit this.

[0130] S502, in the case where the file data type is a file transmission type, obtaining the identifiers of the plurality of data streams.

[0131] If the output result is a file transmission type, it is determined that the file data type is a file transmission type. At this time, the electronic device can obtain the identifier of the data stream based on the communication information of the input data stream. The identifier of the data stream can be a socket, for example, a combination of a local address and a local interface.

[0132] In embodiments of the present application, the data stream used for DFI detection can be any data stream in the plurality of data streams, and the plurality of data streams corresponding to the same file data of the any data stream can be obtained through the communication information of the any data stream. For example, taking the data stream (2) as an example, after determining that the data stream (2) is a file transmission type, the plurality of identifiers of “192.168.142.202 58530” (corresponding to the data stream (2)), “192.168.155.200 58534” (corresponding to the data stream (3)), and “192.168.142.200 58535” (corresponding to the data stream (4)) can be obtained.

[0133] S503, disconnect the transmission link of the data stream carrying the identifier, and split the data stream carrying the identifier.

[0134] The electronic device can cut off the transmission link of the corresponding data stream according to the identifier of the data stream, for example, cut off the transmission link of the data stream (2) according to "192.168.142.202 58530"; cut off the transmission link of the data stream (3) according to "192.168.155.200 58534"; and cut off the transmission link of the data stream (4) according to "192.168.142.200 58535".

[0135] Referring to FIG. 5, before being disconnected, the electronic device can transmit the data streams (1) to (4) based on a single channel; after being disconnected, the electronic device can continue to transmit the data stream (1) based on the single channel, and stop transmitting the data streams (2) to (4).

[0136] It can be understood that after being determined by multiple dimensions, the data streams (2) to (4) are determined to be data streams of the file transmission type, and after the transmission of the data streams of this type is disconnected, the electronic device only suspends the data transmission process of the file transmission type, and the aforementioned problem scenarios such as audio / video interruption or account exit do not occur.

[0137] In addition, the electronic device can re-allocate the data streams whose transmission links are cut off, to determine the data channels used by each data stream.

[0138] In the embodiments of the present application, after determining that the data streams need to be split, the electronic device can establish multiple channels, for example, channel 1 is electronic device 100-wireless network device 200-server 300; channel 2 is electronic device 100-electronic device 400-wireless network device 500-server 300. The electronic device maintains the connection of channel 1, and at the same time establishes the connection of channel 2.

[0139] After the connection is established, the electronic device can split the data streams based on the load condition, network resource state and the like. For example, the data stream (2) is transmitted by using channel 1, the data stream (3) and the data stream (4) are transmitted by using channel 2, as shown in FIG. 5.

[0140] In another possible implementation, since the multiple channels can include a single channel, the single channel transmits multiple data streams. The electronic device can switch part of the multiple data streams to another channel, and another part of the data streams continues to use the single channel for data transmission.

[0141] In the process, the electronic device can first allocate channels to the plurality of data streams, for example, data stream (2) is expected to be transmitted using channel 1, data stream (3) and data stream (4) are expected to be transmitted using channel 2. At this time, the electronic device can disconnect data stream (3) and data stream (4) in channel 1 and transmit data (3) and data (4) using channel 2. In the process of switching channels, the disconnection and reconnection of data stream (2) can not be involved. The embodiments of the present application do not limit this.

[0142] S504, transmitting the data stream based on the plurality of channels.

[0143] For example, in FIG. 5, after splitting, the electronic device can transmit data stream (1) and data stream (2) using channel 1, and transmit data stream (3) and data stream (4) using channel 2.

[0144] At this point, the electronic device can accurately determine the type of data stream through analysis, and perform multi-channel transmission on data streams of a specific type, thereby improving data transmission efficiency and reducing the occurrence of problem scenarios, thereby improving the user's use experience.

[0145] The preset condition 3 will be further described below in combination with Table 1. It can be understood that different types of data streams have different characteristics of transmission information when sending and receiving. For example, Table 1 shows the characteristics of transmission information of a plurality of file data provided by the embodiments of the present application, as shown in Table 1:

[0146] Table 1 Characteristics of Transmission Information of a Plurality of File Data

[0147] The file data suitable for multi-channel transmission in the embodiments of the present application can correspond to the application category of file transmission. The file data of the file transmission type, for example, satisfies the following conditions: uplink and downlink rate asymmetry, 1-2 messages of uplink (or downlink) rate, 100-300 KB of downlink (or uplink) rate, full packet length of downlink (or uplink) packet length, and unstable downlink (or uplink) rate with large fluctuations.

[0148] In the embodiments of the present application, the preset condition 3 can be used to determine whether the data stream is suitable for multi-channel transmission based on the transmission information. The preset condition 3 can correspond to the condition satisfied by the file data of the file transmission type.

[0149] Specifically, in the case where the ratio of downlink rate to uplink rate is less than a ratio threshold 1 (or the ratio of uplink rate to downlink rate is greater than the ratio threshold 1), it can be determined that the uplink and downlink rates are asymmetric. The ratio threshold 1 can be, for example, 30%.

[0150] When sending file data, the uplink rate is greater than the downlink rate, for example, the uplink rate is greater than rate threshold 1, and the downlink rate is less than rate threshold 2; rate threshold 1 may be, for example, 100 KB, and rate threshold 2 may be, for example, 2 messages. When receiving file data, the uplink rate is less than the downlink rate, for example, the downlink rate is greater than rate threshold 1, and the uplink rate is less than rate threshold 2.

[0151] When sending file data, the uplink data packet length is substantially full packet length, for example, the proportion of the number of uplink data packet lengths that are MUT is greater than proportion threshold 2; proportion threshold 2 may be, for example, 80%. When receiving file data, the downlink data packet length is substantially full packet length, for example, the proportion of the number of downlink data packet lengths that are MUT is greater than proportion threshold 2; proportion threshold 2 may be, for example, 80%.

[0152] When sending file data, the uplink rate is unstable and shows a fluctuation trend. When receiving file data, the downlink rate is unstable and shows a fluctuation trend. The fluctuation trend can be understood as: the mean square deviation between the uplink rates is greater than the mean square deviation threshold; or, the mean square deviation between the downlink rates is greater than the mean square deviation threshold.

[0153] Through the above-mentioned preset condition 3, the electronic device can distinguish file data of the file transfer type from most other types of file data.

[0154] It should be noted that for some types of file data, only through the above-mentioned conditions, the specific type of file data may not be distinguished. For example, video live streaming and remote desktop, see Table 1.

[0155] Among them, the application program name of the video live streaming type may not be included in the white list, so as to exclude the judgment interference of the file data of the video live streaming type on the file data of the file transfer type in step S403.

[0156] For the remote desktop type, the data packet interval can be used to exclude the file data. For example, the preset condition 3 can also include: the data packet interval is less than the interval threshold. Specifically, after the processing of the foregoing steps, the file data corresponding to the transmission information input into the DFI model has a large specification. For file data of the file transfer type with a large specification, in the transmission process, the data packet length is substantially full packet length, for example, 80% of the data packet length is MUT; and the density of data packet transmission is large, and the time interval between two consecutive data packets is small, less than the interval threshold. The file data of the remote desktop type has the characteristics that the uplink small data packets are sent at intervals, and the downlink full data packets are sent at intervals, and the data packet interval of the data stream of the remote desktop type is greater than the interval threshold.

[0157] It should be noted that this application embodiment uses a PC as an example for describing the data transmission method provided in this application embodiment. In this application embodiment, the electronic device 100 can also be other electronic devices, such as a mobile phone. Furthermore, in this application embodiment, multi-channel transmission is exemplified by two channels; in practical applications, more channels may be included. For example, the electronic device 400 can support cellular networks and WLAN networks. After the electronic device 100 is connected to the electronic device 400, the electronic device 400 transmits data through both the cellular network and the WLAN network, achieving three-channel transmission. As another example, the electronic device 100 can connect to multiple electronic devices 400 to achieve multi-channel transmission. This application embodiment does not impose any limitations on this.

[0158] The above embodiments illustrate the data transmission method provided in the embodiments of this application. The following describes the data transmission method provided in the embodiments of this application in further detail with reference to the software architecture of the electronic device.

[0159] Figure 6 shows a software structure block diagram of the electronic device 100 according to an embodiment of this application, taking the electronic device 100 as a PC as an example.

[0160] A layered architecture divides software into several layers, each with a clear role and function. Layers communicate with each other through software interfaces. Taking the Windows system as an example, the software structure of electronic device 100 can be divided into user mode (Windows User) and kernel mode (Windows Kernel).

[0161] User space can include the application layer (also known as the application layer) and the framework / interface layer.

[0162] The application layer may include applications such as settings applications, download applications, communication applications, cloud storage applications, and video applications. In this embodiment, applications suitable for multi-channel data transmission may include, for example, download applications, communication applications, and cloud storage applications, and the file data in these applications may be file transfer data.

[0163] The framework / interface layer provides application programming interfaces (APIs) and programming frameworks for applications in the application layer. The framework / interface layer may include awareness modules and the Windows API.

[0164] The perception module can be responsible for collecting and processing various information in the user's environment. The information can include the user's interaction behavior, system status, resource usage, etc. In the embodiments of the present application, the perception module can be used to obtain the communication information (e.g., address and port, etc.) of the data stream; the perception module can also be used to call the Windows API to obtain the disk I / O information (e.g., operation number and byte number, etc.); the perception module can also be used to obtain the transmission information (e.g., uplink and downlink rates, packet number, packet length, and data packet interval, etc.) of the data stream, so as to determine whether to split the data stream. In the embodiments of the present application, the perception module can also store a white list to monitor the data stream of the application in the white list.

[0165] The Windows API can provide system call entry and internal function support for the application. In the embodiments of the present application, the disk I / O information can be obtained by calling the Windows API.

[0166] The kernel mode can include system drivers and network drivers. The system drivers are one of the core parts of the operating system, and the system drivers interact with the hardware devices, and can be used to implement the initialization, operation, and processing of various interrupt events of the hardware. Examples of the system drivers include hard disk drivers, USB controller drivers, graphics card drivers, etc. (not shown in the figure). The network drivers can be used to manage and control the drivers of network hardware (such as network adapters), and the network drivers can implement the transmission of network data packets between physical hardware and the operating system.

[0167] The network drivers can include protocol drivers, intermediate layer drivers, and small port drivers.

[0168] The protocol drivers can be used to implement network communication protocols, and the protocol drivers can be, for example, a TCP / IP protocol stack. The protocol drivers can receive data from the application program in the upper layer, encapsulate and send out through the network, and at the same time, receive data from the network, unpack and decapsulate, so as to be used by the upper layer application program. In the embodiments of the present application, the protocol drivers can obtain the transmission information (e.g., uplink and downlink rates, packet number, packet length, and data packet interval, etc.) of the data during the transmission of the data stream.

[0169] The intermediate layer drivers are located between the protocol drivers and the small port drivers, and act as a bridge, and the intermediate layer drivers can be used to handle the specific interaction between the network protocol and the network hardware. The intermediate layer drivers can provide additional network functions, such as filtering, encryption, etc.

[0170] The small port drivers (also referred to as network interface card drivers (NIC)) are used to communicate with the network hardware, manage the hardware resources of the network interface card, and process the sending and receiving of data packets.

[0171] The electronic device can also include a hardware layer, for example, the hardware layer can include a disk.

[0172] The data transmission process in the embodiment of the present application will be described below in conjunction with FIG. 6.

[0173] Taking a download-type application as an example, referring to FIG. 6:

[0174] In the download-type application interface, an installation control corresponding to an application program can be displayed. After receiving a click operation on the installation control of any application program, the electronic device uses single-channel download file data, which can be an installation package of the application program. During the download process, the download-type application can pass communication information to the perception module of the framework layer / interface layer. The perception module determines whether the application program name of the download-type application is in the whitelist and whether the communication information meets a preset condition 1.

[0175] In the case where the preset condition 1 is met and the application program name is in the whitelist, the perception module can call Windows API to monitor disk I / O information. The Windows API can interact with the disk of the hardware layer based on the disk driver in the system driver to obtain the disk I / O information.

[0176] The perception module determines whether the disk I / O information meets a preset condition 2. In the case where the preset condition 2 is met, the perception module can obtain transmission information from the protocol driver in the kernel mode. The perception module further determines whether the type of the file data is file transmission type through the transmission information, where the transmission information of the file transmission type data can meet a preset condition 3.

[0177] After determining that the file data is of the file transmission type, the perception module can split the data stream, thereby instructing the download-type application to use multi-channel download of the installation package.

[0178] In addition, the judgment and splitting process of the communication-type application and the cloud storage-type application are similar to the process of the download-type application. For example, in the communication-type application interface, a chat box is displayed. In some embodiments, after the file data is dragged from the gallery application interface or the file management application interface to the communication-type application interface, the communication-type application can send the file data. In other embodiments, based on a trigger operation on the add picture control and / or the add document control, the file data can be added to the chat box. After clicking the send control, the communication-type application can send the file data. For another example, in the cloud storage-type application interface, upload controls and download controls corresponding to the file data are displayed. After clicking the upload control or the download control, the cloud storage-type application can send the file data to the cloud or download the file data from the cloud. The above scenarios can trigger the use of single-channel transmission of the file data. During the download process, the process of switching to multi-channel transmission.

[0179] It should be noted that the user information (including but not limited to user equipment information, user personal information, etc.) and data (including but not limited to data for analysis, stored data, displayed data, etc.) involved in the present application are all information and data authorized by the user or authorized by all parties, and the collection, use and processing of related data need to comply with relevant laws, regulations and standards of relevant countries and regions, and provide corresponding operation portal for user to choose authorization or refusal.

[0180] A data transmission method provided by an embodiment of the present application will be described below in combination with FIG. 7; as shown in FIG. 7:

[0181] S701, transmitting the data stream using the first channel.

[0182] The first channel can correspond to the channel 1 in the embodiment shown in FIG. 5.

[0183] S702, obtaining transmission information of the data stream; the transmission information includes one or more of the following: uplink rate, downlink rate, uplink data packet number, downlink data packet number, uplink data packet length and downlink data packet length.

[0184] The process can correspond to the related description in step S401.

[0185] S703, in the case that the transmission information of the data stream meets a first preset condition, transmitting the data stream using the first channel and a second channel; the first channel is different from the second channel; the first preset condition is used to determine a file transmission type data stream; the file transmission type data stream is a non-real-time transmission data stream.

[0186] The second channel can correspond to the channel 2 in the embodiment shown in FIG. 5. The first preset condition can correspond to the preset condition 3 in the embodiment of the present application.

[0187] The first preset condition includes: in the case that the uplink rate is greater than the downlink rate (sending file data), the ratio of the downlink rate to the uplink rate is less than a first threshold value (uplink and downlink rate asymmetry); the uplink rate is greater than a second threshold value, and the downlink rate is less than a third threshold value; in the uplink data packet, the proportion of the number of uplink data packets with the uplink data packet length being MTU is greater than a fourth threshold value; and the mean square error of the uplink rate is greater than a fifth threshold value (the uplink rate is unstable and fluctuates greatly).

[0188] The first threshold value can be a proportion threshold value 1, for example, 30%; the second threshold value can be a rate threshold value 1, for example, 100KB; the third threshold value can be a rate threshold value 2, for example, 2 messages. The fourth threshold value can be a proportion threshold value 2, for example, 80%; and the fifth threshold value can be a mean square error threshold value.

[0189] Alternatively, the first preset condition comprises: in a case where the downlink rate is greater than the uplink rate (for receiving file data), a ratio of the uplink rate to the downlink rate is less than a first threshold value (uplink and downlink rates are asymmetric); the downlink rate is greater than a second threshold value, and the uplink rate is less than a third threshold value; in the downlink data packet, a proportion of a quantity of downlink data packets with a length of MTU is greater than a fourth threshold value; and a mean square error of the downlink rate is greater than a fifth threshold value (the downlink rate is unstable and fluctuates greatly).

[0190] In this way, the electronic device can screen data streams suitable for multi-channel transmission, reduce the problem scenarios caused by data stream interruption in the multi-channel switching process, and improve data transmission efficiency using multi-channel transmission.

[0191] Optionally, before the data stream is transmitted using the first channel, the method comprises: in response to a trigger operation for transmitting file data, establishing a plurality of data streams, and obtaining communication information of any data stream in the plurality of data streams; wherein the communication information comprises one or more of the following: application program name, local address, local port, remote address, remote port, protocol type and process identifier; after the data stream is transmitted using the first channel, the method further comprises: determining whether the plurality of data streams are used for transmitting the same file data based on the communication information; and obtaining transmission information of the data stream, comprising: in a case where the plurality of data streams are used for transmitting the same file data, obtaining the transmission information of the data stream.

[0192] The trigger operation for transmitting file data can correspond to the operation for sending or receiving file data in step S402, or to the related operation in the embodiment shown in FIG. 6.

[0193] In this way, the electronic device can preliminarily determine the specification of the file data based on the data streams of the same file data, so as to subsequently split the large-specification file data.

[0194] Optionally, within a preset time, if the number of data streams whose communication information satisfies the second preset condition is greater than a sixth threshold value, the plurality of data streams are used for transmitting the same file data; wherein the second preset condition comprises: the application program names of the plurality of data streams are the same, the remote addresses are the same, the remote ports are all preset ports, and the protocol types are all preset protocol types.

[0195] The second preset condition can be the preset condition 1 in the embodiments of the present application. The sixth threshold value can be a quantity threshold value, for example, 2.

[0196] In this way, the electronic device can more accurately determine whether the plurality of data streams are used for transmitting the same file data.

[0197] Optionally, before obtaining the transmission information of the data stream, the method further comprises: obtaining disk I / O data corresponding to the data stream according to the process identifier of the data stream, the disk I / O data comprising one or more of: a read operation number, a write operation number, a read byte number, and a write byte number; and obtaining the transmission information of the data stream comprises: obtaining the transmission information of the data stream in a case where the disk I / O data satisfies a third preset condition.

[0198] The third preset condition can be the preset condition 2 in the embodiments of the present application.

[0199] In this way, the electronic device can determine the specification of the file data based on the disk I / O data, and determine the file data splitting timing when the disk I / O data changes.

[0200] Optionally, the third preset condition comprises: the read operation number being greater than a seventh threshold value, and / or the read byte number being greater than an eighth threshold value; or, the third preset condition comprises: the write operation number being greater than the seventh threshold value, and / or the write byte number being greater than the eighth threshold value; or, the third preset condition comprises: the read data amount being greater than a ninth threshold value, or the write data amount being greater than the ninth threshold value; the read data amount being positively correlated with the read operation number and the read byte number respectively, and the write data amount being positively correlated with the write operation number and the write byte number respectively.

[0201] The seventh threshold value can be an operation number threshold value, the eighth threshold value can be a byte number threshold value, and the ninth threshold value can be a data amount threshold value.

[0202] In this way, the electronic device can determine the specification of the file data based on the disk I / O data, and determine the file data splitting timing when the disk I / O data changes.

[0203] Optionally, the electronic device stores a white list, the white list comprising preset application program names, and after obtaining the communication information of any data stream in the plurality of data streams, the method further comprises: searching for the application program name of the data stream in the white list; and obtaining the transmission information of the data stream further comprises: obtaining the transmission information of the data stream in a case where the application program name is included in the white list.

[0204] The preset application program names can be, for example, names of preset communication applications, names of preset download applications, and / or names of preset cloud storage applications.

[0205] In this way, the white list can be used to filter out data that is not suitable for multi-channel transmission at the application level, thereby improving the accuracy of determining file transmission data; for example, data of a video live broadcast type is similar to data of a file transmission type, and the data of the video live broadcast type can be filtered out by the white list.

[0206] Optionally, in a case where the transmission information of the data stream satisfies a first preset condition, the data stream is transmitted using the first channel and the second channel, including: inputting the transmission information of the data stream into a deep / dynamic flow inspection (DFI) model to obtain a type of the data stream; in a case where the type of the data stream is a file transmission type, outputting an identifier of the data stream; the identifier of the data stream includes a local address and a local port; stopping using the first channel to transmit the data stream according to the identifier of the data stream; and after the data stream is split, transmitting the data stream using the first channel and the second channel.

[0207] The process can correspond to the embodiment shown in FIG. 5.

[0208] In this way, the electronic device can use multiple channels to transmit file data, improving the efficiency of data transmission.

[0209] Optionally, the preset port includes a 443 port or an 80 port, and the preset protocol type is a TCP protocol.

[0210] Optionally, the application program related to the file transmission type includes one or more of the following: a communication application, a cloud storage application, and a download application.

[0211] The data transmission method of the embodiments of the present application has been described above, and the device provided by the embodiments of the present application for executing the above data transmission method will be described below. Those skilled in the art can understand that the method and the device can be combined and referenced with each other, and the related device provided by the embodiments of the present application can execute the steps in the above data transmission method.

[0212] As shown in FIG. 8, the data transmission device 800 can be used in a communication device, a circuit, a hardware component, or a chip, and the data transmission device includes a display unit 801 and a processing unit 802. The display unit 801 is configured to support the display steps performed by the data transmission device 800. The processing unit 802 is configured to support the information processing steps performed by the data transmission device 800.

[0213] In a possible implementation, the data transmission device 800 can also include a communication unit 803. Specifically, the communication unit is configured to support the steps of transmitting and receiving data performed by the data transmission device 800. The communication unit 803 can be an input or output interface, a pin, or a circuit, etc.

[0214] In a possible implementation, the data transmission apparatus can further include a storage unit 804. The processing unit 802 and the storage unit 804 are connected through a line. The storage unit 804 can include one or more memories, and the memory can be a device for storing programs or data in one or more devices or circuits. The storage unit 804 can exist independently and be connected to the processing unit 802 of the data transmission apparatus through a communication line. The storage unit 804 can also be integrated with the processing unit 802.

[0215] The storage unit 804 can store computer execution instructions of the method in the terminal device, so that the processing unit 802 executes the method in the above embodiments. The storage unit 804 can be a register, a cache or a RAM, and the storage unit 804 can be integrated with the processing unit 802. The storage unit 804 can be a read-only memory (ROM) or other types of static storage devices that can store static information and instructions, and the storage unit 804 can be independent of the processing unit 802.

[0216] The data transmission method provided by the embodiments of the present application can be applied to an electronic device with a communication function. The electronic device includes an electronic device, and the specific device form of the electronic device can refer to the related description above, which will not be described here.

[0217] The embodiments of the present application provide an electronic device, which includes: a processor and a memory; the memory stores computer execution instructions; and the processor executes the computer execution instructions stored in the memory, so that the electronic device executes the above method.

[0218] The embodiments of the present application also provide a chip system, which includes at least one processor and a communication interface. The communication interface and the at least one processor are interconnected through a line. The at least one processor is used to run a computer program or instructions to execute the above method. The implementation principle and technical effects are similar to those of the above related embodiments, which will not be described here.

[0219] The embodiments of the present application also provide a computer readable storage medium. The computer readable storage medium stores a computer program. The computer program is executed by a processor to implement the above method. The method described in the above embodiments can be implemented by software, hardware, firmware or any combination thereof, in whole or in part. If implemented in software, the functions can be stored as one or more instructions or codes on a computer readable medium or transmitted on a computer readable medium. The computer readable medium can include a computer storage medium and a communication medium, and can also include any medium that can transfer a computer program from one place to another. The storage medium can be any target medium that can be accessed by a computer.

[0220] In a possible implementation, the computer readable medium can include a RAM, a ROM, a compact disc read-only memory (CD-ROM) or other optical disk storage, magnetic disk storage or other magnetic storage devices, or any other medium that is suitable for storing desired program code in the form of instructions or data structures and that can be accessed by a computer. Also, any connection is properly termed a computer readable medium. For example, if the software is transmitted from a website, server, or other remote source using a coaxial cable, fiber optic cable, twisted pair, digital subscriber line (DSL), or wireless technologies such as infrared, radio, and microwave, then the coaxial cable, fiber optic cable, twisted pair, DSL, or wireless technologies such as infrared, radio, and microwave are included in the definition of medium. Disk and disc, as used herein, include compact disc (CD), laser disc, optical disc, digital versatile disc (DVD), floppy disk and Blu-ray® disc where disks usually reproduce data magnetically, while discs reproduce data optically with lasers. Combinations of the above should also be included within the scope of computer readable media.

[0221] The embodiment of the present application provides a computer program product, which comprises a computer program, and when the computer program is executed, the computer executes the above method.

[0222] The embodiment of the present application is described with reference to the flowcharts and / or block diagrams of the method, device (system), and computer program product according to the embodiment of the present application. It should be understood that each flow and / or block in the flowcharts and / or block diagrams, and the combination of the flows and / or blocks in the flowcharts and / or block diagrams can be implemented by computer program instructions. These computer program instructions can be provided to a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing devices to produce a machine, so that the instructions executed by the computer or other programmable data processing devices produce a device for implementing the functions specified in one or more flows in the flowcharts and / or one or more blocks in the block diagrams.

[0223] The above detailed description is further detailed for the purpose of the present application, technical solutions, and beneficial effects, and it should be understood that the above is only a specific embodiment of the present application, and is not used to limit the protection scope of the present application, and any modification, equivalent replacement, improvement, etc. made on the basis of the technical solutions of the present application should be included in the protection scope of the present application.

Claims

1. A data transmission method, characterized by, The application is applied to an electronic device, comprising: transmitting a data stream using a first channel; obtaining transmission information of the data stream; the transmission information comprises one or more of the following: uplink rate, downlink rate, uplink data packet quantity, downlink data packet quantity, uplink data packet length and downlink data packet length; transmitting the data stream using the first channel and a second channel in the case that the transmission information of the data stream meets a first preset condition; the first channel is different from the second channel; the first preset condition is used to determine a file transfer type data stream; the file transfer type data stream is a non-real-time transmission data stream; wherein the first preset condition comprises: in the case that the uplink rate is greater than the downlink rate, a ratio of the downlink rate to the uplink rate is less than a first threshold value; the uplink rate is greater than a second threshold value, the downlink rate is less than a third threshold value; in the uplink data packet, a proportion of the uplink data packet length to a maximum transmission unit (MTU) is greater than a fourth threshold value; and a mean square error of the uplink rate is greater than a fifth threshold value; or, the first preset condition comprises: in the case that the downlink rate is greater than the uplink rate, a ratio of the uplink rate to the downlink rate is less than the first threshold value; the downlink rate is greater than the second threshold value, the uplink rate is less than the third threshold value; in the downlink data packet, a proportion of the downlink data packet length to the MTU is greater than the fourth threshold value; and a mean square error of the downlink rate is greater than a fifth threshold value.

2. The method of claim 1, wherein, Before the step of transmitting the data stream using the first channel, comprising: in response to a trigger operation for transmitting file data, establishing a plurality of data streams, and obtaining communication information of any data stream in the plurality of data streams; wherein the communication information comprises one or more of the following: application program name, local address, local port, remote address, remote port, protocol type and process identifier; after the step of transmitting the data stream using the first channel, further comprising: determining whether the plurality of data streams are used to transmit the same file data based on the communication information; the step of obtaining the transmission information of the data stream, comprising: in the case that the plurality of data streams are used to transmit the same file data, obtaining the transmission information of the data stream.

3. The method of claim 2, wherein, within a preset time, if the number of data streams meeting a second preset condition is greater than a sixth threshold value, the plurality of data streams are used to transmit the same file data; wherein the second preset condition comprises: the application program names of the plurality of data streams are the same, the remote addresses are the same, the remote ports are all preset ports, and the protocol types are all preset protocol types.

4. The method according to claim 2 or 3, characterized in that, before the step of obtaining the transmission information of the data stream, further comprising: obtaining disk I / O data corresponding to the data stream according to the process identifier of the data stream; the disk I / O data comprises one or more of the following: read operation number, write operation number, read byte number and write byte number; the step of obtaining the transmission information of the data stream, comprising: In a case where the disk I / O data meets a third preset condition, transmission information of the data stream is acquired.

5. The method of claim 4, wherein, The third preset condition includes that the read operation number is greater than a seventh threshold value, and / or the read byte number is greater than an eighth threshold value. Alternatively, the third preset condition includes that the write operation number is greater than the seventh threshold value, and / or the write byte number is greater than the eighth threshold value. Alternatively, the third preset condition includes that a read data amount is greater than a ninth threshold value, or a write data amount is greater than the ninth threshold value; the read data amount is positively correlated with the read operation number and the read byte number respectively, and the write data amount is positively correlated with the write operation number and the write byte number respectively.

6. The method according to any one of claims 2-5, characterized in that, The electronic device stores a white list, the white list including a preset application program name, and after the communication information of any data stream in the plurality of data streams is acquired, the method further includes: searching for an application program name of the data stream in the white list; The acquisition of the transmission information of the data stream further includes: in a case where the application program name is included in the white list, acquiring the transmission information of the data stream.

7. The method according to any one of claims 1 to 6, characterized in that, In a case where the transmission information of the data stream meets a first preset condition, the data stream is transmitted using the first channel and the second channel, including: inputting the transmission information of the data stream into a deep / dynamic flow detection (DFI) model to obtain a type of the data stream; in a case where the type of the data stream is the file transmission type, outputting an identifier of the data stream; the identifier of the data stream including a local address and a local port; stopping using the first channel to transmit the data stream according to the identifier of the data stream; after the data stream is shunted, the data stream is transmitted using the first channel and the second channel.

8. The method according to any one of claims 1 to 7, characterized in that, The preset port includes a 443 port or an 80 port, and the preset protocol type is a TCP protocol.

9. The method according to any one of claims 1 to 8, characterized in that, The application program related to the data of the file transmission type includes one or more of the following: a communication application, a cloud storage application, and a download application.

10. An electronic device, comprising: including: a processor and a memory; the memory stores computer execution instructions; the processor executes the computer execution instructions stored in the memory, so that the electronic device executes the method of any one of claims 1-9.

11. A computer-readable storage medium storing a computer program, wherein the computer program comprises the following steps of: The computer program is executed by the processor to implement the method of any one of claims 1-9.

12. A chip system, characterized by including at least one processor and a communication interface, the communication interface and the at least one processor being interconnected by a line, the at least one processor being used to run a computer program or instructions to execute the method of any one of claims 1-9.

13. A computer program product, characterised in that, including a computer program, when the computer program is run, so that the computer executes the method of any one of claims 1-9.

Citation Information

Patent Citations

  • Data transmission method and equipment

    CN115250453A

  • File transmission method and device, storage medium and electronic equipment

    CN116233937A

  • Dual-channel data transmission method and device and storage medium

    CN116582942A

  • Network channel control method and electronic equipment

    CN118368699A

  • Data transmission method and electronic device

    WO2021057429A1