CN116798643A - Method, device, server and storage medium for generating number of new cases - Google Patents

Method, device, server and storage medium for generating number of new cases Download PDF

Info

Publication number
CN116798643A
CN116798643A CN202310804264.1A CN202310804264A CN116798643A CN 116798643 A CN116798643 A CN 116798643A CN 202310804264 A CN202310804264 A CN 202310804264A CN 116798643 A CN116798643 A CN 116798643A
Authority
CN
China
Prior art keywords
case
time range
information
preset
preset time
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202310804264.1A
Other languages
Chinese (zh)
Inventor
张渊
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ping An Technology Shenzhen Co Ltd
Original Assignee
Ping An Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ping An Technology Shenzhen Co Ltd filed Critical Ping An Technology Shenzhen Co Ltd
Priority to CN202310804264.1A priority Critical patent/CN116798643A/en
Publication of CN116798643A publication Critical patent/CN116798643A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G16INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR SPECIFIC APPLICATION FIELDS
    • G16HHEALTHCARE INFORMATICS, i.e. INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR THE HANDLING OR PROCESSING OF MEDICAL OR HEALTHCARE DATA
    • G16H50/00ICT specially adapted for medical diagnosis, medical simulation or medical data mining; ICT specially adapted for detecting, monitoring or modelling epidemics or pandemics
    • G16H50/70ICT specially adapted for medical diagnosis, medical simulation or medical data mining; ICT specially adapted for detecting, monitoring or modelling epidemics or pandemics for mining of medical data, e.g. analysing previous cases of other patients
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/044Recurrent networks, e.g. Hopfield networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • G06N3/0455Auto-encoder networks; Encoder-decoder networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/0464Convolutional networks [CNN, ConvNet]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G16INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR SPECIFIC APPLICATION FIELDS
    • G16HHEALTHCARE INFORMATICS, i.e. INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR THE HANDLING OR PROCESSING OF MEDICAL OR HEALTHCARE DATA
    • G16H50/00ICT specially adapted for medical diagnosis, medical simulation or medical data mining; ICT specially adapted for detecting, monitoring or modelling epidemics or pandemics
    • G16H50/80ICT specially adapted for medical diagnosis, medical simulation or medical data mining; ICT specially adapted for detecting, monitoring or modelling epidemics or pandemics for detecting, monitoring or modelling epidemics or pandemics, e.g. flu
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02ATECHNOLOGIES FOR ADAPTATION TO CLIMATE CHANGE
    • Y02A90/00Technologies having an indirect contribution to adaptation to climate change
    • Y02A90/10Information and communication technologies [ICT] supporting adaptation to climate change, e.g. for weather forecasting or climate simulation

