Automatic testing method and device for breathing machine, electronic equipment and storage medium

By obtaining the test function library and ventilator standard data, and using test scripts to convert and compare the original data of ventilator, the problem of cumbersome detection of ventilator HL7 information in the existing technology is solved, and the automated testing of ventilator HL7 function is realized. Improve verification efficiency and accuracy.

CN119046147APending Publication Date: 2024-11-29SHENZHEN COMEN MEDICAL INSTR
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411086381.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-08
Publication Date
2024-11-29

AI Technical Summary

Technical Problem

In the prior art, the information detection of ventilator HL7 relies on manual verification, which is cumbersome and time-consuming, prone to mistakes, and is difficult to ensure accuracy.

Method used

By obtaining the test function library, ventilator attribute information and ventilator standard data, the original data is converted and compared with the test script to realize automated testing of the ventilator, simplifying the verification process, and improving verification efficiency and accuracy.

Benefits of technology

Automatic testing of the HL7 function of the ventilator is realized, the verification process is simplified, the verification efficiency and accuracy are improved, and the labor intensity is reduced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119046147A_ABST
    Figure CN119046147A_ABST
Patent Text Reader

Abstract

The invention discloses an automatic testing method and device for a breathing machine, electronic equipment and a storage medium. The automatic test method for the breathing machine comprises the following steps: acquiring a test function library, breathing machine attribute information, breathing machine standard data and a test script; wherein the breathing machine standard data comprises a plurality of pieces of data represented in a Chinese form by a breathing machine of a preset model in a preset ventilation mode; according to the test function library and the breathing machine attribute information, receiving original data sent by the breathing machine; wherein the original data is test data of a breathing machine of a preset model in a preset ventilation mode; and converting the original data according to the test script to obtain respirator conversion data, and comparing the respirator conversion data with the respirator standard data to complete the automatic test of the respirator. According to the technical scheme of the embodiment of the invention, the verification process is simplified, and the verification efficiency and accuracy are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present invention relate to the field of medical testing technology, and in particular to a method, device, electronic equipment and storage medium for automated testing of a ventilator. Background Art

[0002] In the field of modern medicine, ventilators, as an effective means of artificially replacing spontaneous ventilation functions, have been widely used in scenarios such as respiratory failure caused by various reasons, anesthesia respiratory management, respiratory support therapy, and emergency resuscitation.

[0003] According to different patient needs and usage scenarios, the types of ventilators are becoming more and more diverse. In order to unify the data interaction of ventilators between heterogeneous systems in various medical institutions, a communication protocol for exchanging data between medical systems, namely Health Level 7 (HL7), is proposed. HL7 data brings together the standard formats used by different manufacturers to design interfaces between application software, which facilitates data transmission between medical devices from different manufacturers. Different types of ventilators have different breathing modes, and each breathing mode has different ventilation parameters and monitoring parameters, with a huge amount of information. These information are encoded and sent in the format of HL7 information to facilitate the detection of HL7 information. However, when detecting HL7 information in the prior art, it depends on manual reference to the coding table to check the HL7 information one by one to determine whether the received HL7 information is accurate and whether there is any mis-sent or missed transmission. In this way, the detection of HL7 information sent by the ventilator is cumbersome and time-consuming, and the long-term manual repetitive verification operation is prone to omissions. Summary of the invention

[0004] The present invention provides a ventilator automatic testing method, device, electronic equipment and storage medium to simplify the verification process and improve the verification efficiency and accuracy.

[0005] According to one aspect of the present invention, there is provided a method for automated testing of a ventilator, comprising:

[0006] Acquire a test function library, ventilator attribute information, ventilator standard data and a test script; wherein the ventilator standard data includes a plurality of data represented in Chinese in a preset ventilation mode of a preset ventilator model;

[0007] According to the test function library and the ventilator attribute information, receiving the original data sent by the ventilator; wherein the original data is the test data of the ventilator of the preset model in the preset ventilation mode;

[0008] The original data is converted according to the test script to obtain ventilator conversion data, and the ventilator conversion data is compared with the ventilator standard data to complete the automated test of the ventilator.

[0009] Optionally, receiving raw data sent from a ventilator according to the test function library and the ventilator attribute information includes:

