A depression risk analysis method and device based on salivary cortisol dynamic timing data, medium and product
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-05-18
- Publication Date
- 2026-08-11
AI Technical Summary
[0004]本申请的目的是提供一种基于唾液皮质醇动态时序数据的抑郁风险分析方法、装置、介质及产品,以解决抑郁风险等级的确定精度较低的问题
本申请公开了一种基于唾液皮质醇动态时序数据的抑郁风险分析方法、装置、介质及产品,通过获取连续多天多个时刻的唾液皮质醇浓度,构建原始动态时序数据向量,相比于单点或稀疏时间点的测量方式,保留了皮质醇分泌的昼夜节律、日间变异性等关键动态信息;在此基础上,对原始数据进行预处理并确定总特征向量,将原始时序信息与多层次特征信息共同输入至基于双向长短时记忆网络、注意力机制层和全连接层构建的深度学习模型中。其中,双向长短时记忆网络能够捕捉时序数据中的长期依赖关系,注意力机制层自动聚焦于与抑郁风险关联度高的关键时间点,全连接层则进一步整合全局特征。通过上述多维度信息融合与深度学习建模,模型能够充分挖掘个体化的时序模式和下丘脑-垂体-肾上腺轴的功能特征,输出更为精确的个体化风险概率,进而确定更准确的抑郁风险等级,提高了抑郁风险等级的确定精度。
Smart Images

