Information processing method and device, electronic equipment and computer readable storage medium
By searching and assigning tasks to near-field communicable devices for parallel processing, the energy consumption and overuse of resources of AI devices during terminal calculations is solved, and the inference computing speed and device life are improved.
Patent Information
- Application Number
- CN202411170872.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-23
- Publication Date
- 2024-12-06
AI Technical Summary
When AI devices are computed on the side, excessive energy consumption will lead to excessive heating of equipment and excessive battery consumption, which will affect service life. The excessive use of single device resources will lead to slow inference calculation speed, which is prone to lag problems.
By receiving task processing data, searching for near-field communication devices, determining and allocating operator subtasks to multiple connected devices to perform, aggregating their subtask data to obtain processing results, realizing parallel processing of multiple devices, and reducing the load of single devices.
It improves the inference calculation speed of complex end computing, makes full use of multi-device resources, reduces equipment heating and lag, and extends the service life of the equipment.
Smart Images

Figure CN119088555A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of computers, specifically to technical fields such as large models, deep learning, image processing, natural language processing, and more particularly to an information processing method and device, an electronic device, a computer-readable storage medium, and a computer program product. Background Art
[0002] Devices with AI (Artificial Intelligence) products consume a lot of energy when performing end-to-end computing. Users often report that the devices overheat and even over-consume batteries, which also affects the service life of the devices. Summary of the invention
[0003] The present disclosure provides an information processing method and apparatus, an electronic device, a computer-readable storage medium, and a computer program product.
[0004] According to a first aspect, an information processing method is provided, the method comprising: searching for at least one communicative device in the near field based on received task processing data; determining at least one connected device based on the at least one communicative device and the task processing data; determining an operator subtask of at least one connected device based on the task processing data; sending corresponding operator subtasks to each connected device; receiving and aggregating subtask data sent by at least one connected device to obtain a processing result of the task processing data.
[0005] According to a second aspect, an information processing device is provided, which includes: a search unit, configured to search for at least one communicative device in the near field based on received task processing data; a device determination unit, configured to determine at least one connected device based on at least one communicative device and the task processing data; a task determination unit, configured to determine an operator subtask of at least one connected device based on the task processing data; a sending unit, configured to send corresponding operator subtasks to each connected device; and an aggregation unit, configured to receive and aggregate subtask data sent by at least one connected device to obtain a processing result of the task processing data.
[0006] According to a third aspect, an electronic device is provided, comprising: at least one processor; and a memory communicatively connected to the at least one processor, wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the method described in any implementation manner of the first aspect.
[0007] According to a fourth aspect, a non-transitory computer-readable storage medium storing computer instructions is provided, where the computer instructions are used to cause a computer to execute the method described in any implementation of the first aspect.
[0008] According to a fifth aspect, a computer program product is provided, comprising a computer program, which implements the method described in any implementation manner of the first aspect when executed by a processor.
[0009] The information processing method and device provided by the embodiments of the present disclosure firstly searches for at least one communicative device in the near field based on the received task processing data; secondly, determines at least one connected device based on the at least one communicative device and the task processing data; thirdly, determines the operator subtask of at least one connected device based on the task processing data; then, sends the corresponding operator subtask to each connected device, and finally, receives and aggregates the subtask data sent by at least one connected device to obtain the processing result of the task processing data. Thus, after receiving the task processing data, searching for communicative devices, selecting connected devices from the communicative devices, executing the operator subtask of the task processing data through the connected devices, and then aggregating the subtask data of the connected devices, multiple devices can execute the task of task processing data in parallel, thereby improving the speed of inference calculation under complex end calculation, making full use of multi-device resources, reducing the excessive use of single device resources, and avoiding problems such as device heating and freezing.
[0010] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0011] The accompanying drawings are used to better understand the present solution and do not constitute a limitation of the present disclosure.
[0012] Figure 1 is a flow chart of an embodiment of an information processing method according to the present disclosure;
[0013] Figure 2 It is a schematic diagram of a structure of communication between two devices disclosed in the present invention;
[0014] Figure 3 is a flow chart of another embodiment of the information processing method according to the present disclosure;
[0015] Figure 4 is a schematic structural diagram of an embodiment of an information processing device according to the present disclosure;
[0016] Figure 5 The block diagram is a block diagram of an electronic device for implementing the information processing method according to an embodiment of the present disclosure. DETAILED DESCRIPTION
[0017] The following is a description of exemplary embodiments of the present disclosure in conjunction with the accompanying drawings, including various details of the embodiments of the present disclosure to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be recognized by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present disclosure. Similarly, for the sake of clarity and conciseness, descriptions of well-known functions and structures are omitted in the following description.
[0018] For AI products or other products with end computing scenarios, the information processing process is as follows: the user triggers the inference engine to work in the application, such as turning on smart scanning, traffic distribution, etc. The application is handed over to the inference engine for inference according to the user scenario. The inference engine generates operators based on the previously generated inference tasks. The inference engine gives each operator to different vertical inference models, and different models perform inference calculations on each operator. The inference engine merges and processes the calculation results of multiple subtasks, i.e. operators, to generate the final calculation results. The aggregated results will be fed back to different business parties. This type of single system has limited resources, concurrent inference and calculation tasks, and high-load transmission can easily cause the device to heat up.
[0019] In view of the defects in the prior art, the present invention proposes an information processing method. Figure 1 A process 100 according to an embodiment of the information processing method of the present disclosure is shown. The information processing method comprises the following steps:
[0020] Step 101: Search for at least one communicative device in the near field based on the received task processing data.
[0021] In this embodiment, the execution subject on which the information processing method runs may be a terminal device, and the terminal device may be Figure 2 As shown in the device A, optionally, the execution subject on which the information processing method runs may also be a server.
[0022] In this embodiment, the task processing data is the data of the user's tasks to be executed. When the execution subject is a terminal device, the task processing data is the end computing scenario data submitted by the user in the application. The end computing scenario data can be algorithm data involving AI capabilities on the terminal. The algorithm data can be image processing data, such as face recognition, text recognition, document recognition, video summary extraction, etc.; the algorithm data can also be text processing data, such as natural language processing.
[0023] In this embodiment, the near-field communicative device is a terminal device that is relatively close to the execution subject. The near-field communicative device has near-field communication capability and can perform near-field communication. After receiving the task processing data, in order not to overload the reasoning and calculation pressure of the execution subject on which the information processing method runs, some near-field communication means can be used to search for near-field communicative devices. Among them, the near-field communicative device has the same near-field communication protocol as the execution subject.
[0024] In this embodiment, the above step 101 includes: receiving task processing data; detecting the computational amount corresponding to the task processing data; in response to the computational amount being greater than a computational amount threshold, searching for at least one communicative device in the near field. In response to the computational amount being less than the computational amount threshold, executing the task related to the task processing data through the execution subject.
[0025] In the technical solution disclosed in this disclosure, the collection, storage, use, processing, transmission, provision and disclosure of task processing data are carried out after authorization and in compliance with relevant laws and regulations. The information related to the user in the task processing data is obtained after the user's permission, and the processing of information related to the user is carried out under confidentiality conditions.
[0026] Step 102: determining at least one connected device based on at least one communicative device and task processing data.
[0027] In this embodiment, the communicative device is only a device that can communicate with the execution subject, and the connected device is a communicative device among the communicative devices that meets the task processing requirements. In order to process the task processing data, it is necessary to select a connected device that can process the task processing data from at least one communicative device.
[0028] In this embodiment, the above step 102 includes: determining the task corresponding to the task processing data; sending an inquiry request related to the task to at least one communicative device; and determining at least one connected device based on the reply information replied by at least one communicative device. The inquiry request is used to determine whether at least one communicative device can process the above task, and the reply information indicates whether the communicative device can process the above task.
[0029] Step 103: Determine an operator subtask of at least one connected device based on the task processing data.
[0030] In this embodiment, the operator subtask is an operator-level task, and the operator is a mapping from a function space to a function space; in a broad sense, any operation on any function can be considered an operator. The operator involved in this disclosure can be a calculation function involved in the network model or the calculation logic in the corresponding layer, for example: the convolution algorithm in the convolution layer is an operator; the weight summation process in the fully-connected layer (FClayer) is also an operator. This disclosure sets an operator calculation as an independent task, which allows each connected device to refine the task corresponding to the task processing data.
[0031] In this embodiment, the task corresponding to the processing task processing data includes multiple operator subtasks, and based on the types of operator subtasks that can be processed by the connected device, the multiple operator subtasks are respectively assigned to each connected device corresponding to at least one connected device. Specifically, if the connected device is a terminal for image recognition, the corresponding image recognition operator subtask is assigned to the connected device.
[0032] In this embodiment, the plurality of operator subtasks corresponding to the task processing data may be only for the connected device. Optionally, the plurality of operator subtasks may also include operator subtasks executed by the execution subject itself.
[0033] like Figure 2 As shown in Figure 1, device A receives the task processing data and starts to infer the subtasks assigned to itself and at least one connected device operator. Device B is the connected device and other devices ( Figure 2 ) simultaneously starts to acquire and infer its assigned operator subtasks.
[0034] Step 104: Send the corresponding operator subtask to each connected device.
[0035] In this embodiment, it is possible to directly communicate with each connected device through the near-end communication protocol, thereby sending an operator subtask to each connected device, and each connected device executes its own operator subtask to obtain subtask data of its own operator subtask, wherein the subtask data is the task result data obtained after the operator subtask is executed. For example, if the operator subtask is a test paper algorithm, then the subtask data is the result data obtained after the test paper algorithm is inferred.
[0036] In order to ensure the reliability of the execution of the operator subtask, the above method also includes: establishing a long connection with each connected device, sending an operator subtask execution request to each connected device; in response to obtaining confirmation information returned by all connected devices in at least one connected device, sending the corresponding operator subtask to each connected device. The operator subtask execution request is a request for the connected device to execute the operator subtask, and when the connected device can execute the operator subtask, the confirmation information is returned to the execution subject.
[0037] Step 105: Receive and aggregate subtask data sent by at least one connected device to obtain a processing result of the task processing data.
[0038] In this embodiment, at least one connected device refers to all communicative devices that can process tasks corresponding to task processing data. When at least one connected device completes executing its own operator subtask, it obtains its own subtask data.
[0039] In this embodiment, the processing result of the task processing data is the result obtained by executing the task corresponding to the task processing data. For example, if the task corresponding to the task processing data is a face recognition task, the processing result of the task processing data is the face recognition result obtained after performing face recognition on the image, and the face recognition result is used to indicate whether there is a face in the image. After receiving all subtask data of at least one connected device, the execution subject on which the information processing method runs can aggregate the subtask data of the operator subtask according to the division order when dividing the operator subtasks to obtain the processing result of the task processing data.
[0040] Optionally, the above step 105 also includes: determining the task logical order of the operator subtask corresponding to the task processing data; receiving subtask data sent by at least one connected device, calculating the subtask data of the operator subtask according to the task logical order, and obtaining the processing result of the task processing data.
[0041] In this embodiment, Figure 2 As shown in the figure, device A and device B use near field communication to transmit subtask data. After device B completes its operator subtask by reasoning, it broadcasts or directly transmits the subtask data to device A through the near field communication protocol. After device A receives the subtask data calculated by reasoning, it receives and confirms the data to ensure data integrity and sequence. After receiving all the reasoning subtask data, device A can also combine the subtask data into the processing result of the complete task processing data according to the predetermined order and position, that is, Figure 2 The step of aggregating subtask data in .
[0042] Optionally, device A may also send processing results to an application operated by the user. The application confirms through the processing results that the reasoning and combination of all devices are complete, verifies the integrity of the processing results, and displays the processing results to the user when the processing results are complete.
[0043] The information processing method provided by the embodiment of the present disclosure first searches for at least one communicative device in the near field based on the received task processing data; secondly, determines at least one connected device based on the at least one communicative device and the task processing data; thirdly, determines the operator subtask of at least one connected device based on the task processing data; then, sends the corresponding operator subtask to each connected device, and finally, receives and aggregates the subtask data sent by at least one connected device to obtain the processing result of the task processing data. Thus, after receiving the task processing data, searching for communicative devices, selecting connected devices from the communicative devices, executing the operator subtask of the task processing data through the connected devices, and then aggregating the subtask data of the connected devices, multiple devices can execute the task of task processing data in parallel, thereby improving the speed of inference calculation under complex end calculation, making full use of multi-device resources, reducing the excessive use of single device resources, and avoiding problems such as device heating and freezing.
[0044] In some optional implementations of the present disclosure, the above-mentioned determining at least one connected device based on at least one communicative device and task processing data includes: sending a performance and status acquisition request to at least one communicative device; receiving status data and performance data sent by at least one communicative device; and determining at least one connected device based on the status data, performance data and task processing data.
[0045] In this optional implementation, the above-mentioned performance and status acquisition request is a request for acquiring performance data and status data sent to the communicative device, and the status data and performance data of the communicative device can be directly obtained through the performance and status acquisition request.
[0046] In this optional implementation, performance data refers to the performance of the communicative device under specific conditions, including efficiency, capability, reliability, stability, etc., including the number of CPU cores and supported inference computing algorithms. Status data refers to the actual operating status of the communicative device at the current moment, including: CPU operating rate, current power value, and current available storage space.
[0047] In this optional implementation, when the task processing data has requirements for both performance data and status data of the communicative device, only a communicative device whose performance data and status data meet the requirements of the task processing data can be selected from at least one communicative device as the connected device.
[0048] The method for determining the connected device provided by this optional implementation, the status data and performance data of the communicative device, reflect the current status of the communicative device, and select at least one connected device that meets the task processing data through the status data and performance data of at least one communicative device, thereby improving the reliability of the connected device.
[0049] Optionally, for task processing data that only requires device performance data, the above-mentioned determining at least one connected device based on at least one communicative device and the task processing data includes: sending a performance acquisition request to at least one communicative device; receiving performance data sent by at least one communicative device; and determining at least one connected device based on the performance data and the task processing data.
[0050] Optionally, for task processing data that only requires device status data, the above-mentioned determining at least one connected device based on at least one communicative device and the task processing data includes: sending a status acquisition request to at least one communicative device; receiving status data sent by at least one communicative device; and determining at least one connected device based on the status data and the task processing data.
[0051] In some optional implementations of the present disclosure, the above-mentioned performance data includes: the number of CPU cores and supported reasoning algorithms; the status data includes: power data and storage space. Based on the status data, performance data and task processing data, determining at least one connected device includes: in response to the power data of the communicative device satisfying a preset power condition and the storage space being greater than a preset space value, detecting whether there is a communicative device in the communicative device whose number of CPU cores and supported reasoning algorithms match the task processing data; in response to the number of CPU cores and supported reasoning algorithms of a communicative device matching the task processing data, using the communicative device that matches the task processing data as a connected device.
[0052] In this optional implementation, the power condition matches the power data. When the power data is the remaining power of the battery or the charge and discharge state, the power condition is that the power data is greater than the preset remaining power. The preset remaining power can be set based on development requirements. Generally, the remaining power is related to the calculation time of the operator subtask. For example, it is 60%.
[0053] In this optional implementation, the preset space value can be set based on development requirements. Generally, the preset space value is related to the computational amount of the operator subtask.
[0054] In this optional implementation, the supportable inference algorithm is an algorithm that can be supported by the communicative device, for example, a convolution algorithm. The number of CPU cores is the number of cores in a central processing unit.
[0055] In this optional implementation, the number of CPU cores and the supported reasoning algorithms of the communicative device match the task processing data, which means that the number of CPU cores of the communicative device supports the tasks corresponding to the task processing data, and the reasoning algorithms supported by the communicative device can calculate the tasks corresponding to the task processing data.
[0056] The method for determining at least one connected device provided by this optional implementation method, when a communicative device that meets the status requirements is detected through power data and storage space, the communicative device whose performance data meets the requirements is screened out from the communicative devices through the number of CPU cores and supported inference algorithms, and the communicative device is used as the connected device, thereby providing a reliable implementation method for obtaining the connected device.
[0057] In some optional implementations of the present disclosure, the above-mentioned search for at least one communicative device in the near field based on the received task processing data includes: in response to receiving the task processing data submitted by the user in the application, controlling the near field communication component to search for nearby devices; in response to obtaining the search result of the near field communication component, using the search result as at least one communicative device in the near field.
[0058] In this optional implementation, the near field communication component is a component installed on the execution entity on which the information processing method runs, which can communicate with near-field communicative devices. The information sent by the near field communication component to surrounding devices complies with the near field communication protocol, and the information can be obtained by communicative devices that also comply with the protocol.
[0059] In this optional implementation, the near field communication component can be a Bluetooth module or a WIFI module. Using a Bluetooth module or a WIFI module for end-to-end reasoning calculation does not rely on an Internet connection, is suitable for environments without a network or an unstable network, and is more flexible and reliable than some existing products that require an Internet connection.
[0060] The method for searching for communicative devices provided by this optional implementation manner controls the near-field communication component to search for nearby devices in response to receiving task processing data submitted by the user in an application; in response to obtaining the search results of the near-field communication component, the search results are used as at least one communicative device in the near field, thereby providing a reliable implementation manner for effectively obtaining communicative devices.
[0061] Optionally, the above-mentioned search for at least one communicative device in the near field based on the received task processing data includes: in response to receiving the task processing data, sending real-time positioning information reflecting the current position to the server, so that the server feeds back at least one communicative device in the near field based on the positioning information; and receiving at least one communicative device fed back by the server.
[0062] In some optional implementations of the present disclosure, the above-mentioned determining an operator subtask of at least one connected device based on task processing data includes: determining at least two operator subtasks and a model adapted for each of the at least two operator subtasks based on the task processing data; and determining an operator subtask of at least one connected device based on the model adapted for each operator subtask.
[0063] In this optional implementation, based on the task processing data, the task corresponding to the task processing data can be determined; based on the basic information of the operator, the task is divided into at least operator subtasks. Since the implementation of the operator subtask has a corresponding model, the model adapted to each operator subtask can be determined.
[0064] In this optional implementation, the model adapted to each operator subtask refers to a model that can execute the operator subtask. When a model adapted to the operator subtask is running on the connected device, the operator subtask that can be assigned to the connected device can be directly determined through the model.
[0065] The method for determining operator subtasks provided by this optional implementation first determines at least two operator subtasks and models adapted to each operator subtask based on task processing data; secondly, based on the models adapted to each operator subtask, determines at least one operator subtask of a connected device, thereby providing a reliable implementation method for obtaining the operator subtasks of the connected device.
[0066] Optionally, the above-mentioned determining an operator subtask of at least one connected device based on the task processing data includes: determining at least two operator subtasks and algorithms of each of the at least two operator subtasks based on the task processing data; and determining an operator subtask of at least one connected device based on the algorithms of each operator subtask.
[0067] In some optional implementations of the present disclosure, the above-mentioned receiving and aggregating sub-task data sent by at least one connected device to obtain the processing result of the task processing data includes: determining the execution order of each connected device in at least one connected device based on the task processing data; receiving sub-task data broadcast or directly transmitted by at least one connected device via a near field communication protocol; and aggregating the received sub-task data according to the execution order to obtain the processing result of the task processing data.
[0068] In this optional implementation, the above-mentioned execution order refers to the execution order of each connected device in all operator subtasks corresponding to the task processing data. Some operator subtasks need to be executed first and their execution order is earlier. Some operator subtasks do not need to be executed first and their execution order is later.
[0069] In this optional implementation, the above-mentioned aggregating the received subtask data in the execution order to obtain the processing result of the task processing data includes: combining the subtask data of different operator subtasks in sequence according to the execution order of each operator subtask to obtain the processing result of the task processing data.
[0070] The method for obtaining the processing results of task processing data provided by this optional implementation determines the execution order of each operator subtask, aggregates the received subtask data based on the execution order, and obtains the processing results of the task processing data, providing a reliable implementation method for obtaining the processing results of the task processing data.
[0071] Figure 3 A process 300 according to an embodiment of the information processing method of the present disclosure is shown. The information processing method includes the following steps:
[0072] Step 301: Search for at least one communicative device in the near field based on the received task processing data.
[0073] Step 302: Determine at least one connected device based on at least one communicative device and task processing data.
[0074] Step 303: Determine an operator subtask of at least one connected device based on the task processing data.
[0075] Step 304: Send the corresponding operator subtask to each connected device.
[0076] Step 305: Send first connection information to each connected device in at least one connected device at intervals of a preset time.
[0077] In this embodiment, the preset duration can be set based on communication requirements, for example, the preset duration is 30 seconds.
[0078] In this embodiment, the first connection information is information for detecting whether the connected device is online. The first connection information has a fixed information format. The fixed information format may be a format agreed upon in advance between the execution subject and all surrounding devices. When the execution subject is a device, the fixed information format may be information that complies with the near field communication protocol. When the execution subject sends the first connection information to any device, the devices surrounding the execution subject determine that the execution subject needs to inquire about its own online status.
[0079] Step 306: Based on the reply information of each connected device to the first connection information, detect whether at least one connected device is in an online state.
[0080] In this embodiment, the reply information to the first connection information is the response information of the connected device to the first connection information. The reply information to the first connection information can be used to indicate whether the connected device is in an online state. When the connected device is in an online state, the reply information to the first connection information directly returned to the execution entity indicates the online state; otherwise, there will be no feedback, and the reply information is empty.
[0081] In this embodiment, the online state is a state in which the connected device can communicate with the execution subject in real time, that is, the connected device and the execution subject are in the same network, and the execution subject can send information to the connected device at any time, and can also get information from the connected device at any time.
[0082] In this embodiment, whether the connected device is online can be detected based on the content of the reply information, that is, when the content of the reply information is not empty, it is determined that the connected device is online; when the content of the reply information is empty, it is determined that the connected device is not online.
[0083] Step 307: In response to detecting that at least one connecting device is in an online state, second connection information is sent to each connected device.
[0084] In this embodiment, the second connection information is information for detecting whether the connected device is in an inference state. The second connection information has a fixed information format. The fixed information format may be a format pre-agreed between the execution subject and all surrounding devices. When the execution subject is a device, the fixed information format may be information that complies with a near field communication protocol. When the execution subject sends the second connection information to any device, the devices surrounding the execution subject determine that the execution subject needs to inquire about the current inference state.
[0085] In this embodiment, the inference state is the state in which the connected device is executing an operator subtask. When the connected device is calculating an operator subtask, the connected device is in the inference state. It should be noted that the second connection information is also information sent at a preset interval and is sent only when it is determined that the connected device is in an online state.
[0086] Step 308: Based on the reply information of each connected device to the second connection information, detect whether at least one connected device is in the inference state.
[0087] In this embodiment, the reply information to the second connection information is the response information of the connected device to the second connection information. The reply information to the second connection information can be used to characterize whether the connected device is in an inference state. When the connected device is in an operator subtask, the reply information to the second connection information directly returned to the execution subject is characterized as being in an inference state; otherwise, the reply information to the second connection information returned is characterized as not being in an inference state.
[0088] Step 309, in response to detecting that at least one connected device is in an inference state, receiving and aggregating subtask data sent by at least one connected device to obtain a processing result of the task processing data.
[0089] In this embodiment, it should be understood that the operations and features in the above steps 301 to 304 and step 309 correspond to the operations and features in steps 101 to 105, respectively. Therefore, the above descriptions of the operations and features in steps 101 to 105 are also applicable to steps 301 to 304 and step 309 and will not be repeated here.
[0090] The information processing method provided in this embodiment sends first connection information to each connected device through a near field communication protocol at a preset time interval before receiving and aggregating subtask data sent by at least one connected device, and detects whether all connected devices in at least one connected device are in an online state through the first connection information; when all connected devices are in an online state, sends second connection information to each connected device to detect whether each connected device is in an inference state through the second connection information; when all connected devices in at least one connected device are in an inference state, receives and aggregates subtask data sent by at least one connected device, thereby monitoring the working status of at least one connected device in real time, providing a reliable guarantee for obtaining the processing results of task processing data.
[0091] In some embodiments of the present disclosure, the above-mentioned information processing method also includes: in response to detecting that any connected device is not in an online state or an inference state, detecting whether there is an idle connected device; in response to detecting that there is an idle connected device, sending the operator subtask of the connected device to the idle connected device.
[0092] In this optional implementation, when determining the connected devices, the execution subject can, in addition to executing the operator subtasks of the task processing data, also control some connected devices to execute empty tasks. At this time, the connected devices executing the empty tasks are idle devices. When it is detected that any connected device executing the operator subtask is not in an online state or an inference state, it is detected whether there are idle connected devices; in response to detecting that there are idle connected devices, the operator subtask of the connected device is sent to the idle connected device.
[0093] The information processing method provided by the embodiments of the present disclosure detects whether there is an idle connected device when it is detected that a connected device is not in an online state or an inference state. When there is an idle connected device, the operator subtask of the connected device that is not in an online state or an inference state is sent to the idle connected device, which can effectively ensure the processing of task processing data and improve the reliability of the processing results.
[0094] In some embodiments of the present disclosure, the above method further includes: in response to not detecting an idle connected device, processing an operator subtask of the connected device.
[0095] In this optional implementation, when the execution subject on which the information processing method runs does not detect an idle connected device, the operator subtask of the connected device is directly processed, which can ensure the effective execution of the operator subtask.
[0096] The information processing method provided in this embodiment directly processes the operator subtask of the connected device when no idle connected device is detected, which can effectively ensure the processing of task processing data and improve the reliability of the processing results.
[0097] Optionally, the above method also includes: in response to not detecting an idle connected device, continuing to search for communicative devices, determining a device that can execute the operator subtask of the connected device from the searched communicative devices, and executing the operator subtask of the connected device through the device.
[0098] Further references Figure 4 As an implementation of the methods shown in the above figures, the present disclosure provides an embodiment of an information processing device, which is similar to Figure 1 Corresponding to the method embodiment shown, the device can be specifically implemented in various electronic devices.
[0099] like Figure 4 As shown, the information processing device 400 provided in this embodiment includes: a search unit 401, a device determination unit 402, a task determination unit 403, a sending unit 404, and an aggregation unit 405. Among them, the above-mentioned search unit 401 can be configured to search for at least one communicative device in the near field based on the received task processing data. The above-mentioned device determination unit 402 can be configured to determine at least one connected device based on at least one communicative device and the task processing data. The above-mentioned task determination unit 403 can be configured to determine the operator subtask of at least one connected device based on the task processing data. The above-mentioned sending unit 404 can be configured to send the corresponding operator subtask to each connected device. The above-mentioned aggregation unit 405 can be configured to receive and aggregate the subtask data sent by at least one connected device to obtain the processing result of the task processing data.
[0100] In this embodiment, the specific processing of the search unit 401, the device determination unit 402, the task determination unit 403, the sending unit 404, and the aggregation unit 405 and the technical effects thereof can be referred to respectively. Figure 1 The relevant descriptions of step 101, step 102, step 103, step 104, and step 105 in the corresponding embodiments are not repeated here.
[0101] In some optional implementations of this embodiment, the above-mentioned device determination unit 402 is configured to: send a performance and status acquisition request to at least one communicative device; receive status data and performance data sent by at least one communicative device; and determine at least one connected device based on the status data, performance data, and task processing data.
[0102] In some optional implementations of this embodiment, the above-mentioned performance data includes: the number of CPU cores and the supported reasoning algorithms; the status data includes: power data and storage space, and the above-mentioned device determination unit 402 is configured to: in response to the power data of the communicative device satisfying the preset power condition and the storage space being greater than the preset space value, detect whether there is a communicative device in the communicative device whose CPU core number and supported reasoning algorithms match the task processing data; in response to the number of CPU cores and supported reasoning algorithms of the communicative device matching the task processing data, use the communicative device that matches the task processing data as the connected device.
[0103] In some optional implementations of this embodiment, the above-mentioned search unit 401 is configured to: in response to receiving task processing data submitted by the user in the application, control the near-field communication component to search for nearby devices; in response to obtaining the search results of the near-field communication component, use the search results as at least one communicative device in the near field.
[0104] In some optional implementations of this embodiment, the above-mentioned task determination unit 403 is configured to: determine at least two operator subtasks and models adapted to each of the at least two operator subtasks based on task processing data; and determine an operator subtask of at least one connected device based on the models adapted to each operator subtask.
[0105] In some optional implementations of this embodiment, the above-mentioned aggregation unit 405 is configured to: determine the execution order of each connected device in at least one connected device based on the task processing data; receive sub-task data broadcast or directly transmitted by at least one connected device through a near field communication protocol; and aggregate the received sub-task data according to the execution order to obtain the processing result of the task processing data.
[0106] In some optional implementations of the present embodiment, the above-mentioned device 400 also includes: a connection unit (not shown in the figure), and the above-mentioned connection unit is configured to: send a first connection information to each connected device in at least one connected device at each preset time interval; based on the reply information of each connected device to the first connection information, detect whether at least one connected device is in an online state; in response to detecting that at least one connected device is in an online state, send a second connection information to each connected device; based on the reply information of each connected device to the second connection information, detect whether at least one connected device is in an inference state; in response to detecting that at least one connected device is in an inference state, receive and aggregate subtask data sent by at least one connected device to obtain a processing result of the task processing data.
[0107] In some optional implementations of this embodiment, the above-mentioned device also includes: a detection unit (not shown in the figure); the above-mentioned detection unit is configured to: in response to detecting that any connected device is not in an online state or an inference state, detect whether there is an idle connected device; in response to detecting that there is an idle connected device, send the operator subtask of the connected device to the idle connected device.
[0108] In some optional implementations of this embodiment, the above-mentioned device also includes: a processing unit (not shown in the figure); the above-mentioned processing unit is configured to: in response to not detecting an idle connected device, process the operator subtask of the connected device.
[0109] The information processing method provided by the embodiment of the present disclosure is as follows: first, the search unit 401 searches for at least one communicative device in the near field based on the received task processing data; secondly, the device determination unit 402 determines at least one connected device based on at least one communicative device and the task processing data; thirdly, the task determination unit 403 determines the operator subtask of at least one connected device based on the task processing data; thirdly, the sending unit 404 sends the corresponding operator subtask to each connected device, and finally, the aggregation unit 405 receives and aggregates the subtask data sent by at least one connected device to obtain the processing result of the task processing data. Thus, after receiving the task processing data, searching for communicative devices, selecting connected devices from the communicative devices, executing the operator subtask of the task processing data through the connected devices, and then aggregating the subtask data of the connected devices, multiple devices can perform the task of task processing data in parallel, thereby improving the speed of inference calculation under complex end calculation, making full use of multi-device resources, reducing the excessive use of single device resources, and avoiding problems such as device heating and freezing.
[0110] In the technical solution of the present disclosure, the collection, storage, use, processing, transmission, provision and disclosure of user personal information involved are in compliance with the provisions of relevant laws and regulations and do not violate public order and good morals.
[0111] According to an embodiment of the present disclosure, the present disclosure also provides an electronic device, a readable storage medium and a computer program product.
[0112] Figure 5 A schematic block diagram of an example electronic device 500 that can be used to implement an embodiment of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present disclosure described and / or required herein.
[0113] like Figure 5 As shown, the device 500 includes a computing unit 501, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 502 or a computer program loaded from a storage unit 508 into a random access memory (RAM) 503. In the RAM 503, various programs and data required for the operation of the device 500 can also be stored. The computing unit 501, the ROM 502, and the RAM 503 are connected to each other via a bus 504. An input / output (I / O) interface 505 is also connected to the bus 504.
[0114] A number of components in the device 500 are connected to the I / O interface 505, including: an input unit 506, such as a keyboard, a mouse, etc.; an output unit 507, such as various types of displays, speakers, etc.; a storage unit 508, such as a disk, an optical disk, etc.; and a communication unit 509, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 509 allows the device 500 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.
[0115] The computing unit 501 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the computing unit 501 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, digital signal processors (DSPs), and any appropriate processors, controllers, microcontrollers, etc. The computing unit 501 performs the various methods and processes described above, such as information processing methods. For example, in some embodiments, the information processing method may be implemented as a computer software program, which is tangibly contained in a machine-readable medium, such as a storage unit 508. In some embodiments, part or all of the computer program may be loaded and / or installed on the device 500 via ROM 502 and / or communication unit 509. When the computer program is loaded into RAM 503 and executed by the computing unit 501, one or more steps of the information processing method described above may be performed. Alternatively, in other embodiments, the computing unit 501 may be configured to perform the information processing method in any other appropriate manner (e.g., by means of firmware).
[0116] Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.
[0117] The program code for implementing the method of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable information processing device, so that the program code, when executed by the processor or controller, implements the functions / operations specified in the flow chart and / or block diagram. The program code may be executed entirely on the machine, partially on the machine, partially on the machine and partially on a remote machine as a stand-alone software package, or entirely on a remote machine or server.
[0118] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0119] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).
[0120] The systems and techniques described herein may be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an information server), or a computing system that includes front-end components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communications network). Examples of communications networks include: a local area network (LAN), a wide area network (WAN), and the Internet.
[0121] A computer system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The relationship of client and server is generated by computer programs running on respective computers and having a client-server relationship with each other. The server may be a cloud server, a server of a distributed system, or a server combined with a blockchain.
[0122] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in this disclosure can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved, and this document does not limit this.
[0123] The above specific implementations do not constitute a limitation on the protection scope of the present disclosure. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present disclosure shall be included in the protection scope of the present disclosure.
Claims
1. An information processing method, the method comprising: searching for at least one communicative device in the near field based on the received task processing data; determining at least one connected device based on the at least one communicative device and the task processing data; Determining an operator subtask of the at least one connected device based on the task processing data; Send the corresponding operator subtask to each connected device; Receive and aggregate subtask data sent by the at least one connected device to obtain a processing result of the task processing data.
2. The method according to claim 1, wherein: The determining, based on the at least one communicative device and the task processing data, at least one connected device comprises: Sending a request for acquiring performance and status to the at least one communicative device; receiving status data and performance data sent by the at least one communicative device; At least one connected device is determined based on the status data, the performance data, and the task processing data.
3. The method according to claim 2, wherein: The performance data includes: the number of CPU cores and supported inference algorithms; the state data includes: power data and storage space; and the determining of at least one connected device based on the state data, the performance data and the task processing data includes: In response to the power data of the communicative device satisfying a preset power condition and the storage space being greater than a preset space value, detecting whether there is a communicative device in the communicative device whose CPU core number and supported inference algorithm both match the task processing data; In response to the fact that the number of CPU cores and the supported inference algorithm of a communicative device both match the task processing data, the communicative device matching the task processing data is used as a connected device.
4. The method according to claim 1, wherein: The step of searching for at least one communicative device in the near field based on the received task processing data comprises: In response to receiving task processing data submitted by a user in an application, controlling a near field communication component to search for nearby devices; In response to obtaining a search result of the near field communication component, the search result is used as at least one near field communicative device.
5. The method according to claim 1, wherein: The determining, based on the task processing data, an operator subtask of the at least one connected device comprises: Based on the task processing data, determining at least two operator subtasks and a model adapted for each of the at least two operator subtasks; Based on the models adapted by the respective operator subtasks, an operator subtask of the at least one connected device is determined.
6. The method according to claim 1, wherein: The receiving and aggregating the subtask data sent by the at least one connected device to obtain the processing result of the task processing data includes: determining, based on the task processing data, an execution order of each connected device in the at least one connected device; Receiving subtask data broadcasted or directly transmitted by the at least one connected device via a near field communication protocol; The received subtask data are aggregated according to the execution order to obtain the processing result of the task processing data.
7. The method according to any one of claims 1 to 6, before receiving and aggregating the subtask data sent by the at least one connected device to obtain the processing result of the task processing data, the method further comprises: Sending first connection information to each connected device in the at least one connected device at intervals of a preset duration; Based on reply information of each connected device to the first connection information, detecting whether the at least one connected device is in an online state; In response to detecting that the at least one connecting device is in an online state, sending second connection information to each connected device; Based on reply information of each connected device to the second connection information, detecting whether the at least one connected device is in an inference state; In response to detecting that at least one connected device is in an inference state, receiving and aggregating subtask data sent by the at least one connected device to obtain a processing result of the task processing data.
8. The method according to claim 7, further comprising: In response to detecting that any connected device is not in an online state or an inference state, detecting whether there is an idle connected device; In response to detecting an idle connected device, sending the operator subtask of the connected device to the idle connected device.
9. The method according to claim 8, further comprising: In response to not detecting an idle connected device, processing an operator subtask of the connected device.
10. An information processing device, comprising: A search unit configured to search for at least one communicative device in the near field based on the received task processing data; a device determining unit configured to determine at least one connected device based on the at least one communicative device and the task processing data; a task determination unit configured to determine an operator subtask of the at least one connected device based on the task processing data; A sending unit, configured to send corresponding operator subtasks to each connected device; The aggregation unit is configured to receive and aggregate the subtask data sent by the at least one connected device to obtain a processing result of the task processing data.
11. The device according to claim 10, wherein: The device determination unit is configured to: send a performance and status acquisition request to the at least one communicative device; receive status data and performance data sent by the at least one communicative device; At least one connected device is determined based on the status data, the performance data, and the task processing data.
12. The device according to claim 11, wherein The performance data includes: the number of CPU cores and the supported reasoning algorithms; the status data includes: power data and storage space, and the device determination unit is configured to: in response to the power data of the communicative device satisfying a preset power condition and the storage space being greater than a preset space value, detect whether there is a communicative device in the communicative device whose CPU core number and supported reasoning algorithms match the task processing data; in response to the number of CPU cores and supported reasoning algorithms of the communicative device matching the task processing data, use the communicative device that matches the task processing data as a connected device.
13. The device according to claim 10, wherein: The search unit is configured to: in response to receiving task processing data submitted by a user in an application, control the near field communication component to search for nearby devices; In response to obtaining a search result of the near field communication component, the search result is used as at least one near field communicative device.
14. The device according to claim 10, wherein: The task determination unit is configured to: determine at least two operator subtasks and models adapted to each of the at least two operator subtasks based on the task processing data; and determine the operator subtask of the at least one connected device based on the models adapted to each operator subtask.
15. The device according to claim 10, wherein: The aggregation unit is configured to: determine the execution order of each connected device in the at least one connected device based on the task processing data; receive subtask data broadcasted or directly transmitted by the at least one connected device through a near field communication protocol; The received subtask data are aggregated according to the execution order to obtain the processing result of the task processing data.
16. The device according to any one of claims 10 to 15, wherein: The device also includes: a connection unit, which is configured to: send first connection information to each connected device in the at least one connected device at intervals of a preset duration; detect whether the at least one connected device is in an online state based on reply information of each connected device to the first connection information; send second connection information to each connected device in response to detecting that the at least one connected device is in an online state; detect whether the at least one connected device is in an inference state based on reply information of each connected device to the second connection information; in response to detecting that the at least one connected device is in an inference state, receive and aggregate subtask data sent by the at least one connected device to obtain a processing result of the task processing data.
17. The apparatus according to claim 16, further comprising: Detection unit; The detection unit is configured to: in response to detecting that any connected device is not in an online state or an inference state, detect whether there is an idle connected device; in response to detecting that there is an idle connected device, send the operator subtask of the connected device to the idle connected device.
18. The apparatus according to claim 17, further comprising: Processing unit; The processing unit is configured to: in response to not detecting an idle connected device, process an operator subtask of the connected device.
19. An electronic device, characterized in that: include: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 9.
20. A non-transitory computer-readable storage medium storing computer instructions, characterized in that: The computer instructions are used to cause the computer to execute the method according to any one of claims 1 to 9.
21. A computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the computer program implements the method according to any one of claims 1 to 9.