Landscapes

  • Engineering & Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • General Health & Medical Sciences (AREA)
  • Biomedical Technology (AREA)
  • Public Health (AREA)
  • Computing Systems (AREA)
  • Molecular Biology (AREA)
  • Software Systems (AREA)
  • Mathematical Physics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Biophysics (AREA)
  • Computational Linguistics (AREA)
  • Evolutionary Computation (AREA)
  • General Physics & Mathematics (AREA)
  • Medical Informatics (AREA)
  • General Engineering & Computer Science (AREA)
  • Epidemiology (AREA)
  • Pathology (AREA)
  • Primary Health Care (AREA)
  • Databases & Information Systems (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The embodiment of the application provides a method, a device, a server and a storage medium for generating the number of new cases, which solve the problem of poor simulation authenticity of the existing time-based infectious disease model. The method comprises the steps of obtaining case information of a first preset time range, wherein the case information comprises case characteristics and a preset new case number of a second preset time range after the first preset time range, inputting the case characteristics as training samples into a number generation model to be trained, generating a predicted new case number of the second preset time range according to the case characteristics, calculating a loss function of the predicted new case number and the preset new case number until the loss function meets preset convergence conditions, and stopping training to obtain a number generation model for generating the new case number. The space-time development trend of the future infectious diseases is generated based on the historical space-time aggregation data of the infectious diseases.

Description

Method, device, server and storage medium for generating number of new cases
Technical Field
The application relates to the technical field of medical artificial intelligence, in particular to a method, a device, a server and a storage medium for generating the number of new cases.
Background
In recent years, an important supporting role in disease prediction, prevention and control can be provided through an infectious disease simulation model, so that a decision maker is helped to better cope with the threat of infectious diseases. In the existing simulation method of infectious diseases, single simulation based on time series is often adopted, such as an SEIR model, but the spread and development of infectious diseases are often dynamically changed, and the accuracy of the simulation with time as a single dimension in the aspects of disease prediction, prevention and control still has a certain deviation from the actual situation.
Disclosure of Invention
The application discloses a method, a device, a server and a storage medium for generating the number of new cases, which solve the problem that the reality of the simulation of the existing infectious disease model based on time as a single dimension is poor.
In a first aspect, the present application provides a method for generating a number of new cases, including:
obtaining case information of a first preset time range from an infectious disease case library, wherein the case information comprises case characteristics and the number of new cases preset in the second preset time range, and taking the case characteristics as training samples; wherein the second preset time range is after the first preset time range;
inputting the training samples into a quantity generation model to be trained, generating the predicted number of new cases in the second preset time range according to the case characteristics by the quantity generation model, and calculating a loss function of the predicted number of new cases and the preset number of new cases;
and if the loss function meets a preset convergence condition, stopping training to obtain a quantity generation model, wherein the quantity generation model is used for generating the quantity of the new cases.
In a second aspect, the present application provides a device for generating the number of new cases, including:
the system comprises a case acquisition module, a training module and a program module, wherein the case acquisition module is used for acquiring case information of a first preset time range from an infectious disease case library, the case information comprises case characteristics and the number of new cases preset in the second preset time range, and the case characteristics are used as training samples; wherein the second preset time range is after the first preset time range;
the loss calculation module is used for inputting the training sample into a quantity generation model to be trained, generating the predicted number of new cases in the second preset time range according to the case characteristics by the quantity generation model, and calculating a loss function of the predicted number of new cases and the preset number of new cases;
and the model obtaining module is used for stopping training if the loss function meets a preset convergence condition to obtain a quantity generation model, and the quantity generation model is used for generating the quantity of the new cases.
In a third aspect, the present application provides a server comprising a processor, a memory, and a computer program stored on the memory and executable by the processor, the memory storing a policy model, wherein the computer program, when executed by the processor, implements a method of generating a number of new cases as provided by any of the embodiments of the present application.
In a fourth aspect, the present application provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, causes the processor to implement a method for generating a number of new cases as provided by any of the embodiments of the present application.
The embodiment of the application provides a method, a device, a server and a storage medium for generating a new case number, which are characterized in that case information in a first preset time range is obtained from an infectious disease case library, the case information comprises case characteristics and a preset new case number in a second preset time range after the first preset time range, the case characteristics are used as training samples to be input into a number generation model to be trained, the number generation model generates a predicted new case number in the second preset time range according to the case characteristics, a loss function of the predicted new case number and the preset new case number is calculated until the loss function meets a preset convergence condition, and training is stopped to obtain a number generation model for generating the new case number. By adopting the provided method for generating the number of the newly increased cases, the number of the newly increased cases in the second preset time range is predicted by the case characteristics in the first preset time range, so that the space-time development trend of the future infectious diseases is generated based on the historical space-time aggregation data of the infectious diseases, and the trained number generation model has no requirement on the input characteristics, so that the flexibility of the model is greatly improved.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the application as claimed.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are needed in the description of the embodiments will be briefly described below, it being obvious that the drawings in the following description are only some embodiments of the present application, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a schematic flow chart of steps of a method for generating a new case number according to an embodiment of the present application;
FIG. 2 is a schematic flow chart of steps of another method for generating a number of new cases according to an embodiment of the present application;
FIG. 3 is a schematic flow chart of the steps of an acquisition method for predicting the number of newly added cases according to an embodiment of the present application;
FIG. 4 is a schematic block diagram of a quantity generation model provided by an embodiment of the present application;
fig. 5 is a schematic structural diagram of a device for generating the number of new cases according to an embodiment of the present application;
fig. 6 is a schematic block diagram of a computer device according to an embodiment of the present application.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the application as claimed.
Detailed Description
The following description of the embodiments of the present application will be made clearly and fully with reference to the accompanying drawings, in which it is evident that the embodiments described are some, but not all embodiments of the application. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
The flow diagrams depicted in the figures are merely illustrative and not necessarily all of the elements and operations/steps are included or performed in the order described. For example, some operations/steps may be further divided, combined, or partially combined, so that the order of actual execution may be changed according to actual situations.
It is to be understood that the terminology used in the description of the application herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. As used in this specification and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise.
It should be understood that, in order to clearly describe the technical solutions of the embodiments of the present application, in the embodiments of the present application, the words "first", "second", etc. are used to distinguish identical items or similar items having substantially the same function and effect. For example, the first preset time range and the second preset time range are only for distinguishing different preset time ranges, and the sequence of the different preset time ranges is not limited. It will be appreciated by those of skill in the art that the words "first," "second," and the like do not limit the amount and order of execution, and that the words "first," "second," and the like do not necessarily differ.
It should also be understood that the term "and/or" as used in the present specification and the appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes such combinations.
In order to facilitate understanding of the embodiments of the present application, some words related to the embodiments of the present application are briefly described below.
1. Diffusion Model (diffusion Model): the inspiration of the diffusion model comes from the unbalanced thermodynamics. A markov chain defining a diffusion step (the current state is only related to the state at the previous moment) slowly adds random noise to the real data (forward process), then learns the back diffusion process (back diffusion process) and builds the required data samples from the noise.
2. Recurrent neural network (Recurrent Neural Network, RNN): RNN is a type of recurrent neural network (Recursive Neural Network) that takes Sequence (Sequence) data as input, performs Recursion (reconcentration) in the evolution direction of the Sequence, and all nodes (loop units) are chained.
The recurrent neural network has memory, parameter sharing and complete graphics (Turing Completeness), so that the recurrent neural network has certain advantages in learning the nonlinear characteristics of the sequence. The recurrent neural network has application in the fields of natural language processing (Natural Language Processing, NLP), such as speech recognition, language modeling, machine translation, etc., and is also used for various time series predictions. A recurrent neural network constructed with the introduction of convolutional neural networks (Convolutional Neural Network, CNN) can address computer vision problems involving sequence inputs.
Some embodiments of the present application are described in detail below with reference to the accompanying drawings. The following embodiments and features of the embodiments may be combined with each other without conflict.
The prediction of the infectious diseases can inhibit the transmission of viruses in a targeted manner, and reduce the damage caused by the viruses. In the existing simulation method of infectious diseases, single simulation based on time series is often adopted, such as an SEIR model, but the spread and development of infectious diseases are often dynamically changed, and the accuracy of the simulation with time as a single dimension in the aspects of disease prediction, prevention and control still has certain deviation from the actual situation.
In order to solve the above problems, the embodiment of the application provides a method for generating the number of new cases. Referring to fig. 1, fig. 1 is a schematic flowchart illustrating steps of a method for generating a new case number according to an embodiment of the present application.
As shown in fig. 1, the proposed method for generating the number of new cases includes steps S101 to S103.
S101, obtaining case information of a first preset time range from an infectious disease case library, wherein the case information comprises case characteristics and the number of new cases preset in a second preset time range, and taking the case characteristics as training samples; wherein the second preset time range is after the first preset time range.
Specifically, by acquiring case information of a first preset time range, for example, case information of 4 months in 2023 in the region a, in the infectious disease case library, the case information includes case characteristics and the number of newly increased cases of a second preset time range, for example, the number of newly increased cases per day including 4 months in 2023 in the region a and the number of newly increased cases from 1 day to 7 days in 2023 in 5 months. By taking the case information in the first preset time range as a training sample, the time information and the space information of the infectious diseases can be linked, so that abstract information in case characteristics is extracted, and the capability of the number generation model to be trained for future space-time trend deduction is improved.
In some embodiments, case features include historical epidemic information, weather information, demographic information, and regional prevention and control information for infectious diseases; obtaining case information of a first preset time range from an infectious disease case library, wherein the case information comprises: and acquiring historical epidemic information, weather information, population information, prevention and control information of infectious diseases in a first preset time range in a preset area from an infectious disease case library, and presetting the number of new cases in a second preset time range. The method has the advantages that through acquiring the historical epidemic information, the meteorological information, the population information and the regional prevention and control information of the infectious diseases, the number generation model to be trained subsequently can learn corresponding abstract features in case features.
In some embodiments, the first predetermined time range is 30 days long and the second time range is 7 days long; obtaining case information of a first preset time range from an infectious disease case library, wherein the case information comprises: acquiring case information of a first preset time range from an infectious disease case library by taking 30 days as a duration, wherein the case information comprises case characteristics and the number of new cases preset in the second preset time range; wherein the second preset time range is 7 days after the first preset time range.
By setting the first preset time range to be 30 days and the second preset time range to be seven days after the first preset time range, the number generation model to be trained is further determined to accurately predict the number of new cases in the future 7 days according to the case characteristics of the past 30 days.
S102, inputting training samples into a quantity generation model to be trained, generating a predicted new case quantity in a second preset time range by the quantity generation model according to case characteristics, and calculating a loss function of the predicted new case quantity and the preset new case quantity.
The number generation model can generate a predicted number of new cases in a second preset time range according to the case characteristics by inputting the case characteristics into the number generation model to be trained, for example, the predicted number of new cases 7 days after the first preset time range is generated, and calculate a loss function according to the predicted number of new cases generated by the number generation model to be trained and the preset number of new cases corresponding to the case characteristics acquired in the infectious disease case library so as to confirm the accuracy of the generated predicted number of new cases.
In some embodiments, the loss function is a cross entropy loss function. As shown in fig. 2, fig. 2 is a schematic flowchart illustrating steps of another method for generating a new case number according to an embodiment of the present application. Unlike the steps provided in fig. 1, the steps provided in fig. 2 include step S102a.
S102a, inputting training samples into a quantity generation model to be trained, generating a predicted new case quantity in a second preset time range by the quantity generation model according to case characteristics, and calculating a cross entropy loss function of the predicted new case quantity and the preset new case quantity, wherein the cross entropy loss function is used for obtaining the quantity generation model when the cross entropy loss function value converges.
The training effect of the number generation model can be accurately measured by calculating a cross entropy loss function of the number of predicted new cases generated by the number generation model, for example, a tanh, sigmoid, softmax or ReLU type cross entropy loss function, corresponding to the number of preset new cases obtained from the case characteristics in the infectious disease case library.
S103, if the loss function meets the preset convergence condition, stopping training to obtain a quantity generation model, wherein the quantity generation model is used for generating the quantity of new cases.
Specifically, when the loss function satisfies a preset convergence condition, for example, the loss function value is smaller than a preset value, training of the log generation model is completed. The obtained quantity generation model can generate the space-time development trend of the future infectious diseases based on the historical space-time aggregation data of the infectious diseases. The proposed architecture can be applied to space-time trend prediction of infectious diseases, and the trained quantity generation model has no requirement on input characteristics, so that the flexibility of the model is greatly improved.
In some embodiments, the quantity generation model includes an encoder, a preset convolutional neural network, and a decoder. As shown in fig. 3, fig. 3 is a schematic flowchart illustrating steps of an acquisition method for predicting the number of new cases according to an embodiment of the present application.
As shown in fig. 3, the provided acquisition method for predicting the number of newly added cases includes steps S201 to S203.
S201, inputting the training sample into the encoder to acquire first coding information and parameter information.
S202, inputting the first coding information into a preset convolutional neural network to obtain second coding information.
S203, inputting the second coding information and the parameter information to a decoder to obtain the number of predicted new cases in a second preset time range.
The training samples are input to an encoder, case characteristics are encoded, first encoding information which can be identified by a preset convolutional neural network and Gaussian distribution of the case characteristics in a hidden variable space are obtained, and the Gaussian distribution is sampled to obtain parameter information of the case characteristics in the hidden variable space. The first coding information is input into a preset convolutional neural network, the second coding information and parameter information of the hidden variable space are obtained and are input into a decoder together, the number of predicted newly increased cases in a second preset time range is obtained through decoding, and further the space-time development trend of the future infectious disease is generated based on historical space-time aggregation data of the infectious disease.
Illustratively, the preset convolutional neural network includes a diffusion model. Referring to fig. 4, fig. 4 is a schematic block diagram of a quantity generation model according to an embodiment of the present application. As shown in fig. 4, the first encoded information is input to a preset convolutional neural network, and the second encoded information includes: and inputting the first coding information into a diffusion model, adding Gaussian noise into the first coding information by the diffusion model according to preset times to obtain third coding information, and denoising the third coding information by the diffusion model to obtain second coding information.
As shown in fig. 4, by using a 10-step U-Net network with a preset number of times of 10 as a diffusion model, the diffusion model can acquire corresponding second encoded information by sequentially adding gaussian noise to the input first encoded information to become random noise and then denoising. Further, by mapping the first encoded information corresponding to the case features as original information to high-dimensional vectors to extract features and performing machine learning tasks on these vectors, the method is excellent in the task of information generation. The information generation by using the diffusion model can simulate the future space-time development trend of the infectious disease.
Illustratively, the encoder includes a multi-layer recurrent neural network; inputting training samples into an encoder to obtain first coding information and parameter information, wherein the training samples comprise: and inputting the training sample into the multi-layer cyclic neural network, and performing nonlinear transformation processing on the training sample by the cyclic neural network to acquire the first coding information and the parameter information.
By adopting a multi-layer cyclic neural network as the structure of the encoder, for example, a 5-layer cyclic neural network, the inside of the cyclic neural network can obtain coding information identifiable by a preset convolutional neural network and Gaussian distribution in a hidden variable space after nonlinear transformation processing is carried out on the input case characteristics, and parameter information is obtained by sampling the distribution. And further, analysis of historical space-time aggregation data based on infectious diseases is realized.
It should be noted that in some embodiments, the decoder is the same as the encoder, and a multi-layer recurrent neural network is also used as the decoder structure to complete the prediction of the future infectious disease trend.
The application provides a method for generating the number of new cases, which predicts the number of new cases in a second preset time range by using case characteristics in a first preset time range, so as to further realize the generation of space-time development trend of future infectious diseases based on historical space-time aggregation data of the infectious diseases, and a trained number generation model has no requirement on input characteristics, thereby greatly improving the flexibility of the model.
As shown in fig. 5, fig. 5 is a schematic structural diagram of a new case number generating device according to an embodiment of the present application, where the new case number generating device is configured to execute the foregoing new case number generating method. The device for generating the number of new cases can be configured at a terminal or a server.
As shown in fig. 5, the apparatus 100 for generating the number of new cases includes a case acquisition module 101, a loss calculation module 102, and a model acquisition module 103.
A case acquisition module 101, configured to acquire case information in a first preset time range from an infectious disease case library, where the case information includes a case feature and a preset number of new cases in the second preset time range, and take the case feature as a training sample; wherein the second preset time range is subsequent to the first preset time range.
The loss calculation module 102 is configured to input the training sample into a number generation model to be trained, where the number generation model generates a predicted number of new cases in the second preset time range according to the case feature, and calculates a loss function of the predicted number of new cases and the preset number of new cases.
And the model obtaining module 103 is configured to stop training if the loss function meets a preset convergence condition, and obtain a number generation model, where the number generation model is used to generate the number of new cases.
In some embodiments, the apparatus for generating a new case number 100 may further include: the system comprises a case prediction module 104, a code acquisition module 105, a parameter acquisition module 106, a convergence calculation module 107, an information acquisition module 108 and a time length determination module 109.
The case prediction module 104 is configured to input the training sample into the encoder, and obtain first coding information and parameter information; inputting the first coding information into the preset convolutional neural network to obtain second coding information; and inputting the second coding information and the parameter information to the decoder to obtain the predicted number of new cases in the second preset time range.
The code obtaining module 105 is configured to input the first code information into the diffusion model, the diffusion model adds gaussian noise to the first code information according to a preset number of times to obtain third code information, and the diffusion model denoises the third code information to obtain the second code information.
And the parameter obtaining module 106 is configured to input the training sample to the multi-layer recurrent neural network, and the recurrent neural network performs nonlinear transformation processing on the training sample to obtain the first coding information and the parameter information.
A convergence calculation module 107, configured to calculate a cross entropy loss function of the predicted number of new cases and the preset number of new cases, and obtain the number generation model when the cross entropy loss function value converges.
The information obtaining module 108 is configured to obtain, from the infectious disease case repository, historical epidemic information, weather information, population information, prevention and control information of infectious disease in the first preset time range, and a preset number of new cases in the second preset time range.
A duration determining module 109, configured to obtain, from the infectious disease case repository, case information in a first preset time range, where the case information includes a case feature and a preset number of new cases in the second preset time range, by using 30 days as a duration; wherein the second preset time range is 7 days after the first preset time range.
It should be noted that, for convenience and brevity of description, the specific working process of the apparatus and each module described above may refer to the corresponding process in the foregoing method embodiment, which is not described herein again.
The apparatus described above may be implemented in the form of a computer program which is executable on a computer device as shown in fig. 6.
Referring to fig. 6, fig. 6 is a schematic block diagram of a computer device according to an embodiment of the present application. The computer device may be a server. With reference to FIG. 6, the computer device includes a processor, memory, and a network interface connected by a system bus, where the memory may include a non-volatile storage medium and an internal memory.
The non-volatile storage medium may store an operating system and a computer program. The computer program comprises program instructions that, when executed, cause the processor to perform any of a number of new cases generation method.
The processor is used to provide computing and control capabilities to support the operation of the entire computer device.
The internal memory provides an environment for the execution of a computer program in a non-volatile storage medium that, when executed by a processor, causes the processor to perform any of a number of new cases generation method.
The network interface is used for network communication such as transmitting assigned tasks and the like. It will be appreciated by those skilled in the art that the structure shown in FIG. 6 is merely a block diagram of some of the structures associated with the present inventive arrangements and is not limiting of the computer device to which the present inventive arrangements may be applied, and that a particular computer device may include more or fewer components than shown, or may combine some of the components, or have a different arrangement of components.
It should be appreciated that the processor may be a central processing unit (Central Processing Unit, CPU), but may also be other general purpose processors, digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), field-programmable gate arrays (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or the like. Wherein the general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
Wherein in one embodiment the processor is configured to run a computer program stored in the memory to implement the steps of:
obtaining case information of a first preset time range from an infectious disease case library, wherein the case information comprises case characteristics and the number of new cases preset in the second preset time range, and taking the case characteristics as training samples; wherein the second preset time range is subsequent to the first preset time range.
Inputting the training samples into a quantity generation model to be trained, generating the predicted number of new cases in the second preset time range according to the case characteristics by the quantity generation model, and calculating a loss function of the predicted number of new cases and the preset number of new cases.
And if the loss function meets a preset convergence condition, stopping training to obtain a quantity generation model, wherein the quantity generation model is used for generating the quantity of the new cases.
In some embodiments, the quantity generation model includes an encoder, a preset convolutional neural network, and a decoder; the training samples are input into a quantity generation model to be trained, the quantity generation model generates the predicted newly-increased case quantity of the second preset time range according to the case characteristics, and the processor is further used for realizing: inputting the training sample into the encoder to obtain first coding information and parameter information; inputting the first coding information into the preset convolutional neural network to obtain second coding information; and inputting the second coding information and the parameter information to the decoder to obtain the predicted number of new cases in the second preset time range.
In some embodiments, the preset convolutional neural network comprises a diffusion model; the first coding information is input to the preset convolutional neural network, the second coding information is obtained, and the processor is further used for realizing: and inputting the first coding information into the diffusion model, adding Gaussian noise into the first coding information by the diffusion model according to preset times to obtain third coding information, and denoising the third coding information by the diffusion model to obtain the second coding information.
In some embodiments, the encoder comprises a multi-layer recurrent neural network; the training samples are input into the encoder, first coding information and parameter information are obtained, and the processor is further used for realizing: and inputting the training sample into the multi-layer cyclic neural network, and performing nonlinear transformation processing on the training sample by the cyclic neural network to acquire the first coding information and the parameter information.
In some embodiments, the loss function is a cross entropy loss function; the calculating the loss function of the predicted number of new cases and the preset number of new cases, the processor is further configured to implement: and calculating a cross entropy loss function of the number of the predicted new cases and the number of the preset new cases, and obtaining the number generation model when the cross entropy loss function value converges.
In some embodiments, the case characteristics include historical epidemic information, weather information, demographic information, and regional control information for infectious diseases; the method comprises the steps that case information of a first preset time range is obtained from an infectious disease case library, and the processor is further used for realizing: and acquiring historical epidemic information, weather information, population information, prevention and control information of infectious diseases in a preset area in the first preset time range and the preset newly-increased case number in the second preset time range from the infectious disease case library.
In some embodiments, the first predetermined time range is 30 days long and the second time range is 7 days long; the method comprises the steps that case information of a first preset time range is obtained from an infectious disease case library, and the processor is further used for realizing: acquiring case information of a first preset time range from the infectious disease case library by taking 30 days as a duration, wherein the case information comprises case characteristics and a preset newly-increased case number of the second preset time range; wherein the second preset time range is 7 days after the first preset time range.
The embodiment of the application also provides a computer readable storage medium, wherein the computer readable storage medium stores a computer program, the computer program comprises program instructions, and the processor executes the program instructions to realize any of the generation methods of the number of the new cases provided by the embodiment of the application.
The computer readable storage medium may be an internal storage unit of the computer device according to the foregoing embodiment, for example, a hard disk or a memory of the computer device. The computer readable storage medium may also be an external storage device of the computer device, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), or the like, which are provided on the computer device.
While the application has been described with reference to certain preferred embodiments, it will be understood by those skilled in the art that various changes and substitutions of equivalents may be made and equivalents will be apparent to those skilled in the art without departing from the scope of the application. Therefore, the protection scope of the application is subject to the protection scope of the claims.