Figure CN122552129A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of biomedical technology, and in particular to a method, device, medium, and product for analyzing depression risk based on dynamic time-series data of salivary cortisol. Background Technology
[0002] The diagnosis of depressive disorders has long relied on clinical interviews and scale assessments, methods that are highly subjective and lack stable, objective biomarkers. Dysfunction of the hypothalamic-pituitary-adrenal (HPA) axis is considered an important pathophysiological mechanism of depression, and the concentration of its terminal product, cortisol, in saliva can non-invasively reflect the activity of the HPA axis; therefore, salivary cortisol is considered a potential biomarker related to depression.
[0003] As our understanding of the dynamic regulatory mechanisms of the hypothalamus-pituitary-adrenal axis deepens, researchers have gradually realized the limited information available from single-point cortisol measurements. They have begun collecting salivary cortisol data at multiple consecutive time points to capture individual circadian rhythms and stress response characteristics. However, the analytical methods for these multi-time-point data still have the following shortcomings: At the analytical level, they often employ population statistical methods such as t-tests, repeated measures ANOVA, or generalized estimating equations. These methods can only reveal differences in average trends between groups and cannot accurately predict individual depression risk. At the feature utilization level, they typically only calculate basic statistics such as mean, peak, or rate of change, failing to fully explore the high-dimensional information contained in the time-series data, such as rhythmic model parameters, nonlinear complexity indicators, and dynamic characteristics of stress response. Therefore, these methods lead to relatively low accuracy in determining the level of depression risk. Summary of the Invention
[0004] The purpose of this application is to provide a method, device, medium, and product for depression risk analysis based on dynamic time-series data of salivary cortisol, in order to solve the problem of low accuracy in determining depression risk levels.
[0005] To achieve the above objectives, this application provides the following solution.
[0006] Firstly, this application provides a method for analyzing depression risk based on dynamic time-series data of salivary cortisol, including: Obtain the raw salivary cortisol dynamic time-series data vector of the target subject; the raw salivary cortisol dynamic time-series data vector includes salivary cortisol concentrations at multiple times over multiple consecutive days; The original salivary cortisol dynamic time-series data vector of the target subjects was preprocessed to obtain the preprocessed salivary cortisol dynamic time-series data vector of the target subjects; Based on the pre-processed salivary cortisol dynamic time-series data vector of the target subjects, the total feature vector of the target subjects is determined; The preprocessed salivary cortisol dynamic time-series data vector and total feature vector of the target subjects are input into the depression risk assessment model to obtain the probability of the target subjects with different depression risk levels. The depression risk assessment model is obtained by training a deep learning model. The deep learning model includes a first branch, a second branch, and a fusion module. The first branch is built based on a bidirectional long short-term memory network and an attention mechanism layer, while the second branch and the fusion module are both built based on fully connected layers. The depression risk level is low risk, medium risk, or high risk. The depression risk level of the target subjects is determined based on their probability of different depression risk levels.
[0007] In one embodiment, the preprocessing includes: outlier detection and correction, missing value imputation, and standardization.
[0008] In one embodiment, the total feature vector of the target subject is determined based on the pretreated salivary cortisol dynamic time-series data vector, including: Feature extraction was performed on the pre-processed salivary cortisol dynamic time-series data vector of the target subjects to obtain the basic statistical feature vector, rhythm model feature vector, nonlinear feature vector and stress response feature vector of the target subjects; The basic statistical feature vector, rhythm model feature vector, nonlinear feature vector, and stress response feature vector of the target subject are concatenated to obtain the total feature vector of the target subject.
[0009] In one embodiment, the basic statistical feature vector includes the area under the daily curve, the diurnal coefficient of variation, the morning peak response, and the diurnal slope; The rhythm model feature vector includes the median salivary cortisol secretion, the salivary cortisol secretion amplitude, and the salivary cortisol secretion peak phase; The nonlinear feature vector includes sample entropy and detrended volatility analysis scaling index; The stress response feature vector includes response intensity, normalized gain, and recovery rate constant.
[0010] In one embodiment, the process of determining the depression risk assessment model includes: Obtain the training set; the training set includes preprocessed salivary cortisol dynamic time-series data vectors, total feature vectors, and corresponding true values of depression risk levels from multiple sample subjects; the true values of depression risk levels include one-hot encoding of probabilities for different depression risk levels; Build deep learning models; The deep learning model is trained using a cross-entropy loss function with category weights, taking the preprocessed salivary cortisol dynamic time-series data vector and total feature vector of each sample subject as input, and the true value of the depression risk level of the corresponding sample subject as output, to obtain the depression risk assessment model.
[0011] In one embodiment, the cross-entropy loss function with class weights includes: ; in, This represents the cross-entropy loss value. The total number of subjects in the training set; The weight of the k-th type of depression risk level; For the one-hot encoding of the risk level of the k-th type of depression in the m-th sample subject, At that time, the risk level for type k depression was low. At that time, the risk level of depression in category k was medium. At that time, the risk level for type k depression was high. Let be the probability of the m-th sample subject regarding the k-th type of depression risk level.
[0012] In one embodiment, the first branch includes a bidirectional long short-term memory network and an attention mechanism layer connected in sequence; the second branch includes a first fully connected layer, and the fusion module includes a splicing module, a second fully connected layer, a third fully connected layer, and a Softmax function connected in sequence; the attention mechanism layer and the first fully connected layer are both connected to the splicing module; The preprocessed salivary cortisol dynamic time-series data vector and total feature vector of the target subjects were input into the depression risk assessment model to obtain the probability of the target subjects with different depression risk levels, including: The preprocessed salivary cortisol dynamic temporal data vector of the target subjects was input into the bidirectional long short-term memory network in the depression risk assessment model to obtain the hidden state sequence of the target subjects. The hidden state sequence of the target subject is input into the attention mechanism layer of the depression risk assessment model to obtain the context vector of the target subject; The total feature vector of the target subject is input into the first fully connected layer in the depression risk assessment model to obtain the static feature representation vector of the target subject; The context vector and static feature representation vector of the target subject are input into the splicing module in the depression risk assessment model to obtain the spliced vector of the target subject. The hidden state vector of the target subject is input into the third fully connected layer in the depression risk assessment model to obtain the logical value vector of the depression risk level of the target subject. The target subject's depression risk level logistic value vector is input into the Softmax function in the depression risk assessment model to obtain the probability of the target subject with different depression risk levels.
[0013] Secondly, this application provides a computer device, including: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the above-described method for depression risk analysis based on dynamic time-series data of salivary cortisol.
[0014] Thirdly, this application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the aforementioned method for depression risk analysis based on dynamic time-series data of salivary cortisol.
[0015] Fourthly, this application provides a computer program product, including a computer program that, when executed by a processor, implements the aforementioned method for depression risk analysis based on dynamic time-series data of salivary cortisol.
[0016] According to the specific embodiments provided in this application, the following technical effects are disclosed: This application discloses a method, device, medium, and product for depression risk analysis based on dynamic time-series data of salivary cortisol. By acquiring salivary cortisol concentrations at multiple times over several consecutive days, a raw dynamic time-series data vector is constructed. Compared to single-point or sparse time-point measurements, this method preserves key dynamic information such as the diurnal rhythm and diurnal variability of cortisol secretion. Based on this, the raw data is preprocessed to determine the overall feature vector. The raw time-series information and multi-level feature information are then input into a deep learning model constructed based on a bidirectional long short-term memory network (BSSM), an attention mechanism layer, and a fully connected layer. The BSSM captures long-term dependencies in the time-series data, the attention mechanism layer automatically focuses on key time points highly correlated with depression risk, and the fully connected layer further integrates global features. Through this multi-dimensional information fusion and deep learning modeling, the model can fully explore individualized time-series patterns and the functional characteristics of the hypothalamus-pituitary-adrenal axis, outputting a more accurate individualized risk probability, thereby determining a more accurate depression risk level and improving the accuracy of depression risk level determination. Attached Figure Description
[0017] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0018] Figure 1 A schematic flowchart of a depression risk analysis method based on dynamic time-series data of salivary cortisol provided in an embodiment of this application; Figure 2 This is a schematic diagram of the structure of a depression risk assessment model provided in an embodiment of this application; Figure 3 This is a schematic diagram of the structure of a computer device provided in an embodiment of this application. Detailed Implementation
[0019] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0020] The purpose of this application is to provide a method, device, medium, and product for depression risk analysis based on dynamic time-series data of salivary cortisol, aiming to improve the accuracy of determining depression risk levels.
[0021] To make the above-mentioned objectives, features and advantages of this application more apparent and understandable, the application will be further described in detail below with reference to the accompanying drawings and specific embodiments.
[0022] In one exemplary embodiment, such as Figure 1 As shown, a method for analyzing depression risk based on dynamic time-series data of salivary cortisol is provided, including the following steps.
[0023] Step 1: Obtain the original salivary cortisol dynamic time-series data vector of the target subject.
[0024] The original salivary cortisol dynamic time-series data vector includes salivary cortisol concentrations at multiple times over several consecutive days.
[0025] Specifically, in the continuous ( ) days Saliva samples were collected from the target subjects at fixed times, and the salivary cortisol concentration (in nanomoles per liter (nmol / mL)) of each saliva sample was measured using an enzyme-linked immunosorbent assay (ELISA) kit, yielding the raw salivary cortisol dynamic time-series data vector for the target subjects. (Daily...) Fixed times include: immediately upon awakening (data collected right after waking), 30-45 minutes after awakening, and other time sequences throughout the day (e.g., 8:00, 12:00, 16:00, 20:00, 23:00). Continuous. ( ) days A total of fixed moments constitute That moment, namely From the first moment of day 1 to the... The first day A stress intervention experiment was conducted in the middle of the time interval between the time points.
[0026] Step 2: Preprocess the original salivary cortisol dynamic time-series data vector of the target subjects to obtain the preprocessed salivary cortisol dynamic time-series data vector of the target subjects.
[0027] As an optional implementation, step 2 includes preprocessing: outlier detection and correction, missing value imputation, and standardization.
[0028] Specifically, outlier detection and correction include: 1) Calculate the mean and standard deviation of the raw salivary cortisol dynamic time-series data vector for the target subjects. The formula for calculating the mean and standard deviation of the raw salivary cortisol dynamic time-series data vector for any subject is as follows: ; ; in, The mean of the original salivary cortisol dynamic time-series data vector; The concentration of salivary cortisol in the subject at time n; The standard deviation of the original salivary cortisol dynamic time-series data vector; 2) For any given moment, if If the concentration of salivary cortisol at that moment is then considered a suspected outlier; 3) Suspected outliers that are outside the physiological range (1-50 nmol / mL) are identified as final outliers; 4) Using cubic spline interpolation, the final outlier is smoothed and corrected based on the difference and the normal values before and after the final outlier, thus completing the outlier detection and correction and obtaining the dynamic time-series data vector of salivary cortisol after outlier detection and correction.
[0029] Missing value imputation specifically includes: for missing values in the dynamic time-series data vector of salivary cortisol after outlier detection and correction, the missing value imputation method of time series K nearest neighbor is used to obtain the dynamic time-series data vector of salivary cortisol after missing value imputation.
[0030] Standardization specifically includes: 1) Perform a natural logarithmic transformation on the salivary cortisol concentration at each time step in the imputed salivary cortisol dynamic time-series data vector to obtain the naturally logarithmic transformed salivary cortisol dynamic time-series data vector. The formula for the natural logarithmic transformation is: ; in, The salivary cortisol concentration at the nth time point is the natural logarithmic transformation of the subject's salivary cortisol concentration. The salivary cortisol concentration after imputing the missing values at the nth time point of the subject; 2) Calculate the mean and standard deviation of the salivary cortisol dynamic time-series data vector after natural logarithmic transformation for the target subjects. The formula for calculating the mean and standard deviation of the salivary cortisol dynamic time-series data vector after natural logarithmic transformation for any subject is as follows: ; ; in, The mean of the dynamic time-series data vector of salivary cortisol after natural logarithmic transformation; is the standard deviation of the dynamic time-series data vector of salivary cortisol after natural logarithmic transformation; 3) Z-score standardization was performed on the mean and standard deviation of the target subjects' salivary cortisol dynamic time-series data vector after natural logarithmic transformation to obtain the preprocessed salivary cortisol dynamic time-series data vector of the target subjects. The formula for Z-score standardization is: ; in, The concentration of salivary cortisol in the subject at time n after pretreatment.
[0031] Step 3: Determine the total feature vector of the target subjects based on the pre-processed salivary cortisol dynamic time-series data vector.
[0032] As an optional implementation, step 3 includes the following steps.
[0033] Step 31: Extract features from the pre-processed salivary cortisol dynamic time-series data vector of the target subjects to obtain the basic statistical feature vector, rhythm model feature vector, nonlinear feature vector, and stress response feature vector of the target subjects.
[0034] As an optional implementation, in step 31, the basic statistical feature vector includes the area under the daily curve, the diurnal coefficient of variation, the morning peak response, and the diurnal slope. The rhythm model feature vector includes the median salivary cortisol secretion, the amplitude of salivary cortisol secretion, and the phase of the salivary cortisol secretion peak; Nonlinear eigenvectors include sample entropy and detrended volatility analysis scaling exponent; The stress response eigenvector includes response intensity, normalized gain, and recovery rate constant.
[0035] Specifically, the process of determining each feature in the basic statistical feature vector is as follows: 1) Using the formula for calculating the area under the daily curve, determine the area under the daily curve for the target subject. The formula for calculating the area under the daily curve for any subject is as follows: ; in, The area under the daily curve for the subject on day d. ; The salivary cortisol concentration of the subject at time j on day d after pretreatment; The salivary cortisol concentration of the subject at time j+1 on day d after pretreatment; The time interval (in hours) between the (j+1)th time and the jth time. 2) Using the formula for calculating the coefficient of variation during the day, determine the coefficient of variation of the target subject. The formula for calculating the coefficient of variation of any subject is as follows: ; ; ; in, For the subjects in The mean area under the daily curve; For the subjects in The standard deviation of the area under the daily curve; The diurnal variation coefficient of the subjects; 3) Using the formula for calculating the morning peak response, determine the morning peak response of the target subject. The formula for calculating the morning peak response of any subject is as follows: ; in, The morning peak response of the subjects on day d; The subject was 30-45 minutes after waking up on day d. The concentration of salivary cortisol after pretreatment; The subject's awakening on day d. The concentration of salivary cortisol after pretreatment; 4) Using the formula for calculating the diurnal slope, determine the diurnal slope of the target subject. The formula for calculating the diurnal slope of any subject is as follows: ; in, The diurnal slope of the subject on day d; This refers to the number of times samples are taken during the daytime hours (8:00-20:00) each day. This refers to the j1st moment (in hours) during the daytime period of each day. The pretreated salivary cortisol concentration of the subject at time j1 during the daytime period on day d.
[0036] The process of determining each feature in the rhythm model feature vector is as follows: First, the pretreated salivary cortisol concentration at each time point during the daytime period in the target subjects' pretreated salivary cortisol dynamic time-series data vector is paired with the corresponding time (converted to hours). Then, using the least squares method, a cosine rhythm model is used to perform nonlinear least squares fitting based on each data pair to obtain the median salivary cortisol secretion, salivary cortisol secretion amplitude, and salivary cortisol secretion peak phase of the target subjects. The cosine rhythm model is as follows: ; in, The pretreated salivary cortisol concentration at time j2 is the pretreated salivary cortisol concentration at each time point during the daytime in the pretreated salivary cortisol dynamic time-series data vector of any subject. This represents the median level of salivary cortisol secretion. This represents the amplitude of salivary cortisol secretion; This represents the peak phase of salivary cortisol secretion; This is the fitting residual.
[0037] The process of determining each feature in a nonlinear eigenvector is as follows: 1) Using the formula for calculating the diurnal slope, determine the sample entropy of the target subject. The formula for calculating the sample entropy of any subject is as follows: ; ; in, Let be the sample entropy of any subject; The number of log matches within tolerance r for a subsequence of length a+1 in the pretreated salivary cortisol dynamic time-series data vector of the subject. The number of matching logs of length a subsequence in the pretreated salivary cortisol dynamic time-series data vector of the subject within the tolerance r; , represents the standard deviation of pretreated salivary cortisol concentration at all times in the dynamic time-series data vector of pretreated salivary cortisol for any subject; 2) First, according to the integral formula, an integration operation is performed based on the preprocessed salivary cortisol dynamic time-series data vector of the target subjects; the integral formula is: ; in, Let be the integral value with an integration length of 0; The pretreated salivary cortisol concentration at time j3, which is the integral length o in the dynamic time-series data vector of the subject's pretreated salivary cortisol. The mean salivary cortisol concentration at all times in the dynamic time-series data vector of pretreated salivary cortisol in the subjects. Then, Divide the data into windows of length p. Within each window, fit the local trend using the least squares method to obtain fitted values with an integral length of o for each window of length p. ; Subsequently, the detrended root mean square volatility of the target subjects was calculated: ; in, denoted as the root mean square fluctuation after detrending for any subject; Finally, plot in a double logarithmic coordinate system. The relationship with p is fitted to a straight line using the least squares method, and its slope is the detrended fluctuation analysis scaling index. The detrended fluctuation analysis scaling index is used to assess the long-range correlation of cortisol sequences: a detrended fluctuation analysis scaling index less than 0.5 indicates an inverse correlation, a detrended fluctuation analysis scaling index equal to 0.5 indicates white noise, and a detrended fluctuation analysis scaling index greater than 0.5 indicates a positive correlation. Depressed patients often show a detrended fluctuation analysis scaling index deviating from 0.5.
[0038] The process of determining each feature in the stress response feature vector is as follows: First, the pre-treated salivary cortisol concentration at the moment preceding the stress intervention experiment was extracted from the dynamic time-series data vector of the target subjects' pre-treated salivary cortisol. and the concentration of salivary cortisol after pretreatment at the next time step. ; Then, the intensity of the intervention response of the target subjects was calculated. : ; Subsequently, the normalized gain of the target subject's response was calculated. : ; Finally, the recovery rate constant of the target subject was obtained by fitting the exponential decay formula, which is: ; in, The pretreated salivary cortisol concentration at time t during the recovery period after the stress intervention experiment; The recovery rate constant of the subject; It is a natural constant.
[0039] Step 32: Concatenate the basic statistical feature vector, rhythm model feature vector, nonlinear feature vector, and stress response feature vector of the target subject to obtain the total feature vector of the target subject.
[0040] Specifically, the basic statistical feature vector, rhythm model feature vector, nonlinear feature vector, and stress response feature vector of the target subjects are horizontally concatenated to obtain the total feature vector of the target subjects. The total feature vector is a 1×12 dimensional vector.
[0041] Step 4: Input the preprocessed salivary cortisol dynamic time-series data vector and total feature vector of the target subjects into the depression risk assessment model to obtain the probability of the target subjects for different depression risk levels.
[0042] The depression risk assessment model is trained using a deep learning model. The deep learning model includes a first branch, a second branch, and a fusion module. The first branch is built based on a bidirectional long short-term memory network and an attention mechanism layer, while the second branch and the fusion module are both built based on fully connected layers. The depression risk level is classified as low, medium, or high.
[0043] As an optional implementation, step 4, the process of determining the depression risk assessment model, includes: Obtain the training set; the training set includes preprocessed salivary cortisol dynamic time-series data vectors, total feature vectors, and corresponding true values of depression risk levels from multiple sample subjects; the true values of depression risk levels include one-hot encoding of probabilities for different depression risk levels.
[0044] Build deep learning models.
[0045] By using the cross-entropy loss function with category weights, and taking the preprocessed dynamic time-series data vector of salivary cortisol and the total feature vector of each sample subject as input, and the true value of the depression risk level of the corresponding sample subject as output, a deep learning model is trained to obtain a depression risk assessment model.
[0046] As an optional implementation, the cross-entropy loss function with class weights includes: ; in, This represents the cross-entropy loss value. The total number of subjects in the training set; The weight of the k-th type of depression risk level; For the one-hot encoding of the risk level of the k-th type of depression in the m-th sample subject, At that time, the risk level for type k depression was low. At that time, the risk level of depression in category k was medium. At that time, the risk level for type k depression was high. Let be the probability of the m-th sample subject regarding the k-th type of depression risk level.
[0047] Specifically, during training, the Adam optimizer is used to optimize parameters, the initial learning rate is set to 0.001, random deactivation (ratio = 0.5) and L2 regularization are introduced to prevent overfitting, and early stopping is adopted, terminating training when the validation set loss no longer decreases for 10 consecutive rounds.
[0048] As an optional implementation method, such as Figure 2 As shown, the depression risk assessment model in step 4 includes: The first branch includes a bidirectional long short-term memory network and an attention mechanism layer connected in sequence; the second branch includes a first fully connected layer, and the fusion module includes a splicing module, a second fully connected layer, a third fully connected layer, and a Softmax function connected in sequence; the attention mechanism layer and the first fully connected layer are both connected to the splicing module.
[0049] Step 4 includes the following steps.
[0050] Step 41: Input the preprocessed salivary cortisol dynamic temporal data vector of the target subject into the bidirectional long short-term memory network in the depression risk assessment model to obtain the hidden state sequence of the target subject.
[0051] Specifically, the bidirectional Long Short-Term Memory (LSTM) network consists of two stacked LSM layers, each with 64 hidden units. The bidirectional LSM network simultaneously captures contextual information from both the past and future. This can be represented as: ; ; ; in, This represents the hidden state of the subject at time n. Forward value of the hidden state of the subject at time n; for; It is a long short-term memory network; The forward value of the hidden state at time n-1 of the experimenter; The backward value of the hidden state at time n of the subject; This is the backward value of the hidden state of the subject at time n+1.
[0052] Step 42: Input the hidden state sequence of the target subject into the attention mechanism layer in the depression risk assessment model to obtain the context vector of the target subject.
[0053] Specifically, at the attention mechanism level, firstly, the attention weights of the target subject at each moment are calculated: ; in, The attention weight of the subject at the nth time step; It is a single-layer feedforward network; This represents the hidden state of the subject at time n1. Then, the context vector of the target subject is calculated: ; in, This is the context vector of the subject.
[0054] Step 43: Input the total feature vector of the target subject into the first fully connected layer in the depression risk assessment model to obtain the static feature representation vector of the target subject.
[0055] Specifically, in the first fully connected layer, a linear transformation and nonlinear activation are performed on the total feature vector of the target subject to obtain the static feature representation vector of the target subject. This is represented as: ; in, This is the static feature representation vector of the subject; It is the ReLU activation function; This is the weight matrix of the first fully connected layer; The total feature vector of the subjects; This is the bias vector of the first fully connected layer; Step 44: Input the context vector and static feature representation vector of the target subject into the splicing module in the depression risk assessment model to obtain the splicing vector of the target subject.
[0056] Specifically, the splicing module is represented as follows: ; in, The concatenated vector of the subject; This is for splicing operations.
[0057] Step 45: Input the spliced vector of the target subject into the second fully connected layer in the depression risk assessment model to obtain the hidden state vector of the target subject.
[0058] Specifically, in the second fully connected layer, a linear transformation and non-linear activation are performed on the concatenated vector of the target subject to obtain the hidden state vector of the target subject. This is represented as: ; in, Let be the hidden state vector of the subject; This is the weight matrix of the second fully connected layer; This is the bias vector for the second fully connected layer.
[0059] Step 46: Input the hidden state vector of the target subject into the third fully connected layer in the depression risk assessment model to obtain the logical value vector of the depression risk level of the target subject.
[0060] Specifically, in the third fully connected layer, a linear transformation is performed on the hidden state vector of the target subject to obtain the logical value vector of the target subject's depression risk level. This is represented as: ; in, This is a vector of logical values representing the depression risk level of the subjects. This is the weight matrix of the third fully connected layer; This is the bias vector for the third fully connected layer.
[0061] Step 47: Input the target subject's depression risk level logical value vector into the Softmax function in the depression risk assessment model to obtain the probability of the target subject with respect to different depression risk levels.
[0062] Specifically, using the Softmax function, a linear transformation is performed on the target subject's logistic value vector of depression risk levels to obtain the probability of the target subject with respect to different depression risk levels. This is represented as: ; in, This represents the probability of the subject having a risk level of type k depression; is the logical value for the k-th type of depression risk level in the logical value vector of the subject's depression risk level.
[0063] Step 5: Determine the target subject's depression risk level based on the probability of the target subject with different depression risk levels.
[0064] Furthermore, following step 5, the process includes: extracting the top three most contributing features from the total feature vector using model interpretation methods (such as attention weight analysis) as key anomalous features, generating a structured report, and providing follow-up or intervention recommendations based on the target subject's depression risk level. The structured report includes: the target subject's depression risk level and probability value, key anomalous feature indications, and a comparison of the salivary cortisol time-series curve with the healthy reference range. In one exemplary embodiment, a depression risk analysis system based on dynamic time-series salivary cortisol data is provided to provide hardware and software support for the implementation of the method of this application. The system includes: 1. Data Acquisition and Access Module: Integrates a portable saliva collection tube barcode scanner with Bluetooth / Wi-Fi, automatically linking sample IDs and subject information. Provides an application programming interface (API) for interfacing with mainstream ELISA readers or chemiluminescence analyzers, automatically acquiring concentration data and uploading it to a cloud database; 2. Data Preprocessing Engine: A software module with built-in processing algorithms corresponding to step 3. It provides a graphical interface to display data quality reports (such as outlier locations and interpolation results), allowing expert users to manually review and adjust them; 3. Automated Feature Engineering Module: This module integrates open-source libraries such as tsfresh and AntroPy, and encapsulates the calculation functions for all features from step 3. It provides a configuration file, allowing users to select or customize the set of features to be calculated.
[0065] 4. Deep Learning Model Service Platform: A model service built on TensorFlowServing or PyTorchServe. It supports online model learning and updates: as the system accumulates new labeled data, incremental training can be initiated to update model parameters without affecting the service, allowing system performance to continuously evolve over time.
[0066] 5. Risk Assessment and Report Generation Module: Receives model output, calls a report template engine (such as Jinja2), and dynamically generates a detailed assessment report in PDF / HTML format, incorporating the subject's basic information. The report template conforms to clinical documentation standards.
[0067] 6. Secure and Compliant User Interaction Portal: A web-based B / S architecture platform. It provides different role permissions (subjects, doctors, researchers). Subjects can view their own reports; doctors can manage patient cohorts and perform batch assessments; researchers can conduct retrospective data analysis and model performance validation. All data transmission and storage are encrypted, complying with medical data privacy regulations (such as HIPAA, GDPR).
[0068] The methods described in this application are: 1) Objective and accurate: Overcoming the limitations of subjective scales, this application utilizes quantifiable biomarker dynamic time-series data, combined with deep learning, to significantly improve the objectivity and individualization accuracy of the assessment. 2) Deep utilization of time-series information: Through multi-level feature engineering and end-to-end deep learning, this application fully explores the volatility, complexity, and dynamic response patterns of cortisol rhythms, capturing key information that traditional methods cannot identify. 3) Systematization and automation: From data acquisition, preprocessing, feature extraction, model evaluation to report generation, a complete automated pipeline is formed, greatly improving analytical efficiency and reducing human error. 4) Strong clinical applicability: The non-invasive sampling method is easily accepted, and the system outputs intuitive and easy-to-understand reports that can directly assist clinical decision-making, making it suitable for large-scale screening and long-term efficacy monitoring. 5) Evolvability and interpretability: The model supports online updates, and performance can be continuously optimized. Attention mechanisms and feature importance analysis provide a certain degree of model interpretability, enhancing physician trust.
[0069] In one exemplary embodiment, a computer device is provided, including: a memory, a processor, and a computer program stored in the memory and executable on the processor, the processor executing the computer program to implement a method for depression risk analysis based on dynamic time-series data of salivary cortisol.
[0070] In one exemplary embodiment, a computer-readable storage medium is provided having a computer program stored thereon that, when executed by a processor, implements a method for depression risk analysis based on dynamic time-series data of salivary cortisol.
[0071] In one exemplary embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements a method for depression risk analysis based on dynamic time-series data of salivary cortisol.
[0072] In one exemplary embodiment, a computer device is provided, which may be a server or a terminal, and its internal structure diagram may be as follows. Figure 3As shown, this computer device includes a processor, memory, input / output (I / O) interfaces, and a communication interface. The processor, memory, and I / O interfaces are connected via a system bus, and the communication interface is also connected to the system bus via the I / O interfaces. The processor provides computational and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and databases. The internal memory provides the environment for the operating system and computer programs stored in the non-volatile storage media. The I / O interfaces are used for exchanging information between the processor and external devices. The communication interface is used for communicating with external terminals via a network connection. When executed by the processor, the computer program implements a method for depression risk analysis based on dynamic time-series data of salivary cortisol.
[0073] Those skilled in the art will understand that Figure 3 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.
[0074] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments described above. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM).
[0075] The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, etc., and are not limited to these.
[0076] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of the relevant data must comply with relevant regulations.
[0077] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0078] This document uses specific examples to illustrate the principles and implementation methods of this application. The descriptions of the above embodiments are only for the purpose of helping to understand the methods and core ideas of this application. Furthermore, those skilled in the art will recognize that, based on the ideas of this application, there will be changes in the specific implementation methods and application scope. Therefore, the content of this specification should not be construed as a limitation of this application.
Claims
1. A method for depression risk analysis based on salivary cortisol dynamic timing data, characterized in that, The depression risk analysis method based on dynamic time-series data of salivary cortisol includes: Obtain the raw salivary cortisol dynamic time-series data vector of the target subject; the raw salivary cortisol dynamic time-series data vector includes salivary cortisol concentrations at multiple times over multiple consecutive days; The original salivary cortisol dynamic time-series data vector of the target subjects was preprocessed to obtain the preprocessed salivary cortisol dynamic time-series data vector of the target subjects; Based on the pre-processed salivary cortisol dynamic time-series data vector of the target subjects, the total feature vector of the target subjects is determined; The preprocessed salivary cortisol dynamic time-series data vector and total feature vector of the target subjects are input into the depression risk assessment model to obtain the probability of the target subjects with different depression risk levels. The depression risk assessment model is obtained by training a deep learning model. The deep learning model includes a first branch, a second branch, and a fusion module. The first branch is built based on a bidirectional long short-term memory network and an attention mechanism layer, while the second branch and the fusion module are both built based on fully connected layers. The depression risk level is low risk, medium risk, or high risk. The depression risk level of the target subjects is determined based on their probability of different depression risk levels.
2. The method of claim 1, wherein the method is a method of depression risk analysis based on salivary cortisol dynamic timing data, characterized by, The preprocessing includes: outlier detection and correction, missing value imputation, and standardization.
3. The method of claim 1, wherein the method is a method of analyzing a risk of depression based on salivary cortisol dynamic timing data, characterized by, Based on the pretreated salivary cortisol dynamic time-series data vector of the target subjects, the total feature vector of the target subjects is determined, including: Feature extraction was performed on the pre-processed salivary cortisol dynamic time-series data vector of the target subjects to obtain the basic statistical feature vector, rhythm model feature vector, nonlinear feature vector and stress response feature vector of the target subjects; The basic statistical feature vector, rhythm model feature vector, nonlinear feature vector, and stress response feature vector of the target subject are concatenated to obtain the total feature vector of the target subject.
4. The method of claim 3, wherein the method is based on salivary Cortisol dynamic timing data. The basic statistical feature vectors include the area under the daily curve, the coefficient of variation during the day, the morning peak response, and the diurnal slope. The rhythm model feature vector includes the median salivary cortisol secretion, the salivary cortisol secretion amplitude, and the salivary cortisol secretion peak phase; The nonlinear feature vector includes sample entropy and detrended volatility analysis scaling index; The stress response feature vector includes response intensity, normalized gain, and recovery rate constant.
5. The method of claim 1, wherein the method further comprises: The process of determining the depression risk assessment model includes: Obtain the training set; the training set includes preprocessed salivary cortisol dynamic time-series data vectors, total feature vectors, and corresponding true values of depression risk levels from multiple sample subjects; the true values of depression risk levels include one-hot encoding of probabilities for different depression risk levels; Build deep learning models; The deep learning model is trained using a cross-entropy loss function with category weights, taking the preprocessed salivary cortisol dynamic time-series data vector and total feature vector of each sample subject as input, and the true value of the depression risk level of the corresponding sample subject as output, to obtain the depression risk assessment model.
6. The method of claim 5, wherein the method further comprises: The cross-entropy loss function with class weights includes: ; in, This represents the cross-entropy loss value. The total number of subjects in the training set; The weight of the k-th type of depression risk level; For the one-hot encoding of the risk level of the k-th type of depression in the m-th sample subject, At that time, the risk level for type k depression was low. At that time, the risk level of depression in category k was medium. At that time, the risk level for type k depression was high. Let be the probability of the m-th sample subject regarding the k-th type of depression risk level.
7. The method of claim 1, wherein the method further comprises: The first branch includes a bidirectional long short-term memory network and an attention mechanism layer connected in sequence; the second branch includes a first fully connected layer; the fusion module includes a splicing module, a second fully connected layer, a third fully connected layer, and a Softmax function connected in sequence; the attention mechanism layer and the first fully connected layer are both connected to the splicing module; The preprocessed salivary cortisol dynamic time-series data vector and total feature vector of the target subjects were input into the depression risk assessment model to obtain the probability of the target subjects with different depression risk levels, including: The preprocessed salivary cortisol dynamic temporal data vector of the target subjects was input into the bidirectional long short-term memory network in the depression risk assessment model to obtain the hidden state sequence of the target subjects. The hidden state sequence of the target subject is input into the attention mechanism layer of the depression risk assessment model to obtain the context vector of the target subject; The total feature vector of the target subject is input into the first fully connected layer in the depression risk assessment model to obtain the static feature representation vector of the target subject; The context vector and static feature representation vector of the target subject are input into the splicing module in the depression risk assessment model to obtain the spliced vector of the target subject. The spliced vector of the target subject is input into the second fully connected layer in the depression risk assessment model to obtain the hidden state vector of the target subject. The hidden state vector of the target subject is input into the third fully connected layer in the depression risk assessment model to obtain the logical value vector of the depression risk level of the target subject. The target subject's depression risk level logistic value vector is input into the Softmax function in the depression risk assessment model to obtain the probability of the target subject with different depression risk levels.
8. A computer apparatus comprising: A memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that the processor executes the computer program to implement the depression risk analysis method based on dynamic time-series data of salivary cortisol as described in any one of claims 1-7.
9. A computer readable storage medium having stored thereon a computer program, characterized in that, When executed by a processor, the computer program implements the depression risk analysis method based on dynamic time-series data of salivary cortisol as described in any one of claims 1-7.
10. A computer program product comprising a computer program, characterized in that, When executed by a processor, the computer program implements the depression risk analysis method based on dynamic time-series data of salivary cortisol as described in any one of claims 1-7.