[0010] The test function library includes a first function library, and the first function library includes a socket library;

[0011] According to the ventilator attribute information, the first function library is called to establish a communication connection with the ventilator of the preset model to receive the original data sent by the ventilator.

[0012] Optionally, the receiving the raw data sent by the ventilator includes:

[0013] A multi-threaded receiving method is adopted to obtain a plurality of sub-data; wherein the sub-data is part of the original data;

[0014] The plurality of sub-data are concatenated to obtain the original data.

[0015] Optionally, converting the original data according to the test script to obtain ventilator conversion data, and comparing the ventilator conversion data with the ventilator standard data to complete the automated test of the ventilator, includes:

[0016] Translating the raw data according to the test script to determine the ventilator conversion data;

[0017] Automatically comparing the ventilator conversion data with the ventilator standard data to generate a comparison result;

[0018] According to the comparison result, it is determined whether there is any error in the original data sent from the ventilator.

[0019] Optionally, translating the original data according to the test script to determine the ventilator conversion data includes:

[0020] The test function library includes a second function library, and the second function library includes a pandas library;

[0021] The ventilator mode parameters are stored in a data storage table in Chinese to obtain a configuration file; wherein the ventilator mode parameters include operating data of ventilators under different preset models and different preset ventilation modes;

[0022] According to the configuration file, the second function library is called to read the data storage table to translate the original data into Chinese form to obtain the ventilator conversion data.

[0023] Optionally, determining whether there is an error in the original data sent from the ventilator according to the comparison result includes:

[0024] When the comparison result indicates that the ventilator conversion data is consistent with the ventilator standard data, the ventilator automation test is completed;

[0025] When the comparison result indicates that the ventilator conversion data does not match the ventilator standard data, the ventilator conversion data is marked for secondary comparison.

[0026] Optionally, before acquiring the test function library, the ventilator attribute information, the ventilator standard data and the test script, the method further includes:

[0027] Establish a test environment for automated testing of ventilators.

[0028] According to another aspect of the present invention, there is provided a ventilator automated testing device, comprising:

[0029] A data acquisition module, used to acquire a test function library, ventilator attribute information, ventilator standard data and a test script; wherein the ventilator standard data includes a plurality of data represented in Chinese in a preset ventilation mode of a preset ventilator model;

[0030] A raw data receiving module, used for receiving raw data sent by the ventilator according to the test function library and the ventilator attribute information; wherein the raw data is the test data of the ventilator of the preset model in the preset ventilation mode;

[0031] The automated testing module is used to convert the original data according to the test script to obtain ventilator conversion data, and compare the ventilator conversion data with the ventilator standard data to complete the automated testing of the ventilator.

[0032] According to another aspect of the present invention, there is also provided an electronic device, the electronic device comprising:

[0033] at least one processor; and

[0034] a memory communicatively connected to the at least one processor; wherein,

[0035] The memory stores a computer program that can be executed by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can execute the ventilator automated testing method described in any embodiment of the first aspect.

[0036] According to another aspect of the present invention, a computer-readable storage medium is provided, characterized in that the computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the ventilator automated testing method described in any embodiment of the first aspect when executed.

[0037] The automated ventilator testing method provided by the embodiment of the present invention obtains the test function library, ventilator attribute information, ventilator standard data and test script; wherein, the ventilator standard data is in Chinese form, so that it is convenient for subsequent intuitive verification, and there is no need to check one by one against the coding table, which is conducive to simplifying the verification process and improving the accuracy of the verification. According to the test function library and the ventilator attribute information, the original data sent by the ventilator is received. According to the test script, the original data can be converted into a format that is easy to verify, and the ventilator conversion data can be obtained, and the ventilator standard data corresponding to the ventilator conversion data can be automatically matched, and the ventilator conversion data can be compared with the ventilator standard data to determine whether the data sent by the ventilator is wrongly sent, missed or multiple, so as to realize the automated test of the ventilator HL7 function. Compared with relying on manual verification by checking the coding table one by one, the embodiment of the present invention is conducive to simplifying the verification process and improving the efficiency and accuracy of the verification.