Claims (10)

1. A method for generating a new case number, comprising:
obtaining case information of a first preset time range from an infectious disease case library, wherein the case information comprises case characteristics and the number of new cases preset in the second preset time range, and taking the case characteristics as training samples; wherein the second preset time range is after the first preset time range;
inputting the training samples into a quantity generation model to be trained, generating the predicted number of new cases in the second preset time range according to the case characteristics by the quantity generation model, and calculating a loss function of the predicted number of new cases and the preset number of new cases;
and if the loss function meets a preset convergence condition, stopping training to obtain a quantity generation model, wherein the quantity generation model is used for generating the quantity of the new cases.
2. The method of claim 1, wherein the quantity generation model comprises an encoder, a preset convolutional neural network, and a decoder; inputting the training samples into a quantity generation model to be trained, wherein the quantity generation model generates the predicted newly-increased case quantity of the second preset time range according to the case characteristics, and the method comprises the following steps:
inputting the training sample into the encoder to obtain first coding information and parameter information;
inputting the first coding information into the preset convolutional neural network to obtain second coding information;
and inputting the second coding information and the parameter information to the decoder to obtain the predicted number of new cases in the second preset time range.
3. The method of claim 2, wherein the predetermined convolutional neural network comprises a diffusion model; the step of inputting the first coding information into the preset convolutional neural network to obtain second coding information includes:
and inputting the first coding information into the diffusion model, adding Gaussian noise into the first coding information by the diffusion model according to preset times to obtain third coding information, and denoising the third coding information by the diffusion model to obtain the second coding information.
4. The method of claim 2, wherein the encoder comprises a multi-layer recurrent neural network; the step of inputting the training samples into the encoder to obtain first coding information and parameter information includes:
and inputting the training sample into the multi-layer cyclic neural network, and performing nonlinear transformation processing on the training sample by the cyclic neural network to acquire the first coding information and the parameter information.
5. The method of claim 1, wherein the loss function is a cross entropy loss function; the calculating a loss function of the predicted number of new cases and the preset number of new cases includes:
and calculating a cross entropy loss function of the number of the predicted new cases and the number of the preset new cases, and obtaining the number generation model when the cross entropy loss function value converges.
6. The method of claim 1, wherein the case characteristics include historical epidemic information, weather information, demographic information, and regional prevention and control information for infectious diseases; the obtaining case information of a first preset time range from the infectious disease case library comprises the following steps:
and acquiring historical epidemic information, weather information, population information, prevention and control information of infectious diseases in a preset area in the first preset time range and the preset newly-increased case number in the second preset time range from the infectious disease case library.
7. The method of claim 1, wherein the first predetermined time range is 30 days long and the second time range is 7 days long; the obtaining case information of a first preset time range from the infectious disease case library comprises the following steps:
acquiring case information of a first preset time range from the infectious disease case library by taking 30 days as a duration, wherein the case information comprises case characteristics and a preset newly-increased case number of the second preset time range; wherein the second preset time range is 7 days after the first preset time range.
8. An apparatus for generating a new case number, comprising:
the system comprises a case acquisition module, a training module and a program module, wherein the case acquisition module is used for acquiring case information of a first preset time range from an infectious disease case library, the case information comprises case characteristics and the number of new cases preset in the second preset time range, and the case characteristics are used as training samples; wherein the second preset time range is after the first preset time range;
the loss calculation module is used for inputting the training sample into a quantity generation model to be trained, generating the predicted number of new cases in the second preset time range according to the case characteristics by the quantity generation model, and calculating a loss function of the predicted number of new cases and the preset number of new cases;
and the model obtaining module is used for stopping training if the loss function meets a preset convergence condition to obtain a quantity generation model, and the quantity generation model is used for generating the quantity of the new cases.
9. A server comprising a processor, a memory, and a computer program stored on the memory and executable by the processor, the memory storing a policy model, wherein the computer program when executed by the processor implements the method of generating the number of new cases according to any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that the computer-readable storage medium has stored thereon a computer program which, when executed by a processor, causes the processor to implement the method of generating a new case number according to any one of claims 1 to 7.
CN202310804264.1A 2023-06-30 2023-06-30 Method, device, server and storage medium for generating number of new cases Pending CN116798643A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310804264.1A CN116798643A (en) 2023-06-30 2023-06-30 Method, device, server and storage medium for generating number of new cases

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310804264.1A CN116798643A (en) 2023-06-30 2023-06-30 Method, device, server and storage medium for generating number of new cases

