Multi-channel physiological data processing method and device and storage medium
By acquiring and sorting data packets according to sampling time in the multi-channel physiological data processing method, the problems of confusing physiological data sequence and slow processing speed are solved, and the orderly processing and real-time improvement of data packets are achieved.
Patent Information
- Application Number
- CN202411958499.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-27
- Publication Date
- 2025-04-18
AI Technical Summary
The prior art cannot guarantee the order of the processed physiological data, which leads to the chaotic data, and the processing speed is slow and the real-time performance is poor, making it difficult to provide users with an ideal experience.
In the multi-channel physiological data processing method, multiple sampled data packets are obtained in sequence according to the sampling time, and each data packet is set to the identification that matches the order of acquisition, input the data packets into the thread pool for processing, and sort the processed data packets according to the identification to ensure the order of the data packets.
The order of sampled packets after processing is ensured, packet confusion is avoided, and processing speed is improved through thread pool, shortening the time from sampling to processing is completed, reducing delay and improving real-time.
Smart Images

Figure CN119847756A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of signal processing technology, and more specifically to a multi-channel physiological data processing method, a multi-channel physiological data processing device, an electronic device, a storage medium and a computer program product. Background Art
[0002] With the development of science and technology, real-time monitoring, analysis and processing of physiological data are becoming more and more important. Physiological data is increasingly widely used in clinical diagnosis, telemedicine, home care and other scenarios. Physiological data such as ECG data, EEG data, EMG data, neural data, etc. are of great significance for diagnosing diseases, evaluating treatment effects and studying human physiological functions. In many application scenarios, physiological data needs to be processed and analyzed, and the analysis of the processed physiological data needs to strictly follow the order of physiological data sampling.
[0003] However, in the related technologies, the order of processed physiological data cannot be guaranteed, which makes the processed physiological data prone to confusion, and the processing speed of sampled physiological data is slow, resulting in poor real-time performance, making it difficult to provide users with an ideal experience. Summary of the invention
[0004] The present invention has been made in view of the above-mentioned problems.
[0005] According to one aspect of the present invention, a multi-channel physiological data processing method is provided, comprising:
[0006] Acquire multiple sampling data packets in sequence according to sampling time, wherein each sampling data packet includes physiological data sampled by using multiple sampling channels of a sampling module; set an identifier that conforms to the acquisition sequence for each of the multiple sampling data packets acquired in sequence; input the acquired multiple sampling data packets in sequence into a thread pool including multiple threads, and process each sampling data packet respectively using the threads in the thread pool; sort all the processed sampling data packets in the acquisition sequence according to the identifiers of the processed sampling data packets to obtain sorted sampling data packets.
[0007] Exemplarily, using threads in the thread pool to process each sampled data packet separately includes: using threads in the thread pool to perform downsampling processing on each sampled data packet separately.
[0008] Exemplarily, before the acquired multiple sampling data packets are sequentially input into a thread pool including multiple threads, the multi-channel physiological data processing method further includes: performing filtering processing, common average reference processing and phase detection processing on the physiological data included in each sampling data packet.
[0009] Exemplarily, the multi-channel physiological data processing method further includes: displaying the sampling data in real time on the host computer front end according to the sorted sampling data packets.
[0010] Exemplarily, the sampling data is displayed in real time on the upper computer front end according to the sorted sampling data packets, including: judging whether the identifier of the next sampling data packet to be displayed in the sorted sampling data packets complies with the acquisition order according to the acquisition order and the identifier of the currently displayed sampling data packet; if it complies with the acquisition order, sending the next sampling data packet to be displayed to the upper computer front end, and displaying the next sampling data packet to be displayed after the upper computer front end completes displaying the currently displayed sampling data packet.
[0011] Exemplarily, the acquired multiple sampling data packets are sequentially input into a thread pool including multiple threads, and each sampling data packet is processed separately using the threads in the thread pool, including: for each thread, the physiological data included in the sampling data packet processed by the thread is processed sequentially according to the preset order of the sampling channels until the physiological data sampled by all sampling channels are processed.
[0012] Exemplarily, there are multiple sampling modules; each sampling data packet includes multiple continuous sub-data packets; multiple sampling data packets are obtained in sequence according to the sampling time, including: obtaining the sub-data packets corresponding to each sampling module in sequence according to the sampling time, and whenever a preset number of sub-data packets are accumulated, the preset number of sub-data packets are used as a sampling data packet; before the obtained multiple sampling data packets are sequentially input into a thread pool including multiple threads, the multi-channel physiological data processing method also includes: time aligning the physiological data in the sub-data packets corresponding to different sampling modules in each sampling data packet.
[0013] Exemplarily, a timestamp is stored in each sub-data packet; the physiological data in the sub-data packets corresponding to different sampling modules in each sampling data packet are time-aligned, including: for each sampling data packet, determining the sub-data packet that is first obtained among multiple consecutive sub-data packets of the sampling data packet; and based on the timestamp of the sub-data packet that is first obtained and the sampling rates of different sampling modules, the physiological data in the sub-data packets corresponding to different sampling modules are time-aligned.
[0014] According to another aspect of the present invention, a multi-channel physiological data processing device is also provided, comprising: an acquisition module, an identification module, a processing module, and a sorting module. The acquisition module is used to sequentially acquire multiple sampling data packets according to the sampling time, wherein each sampling data packet includes physiological data sampled by multiple sampling channels of the sampling module; the identification module is used to set an identification that conforms to the acquisition sequence for each of the multiple sampling data packets acquired successively; the processing module is used to sequentially input the acquired multiple sampling data packets into a thread pool including multiple threads, and use the threads in the thread pool to process each sampling data packet respectively; the sorting module is used to sort all the processed sampling data packets according to the acquisition sequence according to the identification of the processed sampling data packets, and obtain the sorted sampling data packets.
[0015] According to another aspect of the present invention, there is also provided an electronic device, comprising: a processor and a memory, wherein the memory stores computer program instructions, and the computer program instructions are used to execute the multi-channel physiological data processing method as described above when the processor is running.
[0016] According to yet another aspect of the present invention, a storage medium is provided, on which program instructions are stored. When the program instructions are run, they are used to execute the multi-channel physiological data processing method as described above.
[0017] According to another aspect of the present invention, a computer program product is also provided, comprising computer program instructions, which are used to execute the multi-channel physiological data processing method as described above when the computer program instructions are run.
[0018] The above technical solution sets an identifier that conforms to the order of acquisition for multiple sampling data packets including multi-channel physiological data acquired successively, uses the threads in the thread pool to process each sampling data packet respectively, and sorts all the sampling data packets according to the identifier to obtain the sorted sampling data packets. Thus, the order of the processed sampling data packets is guaranteed, the confusion of the processed multiple sampling data packets is avoided, and the thread pool method is used to improve the processing speed, shorten the time from data sampling to processing completion, reduce delay, and improve real-time performance.
[0019] The above description is only an overview of the technical solution of the present invention. In order to more clearly understand the technical means of the present invention, it can be implemented according to the contents of the specification. In order to make the above and other purposes, features and advantages of the present invention more obvious and easy to understand, the specific implementation methods of the present invention are listed below. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] The above and other purposes, features and advantages of the present invention will become more apparent by describing the embodiments of the present invention in more detail in conjunction with the accompanying drawings. The accompanying drawings are used to provide a further understanding of the embodiments of the present invention and constitute a part of the specification. Together with the embodiments of the present invention, they are used to explain the present invention and do not constitute a limitation of the present invention.
[0021] Figure 1 A schematic flow chart of a multi-channel physiological data processing method according to an embodiment of the present invention is shown;
[0022] Figure 2 A schematic block diagram of a multi-channel physiological data processing device according to an embodiment of the present invention is shown;
[0023] Figure 3 A schematic block diagram of an electronic device according to an embodiment of the present invention is shown. DETAILED DESCRIPTION
[0024] In order to make the purpose, technical solution and advantages of the present invention more obvious, exemplary embodiments according to the present invention will be described in detail with reference to the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention.
[0025] In order to at least solve the above technical problems, an embodiment of the present invention provides a multi-channel physiological data processing method. Figure 1 FIG. 4 is a schematic flow chart of a multi-channel physiological data processing method according to an embodiment of the present invention. Figure 1 As shown, the method includes: step S1100, step S1200, step S1300 and step S1400.
[0026] In step S1100, multiple sampling data packets are acquired in sequence according to the sampling time, wherein each sampling data packet includes physiological data sampled by multiple sampling channels of the sampling module. The physiological data may include electrocardiographic data, electroencephalographic data, electromyographic data, neural data, etc. A collection device may be set at a suitable position of the organism to obtain the physiological data of the organism. The collection device may include electrodes, sensors, etc. There may be multiple sampling modules, each of which may have at least one sampling channel. Each sampling channel may include a collection device for sampling physiological data. Each sampling data packet may include physiological data sampled by all sampling channels of each sampling module. Multiple sampling channels may start collecting physiological data at the same time. Multiple sampling data packets may be acquired in sequence according to the sampling time. For example, each sampling data packet may include physiological data collected by multiple sampling channels for 40 milliseconds. Therefore, one sampling data packet may be obtained every 40 milliseconds.
[0027] In step S1200, an identifier that complies with the order of acquisition is set for each of the multiple sampling data packets acquired in sequence. As described above, the multiple sampling data packets may be acquired in sequence and have an order of acquisition. Therefore, an identifier may be set for each sampling data packet according to the order in which the multiple sampling data packets are acquired. In other words, the identifier of each sampling data packet may comply with the order in which the sampling data packets are acquired. For example, the identifier of the next sampling data packet acquired may be the identifier of the last sampling data packet acquired plus one. The identifier of the first sampling data packet acquired may be 1. For example, the identifier of the last sampling data packet acquired may be 10, and the identifier of the currently acquired sampling data packet may be set to 11. Thus, the identifier set for the sampling data packet complies with the order in which the multiple sampling data packets are acquired.
[0028] In step S1300, the acquired multiple sampling data packets are sequentially input into a thread pool including multiple threads, and each sampling data packet is processed by the threads in the thread pool. The thread pool may include multiple threads. The thread pool may manage the threads and assign processing tasks to each thread. The acquired sampling data packets may be sequentially input into the thread pool. One of the multiple threads is used to process a sampling data packet. Usually, a large number of sampling data packets can be obtained in a short time. Thus, multiple sampling data packets can be processed in parallel to improve the processing speed. For example, when a sampling data packet is input into the thread pool, the thread pool may determine whether there is an idle thread. If there is an idle thread, the sampling data packet may be assigned to the idle thread for processing. If there is no idle thread, but the number of threads in the thread pool has not reached the maximum limit, a new thread may be created and the sampling data packet may be assigned to the thread. If there is no idle thread, but the number of threads in the thread pool has reached the maximum limit, the sampling data packet may be put into a work queue for processing.
[0029] In step S1400, according to the identifier of the processed sampling data packet, all processed sampling data packets are sorted in the order of acquisition to obtain the sorted sampling data packets. It can be understood that the threads in the thread pool can have different processing speeds for the sampling data packets. In other words, the time when the processing of the sampling data packet acquired first is completed can be later than the time when the processing of the sampling data packet acquired later is completed. Therefore, according to the identifier of the processed sampling data packet, all processed sampling data packets can be sorted in the order of acquisition, so that the order of the processed sampling data packets conforms to the order of acquisition of the sampling data packets. Ensure the accuracy of physiological data. For example, the processed sampling data packets are sorted as sampling data packet No. 1 and sampling data packet No. 3. In other words, sampling data packet No. 1 and sampling data packet No. 3 have been processed and sorted. After the processing of sampling data packet No. 2 is completed, the processed sampling data packets are sorted as sampling data packet No. 1, sampling data packet No. 2, and sampling data packet No. 3. It can be understood that the sorting of the processed sampling data packets can be sorted according to the identifier of the sampling data packet, according to the order of acquisition of the sampling data packets, rather than according to the order of completion of the processing of the sampling data packets. The processed sample data packets can be sorted by using a heap data structure.
[0030] Optionally, the physiological data in the processed and sorted sampling data packets can be used for data analysis, waveform display, model training, etc.
[0031] The above technical solution sets an identifier that conforms to the order of acquisition for multiple sampling data packets including multi-channel physiological data acquired successively, uses the threads in the thread pool to process each sampling data packet respectively, and sorts all the sampling data packets according to the identifier to obtain the sorted sampling data packets. Thus, the order of the processed sampling data packets is guaranteed, the confusion of the processed multiple sampling data packets is avoided, and the thread pool method is used to improve the processing speed, shorten the time from data sampling to processing completion, reduce delay, and improve real-time performance.
[0032] Exemplarily, each sampled data packet is processed respectively using a thread in a thread pool, including: step S1310, performing downsampling processing on each sampled data packet respectively using a thread in a thread pool.
[0033] The downsampling process can downsample the physiological data of each sampling channel in the sampling data packet to reduce the amount of physiological data corresponding to each sampling channel in the sampling data packet. The downsampling process may include downsampling the sampling data packet using existing or future developed downsampling methods such as random downsampling and layered downsampling. Optionally, a downsampling condition may be set. For example, the sampling condition may include downsampling when the amount of data of each sampling channel in the sampling data packet is greater than a fixed value. If the amount of data of each sampling channel in the sampling data packet is greater than a fixed value, the thread performs downsampling on the sampling data packet. If the amount of data of each sampling channel in the sampling data packet is less than or equal to a fixed value, the thread does not perform downsampling on the sampling data packet.
[0034] The above technical solution downsamples the sampled data packets through threads, reduces the amount of data, meets the requirements of subsequent analysis and processing, improves the speed of subsequent analysis and processing, and reduces the computing cost.
[0035] Exemplarily, step S1300 sequentially inputs the acquired multiple sampling data packets into a thread pool including multiple threads, and uses the threads in the thread pool to process each sampling data packet respectively, including: step S1320, for each thread, uses the thread to process the physiological data included in the sampling data packet processed by it in sequence according to the preset order of the sampling channel until the physiological data sampled by all sampling channels are processed.
[0036] It can be understood that the sampling data packet includes the physiological data collected by all sampling channels of all sampling modules. For example, there may be 4 sampling modules, each of which has 16 sampling channels, and the sampling data packet may include the physiological data collected by 64 sampling channels. In some embodiments, the sampling modules may have a preset order, and the sampling channels of each sampling module may have a preset order respectively. When the thread processes the sampling data packet, the physiological data corresponding to the sampling channels may be processed in sequence according to the preset order of the sampling channels corresponding to the sampling modules. For example, sampling module No. 1 has 16 sampling channels, which are numbered 1, 2, 4...16 in sequence. Sampling module No. 2 has 16 sampling channels, which are numbered 1, 2, 4...16 in sequence. The thread may first process the physiological data corresponding to the sampling channels corresponding to sampling module No. 1 in sequence according to the preset order, and after the physiological data corresponding to all sampling channels of sampling module No. 1 are processed, the physiological data corresponding to the sampling channels of sampling module No. 2 are processed in the preset order until the physiological data sampled by all sampling channels are processed. In other embodiments, a preset order may be set for all sampling channels of all sampling modules. For example, two sampling modules are included, each sampling module includes 4 sampling channels, and the preset order corresponding to the 4 sampling channels of sampling module No. 1 may be 1, 3, 5, and 7. The preset order corresponding to the 4 sampling channels of sampling module No. 2 may be 2, 4, 6, and 8. The thread may first process the physiological data of the sampling channel with the preset order of 1 of sampling module No. 1 in the sampling data packet, and then process the physiological data of the sampling channel with the preset order of 2 of sampling module No. 2, until the physiological data sampled by all sampling channels are processed.
[0037] In the above technical solution, the threads process the corresponding physiological data in the sampling data packets in sequence according to the preset order of the sampling channels, thereby ensuring the order of processing the physiological data, avoiding confusion of the physiological data of multiple channels, and improving the accuracy of the physiological data.
[0038] Exemplarily, the multi-channel physiological data processing method further includes: step S1500, filtering, common average reference and phase detection of the physiological data included in each sampling data packet. Step S1500 should be performed before the acquired multiple sampling data packets are sequentially input into the thread pool including multiple threads.
[0039] Before the sampling data packet is input into the thread pool for processing, the physiological data included in the sampling data packet can be filtered to remove the data that does not meet the requirements in the physiological data of the sampling data packet, thereby improving the quality of the physiological data. The physiological data included in the sampling data packet can also be processed by common average reference, so that the physiological data of different channels of the sampling data packet can better reflect their local and differential characteristics. The physiological data in the sampling data packet can be phase-detected to obtain the corresponding phase, so as to determine the order relationship and synchronization between the physiological data, etc., for easy processing and analysis.
[0040] The above technical solution performs filtering, common average reference and phase detection processing on the physiological data corresponding to the sampling data packet before inputting the sampling data packet into the thread pool for processing, thereby improving the quality of the physiological data included in the sampling data packet and thus improving the quality of the processed physiological data.
[0041] Exemplarily, the multi-channel physiological data processing method also includes: step S1600, displaying the sampled data in real time on the host computer front end according to the sorted sampled data packets. The sorted processed sampled data packets can be sent to the host computer front end in sequence in the sorted order for display. The host computer front end can be a component with a display function in the host computer, such as a display. The host computer front end can render the physiological data in the processed sampled data packets sent from the upper computer for display. The physiological data can be displayed by channel. Each physiological data can be displayed according to the physiological data in the sampled data packets after downsampling processing. Optionally, after the physiological data in a sampled data packet is displayed on the host computer front end, the next data packet in the sorted processed sampled data packet can be sent to the host computer front end.
[0042] The above technical solution ensures the accuracy of the processed physiological data, avoids disordered order, and facilitates users to analyze physiological data by sending the sorted sampling data packets to the host computer front end for display.
[0043] Exemplarily, step S1600, displaying the sampled data in real time on the upper computer front end according to the sorted sampled data packets, includes: step S1610 and step S1620.
[0044] In step S1610, according to the acquisition sequence and the identifier of the currently displayed sampling data packet, it is determined whether the identifier of the next sampling data packet to be displayed in the sorted sampling data packets conforms to the acquisition sequence. In some embodiments, it is possible to determine whether the identifier of the next sampling data packet to be displayed in the sorted sampling data packets conforms to the acquisition sequence according to the identifier of the sampling data packet currently displayed by the host computer front end. For example, the identifier of the currently displayed sampling data packet is 5, that is, the sampling data packet No. 5 is currently displayed, and the corresponding identifier of the next sampling data packet to be displayed that conforms to the acquisition sequence should be 6. It can be determined in the sorted sampling data packets whether the identifier of the next sampling data packet to be displayed is 6. If it is 6, then whether the identifier of the next sampling data packet to be displayed conforms to the preset rule. Otherwise, it does not conform.
[0045] In step S1620, if the acquisition sequence is met, the next sampling data packet to be displayed is sent to the host computer front end, and the next sampling data packet to be displayed is displayed after the host computer front end displays the currently displayed sampling data packet. When the host computer is displaying the current sampling data packet, if the identifier of the next sampling data packet to be displayed in the sorted sampling data packet meets the acquisition sequence, it is sent to the host computer front end. When the sampling data packet currently displayed by the host computer front end is displayed, the next sampling data packet to be displayed is displayed as the new currently displayed sampling data packet. Further, it can be determined whether the identifier of the new next sampling data packet to be displayed in the sorted sampling data packet meets the acquisition sequence to display all sorted sampling data packets.
[0046] The above technical solution determines whether the identifier of the next sample data packet to be displayed in the sorted sample data packets conforms to the acquisition sequence, and sends it to the host computer front end if it conforms to the acquisition sequence. The host computer front end displays the next sample data packet to be displayed after the currently displayed sample data packet is displayed. It ensures that the order of displaying the sample data packets conforms to the order of acquiring the sample data packets, avoids display confusion, and improves the accuracy of display.
[0047] Exemplarily, there are multiple sampling modules; each sampling data packet includes multiple continuous sub-data packets. There may be multiple sampling modules, each sampling module may have at least one sampling channel. Each sampling data packet may include multiple sub-data packets continuously acquired by multiple sampling modules.
[0048] Step S1100, sequentially obtaining multiple sampling data packets according to the sampling time, including: step S1110, sequentially obtaining sub-data packets corresponding to each sampling module according to the sampling time, and whenever a preset number of sub-data packets are accumulated, the preset number of sub-data packets are used as a sampling data packet. In some embodiments, each sub-data packet may have physiological data with the same sampling time or data volume. For example, whenever a sampling module samples for 4 milliseconds, the physiological data collected by all sampling channels of the sampling module in these 4 milliseconds can be used as a sub-data packet. The sampling rate of all sampling modules can be 10,000 Hz, then the amount of physiological data collected by the sampling channel of each sampling module in 4 milliseconds is 40, that is, whenever the amount of physiological data collected by each sampling channel of a sampling module is 40, the 40 physiological data collected by all sampling channels of the sampling module are used as a sub-data packet. Multiple sub-data packets corresponding to each sampling module can be obtained according to the sampling time. The preset number can be determined jointly according to factors such as the processing speed of the host computer and the amount of physiological data in the sub-data packet. For example, the processing speed of the host computer affects the amount of physiological data in the sampling data packet, and the preset number and the amount of physiological data in the sub-data packet affect the amount of physiological data in the sampling data packet. For example, the faster the processing speed of the host computer, the larger the amount of physiological data in the sampling data packet can be, and further, the larger the preset number of sub-data packets can be. For another example, there can be four sampling modules, and the preset number can be 40, that is, when 40 sub-data packets are obtained, these 40 sub-data packets are used as sampling data packets. In other words, one sampling data packet includes 10 sub-data packets corresponding to the four sampling modules respectively.
[0049] Before the acquired multiple sampling data packets are sequentially input into the thread pool including multiple threads, the multi-channel physiological data processing method further includes: step S1700 time-aligning the physiological data in the sub-data packets corresponding to different sampling modules in each sampling data packet. Before the sampling data packets are input into the thread pool, the discrete sampled physiological data in the sub-data packets corresponding to different sampling modules in each sampling data packet can be time-aligned. When each sampling module collects physiological data, due to various reasons, the physiological data sampled by some sampling modules may not be aligned with the physiological data sampled by the remaining sampling modules. In other words, there is a time deviation in the physiological data collected by different sampling modules at the same time. In some embodiments, the physiological data of the sub-data packet corresponding to a sampling module in a sampling data packet can be used as a reference, and the physiological data of the sub-data packets corresponding to the remaining sampling modules in the sampling data packet can be aligned with the physiological data of the sub-data packet corresponding to the sampling module, so as to achieve time alignment of the physiological data of all sampling modules of the sampling data packet. In other embodiments, the physiological data of the sub-data packets corresponding to all sampling modules in a sampling data packet can be time-aligned according to the reference sampling time.
[0050] The above technical solution performs time alignment on the physiological data in the sub-data packets corresponding to different sampling modules in each sampling data packet before the sampling data packet is input into the thread pool, thereby ensuring the accuracy of the physiological data in time, facilitating subsequent processing and analysis, and improving the user experience.
[0051] Exemplarily, a timestamp is stored in each sub-data packet. Each time a sub-data packet is acquired, the sub-data packet may be timestamped and stored in the sub-data packet. The timestamp may indicate the time of each physiological data in the first data packet.
[0052] Step S1700 time-aligns the physiological data in the sub-data packets corresponding to different sampling modules in each sampling data packet, including: step S1710 and step S1720.
[0053] In step S1710, for each sampled data packet, the sub-data packet obtained first among the multiple continuous sub-data packets of the sampled data packet is determined. The sampled data packet includes multiple sub-data packets obtained continuously. Thus, for each sampled data packet, the sub-data packet obtained first among the multiple sub-data packets in the sampled data packet can be determined. The sub-data packet obtained first can be determined according to the order in which the multiple sub-data packets in the sampled data packet are obtained.
[0054] In step S1720, the physiological data in the sub-packets corresponding to different sampling modules are time-aligned according to the timestamp of the first acquired sub-packet and the sampling rates of different sampling modules. In some embodiments, the sampling rates of the sampling modules may be different. The time reference may be determined according to the timestamp in the first acquired sub-packet and the sampling rate of the sampling module corresponding to the sub-packet. The physiological data of the sub-packets corresponding to the remaining sampling modules in the sampling data packet are time-aligned with the time reference so that the sampling time of the physiological data in the sub-packets of all sampling modules is the same without deviation. In other embodiments, the sampling rates of all sampling modules may be the same, and the physiological data of the sampling module corresponding to the sub-packet in the sampling data packet may be used as a reference according to the timestamp of the first acquired sub-packet, and the physiological data of the sub-packets corresponding to the remaining sampling modules may be time-aligned with the physiological data of the sub-packets corresponding to the sampling module.
[0055] The above technical solution time-aligns the physiological data in the sub-packets corresponding to different sampling modules according to the timestamp of the sub-packet first obtained in the sampling data packet and the sampling rates of different sampling modules, thereby ensuring the accuracy of the physiological data, avoiding errors, and improving the accuracy of subsequent processing and analysis.
[0056] Illustratively, according to yet another aspect of the present invention, a multi-channel physiological data processing device is also provided. Figure 2 FIG. 2 shows a schematic block diagram of a multi-channel physiological data processing device 200 according to an embodiment of the present invention. Figure 2 As shown, the multi-channel physiological data processing device 200 includes an acquisition module 210 , an identification module 220 , a processing module 230 and a sorting module 240 .
[0057] The acquisition module 210 is used to sequentially acquire multiple sampling data packets according to the sampling time, wherein each sampling data packet includes physiological data sampled by using multiple sampling channels of the sampling module. The identification module 220 is used to set an identification that conforms to the acquisition sequence for each of the multiple sampling data packets acquired in sequence. The processing module 230 is used to sequentially input the acquired multiple sampling data packets into a thread pool including multiple threads, and use the threads in the thread pool to process each sampling data packet respectively. The sorting module 240 is used to sort all processed sampling data packets according to the acquisition sequence according to the identification of the processed sampling data packets, and obtain sorted sampling data packets.
[0058] Exemplarily, the processing module 230 includes a down-sampling submodule. The down-sampling submodule is used to perform down-sampling processing on each sampled data packet using threads in the thread pool.
[0059] Exemplarily, before sequentially inputting the acquired multiple sampling data packets into a thread pool including multiple threads, the multi-channel physiological data processing device 200 further includes: a second processing module. The second processing module is used to perform filtering processing, common average reference processing and phase detection processing on the physiological data included in each sampling data packet.
[0060] Exemplarily, the multi-channel physiological data processing device 200 further includes a display module. The display module is used to display the sampled data in real time on the host computer front end according to the sorted sampled data packets.
[0061] Exemplarily, the display module includes a judgment submodule and a first display submodule. The judgment submodule is used to judge whether the identifier of the next sampling data packet to be displayed in the sorted sampling data packets conforms to the acquisition sequence according to the acquisition sequence and the identifier of the currently displayed sampling data packet. The first display submodule is used to send the next sampling data packet to be displayed to the host computer front end if it conforms to the acquisition sequence, and display the next sampling data packet to be displayed after the host computer front end displays the currently displayed sampling data packet.
[0062] Exemplarily, the processing module includes a first processing submodule. The first processing submodule is used to process the physiological data included in the sampled data packet processed by each thread in sequence according to the preset order of the sampling channels, until the physiological data sampled by all sampling channels are processed.
[0063] Exemplarily, there are multiple sampling modules; each sampling data packet includes multiple continuous sub-data packets. The acquisition module includes a first acquisition sub-module. Before the multiple acquired sampling data packets are sequentially input into a thread pool including multiple threads, the multi-channel physiological data processing device 200 includes a time alignment module. The first acquisition sub-module is used to sequentially acquire the sub-data packets corresponding to each sampling module according to the sampling time, and whenever a preset number of sub-data packets are accumulated, the preset number of sub-data packets are used as a sampling data packet. The time alignment module is used to time-align the physiological data in the sub-data packets corresponding to different sampling modules in each sampling data packet.
[0064] Exemplarily, a timestamp is stored in each sub-data packet, and the time alignment module includes a second acquisition sub-module and a first time alignment sub-module. The second acquisition sub-module is used to determine, for each sampling data packet, the sub-data packet that is first acquired among a plurality of consecutive sub-data packets of the sampling data packet. The first time alignment sub-module is used to time-align the physiological data in the sub-data packets corresponding to different sampling modules according to the timestamp of the sub-data packet that is first acquired and the sampling rates of different sampling modules.
[0065] Illustratively, according to yet another aspect of the present invention, an electronic device is also provided. Figure 3 A schematic block diagram of an electronic device 300 according to an embodiment of the present invention is shown. The electronic device 300 includes a processor 310 and a memory 320. The memory 320 stores computer program instructions, which are used by the processor 310 to execute the multi-channel physiological data processing method described above when the computer program instructions are executed.
[0066] Exemplarily, according to another aspect of the present invention, a storage medium is also provided, on which program instructions are stored, and the program instructions are used to execute the multi-channel physiological data processing method as described above when running. The storage medium may include, for example, an erasable programmable read-only memory (EPROM), a portable read-only memory (CD-ROM), a USB memory, or any combination of the above storage media. The storage medium may be any combination of one or more computer-readable storage media.
[0067] Illustratively, according to yet another aspect of the present invention, there is further provided a computer program product, comprising computer program instructions, which are used to execute the multi-channel physiological data processing method as described above when the computer program instructions are run.
[0068] A person skilled in the art can understand the specific implementation scheme and beneficial effects of the above-mentioned multi-channel physiological data processing device, electronic device, storage medium and computer program product by reading the above-mentioned description of the multi-channel physiological data processing method. For the sake of brevity, they will not be repeated here.
[0069] Although example embodiments have been described herein with reference to the accompanying drawings, it should be understood that the above example embodiments are merely exemplary and are not intended to limit the scope of the present application to this. Those of ordinary skill in the art may make various changes and modifications therein without departing from the scope and spirit of the present application. All these changes and modifications are intended to be included within the scope of the present application as required by the appended claims.
[0070] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0071] In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic, for example, the division of the units is only a logical function division, and there may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed.
[0072] In the description provided herein, a large number of specific details are described. However, it is understood that the embodiments of the present application can be practiced without these specific details. In some instances, well-known methods, structures and techniques are not shown in detail so as not to obscure the understanding of this description.
[0073] Similarly, it should be understood that in order to streamline the present application and help understand one or more of the various inventive aspects, in the description of the exemplary embodiments of the present application, the various features of the present application are sometimes grouped together into a single embodiment, figure, or description thereof. However, the method of the present application should not be interpreted as reflecting the following intention: the claimed application requires more features than the features clearly stated in each claim. More specifically, as reflected in the corresponding claims, the inventive point is that the corresponding technical problem can be solved with features less than all the features of a single disclosed embodiment. Therefore, the claims following the specific embodiment are hereby explicitly incorporated into the specific embodiment, wherein each claim itself serves as a separate embodiment of the present application.
[0074] It will be understood by those skilled in the art that, except for mutually exclusive features, all features disclosed in this specification (including the accompanying claims, abstracts and drawings) and all processes or units of any method or device disclosed in this specification may be combined in any combination. Unless otherwise expressly stated, each feature disclosed in this specification (including the accompanying claims, abstracts and drawings) may be replaced by an alternative feature that provides the same, equivalent or similar purpose.
[0075] In addition, those skilled in the art will appreciate that, although some embodiments described herein include certain features included in other embodiments but not other features, the combination of features of different embodiments is meant to be within the scope of the present application and form different embodiments. For example, in the claims, any one of the claimed embodiments can be used in any combination.
[0076] The various component embodiments of the present application can be implemented in hardware, or in software modules running on one or more processors, or in a combination thereof. It should be understood by those skilled in the art that a microprocessor or a digital signal processor (DSP) can be used in practice to implement some or all functions of some modules in the multi-channel physiological data processing device according to the embodiment of the present application. The present application can also be implemented as a device program (e.g., a computer program and a computer program product) for executing part or all of the methods described herein. Such a program implementing the present application can be stored on a computer-readable medium, or can have the form of one or more signals. Such a signal can be downloaded from an Internet website, or provided on a carrier signal, or provided in any other form.
[0077] It should be noted that the above embodiments illustrate the present application rather than limit the present application, and that those skilled in the art may design alternative embodiments without departing from the scope of the appended claims. In the claims, any reference symbol between brackets should not be constructed as a limitation to the claims. The word "comprising" does not exclude the presence of elements or steps not listed in the claims. The word "one" or "an" preceding an element does not exclude the presence of multiple such elements. The present application may be implemented by means of hardware including several different elements and by means of a suitably programmed computer. In a unit claim that lists several devices, several of these devices may be embodied by the same hardware item. The use of the words first, second, and third, etc. does not indicate any order. These words may be interpreted as names.
[0078] The above is only a specific implementation or description of a specific implementation of the present application, and the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. The protection scope of the present application shall be based on the protection scope of the claims.
Claims
1. A multi-channel physiological data processing method, characterized in that: Acquire multiple sampling data packets in sequence according to the sampling time, wherein each sampling data packet includes physiological data sampled by using multiple sampling channels of the sampling module; Setting an identifier that complies with the acquisition sequence for each of the plurality of sampling data packets acquired successively; Inputting the obtained multiple sampling data packets into a thread pool including multiple threads in sequence, and using the threads in the thread pool to process each sampling data packet respectively; According to the identifiers of the processed sampling data packets, all the processed sampling data packets are sorted in the acquisition order to obtain sorted sampling data packets.
2. The multi-channel physiological data processing method according to claim 1, characterized in that: The using threads in the thread pool to process each sampled data packet respectively includes: The threads in the thread pool are used to perform downsampling processing on each sampled data packet.
3. The multi-channel physiological data processing method according to claim 2, characterized in that: Before sequentially inputting the acquired multiple sampling data packets into a thread pool including multiple threads, the multi-channel physiological data processing method further includes: The physiological data included in each sampling data packet is subjected to filtering processing, common average reference processing and phase detection processing.
4. The multi-channel physiological data processing method according to claim 2, characterized in that: The multi-channel physiological data processing method further includes: The sampling data is displayed in real time on the upper computer front end according to the sorted sampling data packets.
5. The multi-channel physiological data processing method according to claim 4, characterized in that: The real-time display of the sampling data on the host computer front end according to the sorted sampling data packets includes: According to the acquisition sequence and the identifier of the currently displayed sample data packet, determining whether the identifier of the next sample data packet to be displayed in the sorted sample data packets conforms to the acquisition sequence; In accordance with the acquisition sequence, the next sampling data packet to be displayed is sent to the host computer front end, and the next sampling data packet to be displayed is displayed after the host computer front end has completed displaying the currently displayed sampling data packet.
6. The multi-channel physiological data processing method according to claim 1, characterized in that: The step of sequentially inputting the plurality of sample data packets obtained into a thread pool including a plurality of threads, and using the threads in the thread pool to process each sample data packet respectively includes: For each thread, the physiological data included in the sampled data packet processed by the thread is processed in sequence according to the preset order of the sampling channels until the physiological data sampled by all the sampling channels are processed.
7. The multi-channel physiological data processing method according to claim 1, characterized in that: The number of the sampling modules is multiple; each sampling data packet includes multiple consecutive sub-data packets; The step of sequentially acquiring a plurality of sampling data packets according to the sampling time includes: Sequentially acquiring the sub-data packets corresponding to each sampling module according to the sampling time, and whenever a preset number of sub-data packets are accumulated, taking the preset number of sub-data packets as a sampling data packet; Before sequentially inputting the acquired multiple sampling data packets into a thread pool including multiple threads, the multi-channel physiological data processing method further includes: The physiological data in the sub-data packets corresponding to different sampling modules in each sampling data packet are time-aligned.
8. The multi-channel physiological data processing method according to claim 7, characterized in that: A timestamp is stored in each sub-data packet; The step of time aligning the physiological data in the sub-data packets corresponding to different sampling modules in each sampling data packet includes: For each sampled packet, Determine a sub-data packet obtained first among a plurality of consecutive sub-data packets of the sampled data packet; According to the timestamps of the sub-data packets first acquired and the sampling rates of the different sampling modules, the physiological data in the sub-data packets corresponding to the different sampling modules are time-aligned.
9. A multi-channel physiological data processing device, characterized in that: An acquisition module, used to sequentially acquire a plurality of sampling data packets according to a sampling time, wherein each sampling data packet includes physiological data sampled by a plurality of sampling channels of the sampling module; an identification module, used for setting an identification in accordance with the acquisition sequence for each of the plurality of sampling data packets acquired successively; A processing module, used for sequentially inputting the obtained multiple sampling data packets into a thread pool including multiple threads, and using the threads in the thread pool to process each sampling data packet respectively; The sorting module is used to sort all processed sampling data packets according to the acquisition sequence according to the identifiers of the processed sampling data packets, so as to obtain sorted sampling data packets.
10. An electronic device comprising: A processor and a memory, characterized in that The memory stores computer program instructions, which are used by the processor to execute the multi-channel physiological data processing method according to any one of claims 1 to 8 when the processor runs the computer program instructions.
11. A storage medium having program instructions stored thereon, characterized in that: The program instructions are used to execute the multi-channel physiological data processing method according to any one of claims 1 to 8 when running.
12. A computer program product comprising computer program instructions, characterized in that The computer program instructions are used to execute the multi-channel physiological data processing method according to any one of claims 1 to 8 when running.