[0038] It should be understood that the contents described in this section are not intended to identify the key or important features of the embodiments of the present invention, nor are they intended to limit the scope of the present invention. Other features of the present invention will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0040] Figure 1 It is a flowchart of a ventilator automated testing method provided according to an embodiment of the present invention;

[0041] Figure 2 This is a specific flow chart of step S120 in a ventilator automated testing method provided according to an embodiment of the present invention;

[0042] Figure 3This is a specific flow chart of step S121 in a ventilator automated testing method provided according to an embodiment of the present invention;

[0043] Figure 4 It is a specific flow chart of step S130 in a ventilator automated testing method provided according to an embodiment of the present invention;

[0044] Figure 5 This is a specific flow chart of step S131 in a ventilator automated testing method provided according to an embodiment of the present invention;

[0045] Figure 6 Another method for automatically testing a ventilator is provided according to an embodiment of the present invention;

[0046] Figure 7 It is a flowchart of another automated testing method for a ventilator provided according to an embodiment of the present invention;

[0047] Figure 8 is a structural schematic diagram of a ventilator automated testing device provided according to an embodiment of the present invention;

[0048] Fig. 9 It is a schematic diagram of the structure of an electronic device provided according to an embodiment of the present invention. DETAILED DESCRIPTION

[0049] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.

[0050] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0051] An embodiment of the present invention provides a method for automated testing of a ventilator. Figure 1 A flowchart of a ventilator automated testing method provided by an embodiment of the present invention. This embodiment is applicable to the case of automated testing of HL7 functions of ventilators of different types and different ventilation modes. The method can be performed by a ventilator automated testing device, which can be implemented in the form of hardware and / or software. The ventilator automated testing device can be configured in an electronic device such as a computer or server. The ventilator automated testing method specifically includes the following steps:

[0052] S110, obtaining a test function library, ventilator attribute information, ventilator standard data and a test script; wherein the ventilator standard data includes a plurality of data represented in Chinese in a preset ventilation mode of a preset ventilator model.

[0053] Exemplarily, the test function library is a third-party library that executes various functions in the Python computer language. The ventilator attribute information includes the ventilator's own relevant information about data transmission. The test script is a computer program for automated testing of the HL7 function of the ventilator, which can be used to automatically identify the data corresponding to the ventilator under different preset models and different preset ventilation modes. The test script can be written by the user using the Python computer language according to actual needs, and there is no limitation here.

[0054] The standard data of ventilators are the standard parameters obtained by normal data transmission of ventilators of different models in different ventilation modes. According to different patient categories, ventilators can be roughly divided into invasive ventilators, non-invasive ventilators and neonatal ventilators, etc.; according to the needs of ventilators in different application scenarios, ventilators can also be subdivided into emergency transport ventilators, intensive care ventilators and high-frequency oscillation ventilators, etc. Different types of ventilators have different ventilation modes, and the control parameters and monitoring parameters of each ventilation mode are as high as hundreds. In addition, the standard data of ventilators can also include waveform information and alarm information, such as: message source, parameter setting value, parameter monitoring value, unit, alarm limit, alarm level and patient information. Therefore, different models of ventilators are set with corresponding standard data of ventilators in different ventilation modes, and the amount of data is huge. In order to facilitate subsequent information verification, the standard data of ventilators is in Chinese, so there is no need to translate one by one against the coding table during verification to complete the verification, which simplifies the verification process.

[0055] S120. Receive original data sent by the ventilator according to the test function library and the ventilator attribute information; wherein the original data is the test data of the ventilator of a preset model in a preset ventilation mode.

[0056] For example, according to the acquired ventilator attribute information, that is, the data transmission status of the ventilator, when the ventilator is in a state where data can be sent, the original data sent by the ventilator is received in real time according to the test function library, that is, the HL7 data obtained by real-time testing of the preset model of the ventilator in the preset ventilation mode. For ventilators of different preset models and working in different preset ventilation modes, the test script can automatically identify the model and ventilation mode of the ventilator before testing, and perform corresponding data verification.

[0057] S130, converting the original data according to the test script to obtain ventilator conversion data, and comparing the ventilator conversion data with the ventilator standard data to complete the automated test of the ventilator.

[0058] Exemplarily, according to the test script, the original data in the HL7 information format can be converted to obtain the ventilator conversion data for data verification. And the test script can match the ventilator standard data corresponding to the model and ventilation mode of the current ventilator, and compare and verify the ventilator conversion data with the ventilator standard data, so as to determine whether the ventilator conversion data sent by the ventilator is consistent with the ventilator standard data, whether there is a wrong transmission, missing or multiple transmission, and realize the automatic test of the ventilator HL7 function. Compared with the related art that relies on manual data verification one by one, the ventilator automatic test method provided by the embodiment of the present invention can quickly complete the automatic test of the ventilator HL7 function, and is conducive to improving the accuracy of data verification.

[0059] The automated ventilator testing method provided by the embodiment of the present invention obtains the test function library, ventilator attribute information, ventilator standard data and test script; wherein, the ventilator standard data is in Chinese form, so that it is convenient for subsequent intuitive verification, and there is no need to check one by one against the coding table, which is conducive to simplifying the verification process and improving the accuracy of the verification. According to the test function library and the ventilator attribute information, the original data sent by the ventilator is received. According to the test script, the original data can be converted into a format that is easy to verify, and the ventilator conversion data can be obtained, and the ventilator standard data corresponding to the ventilator conversion data can be automatically matched, and the ventilator conversion data can be compared with the ventilator standard data to determine whether the data sent by the ventilator is wrongly sent, missed or multiple, so as to realize the automated test of the ventilator HL7 function. Compared with relying on manual verification by checking the coding table one by one, the embodiment of the present invention is conducive to simplifying the verification process and improving the efficiency and accuracy of the verification.

[0060] A feasible implementation method is: Figure 2 FIG. 1 is a specific flow chart of step S120 in a method for automatically testing a ventilator provided in an embodiment of the present invention. Figure 2As shown, step S120 receives the original data sent by the ventilator according to the test function library and the ventilator attribute information, which specifically includes the following steps:

[0061] S121. According to the ventilator attribute information, the first function library is called to establish a communication connection with a ventilator of a preset model to receive original data sent by the ventilator.

[0062] Exemplarily, the test function library includes a first function library, and the first function library includes a socket library. In the Python computer language, the socket library can be used to realize a real-time communication connection between a computer and an external device to send and receive data. Exemplarily, in this embodiment, the computer is connected to the ventilator via a network cable, and the socket library is called to realize a real-time communication connection between the computer and the ventilator, so that the computer can receive the original data in the HL7 information format sent by the ventilator.

[0063] A feasible implementation method is: Figure 3 FIG. 1 is a specific flow chart of step S121 in a method for automatically testing a ventilator provided in an embodiment of the present invention. Figure 3 As shown, the receiving of the original data sent by the ventilator in step S121 specifically includes the following steps:

[0064] S1211. Acquire multiple sub-data using a multi-threaded receiving method; wherein the sub-data is part of the original data.

[0065] Exemplarily, a multi-threaded receiving method is a method in which a computer and a ventilator have multiple parallel data transmission channels, so that the computer can receive data. In this embodiment, a piece of original data corresponding to a preset model of a ventilator in a preset ventilation mode can be divided into multiple sub-data, and the multiple sub-data are sent to the computer through multiple data transmission channels. The computer can adopt a multi-threaded receiving method to simultaneously receive multiple sub-data sent by the ventilator. Compared with the single-threaded receiving method, the integrity of the data sent by the ventilator can be guaranteed, and the data receiving speed can be increased, which is conducive to improving the efficiency of the automated testing of the ventilator.

[0066] S1212. Join multiple sub-data to obtain original data.

[0067] Exemplarily, a special method of splicing the received multiple sub-data is used to obtain the complete original data sent by the ventilator. In this way, the complete original data is split into multiple sub-data and then sent by multiple threads, and the multiple sub-data received by multiple threads are spliced ​​to obtain the complete original data, which is conducive to improving the speed of data transmission, and further conducive to improving the efficiency of the automated test of the ventilator.

[0068] The automated testing method for a ventilator provided in this embodiment uses a multi-threaded receiving method to obtain sub-data and perform splicing, thereby obtaining complete original data and improving the data transmission speed.

