Method, device, equipment and computer storage medium for training resource configuration model
The resource allocation model is trained through the neural network model, and the first aid dispatch record information is used to quickly and accurately allocate first aid resources, which solves the problem of inaccurate and slow configuration caused by manual decision-making, and improves first aid efficiency.
Patent Information
- Application Number
- CN202010680128.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-07-15
- Publication Date
- 2024-09-10
- Estimated Expiration
- 2040-07-15
AI Technical Summary
In the existing technology, first aid resource allocation relies on manual experience, resulting in inaccurate and slow configuration, which affects the first aid effect.
A training sample set is generated by obtaining the emergency dispatch record information, and the resource allocation model is trained based on the neural network model to quickly and accurately predict the emergency resources that should be allocated to patients in need of emergency treatment.
It achieves rapid and accurate allocation of first aid resources, improves first aid efficiency, and reduces configuration errors caused by manual decision-making.
Smart Images

Figure CN113947265B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of machine learning technology, and in particular to a method, device, equipment and computer storage medium for training a resource configuration model. Background Art
[0002] In the prior art, after receiving an emergency call, it is usually manually selected which hospital's ambulance will be dispatched. Various emergency resource configurations usually include the following: medical equipment equipped in the ambulance, specific medicines equipped in the ambulance, medical staff of the emergency center equipped in the ambulance, and the destination hospital. The above-mentioned various emergency resource configurations are usually selected based on manual experience.
[0003] Since the configuration of the above-mentioned various emergency resources is determined manually based on experience, there is a possibility that the configuration of emergency resources is inaccurate or the configuration speed is slow, which affects the effect of emergency treatment. Summary of the invention
[0004] The embodiments of the present invention provide a method, device, equipment and computer storage medium for training a resource allocation model, so as to solve the problem that the allocation of emergency resources by manual decision-making results in slow and inaccurate allocation of emergency resources.
[0005] In a first aspect, an embodiment of the present invention provides a method for training a resource configuration model, the method comprising:
[0006] Obtain emergency vehicle dispatch record information of all hospitals in a preset area, wherein the emergency vehicle dispatch record information includes: patient characteristics and emergency resources;
[0007] Generate a training sample set based on the emergency vehicle dispatch record information, wherein the training sample set indicates the corresponding relationship between the patient characteristics and the emergency resources;
[0008] Based on the training sample set, a neural network model is trained as a resource configuration model.
[0009] Further, in one embodiment, the training sample set includes: one type of samples and two types of samples;
[0010] The first type of samples is generated by encoding and normalizing the emergency vehicle dispatch record information, and the first type of samples includes a sample feature;
[0011] The second type of samples are generated by mixing the dimensions of any two of the first type of samples.
[0012] Further, in one embodiment, the training of a neural network model as a resource configuration model based on the training sample set includes:
[0013] Construct a 2k-1 layer neural network, where the number of nodes in the first layer of the neural network is the dimension value of the samples in the training sample set;
[0014] The number of nodes in each of the first k layers of the neural network is half of that in the previous layer, and the number of nodes in each of the last k-1 layers is twice that in the previous layer, where k is a positive integer greater than 1 selected according to the complexity of the training sample set;
[0015] Inputting the training sample set into the neural network and forming an output at the same time, training the neural network until the neural network meets a preset condition, thereby obtaining the trained neural network;
[0016] The first k layers of the trained neural network are retained to obtain a resource allocation model.
[0017] Furthermore, in one embodiment, the preset conditions include:
[0018] The minimum mean square error between the sample input value of the training sample set and the output value of the neural network is less than a preset threshold.
[0019] Furthermore, in one embodiment, the method further comprises:
[0020] When the minimum mean square error is always not less than the preset threshold, the value of k is adjusted.
[0021] Furthermore, in one embodiment, the emergency resources include on-board medical supplies, on-board medical personnel, and a destination hospital.
[0022] In a second aspect, an embodiment of the present invention provides a method for configuring resources using a resource configuration model, wherein the resource configuration model is trained by a method for training a resource configuration model, and the method includes:
[0023] Collect characteristics of patients waiting for emergency treatment;
[0024] Inputting the characteristics of the patient to be treated into the resource allocation model to obtain emergency resource allocation information;
[0025] The emergency resource configuration information includes: on-board medical supplies, on-board medical personnel, and destination hospital.
[0026] In a third aspect, an embodiment of the present invention provides a device for training a resource configuration model, the device comprising:
[0027] An acquisition module, used to acquire emergency vehicle dispatch record information of all hospitals in a preset area, wherein the emergency vehicle dispatch record information includes: patient characteristics and emergency resources;
[0028] An information processing module, used to generate a training sample set based on the emergency vehicle dispatch record information, wherein the training sample set indicates the corresponding relationship between the patient characteristics and the emergency resources;
[0029] The model training module is used to train a neural network model as a resource configuration model based on the training sample set.
[0030] In a fourth aspect, an embodiment of the present invention provides a device for configuring resources using a resource configuration model, wherein the resource configuration model is trained by the device for training the resource configuration model, and the device includes:
[0031] A collection module, used to collect characteristics of patients waiting for emergency treatment;
[0032] A resource configuration module, used to input the characteristics of the patient to be treated into the resource configuration model to obtain emergency resource configuration information;
[0033] The emergency resource configuration information includes: on-board medical supplies, on-board medical personnel, and destination hospital.
[0034] In a fifth aspect, an embodiment of the present invention provides a computing device, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program implements the method for training a resource configuration model when executed by the processor.
[0035] In a sixth aspect, an embodiment of the present invention provides a computer-readable storage medium, on which is stored an implementation program for information transmission, and when the program is executed by a processor, the method for training the resource configuration model is implemented.
[0036] By adopting the embodiment of the present invention, a resource configuration model reflecting the mapping of patient characteristics and emergency resources can be trained according to emergency vehicle dispatch record information, and the resource configuration model can be used to quickly and accurately obtain emergency resource configuration information that should be configured according to the characteristics of the patient to be rescued. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] Figure 1 It is a flowchart of a method for training a resource configuration model provided by an embodiment of the present invention;
[0038] Figure 2 It is a flowchart of a method for configuring resources using a resource configuration model provided by an embodiment of the present invention;
[0039] Figure 3 It is a structural schematic diagram of a device for training a resource configuration model provided by an embodiment of the present invention;
[0040] Figure 4It is a structural schematic diagram of a device for configuring resources using a resource configuration model provided by an embodiment of the present invention;
[0041] Figure 5 It is a structural schematic diagram of a computing device provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0042] The features and exemplary embodiments of various aspects of the present invention will be described in detail below. In order to make the purpose, technical solutions and advantages of the present invention clearer, the present invention will be further described in detail below in conjunction with the accompanying drawings and specific embodiments. It should be understood that the specific embodiments described herein are only configured to explain the present invention and are not configured to limit the present invention. For those skilled in the art, the present invention can be implemented without the need for some of these specific details. The following description of the embodiments is only to provide a better understanding of the present invention by illustrating examples of the present invention.
[0043] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the statement "include..." does not exclude the presence of other identical elements in the process, method, article or device including the element.
[0044] Since the allocation of emergency resources is determined manually based on experience, there may be inaccuracies or slow allocation speed, which will affect the effectiveness of emergency treatment. For example, a manual decision specifies that the ambulance should be sent to the nearest hospital, but in fact the corresponding department of the hospital is already full of patients and cannot be treated immediately. At this time, sending to the nearest hospital is not the best strategy, but sending to a hospital that is slightly farther away but can be treated immediately is more appropriate.
[0045] In order to solve the problems of the prior art, the embodiments of the present invention provide a method, device, equipment and computer storage medium for training a resource allocation model. The embodiments of the present invention generate a training sample set by acquiring emergency vehicle dispatch record information, and then train a resource allocation model based on the training sample set. The resource allocation model can quickly and accurately obtain the emergency resource allocation information that should be configured according to the characteristics of the patient to be rescued, solving the problem of inaccurate and slow determination of emergency resource allocation based on manual experience.
[0046] The solution provided by the embodiment of the present invention is described below with reference to the accompanying drawings.
[0047] Figure 1 FIG. 1 is a flow chart of a method for training a resource configuration model provided by an embodiment of the present invention. Figure 1 As shown, the method may include the following steps:
[0048] S10, obtaining emergency vehicle dispatch record information of all hospitals in a preset area.
[0049] Usually, each emergency vehicle dispatch event will store corresponding emergency vehicle dispatch record information on the electronic equipment of the hospital or the emergency center, and the emergency vehicle dispatch record information can be obtained from the electronic equipment of the hospital or the emergency center.
[0050] The emergency vehicle dispatch record information may include patient characteristics and emergency resources.
[0051] The patient characteristics are characteristics related to the patient, including but not limited to gender, age, occupation, place of residence, place of birth, patient's physical signs at the time of emergency treatment, medical history, hospitalization record and the status of various hospitals in the area where the patient was located at the time of emergency treatment.
[0052] The emergency resources are the medical resources used to rescue patients, including but not limited to on-board medical supplies, on-board medical staff and the destination hospital.
[0053] S12, generating a training sample set based on the emergency vehicle dispatch record information, the training sample set indicating the corresponding relationship between the patient characteristics and the emergency resources. For example, for a patient with a severe bleeding characteristic, the corresponding emergency resources are usually medical plasma, tourniquet, etc.
[0054] The training sample set may be generated by encoding and normalizing the emergency vehicle dispatch record information.
[0055] S14: Based on the training sample set, a neural network model is trained as a resource configuration model.
[0056] The resource allocation model is used to predict the emergency resources that should be allocated according to the patient's characteristics.
[0057] By adopting the embodiment of the present invention, a resource configuration model reflecting the mapping of patient characteristics and emergency resources can be trained according to emergency vehicle dispatch record information, and the resource configuration model can be used to quickly and accurately obtain emergency resource configuration information that should be configured according to the characteristics of the patient to be rescued.
[0058] The neural network in this embodiment may be a fully connected neural network.
[0059] Optionally, in one embodiment, the training sample set may include: one type of samples and two types of samples;
[0060] The emergency vehicle dispatch record information is represented by X, and the i-th sample is represented by X i Indicates that the dimension of the jth column of the i-th sample is X i,j Indicates that the total number of samples is represented by m, and the dimension value of the original sample is represented by n.
[0061] The first type of sample is generated by encoding and normalizing the emergency vehicle dispatch record information. The first type of sample includes a sample feature. The first type of sample can use one-hot to encode the emergency vehicle dispatch record information, and then normalize it to the interval [0, 1]. Each type of sample only reflects one sample feature. For example, a certain type of sample only reflects "place of residence". If it is accurate to the province, there are more than 30 dimensional values in total. Each dimension has only two values of 0 or 1. For example, the converted dimensions include "place of residence - whether it is Sichuan", "place of residence - whether it is Beijing", "place of residence - whether it is Jiangsu", etc. Among them, the dimension value of the first type of sample remains unchanged at n, and the dimension of the i-th sample of the first type of sample can be expressed as [X i1 ,,X i2 , ..., X in ] T .
[0062] In an embodiment of the present invention, in addition to directly using one-hot and normalized dimensions of a class of samples as input dimensions of the neural network, it is also considered to mix the dimensions of a class of samples in pairs to form new dimensions. For example, women in Sichuan are prone to certain diseases. When "place of residence-whether Sichuan" and "gender-female" are combined, two dimensions of "place of residence" and "gender" are included at the same time, which is easier to capture than samples containing only a single dimension. Although fixed patterns may be captured after mixing more than two dimensions, the situation is rare and the generalization is poor. In addition, the combination of more than two dimensions will sharply increase the number of dimensions after the combination, so only the situation of combining the dimensions of a class of samples in pairs is considered.
[0063] That is, the second-class sample is generated by mixing the dimensions of any two of the first-class samples. Each second-class sample reflects two sample characteristics. For example, if one of the above second-class samples reflects both gender and place of residence, the latitude value of the second-class sample is n×(n-1) / 2. The dimension of the i-th sample of the second-class sample can be expressed as [M i,1,2 ,M i,1,3 ,……,M i,n-1,n ] T , where M i,p,q Represents the new dimension composed of the mixture of the pth and qth dimensions of the i-th sample.
[0064] At this time, the dimension value of the samples in the training sample set is n+n×(n-1) / 2, and the dimension of the i-th sample in the training sample set can be expressed as [Xi1 , X i2 , ..., X in , M i,1,2 ,M i,1,3 ,……,M i,n-1,n ] T .
[0065] By adopting the embodiment of the present invention, a resource configuration model reflecting the mapping between patient characteristics and emergency resources can be trained based on the emergency vehicle dispatch record information, and the emergency resource configuration information that should be configured according to the characteristics of the patient to be rescued can be quickly and accurately obtained by using the resource configuration model. And because the training sample set contains new dimensions after two-by-two mixing, it is easier to capture fixed patterns in medical scenarios.
[0066] The embodiment of the present invention further provides a training scheme for a resource configuration model, and S14 may include:
[0067] Construct a 2k-1 layer neural network. The number of nodes in the first layer of the neural network is the dimension value of the sample in the training sample set. For example, the output of the first layer of the neural network is [X i,1 ,X i,2 ,……X i,n ,V 1,2 M i,1,2 ,V 1,3 M i,1,3 ,……,V n-1, n M i,n-1,n ] T , V p,q Represents the new dimension M composed of the mixture of the pth and qth dimensions of the i-th sample in the second category i,p,q The coefficient of .
[0068] In one embodiment, we can let , = <,>, where <.> represents the inner product of two vectors, v p and v q Respectively represent the hidden vectors corresponding to the pth dimension and the qth dimension. p,q The number of hidden vectors is reduced from n×(n-1) / 2 to n×v, where v is the dimension of the hidden vector. The specific dimension v of the hidden vector can be designed according to the complexity of the problem to be solved. The more complex the problem, the higher the dimension. Usually v is much smaller than n. By constructing the hidden vector, the number of neural network parameters can be greatly reduced and the generalization performance can be improved.
[0069] Considering that if the number of nodes in each layer of the neural network is the same as that in the first layer, the input dimension of the neural network will be too high, which will greatly reduce the generalization ability of the neural network. In one embodiment of the present invention, the number of nodes in each of the first k layers of the neural network is set to be half of that in the previous layer, that is, each additional layer, considering the rounding operation when the odd number cannot be divided evenly, can reduce the input dimension by about half, and the number of nodes in each of the next k-1 layers is double that of the previous layer, and k is a positive integer greater than 1 selected according to the complexity of the training sample set;
[0070] The training sample set is input into the neural network and output is formed at the same time, and the neural network is trained until the neural network meets the preset conditions, thereby obtaining the trained neural network;
[0071] In order to further reduce the input dimension of the neural network and improve the generalization performance of the neural network, only the first k layers of the trained neural network can be retained under the constraints of preset conditions to obtain a resource allocation model.
[0072] Optionally, in one embodiment, the preset condition may include:
[0073] The minimum mean square error between the sample input value of the training sample set and the output value of the neural network is less than a preset threshold.
[0074] For quantifiable sample types, such as on-board medical supplies and on-board medical staff, the minimum mean square error loss can be calculated using the following formula:
[0075] loss = μ1(O i,1 -Y i,1 ) 2 +μ2(O i,2 -Y i,2 ) 2 +…+μ p (O i,p -Y i,p ) 2 +λ1L1+λ2L2
[0076] Among them, O ij is the neural network output value of the j-th dimension of the i-th sample, Y ij is the input value of the j-th dimension of the i-th sample, λ1L1 and λ2L2 are L1 regularization and L2 regularization respectively; μ p Represents the weight of the loss of p dimensions.
[0077] For non-quantifiable sample types, such as the destination hospital, the minimum mean square error loss can be calculated by the following formula:
[0078] Among them, iis the neural network output probability corresponding to the i-th sample.
[0079] Optionally, in one embodiment, the method may further include:
[0080] When the minimum mean square error is always not less than the preset threshold, it is considered that the dimension may be reduced too much, so it is difficult to restore the original dimension of the input, so the value of k can be adjusted.
[0081] By adopting the embodiment of the present invention, a resource configuration model reflecting the mapping of patient characteristics and emergency resources can be trained according to the emergency vehicle dispatch record information. By using the resource configuration model, the emergency resource configuration information that should be configured according to the characteristics of the patient to be first-aided can be quickly and accurately obtained; and because the neural network is subjected to dimensionality reduction processing, the generalization performance of the resource configuration model is improved.
[0082] In order to quickly and accurately obtain the emergency resource configuration information that should be configured according to the characteristics of the patient to be rescued, an embodiment of the present invention provides a method for configuring resources using a resource configuration model. The resource configuration model is configured by Figure 1 The steps shown are trained to obtain Figure 2 FIG. 2 shows a flow chart of the method for configuring resources using a resource configuration model. Figure 2 As shown, the method may include the following steps:
[0083] S20: Collect the characteristics of the patient in need of emergency treatment, including but not limited to gender, age, occupation, place of residence, place of birth, patient's physical signs at the time of emergency treatment, medical history, hospitalization record, and the status of each hospital in the area where the patient is located at the time of emergency treatment.
[0084] S22, input the characteristics of the patient to be treated into the resource allocation model to obtain emergency resource allocation information, which includes but is not limited to on-board medical supplies, on-board medical staff and destination hospital.
[0085] By adopting the embodiment of the present invention and utilizing the resource configuration model, it is possible to rapidly and accurately obtain the emergency resource configuration information that should be configured according to the characteristics of the patient to be treated.
[0086] Figure 1 and Figure 2 The method of training resource configuration model and the method of configuring resources using resource configuration model are described below. Figure 3 , Attachment Figure 4 and attached Figure 5 The device provided by the embodiment of the present invention is described.
[0087] Figure 3 FIG. 1 is a schematic diagram of a structure of a device for training a resource configuration model according to an embodiment of the present invention. Figure 3 As shown, Figure 3Each module in the device shown has the function of realizing Figure 1 The device can realize the functions of each step in the above process and achieve the corresponding technical effects, and can include:
[0088] The acquisition module 30 is used to obtain emergency vehicle dispatch record information of all hospitals in a preset area.
[0089] Usually, each emergency vehicle dispatch event will store corresponding emergency vehicle dispatch record information on the electronic equipment of the hospital or the emergency center, and the emergency vehicle dispatch record information can be obtained from the electronic equipment of the hospital or the emergency center.
[0090] The emergency dispatch record information includes: patient characteristics and emergency resources.
[0091] The patient characteristics are characteristics related to the patient, including but not limited to gender, age, occupation, place of residence, place of birth, patient's physical signs at the time of emergency treatment, medical history, hospitalization record and the status of various hospitals in the area where the patient was located at the time of emergency treatment.
[0092] The emergency resources are the medical resources used to rescue patients, including but not limited to on-board medical supplies, on-board medical staff and the destination hospital.
[0093] The information processing module 32 is used to generate a training sample set based on the emergency vehicle dispatch record information, and the training sample set indicates the corresponding relationship between the patient characteristics and the emergency resources.
[0094] The training sample set may be generated by encoding and normalizing the emergency vehicle dispatch record information.
[0095] The model training module 34 is used to train a neural network model as a resource configuration model based on the training sample set.
[0096] The resource allocation model is used to predict the emergency resources that should be allocated according to the patient's characteristics.
[0097] By adopting the embodiment of the present invention, a resource configuration model reflecting the mapping of patient characteristics and emergency resources can be trained according to emergency vehicle dispatch record information, and the resource configuration model can be used to quickly and accurately obtain emergency resource configuration information that should be configured according to the characteristics of the patient to be rescued.
[0098] The neural network in this embodiment may be a fully connected neural network.
[0099] Optionally, in one embodiment, the training sample set may include: one type of samples and two types of samples;
[0100] The emergency vehicle dispatch record information is represented by X, and the i-th sample is represented by X i Indicates that the dimension of the jth column of the i-th sample is X i,jIndicates that the total number of samples is represented by m, and the dimension value of the original sample is represented by n.
[0101] The first type of sample is generated by encoding and normalizing the emergency vehicle dispatch record information. The first type of sample includes a sample feature. The first type of sample can use one-hot to encode the emergency vehicle dispatch record information, and then normalize it to the interval [0, 1]. Each type of sample only reflects one sample feature. For example, a certain type of sample only reflects "place of residence". If it is accurate to the province, there are more than 30 dimensional values in total. Each dimension has only two values of 0 or 1. For example, the converted dimensions include "place of residence - whether it is Sichuan", "place of residence - whether it is Beijing", "place of residence - whether it is Jiangsu", etc. Among them, the dimension value of the first type of sample remains unchanged at n, and the dimension of the i-th sample of the first type of sample can be expressed as [X i1 ,,X i2 , ..., X in ] T .
[0102] In an embodiment of the present invention, in addition to directly using one-hot and normalized dimensions of a class of samples as input dimensions of the neural network, it is also considered to mix the dimensions of a class of samples in pairs to form new dimensions. For example, women in Sichuan are prone to certain diseases. When "place of residence-whether Sichuan" and "gender-female" are combined, two dimensions of "place of residence" and "gender" are included at the same time, which is easier to capture than samples containing only a single dimension. Although fixed patterns may be captured after mixing more than two dimensions, the situation is rare and the generalization is poor. In addition, the combination of more than two dimensions will sharply increase the number of dimensions after the combination, so only the situation of combining the dimensions of a class of samples in pairs is considered.
[0103] That is, the second-class sample is generated by mixing the dimensions of any two of the first-class samples. Each second-class sample reflects two sample characteristics. For example, if one of the above second-class samples reflects both gender and place of residence, the latitude value of the second-class sample is n×(n-1) / 2. The dimension of the i-th sample of the second-class sample can be expressed as [M i,1,2 ,M i,1,3 ,……,M i,n-1,n ] T , where M i,p,q Represents the new dimension composed of the mixture of the pth and qth dimensions of the i-th sample.
[0104] Then the dimension value of the samples in the training sample set is n+n×(n-1) / 2, and the dimension of the i-th sample in the training sample set can be expressed as [X i1 , X i2 , ..., X in , M i,1,2 ,M i,1,3,……,M i,n-1,n ] T .
[0105] By adopting the embodiment of the present invention, a resource configuration model reflecting the mapping of patient characteristics and emergency resources can be trained according to the emergency vehicle record information. The resource configuration model can be used to quickly and accurately obtain the emergency resource configuration information that should be configured according to the characteristics of the patient to be treated. And because the training sample set contains new dimensions after two-by-two mixing, it is easier to capture fixed patterns in medical scenarios; the new mixed dimensions are equivalent to helping the neural network mix some features to generate new features, so it can well deal with the situation where it is difficult to extract sufficient data features due to the small amount of data. Moreover, the way of combining dimensions in pairs, compared with the combination of higher dimensions, not only has the ability to easily capture features, but also the increase in dimensions is not too much, thus avoiding a significant reduction in the generalization ability of the neural network.
[0106] The embodiment of the present invention further provides a training scheme for a resource configuration model. The model training module 300 can be specifically used for:
[0107] Construct a 2k-1 layer neural network. The number of nodes in the first layer of the neural network is the dimension value of the sample in the training sample set. The output of the first layer of the neural network is [X i,1 ,X i,2 ,……X i,n ,V 1,2 M i,1,2 ,V 1,3 M i,1,3 ,……,V n-1,n M i,n-1,n ] T , V p,q Represents the new dimension M composed of the mixture of the pth and qth dimensions of the i-th sample in the second category i,p,q The coefficient of .
[0108] Optionally, in one embodiment, we can let , = <,>, where <.> represents the inner product of two vectors, v p and v q Respectively represent the hidden vectors corresponding to the pth dimension and the qth dimension. Then V p,q The number of hidden vectors is reduced from n×(n-1) / 2 to n×v, where v is the dimension of the hidden vector. The specific dimension v of the hidden vector can be designed according to the complexity of the problem to be solved. The more complex the problem, the higher the dimension. Usually v is much smaller than n. By constructing the hidden vector, the number of neural network parameters can be greatly reduced and the generalization performance can be improved.
[0109] Considering that if the number of nodes in each layer of the neural network is the same as that in the first layer, the input dimension of the neural network will be too high, which will greatly reduce the generalization ability of the neural network. Therefore, the number of nodes in each of the first k layers of the neural network is set to be half of the previous layer, that is, each additional layer, considering the rounding operation when the odd number cannot be divided evenly, can reduce the input dimension by about half, and the number of nodes in each of the next k-1 layers is double that of the previous layer, and k is a positive integer greater than 1 selected according to the complexity of the training sample set;
[0110] The training sample set is input into the neural network and output is formed at the same time, and the neural network is trained until the neural network meets the preset conditions, thereby obtaining the trained neural network;
[0111] In order to further reduce the input dimension of the neural network and improve the generalization performance of the neural network, only the first k layers of the trained neural network can be retained under the constraints of preset conditions to obtain a resource allocation model.
[0112] The preset conditions may include:
[0113] The minimum mean square error between the sample input value of the training sample set and the output value of the neural network is less than a preset threshold.
[0114] For quantifiable sample types, such as on-board medical supplies and on-board medical staff, the minimum mean square error loss can be calculated using the following formula:
[0115] loss = μ1(O i,1 -Y i,1 ) 2 +μ2(O i,2 -Y i,2 ) 2 +…+μ p (O i,p -Y i,p ) 2 +λ1L1+λ2L2
[0116] Among them, O ij is the neural network output value of the j-th dimension of the i-th sample, Y ij is the input value of the j-th dimension of the i-th sample, λ1L1 and λ2L2 are L1 regularization and L2 regularization respectively; μ p Represents the weight of the loss of p dimensions.
[0117] For non-quantifiable sample types, such as the destination hospital, the minimum mean square error loss can be calculated by the following formula:
[0118] Among them, i is the neural network output probability corresponding to the i-th sample.
[0119] When the minimum mean square error is always not less than the preset threshold, it is considered that the dimension may be reduced too much and it is difficult to restore the original dimension of the input. At this time, the value of k should be adjusted.
[0120] Optionally, in one embodiment, the device may further include:
[0121] Parameter adjustment module, used to adjust the value of k.
[0122] By adopting the embodiment of the present invention, a resource configuration model reflecting the mapping of patient characteristics and emergency resources can be trained according to the emergency vehicle dispatch record information. By using the resource configuration model, the emergency resource configuration information that should be configured according to the characteristics of the patient to be first-aided can be quickly and accurately obtained; and because the neural network is subjected to dimensionality reduction processing, the generalization performance of the resource configuration model is improved.
[0123] In order to quickly and accurately obtain the emergency resource configuration information that should be configured according to the characteristics of the patient to be rescued, an embodiment of the present invention provides a device for configuring resources using a resource configuration model. Figure 4 The schematic diagram of the structure of the device is shown in FIG. Figure 4 As shown, Figure 4 Each module in the device shown has the function of realizing Figure 2 The device can realize the functions of each step in the above process and achieve the corresponding technical effects, and can include:
[0124] The collection module 40 is used to collect the characteristics of the patient in need of emergency treatment, including but not limited to gender, age, occupation, place of residence, place of birth, physical signs of the patient at the time of emergency treatment, medical history, hospitalization record and the status of each hospital in the area where the patient is located at the time of emergency treatment.
[0125] The resource allocation module 42 is used to input the characteristics of the patient to be urgently needed into the resource allocation model to obtain emergency resource allocation information, which includes but is not limited to on-board medical supplies, on-board medical staff and destination hospital.
[0126] By adopting the embodiment of the present invention and utilizing the resource configuration model, it is possible to rapidly and accurately obtain the emergency resource configuration information that should be configured according to the characteristics of the patient to be treated.
[0127] Figure 5 A schematic diagram of the hardware structure of a computing device provided by an embodiment of the present invention is shown.
[0128] The computing device may include a processor 501 and a memory 502 storing computer program instructions.
[0129] Specifically, the processor 501 may include a central processing unit (CPU), or an application specific integrated circuit (ASIC), or may be configured to implement one or more integrated circuits of the embodiment of the present invention.
[0130] The memory 502 may include a large capacity memory for data or instructions. By way of example and not limitation, the memory 502 may include a hard disk drive (HDD), a floppy disk drive, a flash memory, an optical disk, a magneto-optical disk, a magnetic tape, or a universal serial bus (USB) drive or a combination of two or more of these. In one example, the memory 502 may include a removable or non-removable (or fixed) medium, or the memory 502 is a non-volatile solid-state memory. The memory 502 may be inside or outside the integrated gateway disaster recovery device.
[0131] In one example, the memory 502 may be a read-only memory (ROM). In one example, the ROM may be a mask-programmed ROM, a programmable ROM (PROM), an erasable PROM (EPROM), an electrically erasable PROM (EEPROM), an electrically rewritable ROM (EAROM), or a flash memory, or a combination of two or more of these.
[0132] The processor 501 reads and executes the computer program instructions stored in the memory 502 to implement Figure 1 and Figure 2 The method / steps S10 to S14 and steps S20 to S22 in the illustrated embodiment are achieved Figure 1 and Figure 2 The corresponding technical effects achieved by executing the methods / steps in the example shown are not repeated here for the sake of brevity.
[0133] In one example, the computing device may further include a communication interface 503 and a bus 510. Figure 5 As shown, the processor 501, the memory 502, and the communication interface 503 are connected via a bus 510 and communicate with each other.
[0134] The communication interface 503 is mainly used to implement the communication between the modules, devices, units and / or equipment in the embodiment of the present invention.
[0135] Bus 510 includes hardware, software or both, and couples the components of online data traffic billing equipment to each other. For example, but not limitation, the bus may include Accelerated Graphics Port (AGP) or other graphics bus, Enhanced Industry Standard Architecture (EISA) bus, Front Side Bus (FSB), Hyper Transport (HT) interconnection, Industry Standard Architecture (ISA) bus, InfiniBand interconnection, Low Pin Count (LPC) bus, Memory bus, Micro Channel Architecture (MCA) bus, Peripheral Component Interconnect (PCI) bus, PCI-Express (PCI-X) bus, Serial Advanced Technology Attachment (SATA) bus, Video Electronics Standards Association Local (VLB) bus or other suitable bus or two or more of these combinations. In appropriate cases, bus 510 may include one or more buses. Although the embodiment of the present invention describes and shows a specific bus, the present invention considers any suitable bus or interconnection.
[0136] The computing device can execute the method of training resource configuration model and the method of configuring resources using resource configuration model in the embodiment of the present invention based on the characteristics of the patient to be treated, thereby realizing the combination of Figure 1 and Figure 2 The invention describes a method for training a resource configuration model and a method for configuring resources using the resource configuration model.
[0137] In addition, in combination with the method for training a resource configuration model and the method for configuring resources using a resource configuration model in the above embodiments, an embodiment of the present invention may provide a computer storage medium for implementation. The computer storage medium stores computer program instructions; when the computer program instructions are executed by a processor, any one of the methods for training a resource configuration model and the method for configuring resources using a resource configuration model in the above embodiments is implemented.
[0138] It should be clear that the present invention is not limited to the specific configuration and processing described above and shown in the figures. For the sake of simplicity, a detailed description of the known method is omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of the present invention is not limited to the specific steps described and shown, and those skilled in the art can make various changes, modifications and additions, or change the order between the steps after understanding the spirit of the present invention.
[0139] The functional blocks shown in the above-described block diagram can be implemented as hardware, software, firmware or a combination thereof. When implemented in hardware, it can be, for example, an electronic circuit, an application-specific integrated circuit (Application Specific Integrated Circuit, ASIC), appropriate firmware, plug-in, function card, etc. When implemented in software, the elements of the present invention are programs or code segments used to perform the required tasks. The program or code segment can be stored in a machine-readable medium, or transmitted on a transmission medium or a communication link by a data signal carried in a carrier. "Machine-readable medium" can include any medium capable of storing or transmitting information. Examples of machine-readable media include electronic circuits, semiconductor memory devices, ROM, flash memory, erasable ROM (EROM), floppy disks, CD-ROMs, optical disks, hard disks, optical fiber media, radio frequency (Radio Frequency, RF) links, etc. The code segment can be downloaded via a computer network such as the Internet, an intranet, etc.
[0140] It should also be noted that the exemplary embodiments mentioned in the present invention describe some methods or systems based on a series of steps or devices. However, the present invention is not limited to the order of the above steps, that is, the steps can be performed in the order mentioned in the embodiments, or in a different order from the embodiments, or several steps can be performed simultaneously.
[0141] The above is only a specific implementation of the present invention. Those skilled in the art can clearly understand that for the convenience and simplicity of description, the specific working process of the system, module and unit described above can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here. It should be understood that the protection scope of the present invention is not limited to this. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed by the present invention, and these modifications or replacements should be covered within the protection scope of the present invention.
Claims
1. A method for training a resource configuration model, characterized in that: include: Obtain emergency vehicle dispatch record information of all hospitals in a preset area, wherein the emergency vehicle dispatch record information includes: patient characteristics and emergency resources; Generate a training sample set based on the emergency vehicle dispatch record information, wherein the training sample set indicates the corresponding relationship between the patient characteristics and the emergency resources; Based on the training sample set, training a neural network model as a resource configuration model; The step of training a neural network model as a resource configuration model based on the training sample set includes: Construct a 2k-1 layer neural network, where the number of nodes in the first layer of the neural network is the dimension value of the samples in the training sample set; The number of nodes in each of the first k layers of the neural network is half of that in the previous layer, and the number of nodes in each of the last k-1 layers is twice that in the previous layer, where k is a positive integer greater than 1 selected according to the complexity of the training sample set; Inputting the training sample set into the neural network and forming an output at the same time, training the neural network until the neural network meets a preset condition, thereby obtaining the trained neural network; The first k layers of the trained neural network are retained to obtain a resource allocation model.
2. The method for training a resource configuration model according to claim 1, characterized in that: The training sample set includes: one type of samples and two types of samples; The first type of samples is generated by encoding and normalizing the emergency vehicle dispatch record information, and the first type of samples includes a sample feature; The second type of samples are generated by mixing the dimensions of any two of the first type of samples.
3. The method for training a resource configuration model according to claim 1, characterized in that: The preset conditions include: The minimum mean square error between the sample input value of the training sample set and the output value of the neural network is less than a preset threshold.
4. The method for training a resource configuration model according to claim 3, characterized in that: The method further comprises: When the minimum mean square error is always not less than the preset threshold, the value of k is adjusted.
5. The method for training a resource configuration model according to claim 1, characterized in that: The emergency resources include on-board medical supplies, on-board medical personnel, and a destination hospital.
6. A method for configuring resources using a resource configuration model, characterized in that: The resource configuration model is trained by the method of claim 1, the method comprising: Collect characteristics of patients waiting for emergency treatment; Inputting the characteristics of the patient to be treated into the resource allocation model to obtain emergency resource allocation information; The emergency resource configuration information includes: on-board medical supplies, on-board medical personnel, and destination hospital.
7. A device for training a resource allocation model, characterized in that: include: An acquisition module is used to acquire emergency vehicle dispatch record information of all hospitals in a preset area, wherein the emergency vehicle dispatch record information includes: patient characteristics and emergency resources; An information processing module, used to generate a training sample set based on the emergency vehicle dispatch record information, wherein the training sample set indicates the corresponding relationship between the patient characteristics and the emergency resources; A model training module, used for training a neural network model as a resource configuration model based on the training sample set; The step of training a neural network model as a resource configuration model based on the training sample set includes: Construct a 2k-1 layer neural network, where the number of nodes in the first layer of the neural network is the dimension value of the samples in the training sample set; The number of nodes in each of the first k layers of the neural network is half of that in the previous layer, and the number of nodes in each of the last k-1 layers is twice that in the previous layer, where k is a positive integer greater than 1 selected according to the complexity of the training sample set; Inputting the training sample set into the neural network and forming an output at the same time, training the neural network until the neural network meets a preset condition, thereby obtaining the trained neural network; The first k layers of the trained neural network are retained to obtain a resource allocation model.
8. A device for configuring resources using a resource configuration model, characterized in that: The resource configuration model is trained by the device according to claim 7, wherein the device comprises: A collection module, used to collect characteristics of patients waiting for emergency treatment; A resource configuration module, used to input the characteristics of the patient to be treated into the resource configuration model to obtain emergency resource configuration information; The emergency resource configuration information includes: on-board medical supplies, on-board medical personnel, and destination hospital.
9. A computing device, characterized in that include: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program implements the method according to any one of claims 1 to 6 when executed by the processor.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores an implementation program for information transmission, and when the program is executed by a processor, the method according to any one of claims 1 to 6 is implemented.
