Ambulance electrocardiogram data transmission method, device, equipment, medium and product
By converting electrocardiogram (ECG) waveforms into coordinate values and using deep learning technology to identify arrhythmias, the problem of ECG data transmission interruption in areas with incomplete signal in ambulances was solved, achieving complete and stable transmission of ECG data.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- WUHAN UNIV
- Filing Date
- 2026-01-21
- Publication Date
- 2026-05-29
AI Technical Summary
When ambulances travel on roads with incomplete 4G/5G signal coverage, electrocardiogram data transmission is easily interrupted, leading to the loss of important diagnostic information and affecting emergency response efficiency.
The electrocardiogram waveform is converted into coordinate values and stored. Multi-scale CNN and channel attention residual mechanism are used to identify arrhythmia components. When the network is normal, the data is sent to the cloud server. When there is an anomaly, graded caching and delayed transmission are implemented.
This ensures the integrity and stable transmission of electrocardiogram (ECG) data, avoids data loss due to network interruptions, and improves transmission efficiency and accuracy.
Smart Images

Figure CN122120290A_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of remote transmission technology of medical data, and in particular to a method, apparatus, equipment, medium and product for transmitting electrocardiogram data in an ambulance. Background Technology
[0002] Currently, in ambulances (clinical medicine), vital sign monitors collect patients' vital sign information, primarily electrocardiogram (ECG), blood pressure, and blood oxygen saturation. Especially for patients with acute heart disease, which has a high mortality rate, ECG data is the most important basis for professional cardiologists to analyze the cause and determine treatment measures. Since the medical staff in ambulances are not cardiologists, transmitting the ambulance's ECG data to specialists at the emergency center allows them to guide in-vehicle care based on the patient's actual condition, potentially buying precious time for critically ill patients.
[0003] The most direct way to transmit electrocardiogram (ECG) data from an ambulance to an emergency center is to use a camera to send the ECG waveform data to the receiving terminal at the emergency center. However, because 4G / 5G signals cannot achieve complete, all-around coverage, there are still some areas on current highways where 4G / 5G signals are not available.
[0004] Figure 1 This data represents actual road test results for mobile signal coverage on highways, national roads, and some provincial and county roads in the Xiangyang area, between Xiangyang Central Hospital and Hubei Provincial People's Hospital. Dark green indicates sections with normal real-time video transmission; light green indicates sections with packet loss in real-time video; blue indicates sections with normal text data transmission; yellow indicates sections with long text data transmission delays; and red indicates sections with network transmission interruptions. It can be seen that some sections still suffer from long transmission delays and network transmission interruptions. Ambulances traveling on these sections will find it difficult to maintain real-time signal connectivity with the hospital. Furthermore, road tests on mobile signal coverage from various cities and counties in the Xiangyang area to Xiangyang Central Hospital, and from various township hospitals to county central hospitals, indicate that many sections far from villages and towns only support voice call transmission and do not yet support internet data transmission.
[0005] In general, ambulances may experience network outages while operating on certain roads due to incomplete 4G / 5G signal coverage. Current network outages include short-term and long-term interruptions. Short-term outages last approximately 3-5 seconds and are the most common type of network outage; long-term outages are rare and can last for tens of minutes. Network outages can significantly hinder emergency medical activities within ambulances. For example, during electrocardiogram (ECG) transmission, because arrhythmias are not continuous on ECGs but are intermittent, even a small amount of ECG data lost due to a 3-5 second network outage can result in the loss of crucial diagnostic information. Summary of the Invention
[0006] This disclosure provides a method, apparatus, device, medium, and product for transmitting electrocardiogram (ECG) data in an ambulance, which can improve the transmission efficiency of ECG data and ensure the integrity of ECG data in the event of network abnormalities. The technical solution includes at least the following: In a first aspect, a method for transmitting electrocardiogram (ECG) data in an ambulance is provided, comprising: an industrial control computer in the ambulance receiving vital sign monitoring data from a vital signs monitor; converting the vital sign monitoring data into an ECG waveform, and converting the ECG waveform into coordinate values for storage; identifying the arrhythmia portion of the ECG waveform; under normal network conditions, sending the converted coordinate values of the ECG waveform to a cloud server, the cloud server being connected to a hospital client, the cloud server being used to send the received ECG waveform coordinate values to the hospital client; under abnormal network conditions, performing graded caching and delayed transmission of the coordinate values corresponding to the arrhythmia portion of the ECG waveform.
[0007] Optionally, the step of converting the vital signs monitoring data into electrocardiogram (ECG) waveforms and converting the ECG waveforms into coordinate values for storage includes: parsing the vital signs monitoring data using the HL7 protocol, an international standard for medical information exchange, to obtain the patient's physiological information data, which includes ECG data, blood oxygen saturation data, non-invasive blood pressure, and respiratory rate data; acquiring the ECG waveforms from the ECG data and converting the ECG waveforms into coordinate values for storage.
[0008] Optionally, identifying the arrhythmia portion of the electrocardiogram (ECG) waveform includes: preprocessing the ECG waveform, the preprocessing including filtering, amplitude normalization, and heartbeat segmentation; inputting the preprocessed ECG waveform into a network model combining a multi-scale CNN and a channel attention residual mechanism to obtain the morphological features of the ECG waveform; and inputting the morphological features into an improved bidirectional long short-term memory network to obtain the arrhythmia identification result.
[0009] Optionally, the network model combining multi-scale CNN with channel attention residual mechanism includes multi-scale CNN units and channel attention residual units connected in sequence; the multi-scale CNN unit includes a first convolutional branch and a second convolutional branch, the first convolutional branch uses a conventional convolutional kernel for convolution, and the second convolutional branch uses a dilated convolutional kernel for convolution; the channel attention residual unit includes channel attention processing and residual connection processing.
[0010] Optionally, the improved bidirectional long short-term memory network includes a bidirectional long short-term memory network and a self-attention mechanism connected to the bidirectional long short-term memory network.
[0011] Secondly, an ambulance electrocardiogram (ECG) data transmission device is also provided, comprising: a receiving module for receiving vital sign monitoring data from a vital signs monitor via an industrial control computer inside the ambulance; a conversion module for converting the vital sign monitoring data into an ECG waveform and converting the ECG waveform into coordinate values for storage; an arrhythmia identification module for identifying arrhythmia components in the ECG waveform; a sending module for sending the converted coordinate values of the ECG waveform to a cloud server when the network is normal, the cloud server being connected to a hospital client, the cloud server being used to send the received ECG waveform coordinate values to the hospital client; and a caching module for performing graded caching and delayed transmission of the coordinate values corresponding to the arrhythmia components in the ECG waveform when the network is abnormal.
[0012] Optionally, the conversion module is further configured to parse the vital signs data using the HL7 protocol, an international standard for medical information exchange, to obtain the patient's physiological information data, including electrocardiogram (ECG) data, blood oxygen saturation data, non-invasive blood pressure, and respiratory rate data; acquire the ECG waveform from the ECG data, and convert the ECG waveform into coordinate values for storage.
[0013] Optionally, the arrhythmia recognition module is further configured to preprocess the electrocardiogram waveform, the preprocessing including filtering, amplitude normalization, and heartbeat segmentation; input the preprocessed electrocardiogram waveform into a network model combining multi-scale CNN and channel attention residual mechanism to obtain the morphological features of the electrocardiogram waveform; input the morphological features into an improved bidirectional long short-term memory network to obtain the arrhythmia recognition result.
[0014] Optionally, in the arrhythmia recognition module, the network model combining multi-scale CNN and channel attention residual mechanism includes multi-scale CNN units and channel attention residual units connected in sequence; the multi-scale CNN unit includes a first convolution branch and a second convolution branch, the first convolution branch uses a conventional convolution kernel for convolution, and the second convolution branch uses a dilated convolution kernel for convolution; the channel attention residual unit includes channel attention processing and residual connection processing.
[0015] Optionally, in the arrhythmia recognition module, the improved bidirectional long short-term memory network includes a bidirectional long short-term memory network and a self-attention mechanism connected to the bidirectional long short-term memory network.
[0016] Thirdly, a computer device is also provided, comprising: a memory and a processor, wherein the memory stores at least one computer program, the at least one computer program being loaded and executed by the processor to perform the ambulance electrocardiogram data transmission method described in the above embodiments.
[0017] Fourthly, a computer-readable storage medium is also provided, wherein at least one computer program is stored in the computer-readable storage medium, the at least one computer program being loaded and executed by a processor to perform the ambulance electrocardiogram data transmission method described in the above embodiments.
[0018] Fifthly, a computer program product is provided, including a computer program / instructions that, when executed by a processor, implement the method described in the first aspect.
[0019] The beneficial effects of the technical solutions provided in this disclosure include at least the following: In this embodiment, since text data transmission is faster, more efficient, and less prone to packet loss than image data transmission over a network, the coordinate values of the converted ECG waveform are sent to the cloud server, and the cloud server then sends the received ECG waveform coordinate values to the hospital client. This is equivalent to converting the ECG waveform into text data instead of directly transmitting graphic data, thus ensuring stable transmission of the ECG waveform. Furthermore, by hierarchically caching and delaying the transmission of coordinate values corresponding to the arrhythmia portion of the ECG waveform in the event of network anomalies, the integrity of the ECG waveform under abnormal network conditions can be guaranteed, and storage overflow due to large cached data volume cannot be prevented (only the coordinate values of the arrhythmia portion are stored, not the entire ECG coordinate values, thus requiring less cached data). Attached Figure Description
[0020] To more clearly illustrate the technical solutions in the embodiments of this disclosure, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this disclosure. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0021] Figure 1 The data represents the actual road test results of mobile signals on highways, national roads, and some provincial and county roads in the Xiangyang area between Xiangyang Central Hospital and Hubei Provincial People's Hospital. Figure 2 A schematic diagram illustrating an application scenario provided by an exemplary embodiment of this disclosure is shown; Figure 3 A flowchart illustrating an exemplary embodiment of the present disclosure of an ambulance electrocardiogram data transmission method is shown. Figure 4 This is a schematic diagram of the data format in the HL7 protocol; Figure 5 This is a flowchart illustrating the process of extracting morphological features; Figure 6 This is a schematic diagram of channel attention processing and residual connection processing; Figure 7 This illustration shows a schematic diagram of the structure of an ambulance electrocardiogram data transmission device provided in an exemplary embodiment of the present disclosure; Figure 8 This is a schematic diagram of the structure of a computer device provided in an embodiment of this disclosure. Detailed Implementation
[0022] Unless otherwise defined, the technical or scientific terms used herein shall have the ordinary meaning as understood by one of ordinary skill in the art to which this disclosure pertains. The terms “first,” “second,” “third,” and similar terms used in this patent application specification and claims do not indicate any order, quantity, or importance, but are merely used to distinguish different components. Similarly, the terms “an” or “a” and similar terms do not indicate a quantity limitation, but rather indicate the presence of at least one. The terms “comprising” or “including” and similar terms mean that the elements or objects preceding “comprising” or “including” encompass the elements or objects listed following “comprising” or “including” and their equivalents, and do not exclude other elements or objects. The terms “connected” or “linked” and similar terms are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect.
[0023] To make the objectives, technical solutions, and advantages of this disclosure clearer, the embodiments of this disclosure will be described in further detail below with reference to the accompanying drawings.
[0024] Figure 2 A schematic diagram illustrating an application scenario provided by an exemplary embodiment of this disclosure is shown. See also Figure 2 The ambulance 20 includes a vital signs monitor 21 and an industrial control computer 22. The vital signs monitor 21 and the industrial control computer 22 are connected in communication. The industrial control computer 22 is connected in communication with a cloud server 23. The cloud server 23 is connected in communication with a hospital client 24.
[0025] In this embodiment, the industrial control computer 22 is a computer device specifically designed for industrial control and installed on the ambulance 20. The vital signs monitor 21 is used to monitor the vital signs of the patient in the ambulance. The hospital client 14 is a computer device installed at the hospital, from which the ambulance 10 also departs.
[0026] The industrial control computer 22 is specifically designed to receive vital sign monitoring data sent by the vital sign monitor 21. After receiving the vital sign monitoring data, the industrial control computer 22 performs a series of processing steps on the data and then uploads the processed data to the cloud server 23. The hospital client 24 can retrieve the vital sign monitoring data uploaded by the industrial control computer 22 from the cloud server 23 and parse and display it. For example, when displaying the data, the hospital client 24 uses charts to show the changing trends of various parameters in the medical data in real time.
[0027] Based on the real-time data transmission requirements of the vital signs monitor 21, the industrial control computer 22 in the ambulance and the cloud server 23, as well as the hospital client 24 and the cloud server 23, can be connected using the WebSocket full-duplex communication protocol. WebSocket provides low latency and high reliability data communication services based on TCP (Transmission Control Protocol), which meets the real-time data transmission requirements of the vital signs monitor 21.
[0028] The industrial control computer 22 uses the Netty framework to receive and process the vital signs monitoring data collected by the vital signs monitor 21, ensuring that the industrial control computer 22 can efficiently obtain real-time vital signs monitoring data from the vital signs monitor 21. Netty is a client / server based programming framework that allows for the rapid and simple development of network applications. In this scenario, the industrial control computer 22 acts as a client, periodically requesting vital signs monitoring data from the vital signs monitor 23 (acting as a cloud server) every second, and receiving the corresponding vital signs monitoring data from the monitor.
[0029] Implementing WebSocket communication in Netty involves creating a cloud server 23 handler and a WebSocket frame processing procedure. First, a server class is created to initialize and configure the server (like a vital signs monitor). This involves setting the port the server will listen on and configuring how the server handles new connections. In Netty, this is typically done by creating a class that inherits from `ChannelInitializer`, which defines a series of handlers responsible for processing data received over network connections. Further, to achieve full-duplex communication, a handler for processing WebSocket frames is needed to transfer data between the client and server. In Netty, this is implemented by creating a class that inherits from `SimpleChannelInboundHandler` and overriding its `channelRead0` method. Finally, by writing a startup class and configuring the `ServerBootstrap` object, the cloud server 23 can start and wait for client connections. This object configuration includes specifying the `EventLoopGroup` for Netty to handle I / O operations, which is fundamental to Netty's high-performance processing capabilities. After starting, the cloud server 23 continuously listens on the specified port, ready to handle connection requests from clients (industrial control computers).
[0030] After the vital signs monitor 21 is powered on, the industrial control computer 22 listens on port 4601. Once the industrial control computer 22 establishes a connection with port 4601 of the vital signs monitor 21, it sends a fixed-format heartbeat packet to the vital signs monitor 21 every second, which also serves as a request packet to read vital signs monitoring data. After receiving the heartbeat packet, the vital signs monitor 21 sends the vital signs monitoring data collected in the current cycle to the industrial control computer 22. If no heartbeat packet is received for more than 10 seconds, the vital signs monitor 21 actively disconnects from the industrial control computer 22 and stops sending vital signs monitoring data.
[0031] At the industrial control computer 22, after receiving the vital signs monitoring data transmitted from the vital signs monitor 21, it begins to parse the vital signs monitoring data according to the Health Level Seven (HL7) protocol, an international standard for medical information exchange, to obtain the patient's physiological information data, including ECG data, SpO2 blood oxygen saturation data, NIBP non-invasive blood pressure, respiratory rate, and other data. After parsing the vital signs monitoring data, the industrial control computer 22 stores the parsed physiological information data in a local cache according to the fields. At the same time, the industrial control computer 22 sends the parsed physiological information data to the cloud server 23 for caching via the connected mobile communication network.
[0032] In the hospital client 24, the ECharts library provides robust support for real-time data visualization. Once the front-end receives data pushed from the back-end via the established WebSocket connection, it can dynamically plot the patient's physiological waveforms, such as electrocardiograms or blood oxygen saturation waveforms, based on the sampling rate and binary data in the waveform header. ECharts' dynamic data update capabilities are particularly well-suited for handling the needs of real-time monitoring systems, enabling medical staff to observe any changes in the patient's condition in real time.
[0033] Figure 3 A flowchart illustrating an exemplary embodiment of this disclosure of an ambulance electrocardiogram (ECG) data transmission method is shown. See also: Figure 3 The method includes: In step 301, the industrial control computer inside the ambulance receives life monitoring data from the vital signs monitor.
[0034] The implementation method for an industrial control computer to receive vital sign monitoring data from a vital signs monitor is described above. Figure 2 Details are omitted here.
[0035] In step 302, the vital signs monitoring data are converted into electrocardiogram (ECG) waveforms, and the ECG waveforms are converted into coordinate values for storage.
[0036] Optionally, step 302 includes: Step 3021: The vital signs monitoring data is parsed using the HL7 protocol, an international standard for medical information exchange, to obtain the patient's physiological information data.
[0037] Physiological information data includes electrocardiogram data, blood oxygen saturation data, non-invasive blood pressure, and respiratory rate data.
[0038] Figure 4 This is a schematic diagram of the data format in the HL7 protocol.
[0039] The HL7 message encapsulation format is as follows: Figure 4 As shown in section (a), an HL7 message begins with 0x0B and ends with 0x1C followed by 0x0D, with the actual message body enclosed between the start and end boundaries. An HL7 message consists of multiple sequential message segments, separated by delimiters. <cr>The corresponding hexadecimal value is 0x0D; each message segment consists of multiple fields arranged in sequence, separated by "". Each field can be repeated, therefore, a field is composed of repeating fields (FieldRepetition), separated by "". Each repeating field consists of multiple sequential components, separated by "". Each component is composed of multiple sub-components in sequence, separated by "". ".
[0040] The parsing process first identifies the start and end boundaries of the HL7 message to obtain a complete HL7 message, avoiding packet merging and incomplete packet issues that occur during TCP transmission. Then, based on the HL7 message encapsulation format, the message segments, fields, repeating fields, components, and sub-components are obtained, using the delimiters of each part as boundaries. Since the HL7 message type information is in the first segment, an HL7 message type filter can be set for the information in the first segment to filter out message segments containing patient physiological data. Then, the patient's physiological parameters and waveform data (equivalent to physiological information data) are extracted from the message segments containing patient physiological data. Because the obtained waveform data is encrypted ciphertext, decryption is also required according to the data encryption process.
[0041] Step 3022: Obtain the electrocardiogram waveform from the electrocardiogram data and convert the electrocardiogram waveform into coordinate values for storage.
[0042] The message segment identifier for waveform data is ZMW, and the data format of the ZMW segment is as follows: Figure 4 As shown in part (b), the first 4 bytes of the ZMW segment are fixed as " Furthermore, this segment contains only one field, the value of which is the encoded waveform data. The encoded data consists of data blocks. Each data block consists of 8 bytes, with the highest bit of each of these 8 bytes being 1. The last byte (Byte 8) of these 8 bytes is used to store the values of the highest bits of the preceding 7 bytes before encoding. When the number of bytes in the data is not a multiple of 7, it needs to be padded with 0x00, and then the highest bit of each byte in the padded data block is set to 1.
[0043] The decrypted waveform data consists of a data header and binary waveform data. The format of the decrypted waveform data is as follows: Figure 4 As shown in section (c), the data header consists of 8 bytes: 2 bytes for the checksum, 2 bytes for the waveform type, 1 byte for the Data Size, 2 bytes for the sampling rate, and 1 byte for reserved bytes. The Data Size represents the number of bytes representing the value of one sample point of the waveform (within 1 second). During unpacking, the checksum of the received data packet is calculated first. If the final result is 0, it indicates that the checksum is correct. This ensures that the received data has not been lost or tampered with during transmission, guaranteeing the accuracy and security of the waveform data.
[0044] In step 303, the arrhythmia portion of the electrocardiogram waveform is identified.
[0045] In this embodiment, the identification of the arrhythmia portion of the electrocardiogram waveform is achieved through a network model combining multi-scale CNN with channel attention residual mechanism (MCAR) or through a combination of MCAR model and improved bidirectional long short-term memory network (BiLSTM).
[0046] Optionally, step 303 includes steps 3031 to 3033.
[0047] In step 3031, the electrocardiogram waveform is preprocessed.
[0048] Preprocessing includes filtering, amplitude normalization, and heartbeat segmentation.
[0049] The electrocardiogram (ECG) waveforms received and analyzed from the vital signs monitor cannot be directly input into the MCAR model. Preprocessing of the analyzed ECG waveforms is required before they can be input into the MCAR model. In this embodiment, the ECG waveform preprocessing includes filtering, amplitude normalization, and heartbeat segmentation.
[0050] (1) Filtering Electrocardiogram (ECG) signals are characterized by their weakness, low frequency, and instability, making them highly susceptible to environmental interference and resulting in significant noise. Common noise sources include power line interference, electromyography (EMG) interference, and baseline drift noise, all of which urgently need to be suppressed and removed during the filtering process.
[0051] In this embodiment, a notch filter method is used to remove power frequency interference noise. A notch filter is a band-stop filter used to attenuate frequency components at and near a specific frequency, while having little impact on other frequency components. Therefore, the notch filter method is particularly suitable for removing 60Hz power frequency interference.
[0052] In this embodiment, wavelet transform is used to remove electromyographic interference noise. Wavelet transform can decompose the electrocardiogram signal into multiple frequency bands, and selectively remove noise based on the characteristics of different frequency bands. It is a method that can analyze the frequency characteristics of the signal from a local perspective.
[0053] In this embodiment, the moving average filtering method is used to remove baseline drift noise. Its basic principle is to take the average value of a continuous set of values in the input signal as the output, thereby reducing the randomness in the data and transforming it into a smoother signal trend.
[0054] Table 1: Denoising results of three denoising methods in different orders.
[0055]
[0056] In Table 1, "baseline" represents baseline drift noise, "power frequency" represents power frequency interference noise, and "electromyography" represents electromyography (EMG) interference noise. The denoising order of baseline-power frequency-electromyography is to remove baseline drift noise first, then power frequency interference noise, and finally EMG interference noise. Other denoising orders follow the same principle and are omitted here for further detail.
[0057] As can be seen from the six different denoising sequences in Table 1, processing EMG interference may need to be performed after other types of interference have been properly addressed to avoid adversely affecting the processing of baseline drift and power frequency interference. Power frequency interference should be processed before other types of interference, especially before processing EMG interference. Furthermore, processing baseline drift before EMG interference generally yields better denoising results. Therefore, an ideal denoising sequence is: first, eliminate power frequency interference; second, overcome baseline drift; and finally, filter EMG interference. This processing flow maximizes the quality of denoising.
[0058] (2) Amplitude normalization processing Since the amplitude of electrocardiogram (ECG) signals may vary under different acquisition equipment conditions, if they are directly input into a neural network without processing, this inconsistency in amplitude may affect the efficiency of deep learning models in analyzing and learning data, leading to biased model predictions.
[0059] In this embodiment, the maximum and minimum value normalization method is used to normalize the amplitude of the electrocardiogram signal. There are many related technologies that describe the implementation methods of maximum and minimum value normalization, which will not be detailed here.
[0060] (3) Heartbeat segmentation processing Expert annotations from a large number of arrhythmia samples show that arrhythmias are concentrated on the most prominent waveform on the electrocardiogram (ECG), the R wave. The area surrounding the R wave often covers the entire QRS complex, and even the entire cardiac cycle. Therefore, by segmenting the heartbeat and focusing the ECG waveform on the R wave and its vicinity, key features can be effectively extracted from a large number of ECG waveforms.
[0061] A normal adult's heart rate is between 60 and 100 beats per minute. The sampling frequency of a vital signs monitor is 360 Hz. Calculations show that the number of sampling points for one heartbeat is approximately 300. Therefore, in this embodiment, the segmentation method for a single heartbeat in the extracted electrocardiogram signal is as follows: 99 points are taken before the R wave, and 200 points are taken after the R wave, thus obtaining a complete heartbeat containing 300 data points.
[0062] Since the analysis of a single heartbeat cannot fully utilize key information such as the RR interval, PP interval, and compensatory pause, this embodiment adopts a heartbeat segmentation method based on a sliding time window. By analyzing long data segments containing multiple heartbeat waveforms, this method effectively extracts and utilizes these key interval information.
[0063] The heartbeat segmentation method based on a sliding time window includes: using a sliding window of length L heartbeats to segment the heartbeats preceding a certain heartbeat in the electrocardiogram signal. Each heart-shaped photo and the back Each heartbeat is extracted to obtain a data segment containing multiple heartbeats. The heartbeat annotations for this data segment use the heartbeat type annotation from the center of the window.
[0064] In step 3032, the preprocessed electrocardiogram waveform is input into a network model that combines multi-scale CNN with channel attention residual mechanism to obtain the morphological features of the electrocardiogram waveform.
[0065] The preprocessed electrocardiogram waveform is segmented into multiple heartbeats, and the final arrhythmia identification result is essentially a classification of each heartbeat. The classification results include five categories: N (normal rhythm), A (atrial ectopic heartbeat), V (ventricular ectopic heartbeat), L (left bundle branch block), and R (right bundle branch block). If a heartbeat belongs to one of these four categories, it indicates that the heartbeat is related to an arrhythmia; if a heartbeat belongs to category N, it indicates that the heartbeat is not related to an arrhythmia, i.e., a normal heartbeat.
[0066] During input, multiple heartbeats are sequentially fed into a network model that combines multi-scale CNN with channel attention residual mechanism to obtain the classification results of each heartbeat.
[0067] The structure of the MCAR model is explained below. The MCAR model consists of multi-scale CNN units and channel attention residual units connected in sequence. The multi-scale CNN units and channel attention residual units are used to extract the morphological features of the heartbeat.
[0068] When using only the MCAR model to identify the arrhythmia portion, the channel attention residual unit in the MCAR model is also connected to the flattened layer, the fully connected layer, and the Softmax activation function (i.e., the multi-scale CNN unit, channel attention residual unit, flattened layer, fully connected layer, and Softmax activation function are connected in sequence). At this time, morphological features are input into the fully connected layer and the Softmax activation function to identify the arrhythmia portion in the electrocardiogram waveform.
[0069] When using the MCAR model and the improved BiLSTM to jointly identify the arrhythmia component, the MCAR model only includes a multi-scale CNN unit and a channel attention residual unit connected in sequence. In this case, the MCAR model is used to extract morphological features from the electrocardiogram waveform and input the extracted morphological features into the improved BiLSTM. The improved BiLSTM then uses the morphological features to diagnose the arrhythmia.
[0070] Figure 5 This is a flowchart illustrating the process of extracting morphological features. Figure 5 Part (a) is a schematic diagram of the structure of a multi-scale CNN unit. Figure 5 Part (b) is a schematic diagram of the channel residual attention unit.
[0071] like Figure 5 As shown in part (a), the multi-scale CNN unit includes a first convolutional branch 501 and a second convolutional branch 502. The first convolutional branch 501 performs convolution using a conventional convolutional kernel, and the second convolutional branch 502 performs convolution using a dilated convolutional kernel.
[0072] Dilated convolution is a special type of convolution operation that introduces a dilation parameter into traditional convolution. The main advantage of using dilated convolution in branches is that it increases the receptive field of the network without requiring additional convolutional layers.
[0073] like Figure 5 As shown in part (a), the first convolutional branch 501 includes a first convolutional layer, a second convolutional layer, a first max pooling layer, a third convolutional layer, a fourth convolutional layer, and a second max pooling layer connected in sequence.
[0074] The second convolutional branch 502 includes a first dilated convolutional layer, a second dilated convolutional layer, a third max-pooling layer, a third dilated convolutional layer, a fourth dilated convolutional layer, and a fourth max-pooling layer connected in sequence.
[0075] Table 2 illustrates the parameters related to the convolution kernels of each convolutional layer in a multi-scale CNN unit.
[0076]
[0077] As shown in Table 2, the difference between the first convolution branch 501 and the second convolution branch is that the expansion rate of each hole convolution layer gradually increases.
[0078] In the first convolutional branch 501, each conventional convolutional layer uses convolutional kernels of different sizes (3, 5, 7, 11) to capture the temporal characteristics of the heartbeat signal layer by layer. As the kernel size increases, the waveform features that each layer can capture also increase. A 3×1 kernel can capture very fine ECG waveform features, such as the P wave or the initial phase of the QRS complex. A 5×1 kernel can extract slightly wider features, such as the entire PR interval or the main body of the QRS complex. A 7×1 kernel can extract a wider T wave and ST interval. An 11×1 kernel can potentially capture even wider waveform structures, such as the QT interval.
[0079] In the second convolutional branch 502, each dilated convolutional layer, by setting its dilation rate (sizes 2, 3, 4, 5), allows the network to increase its receptive field while maintaining computational efficiency, capturing a wider range of dependencies. A 3×1 convolutional kernel with a dilation rate of 2 does not change the dimension of the output features but spatially expands the receptive field, capturing more information than a standard 3×1 convolution. A 5×1 convolutional kernel with a dilation rate of 3 and a 7×1 convolutional kernel with a dilation rate of 4 further expand the receptive field, covering larger waveform segments, such as the entire QRS-T cycle. An 11×1 convolutional kernel with a dilation rate of 5 provides the largest receptive field, covering a large ECG cycle region and capturing the waveform dynamics of the entire ECG.
[0080] By combining the advantages of ordinary convolution and dilated convolution, multi-scale CNN units provide comprehensive feature extraction capabilities from fine to coarse. They can not only identify and analyze individual basic waveforms in ECG signals, such as P-waves, QRS complexes, and T-waves, but also capture the contextual relationships of these waveforms and their variation patterns in time series.
[0081] like Figure 5 As shown in part (b), the output of the first convolutional branch 501 and the output of the second convolutional branch 502 are processed by channel attention and residual connection (the outputs of channel attention and residual connection are concatenated in the channel dimension) to obtain two fused features. After concatenating the two fused features in the channel dimension, channel attention and residual connection are processed again on the concatenated fused features (similarly, the outputs of channel attention and residual connection are also concatenated in the channel dimension) to finally obtain morphological features.
[0082] In the basic structure of the channel attention mechanism, the weight coefficient of each channel is dynamically adjusted according to its importance. Channels with higher importance will receive greater weights, while those with less importance will be assigned lower weights. To avoid the gradient vanishing problem during training, residual network connections are also combined with channel attention.
[0083] Figure 6 This is a schematic diagram of channel attention processing and residual connection processing. Figure 6 Part (a) is a schematic diagram of channel attention processing. Figure 6 Part (b) is a schematic diagram of residual connection processing.
[0084] like Figure 6 As shown in section (a), channel attention processing includes compression and activation operations. The compression operation, also known as global flat pooling, converts a given value into a pool of size 1. The feature map is compressed into a feature vector. The feature vector of size. Where H and W are the height and width, respectively, and C is the number of channels.
[0085] The activation process consists of a first fully connected layer, a ReLU activation function, a second fully connected layer, and a Sigmoid activation function, connected sequentially. The first fully connected layer processes the compressed... The feature vector is transformed into a vector of size . The intermediate vector is then followed by a ReLU activation function. The second fully connected layer... The intermediate vector is transformed into a vector of size . The feature vector is then processed. Finally, a sigmoid activation function is applied, ensuring the value is between 0 and 1. The output of the sigmoid activation function is recalibrated with the input features to obtain the output of the channel attention processing.
[0086] like Figure 6 As shown in part (b), in the residual connection processing, the input feature map is convolved by two convolutional layers in sequence, and then concatenated with the feature map of the identity mapping itself to obtain the output of the residual processing.
[0087] Finally, the output of the residual processing and the output of the channel attention processing need to be concatenated in the channel dimension.
[0088] In actual electrocardiogram (ECG) signal analysis, different feature information has varying degrees of influence on the results. In this embodiment, a channel attention mechanism is used to automatically identify and prioritize key feature information in the ECG signal, while reducing reliance on less important information, adaptively selecting and emphasizing important features, and improving the discriminative ability of features, thereby obtaining morphological features.
[0089] In step 3033, the morphological features are input into an improved bidirectional long short-term memory network to obtain the arrhythmia recognition result.
[0090] If only the MCAR model is used to identify the arrhythmia portion, step 3033 should be replaced with: inputting morphological features into a sequentially connected flattened layer, a fully connected layer, and a Softmax activation function to obtain the arrhythmia identification result. The flattened layer can convert multidimensional morphological features into one-dimensional data, making it processable by the fully connected layer in the network. The fully connected layer is used to prevent network overfitting by randomly setting the activation values of a portion of neurons to zero, thereby increasing the model's generalization ability. Finally, the classification result of the heartbeat is obtained through the output of the Softmax activation function.
[0091] Step 3033 in this embodiment is for the case where the MCAR model and the improved BiLSTM are used to jointly identify the arrhythmia component.
[0092] BiLSTM can learn the correlation features between multiple heartbeats, including RR intervals, PP intervals, and compensatory pauses. The LSTM network generates internal feedback through connections between multiple units, allowing information to circulate between consecutive time points, thereby enhancing the network's understanding of long-term dependencies in time series. Furthermore, the constant error backpropagation mechanism within LSTM effectively mitigates the potential long latency issues when processing time series information.
[0093] In the BiLSTM structure, by combining a forward LSTM and a backward LSTM network, each network containing the same number of LSTM units, the output feature information from the two directions is concatenated as the final feature information expression, which can simultaneously capture information before and after the current data point of the ECG signal.
[0094] To process ECG signals more effectively and improve the classification accuracy of arrhythmias, the improved BiLSTM in this embodiment introduces a self-attention mechanism after the original BiLSTM.
[0095] The self-attention mechanism can simulate the information processing mode of the human brain. The BiLSTM layer extracts key features by capturing the contextual relationship of the electrocardiogram signal, and the subsequent self-attention layer can selectively assign weights to these features, focusing on the signal parts that are most critical to classification.
[0096] There are many ways to implement self-attention mechanisms, so we will omit the details here.
[0097] The features after attention processing are sequentially processed through a flattening layer, a fully connected layer, and a Softmax activation function to obtain the heartbeat classification result.
[0098] In step 304, assuming the network is functioning normally, the coordinate values of the converted electrocardiogram waveform are sent to the cloud server.
[0099] The cloud server connects to the hospital client, and the cloud server is used to send the received electrocardiogram waveform coordinate values to the hospital client.
[0100] When the network transmission is normal, the data recorded in the ambulance client's memory cache is uploaded to the cloud server one by one, and then the cloud server transmits the data to the emergency center client one by one.
[0101] In step 305, in the event of network malfunction, the coordinate values corresponding to the arrhythmia portion of the electrocardiogram waveform are cached and transmitted with delay.
[0102] Due to the potential intermittent nature of mobile communication signals on ambulance routes, a caching and delayed transmission strategy can be adopted for ECG data detecting arrhythmias in the event of network transmission interruption.
[0103] The first step is to perform network status awareness, that is, to determine whether the current network status is normal or abnormal.
[0104] Data is transmitted between the industrial control computer 22 and the vital signs monitor 21 via WebSocket. Therefore, the communication connection status is diagnosed by listening for "onclose" and "error" events on the industrial control computer 22. Based on actual drive test data analysis and considering that the vital signs monitor sends data once per second, this invention sets the WebSocket long connection timeout parameter to 10 seconds. Once the network is interrupted, a hierarchical caching mode for abnormal heart rate data is triggered (step 305 is executed).
[0105] This tiered caching model includes a three-level caching system to achieve a balance between resources and efficiency. These three levels of caching are: memory cache, SSD cache, and HDD persistent cache.
[0106] The memory cache adopts a circular buffer structure, which retains the raw ECG signal (in coordinate value format, equivalent to text format), time, arrhythmia detection type and other data for the most recent 60 seconds. It supports millisecond-level read and write for real-time analysis and emergency retrieval.
[0107] The SSD cache stores datasets marked as having heart rhythm abnormalities in the memory cache after a network interruption. The datasets are sharded by time (one file every 5 minutes) and an LSM-Tree structure is used to optimize high-frequency write performance.
[0108] The HDD persistent area uses columnar storage (Parquet format) to archive historical data, and reduces storage space by 70% through the Zstandard compression algorithm, while retaining clinical metadata (such as arrhythmia type and duration) for easy subsequent tracing.
[0109] The memory cache and SSD cache are located on the ambulance client, while the HDD persistent area is located on the cloud server.
[0110] When network transmission is interrupted, the abnormal heart rhythm data recorded in the ambulance client's memory cache is saved to the SSD cache. After the network transmission returns to normal, the data in the SSD cache is first transmitted to the cloud server and stored in the HDD persistent area. Subsequently, the normal data transmission process is resumed.
[0111] Data records stored in the persistent area of the cloud server are communicated to the emergency center client via messages and displayed on the screen, including the ambulance number and the number of records. Emergency center doctors can download ECG data on arrhythmias saved during network interruptions during patient transport from the cloud server as needed, and can also delete data stored in the cloud server as required.
[0112] In addition, after detecting a network interruption, to prevent frequent switching of caching modes, a Ping command is sent after 10 seconds to probe the network status. Afterward, a Ping command is sent every 3 seconds. If the transmission latency of three consecutive Ping commands is less than 500 milliseconds, it is confirmed that the network has returned to a stable transmission state, the WebSocket connection is re-established, and the abnormal heart rate data caching mode is canceled.
[0113] The selection of the above parameters is based on statistical analysis of actual road test data. In our actual road tests, over 70% of service interruptions lasted less than 10 seconds, with most lasting 3-5 seconds; of the 30% of service interruptions lasting more than 10 seconds, a few exceeded 20 seconds, some lasting several minutes, and occasionally reaching more than ten minutes. Additionally, when the Ping command latency was less than 500 milliseconds, the continuously displayed ECG waveforms in the emergency center were normal; when the Ping command latency was greater than 600 milliseconds but less than 1000 milliseconds, the continuously displayed ECG waveforms in the emergency center showed slight jitter; and when the Ping command latency was greater than 1500 milliseconds, the continuously displayed ECG waveforms in the emergency center showed obvious jitter.
[0114] In this embodiment, since text data transmission is faster, more efficient, and less prone to packet loss than image data transmission over a network, the coordinate values of the converted ECG waveform are sent to the cloud server, and the cloud server then sends the received ECG waveform coordinate values to the hospital client. This is equivalent to converting the ECG waveform into text data instead of directly transmitting graphic data, thus ensuring stable transmission of the ECG waveform. Furthermore, by hierarchically caching and delaying the transmission of coordinate values corresponding to the arrhythmia portion of the ECG waveform in the event of network anomalies, the integrity of the ECG waveform under abnormal network conditions can be guaranteed, and storage overflow due to large cached data volume cannot be prevented (only the coordinate values of the arrhythmia portion are stored, not the entire ECG coordinate values, thus requiring less cached data).
[0115] The following are device embodiments of this application. For details not described in detail in the device embodiments, please refer to the above method embodiments.
[0116] Figure 7 A schematic diagram of an ambulance electrocardiogram (ECG) data transmission device provided in an exemplary embodiment of this disclosure is shown. See also Figure 7 The ambulance electrocardiogram data transmission device 700 includes: a receiving module 701, a conversion module 702, an arrhythmia recognition module 703, a sending module 704, and a buffer module 705.
[0117] The receiving module 701 is used by the industrial control computer in the ambulance to receive life monitoring data from the vital signs monitor.
[0118] The conversion module 702 is used to convert vital signs monitoring data into electrocardiogram (ECG) waveforms and convert the ECG waveforms into coordinate values for storage.
[0119] The arrhythmia recognition module 703 is used to identify the arrhythmia portion of an electrocardiogram waveform.
[0120] The sending module 704 is used to send the coordinate values of the converted electrocardiogram waveform to the cloud server when the network is normal. The cloud server is connected to the hospital client and is used to send the received electrocardiogram waveform coordinate values to the hospital client.
[0121] The caching module 705 is used to perform hierarchical caching and delayed transmission of the coordinate values corresponding to the arrhythmia part of the electrocardiogram waveform in the event of abnormal network conditions.
[0122] Optionally, the conversion module 702 is also used to parse the vital signs data using the HL7 protocol, an international standard for medical information exchange, to obtain the patient's physiological information data, including electrocardiogram data, blood oxygen saturation data, non-invasive blood pressure, and respiratory rate data; to acquire the electrocardiogram waveform from the electrocardiogram data, and to convert the electrocardiogram waveform into coordinate values for storage.
[0123] Optionally, the arrhythmia recognition module 703 is also used to preprocess the electrocardiogram waveform, including filtering, amplitude normalization and heartbeat segmentation; input the preprocessed electrocardiogram waveform into a network model combining multi-scale CNN and channel attention residual mechanism to obtain the morphological features of the electrocardiogram waveform; input the morphological features into an improved bidirectional long short-term memory network to obtain the arrhythmia recognition result.
[0124] Optionally, in the arrhythmia recognition module 703, the network model combining multi-scale CNN and channel attention residual mechanism includes multi-scale CNN units and channel attention residual units connected in sequence; the multi-scale CNN unit includes a first convolution branch and a second convolution branch, the first convolution branch uses a conventional convolution kernel for convolution, and the second convolution branch uses a dilated convolution kernel for convolution; the channel attention residual unit includes channel attention processing and residual connection processing.
[0125] Optionally, in the arrhythmia recognition module 703, the improved bidirectional long short-term memory network includes a bidirectional long short-term memory network and a self-attention mechanism connected to the bidirectional long short-term memory network.
[0126] It should be noted that the above embodiments of the ambulance electrocardiogram (ECG) data transmission device are only illustrated by the division of the above functional modules. In practical applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. Furthermore, the ambulance ECG data transmission device and the ambulance ECG data transmission method embodiments belong to the same concept, and their specific implementation process is detailed in the method embodiments, which will not be repeated here.
[0127] The module division in this embodiment is illustrative and represents only one logical functional division. In actual implementation, other division methods are possible. Furthermore, the functional modules in the various embodiments of this disclosure can be integrated into a single processor, exist as separate physical entities, or be integrated into a single module. The integrated modules described above can be implemented in hardware or as software functional modules.
[0128] If the integrated module is implemented as a software functional module and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this disclosure, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a terminal device (which may be a personal computer, mobile phone, or communication device, etc.) or processor to execute all or part of the steps of the methods of the various embodiments of this disclosure. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0129] Figure 8 This is a schematic diagram of the structure of a computer device provided in an embodiment of this disclosure. For example... Figure 8 As shown, the computer device 800 includes a processor 801 and a memory 802.
[0130] Processor 801 may include one or more processing cores, such as a quad-core processor, an octa-core processor, etc. Processor 801 may be implemented using at least one hardware form selected from DSP (Digital Signal Processing), FPGA (Field-Programmable Gate Array), and PLA (Programmable Logic Array). Processor 801 may also include a main processor and a coprocessor. The main processor, also known as a CPU (Central Processing Unit), is used to process data in the wake-up state; the coprocessor is a low-power processor used to process data in the standby state. In some embodiments, processor 801 may integrate a GPU (Graphics Processing Unit), which is responsible for rendering and drawing the content to be displayed on the screen. In some embodiments, processor 801 may also include an AI (Artificial Intelligence) processor, which is used to handle computational operations related to machine learning.
[0131] The memory 802 may include one or more computer-readable storage media, which may be non-transitory. The memory 802 may also include high-speed random access memory and non-volatile memory, such as one or more disk storage devices or flash memory devices. In some embodiments, the non-transitory computer-readable storage media in the memory 802 is used to store at least one instruction, which is executed by the processor 801 to implement the ambulance electrocardiogram data transmission method provided in this disclosure embodiment.
[0132] Those skilled in the art will understand that Figure 8 The structure shown does not constitute a limitation on the computer device 800, and may include more or fewer components than shown, or combine certain components, or use different component arrangements.
[0133] This disclosure also provides a non-transitory computer-readable storage medium, which, when the instructions in the storage medium are executed by the processor of a computer device, enables the computer device to execute the ambulance electrocardiogram data transmission method provided in this disclosure.
[0134] This disclosure also provides a computer program product, including a computer program / instructions, which, when executed by a processor, implement the ambulance electrocardiogram data transmission method provided in this disclosure.
[0135] The above description is merely an optional embodiment of this disclosure and is not intended to limit this disclosure. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this disclosure should be included within the protection scope of this disclosure.< / cr>
Claims
1. A method for transmitting electrocardiogram (ECG) data in an ambulance, characterized in that, The method includes: The industrial control computer inside the ambulance receives vital sign monitoring data from the vital signs monitor. The vital signs data are converted into electrocardiogram (ECG) waveforms, and the ECG waveforms are then converted into coordinate values for storage. Identify the arrhythmia portion of the electrocardiogram waveform; Under normal network conditions, the coordinate values of the converted electrocardiogram waveform are sent to the cloud server. The cloud server is connected to the hospital client and is used to send the received electrocardiogram waveform coordinate values to the hospital client. In the event of network abnormalities, the coordinate values corresponding to the arrhythmia portion of the electrocardiogram waveform are cached and transmitted with delay in a tiered manner.
2. The method according to claim 1, characterized in that, The step of converting the vital signs data into an electrocardiogram (ECG) waveform and then converting the ECG waveform into coordinate values for storage includes: The vital signs data are analyzed using the HL7 protocol, an international standard for medical information exchange, to obtain the patient's physiological information data, including electrocardiogram data, blood oxygen saturation data, non-invasive blood pressure, and respiratory rate data. The electrocardiogram (ECG) waveform in the ECG data is obtained, and the ECG waveform is converted into coordinate values and stored.
3. The method according to claim 1 or 2, characterized in that, The identification of the arrhythmia portion in the electrocardiogram waveform includes: The electrocardiogram waveform is preprocessed, including filtering, amplitude normalization, and heartbeat segmentation. The preprocessed electrocardiogram waveform is input into a network model that combines multi-scale CNN with channel attention residual mechanism to obtain the morphological features of the electrocardiogram waveform; The morphological features are input into an improved bidirectional long short-term memory network to obtain arrhythmia recognition results.
4. The method according to claim 3, characterized in that, The network model combining multi-scale CNN with channel attention residual mechanism includes multi-scale CNN units and channel attention residual units connected in sequence; The multi-scale CNN unit includes a first convolutional branch and a second convolutional branch. The first convolutional branch uses a conventional convolutional kernel for convolution, and the second convolutional branch uses a dilated convolutional kernel for convolution. The channel attention residual unit includes channel attention processing and residual connection processing.
5. The method according to claim 3, characterized in that, The improved bidirectional long short-term memory network includes a bidirectional long short-term memory network and a self-attention mechanism connected to the bidirectional long short-term memory network.
6. A data transmission device for electrocardiogram (ECG) data in an ambulance, characterized in that, The device includes: The receiving module is used by the industrial control computer inside the ambulance to receive vital signs monitoring data from the vital signs monitor. The conversion module is used to convert the vital signs data into electrocardiogram (ECG) waveforms and convert the ECG waveforms into coordinate values for storage. The arrhythmia recognition module is used to identify the arrhythmia portion of the electrocardiogram waveform; The sending module is used to send the coordinate values of the converted electrocardiogram waveform to the cloud server when the network status is normal. The cloud server is connected to the hospital client and is used to send the received electrocardiogram waveform coordinate values to the hospital client. The caching module is used to perform hierarchical caching and delayed transmission of the coordinate values corresponding to the arrhythmia portion of the electrocardiogram waveform in the event of network abnormalities.
7. The apparatus according to claim 6, characterized in that, The conversion module is also used to parse the vital signs data using the HL7 protocol, an international standard for medical information exchange, to obtain the patient's physiological information data, including electrocardiogram data, blood oxygen saturation data, non-invasive blood pressure, and respiratory rate data; to acquire the electrocardiogram waveform from the electrocardiogram data, and to convert the electrocardiogram waveform into coordinate values for storage.
8. A computer device, characterized in that, The computer device includes a memory and a processor, wherein the memory stores at least one computer program, which is loaded and executed by the processor to implement the method according to any one of claims 1 to 6.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores at least one computer program, which is loaded and executed by a processor to implement the method according to any one of claims 1 to 6.
10. A computer program product comprising a computer program / instructions, characterized in that, When the computer program / instructions are executed by the processor, they implement the method described in any one of claims 1 to 6.