[0069] A feasible implementation method is: Figure 4 FIG. 1 is a specific flow chart of step S130 in a method for automatically testing a ventilator provided in an embodiment of the present invention. Figure 4 As shown, in step S130, the original data is converted according to the test script to obtain ventilator conversion data, and the ventilator conversion data is compared with the ventilator standard data to complete the automated test of the ventilator, which specifically includes the following steps:

[0070] S131. Translate the original data according to the test script to determine the ventilator conversion data.

[0071] Exemplarily, the test script can translate the original data into Chinese to obtain ventilator conversion data for subsequent automated data verification.

[0072] S132, automatically comparing the ventilator conversion data and the ventilator standard data to generate a comparison result.

[0073] Exemplarily, the test script can match the ventilator standard data corresponding to the ventilator conversion data, and automatically compare the ventilator conversion data with the ventilator standard data to generate a comparison result based on the consistency between the ventilator conversion data and the ventilator standard data, and display the comparison result in real time.

[0074] S133. Determine whether there are any errors in the original data sent from the ventilator based on the comparison result.

[0075] Exemplarily, the generated comparison results can be used to determine whether the original data sent by the ventilator is accurate, thereby completing the automated test of the ventilator.

[0076] A feasible implementation method is: Figure 5 FIG. 1 is a specific flow chart of step S131 in a method for automatically testing a ventilator provided in an embodiment of the present invention. Figure 5 As shown, the step S131 of translating the original data according to the test script to determine the ventilator conversion data specifically includes the following steps:

[0077] S1311. Store the ventilator mode parameters in Chinese in a data storage table to obtain a configuration file; wherein the ventilator mode parameters include operating data of ventilators under different preset models and different preset ventilation modes.

[0078] Exemplarily, the ventilator mode parameters include standard data for the operation of ventilators of different preset models, and standard data for the operation of the same preset model of ventilator in different preset ventilation modes, so the ventilator mode parameters may include multiple pieces of standard operation data. The ventilator mode parameters are stored in Chinese, so that a configuration file can be obtained.

[0079] S1312. According to the configuration file, call the second function library to read the data storage table to translate the original data into Chinese format to obtain ventilator conversion data.

[0080] Exemplarily, the test function library includes a second function library, and the second function library includes a pandas library. Among them, the pandas library is used to read data. The configuration file is a data storage table storing ventilator mode parameters in Chinese. Exemplarily, the data storage table may include a plain text file (Comma-Separated Values, CSV file). In this embodiment, calling the pandas library to read the data storage table of the configuration file can translate the original data sent by the ventilator into Chinese, thereby determining the ventilator conversion data.

[0081] A feasible implementation method, based on the above embodiments, determines whether there is an error in the original data sent by the ventilator according to the comparison result in step S133, specifically includes the following steps:

[0082] S1331. When the comparison result indicates that the ventilator conversion data is consistent with the ventilator standard data, the ventilator automation test is completed.

[0083] For example, if the generated comparison result indicates that the ventilator conversion data is completely consistent with the ventilator standard data, it means that the real-time test data of the ventilator meets the standard parameters of the preset model of ventilator operating in the corresponding preset ventilation mode. Therefore, the ventilator has passed the test and can be shipped and put into use normally.

[0084] S1332. When the comparison result indicates that the ventilator conversion data does not match the ventilator standard data, the ventilator conversion data is marked for secondary comparison.

[0085] Exemplarily, if the generated comparison result indicates that there is a difference between the ventilator conversion data and the ventilator standard data, the data with differences in the ventilator conversion data can be screened out and marked, so as to facilitate a secondary comparison of the data with differences. The secondary comparison can be performed by manual verification to improve the accuracy of data verification. Since the ventilator conversion data is already data in Chinese form obtained by form conversion, and the ventilator standard data is also data in Chinese form, therefore, when performing the secondary comparison, the staff can directly check the marked ventilator conversion data against the ventilator standard data, without the need to refer to the coding table for translation one by one. This can effectively reduce the workload and working hours of the staff, which is conducive to improving the accuracy and efficiency of data verification.

[0086] The automated ventilator testing method provided in this embodiment uses a test script to automatically translate and verify the data information sent by the ventilator, which greatly reduces the manual labor intensity and is conducive to improving the verification efficiency and accuracy.

[0087] A feasible implementation method is: Figure 6 This is another automatic testing method for a ventilator provided by an embodiment of the present invention. Figure 6 As shown, before step S110, it also includes:

[0088] S140. Establish a test environment for automated testing of ventilators.

[0089] Exemplarily, before performing the automated test of the HL7 function of the ventilator, a test environment needs to be set up on the computer in advance. In this embodiment, Python and Pycharm software required for the test process need to be downloaded and installed on the computer to facilitate coding in the subsequent process. After that, the third-party libraries required to execute each function need to be downloaded and installed on the computer. Exemplarily, the third-party libraries may include: threading, socket, pandas, and tkinter, etc., which are not limited here.

[0090] The automated ventilator testing method provided in this embodiment sets up a test environment before testing the ventilator, which is convenient for coding, and can implement function execution by calling corresponding third-party libraries, which is helpful to simplify the verification process and improve the accuracy of verification.

[0091] A feasible embodiment, Figure 7 FIG. 1 is a flow chart of another method for ventilator automation testing provided by an embodiment of the present invention. Figure 7 As shown, the ventilator automated testing method comprises the following steps:

[0092] S1, start;

[0093] S2. Create a configuration file;

[0094] S3, read the data storage table;

[0095] S4, determine whether the reading is successful; if not, proceed to step S5; if yes, proceed to step S6;

[0096] S5, check the code and files, then go to step S3;

[0097] S6, connect to ventilator;

[0098] S7, receive and translate HL7 information;

[0099] S8, determine whether the information is successfully received; if not, proceed to step S9; if yes, proceed to step S10;

[0100] S9, check the code, then go to step S6;

[0101] S10, perform automated testing and generate test results; if the test results are incorrect, proceed to step S11; if the test results are correct, proceed to step S13;

[0102] S11, perform manual verification and generate verification results; if the verification result is incorrect, proceed to step S12; if the verification result is correct, proceed to step S13;

[0103] S12, test failed;

[0104] S13. Test successful.

[0105] The embodiment of the present invention also provides a ventilator automatic testing device. Figure 8 Schematic diagram of the structure of a ventilator automatic test device provided by an embodiment of the present invention. Figure 8 As shown, the ventilator automated testing device 100 comprises:

[0106] The data acquisition module 101 is used to acquire the test function library, ventilator attribute information, ventilator standard data and test scripts; wherein the ventilator standard data includes a plurality of data represented in Chinese in a preset ventilation mode of a preset ventilator model;

[0107] The raw data receiving module 102 is used to receive the raw data sent by the ventilator according to the test function library and the ventilator attribute information; wherein the raw data is the test data of the ventilator of a preset model under a preset ventilation mode;

[0108] The automated testing module 103 is used to convert the original data according to the test script to obtain ventilator conversion data, and compare the ventilator conversion data with the ventilator standard data to complete the automated testing of the ventilator.

[0109] The ventilator automated test device provided in the embodiment of the present invention can execute the ventilator automated test method provided in any embodiment of the present invention, and has the functional modules and beneficial effects corresponding to the execution method. Specifically, the data acquisition module 101 acquires the test function library, ventilator attribute information, ventilator standard data and test script; wherein, the ventilator standard data is in Chinese form, so as to facilitate the subsequent intuitive verification, without the need to check one by one against the coding table, which is conducive to simplifying the verification process and improving the verification accuracy. The original data receiving module 102 receives the original data sent by the ventilator according to the test function library and the ventilator attribute information. The automated test module 103 can convert the original data into a format that is easy to verify according to the test script, obtain the ventilator conversion data, and automatically match the ventilator standard data corresponding to the ventilator conversion data, compare the ventilator conversion data with the ventilator standard data, determine whether the data sent by the ventilator is wrongly sent, missed or multiple, and realize the automated test of the ventilator HL7 function. The ventilator automated test device can effectively reduce the dependence on manual labor, which is conducive to simplifying the verification process and improving the verification efficiency and accuracy.

[0110] In an achievable embodiment, based on the above embodiment, the original data receiving module 102 includes:

[0111] The communication connection unit is used to call the first function library according to the ventilator attribute information, establish a communication connection with a ventilator of a preset model, and receive the original data sent by the ventilator.

[0112] In an achievable embodiment, based on the above embodiments, the communication connection unit includes:

[0113] The sub-data receiving sub-unit is used to obtain a plurality of sub-data by adopting a multi-thread receiving method; wherein the sub-data is part of the original data;

[0114] The sub-data splicing sub-unit is used to splice multiple sub-data to obtain original data.

[0115] In an achievable embodiment, based on the above embodiments, the automated testing module 103 includes:

[0116] A data conversion unit, used for translating the original data according to the test script and determining the ventilator conversion data;

[0117] A data comparison unit, used for automatically comparing the ventilator conversion data with the ventilator standard data and generating a comparison result;

[0118] The result determination unit is used to determine whether there is an error in the original data sent by the ventilator according to the comparison result.

[0119] In an achievable embodiment, based on the above embodiments, the data conversion unit includes:

[0120] The configuration file making subunit is used to store the ventilator mode parameters in the data storage table in Chinese to obtain the configuration file; wherein the ventilator mode parameters include the operation data of the ventilator under different preset models and different preset ventilation modes;

[0121] The data translation subunit is used to call the second function library to read the data storage table according to the configuration file to translate the original data into Chinese form to obtain the ventilator conversion data.

[0122] In an achievable embodiment, based on the above embodiments, the result determination unit includes:

[0123] A test completion subunit, used to complete the ventilator automation test when the comparison result indicates that the ventilator conversion data is consistent with the ventilator standard data;

[0124] The secondary comparison subunit is used to mark the ventilator conversion data for secondary comparison when the comparison result indicates that the ventilator conversion data does not match the ventilator standard data.

[0125] In an achievable embodiment, based on the above embodiments, the ventilator automated testing device 100 further includes:

[0126] The test environment establishment module is used to establish a test environment for performing automated testing of the ventilator.

[0127] An embodiment of the present invention further provides an electronic device. Fig. 9 A schematic diagram of the structure of an electronic device provided for an embodiment of the present invention. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present invention described and / or claimed herein.

[0128] like Fig. 9As shown, the electronic device 10 includes at least one processor 11, and a memory connected to the at least one processor 11, such as a read-only memory (ROM) 12, a random access memory (RAM) 13, etc., wherein the memory stores a computer program that can be executed by at least one processor, and the processor 11 can perform various appropriate actions and processes according to the computer program stored in the read-only memory (ROM) 12 or the computer program loaded from the storage unit 18 to the random access memory (RAM) 13. In the RAM 13, various programs and data required for the operation of the electronic device 10 can also be stored. The processor 11, the ROM 12, and the RAM 13 are connected to each other through a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.

[0129] A number of components in the electronic device 10 are connected to the I / O interface 15, including: an input unit 16, such as a keyboard, a mouse, etc.; an output unit 17, such as various types of displays, speakers, etc.; a storage unit 18, such as a disk, an optical disk, etc.; and a communication unit 19, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 19 allows the electronic device 10 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.

[0130] The processor 11 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, digital signal processors (DSPs), and any appropriate processors, controllers, microcontrollers, etc. The processor 11 executes the various methods and processes described above, such as a ventilator automated testing method.

[0131] In some embodiments, the ventilator automated testing method may be implemented as a computer program, which is tangibly contained in a computer-readable storage medium, such as a storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or installed on the electronic device 10 via the ROM 12 and / or the communication unit 19. When the computer program is loaded into the RAM 13 and executed by the processor 11, one or more steps of the ventilator automated testing method described above may be performed. Alternatively, in other embodiments, the processor 11 may be configured to perform the ventilator automated testing method in any other suitable manner (e.g., by means of firmware).

[0132] In the context of the present invention, a computer-readable storage medium may be a tangible medium that may contain or store a computer program for use by or in combination with an instruction execution system, device or equipment. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices or equipment, or any suitable combination of the foregoing. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0133] The systems and techniques described herein may be implemented in a computing system that includes backend components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes frontend components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such backend components, middleware components, or frontend components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), a blockchain network, and the Internet.

[0134] A computing system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The client and server relationship is generated by computer programs running on the corresponding computers and having a client-server relationship with each other. The server may be a cloud server, also known as a cloud computing server or cloud host, which is a host product in the cloud computing service system to solve the defects of difficult management and weak business scalability in traditional physical hosts and VPS services.

[0135] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps described in the present invention can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solution of the present invention can be achieved, and this document does not limit this.

[0136] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims

1. A method for automated testing of a ventilator, characterized in that: include: Acquire a test function library, ventilator attribute information, ventilator standard data and a test script; wherein the ventilator standard data includes a plurality of data represented in Chinese in a preset ventilation mode of a preset ventilator model; According to the test function library and the ventilator attribute information, receiving the original data sent by the ventilator; wherein the original data is the test data of the ventilator of the preset model in the preset ventilation mode; The original data is converted according to the test script to obtain ventilator conversion data, and the ventilator conversion data is compared with the ventilator standard data to complete the automated test of the ventilator.

2. The automated testing method for a ventilator according to claim 1, wherein: The receiving of raw data sent by the ventilator according to the test function library and the ventilator attribute information includes: The test function library includes a first function library, and the first function library includes a socket library; According to the ventilator attribute information, the first function library is called to establish a communication connection with the ventilator of the preset model to receive the original data sent by the ventilator.

3. The automated testing method for a ventilator according to claim 2, wherein: The receiving device receives the raw data sent by the ventilator, including: A multi-threaded receiving method is adopted to obtain a plurality of sub-data; wherein the sub-data is part of the original data; The plurality of sub-data are concatenated to obtain the original data.

4. The automated testing method for a ventilator according to claim 1, wherein: The converting the original data according to the test script to obtain ventilator conversion data, and comparing the ventilator conversion data with the ventilator standard data to complete the automated test of the ventilator, includes: Translating the raw data according to the test script to determine the ventilator conversion data; Automatically comparing the ventilator conversion data with the ventilator standard data to generate a comparison result; According to the comparison result, it is determined whether there is any error in the original data sent from the ventilator.

5. The automated testing method for a ventilator according to claim 4, characterized in that: The translating the original data according to the test script to determine the ventilator conversion data includes: The test function library includes a second function library, and the second function library includes a pandas library; The ventilator mode parameters are stored in a data storage table in Chinese to obtain a configuration file; wherein the ventilator mode parameters include operating data of ventilators under different preset models and different preset ventilation modes; According to the configuration file, the second function library is called to read the data storage table to translate the original data into Chinese form to obtain the ventilator conversion data.

6. The automated testing method for a ventilator according to claim 4, characterized in that: Determining whether there is an error in the original data sent by the ventilator according to the comparison result includes: When the comparison result indicates that the ventilator conversion data is consistent with the ventilator standard data, the ventilator automation test is completed; When the comparison result indicates that the ventilator conversion data does not match the ventilator standard data, the ventilator conversion data is marked for secondary comparison.

7. The automated testing method for a ventilator according to claim 1, characterized in that: Before obtaining the test function library, ventilator attribute information, ventilator standard data and test script, it also includes: Establish a test environment for automated testing of ventilators.

8. A ventilator automated testing device, characterized in that: include: A data acquisition module, used to acquire a test function library, ventilator attribute information, ventilator standard data and a test script; wherein the ventilator standard data includes a plurality of data represented in Chinese in a preset ventilation mode of a preset ventilator model; A raw data receiving module, used for receiving raw data sent by the ventilator according to the test function library and the ventilator attribute information; wherein the raw data is the test data of the ventilator of the preset model in the preset ventilation mode; The automated testing module is used to convert the original data according to the test script to obtain ventilator conversion data, and compare the ventilator conversion data with the ventilator standard data to complete the automated testing of the ventilator.

9. An electronic device, characterized in that: The electronic device comprises: at least one processor; and a memory communicatively connected to the at least one processor; wherein, The memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can perform the ventilator automated testing method according to any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the ventilator automated testing method according to any one of claims 1 to 7 when executed.