Publications (1)

Publication Number Publication Date
CN116798643A true CN116798643A (en) 2023-09-22

Family

ID=88049515

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310804264.1A Pending CN116798643A (en) 2023-06-30 2023-06-30 Method, device, server and storage medium for generating number of new cases

Country Status (1)

Country Link
CN (1) CN116798643A (en)

Similar Documents

Publication Publication Date Title
CN110929869B (en) Sequence data processing method, device, equipment and storage medium
CN108021983A (en) Neural framework search
CN112579758A (en) Model training method, device, equipment, storage medium and program product
US20220147877A1 (en) System and method for automatic building of learning machines using learning machines
CN113516248B (en) Quantum gate testing method and device and electronic equipment
CN111027672A (en) Time sequence prediction method based on interactive multi-scale recurrent neural network
WO2021012263A1 (en) Systems and methods for end-to-end deep reinforcement learning based coreference resolution
CN114358317B (en) Data classification method based on machine learning framework and related equipment
CN113467487A (en) Path planning model training method, path planning device and electronic equipment
CN114358216B (en) Quantum clustering method based on machine learning framework and related device
CN108475346A (en) Neural random access machine
CN117351299A (en) Image generation and model training method, device, equipment and storage medium
CN113490955A (en) System and method for generating a pyramid level architecture
CN108376283B (en) Pooling device and pooling method for neural network
CN114372539B (en) Machine learning framework-based classification method and related equipment
CN116798643A (en) Method, device, server and storage medium for generating number of new cases
CN114238658A (en) Link prediction method and device of time sequence knowledge graph and electronic equipment
CN114764619A (en) Convolution operation method and device based on quantum circuit
CN116134415A (en) Pulse generation for updating a crossbar array
CN114730380A (en) Deep parallel training of neural networks
CN113160795B (en) Language feature extraction model training method, device, equipment and storage medium
CN114037066B (en) Data processing method and device, electronic equipment and storage medium
US20220129436A1 (en) Symbolic validation of neuromorphic hardware
CN116455427A (en) Time-frequency fusion analysis method, device and equipment for power line noise and storage medium
CN117951200A (en) Space-time sequence data complement method, equipment and medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination