DNA regulatory element design method based on STRs prior information
Through a deep generation network method based on STRs prior information, DNA regulatory elements containing short tandem repeat sequence characteristics are designed, combined with conditional adversarial generation network and multi-scale convolutional attention mechanism, the neglected biological characteristics of gene sequence generation in the existing technology is solved. and the problem of low accuracy of the prediction model, efficient generation of DNA regulatory elements with diverse and effective biological functions is achieved.
Patent Information
- Application Number
- CN202411196700.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-29
- Publication Date
- 2024-12-03
AI Technical Summary
Existing gene sequence generation and analysis methods ignore important biological characteristics, the prediction model is not accurate, and it is difficult to design DNA regulatory elements with high diversity and effective biological functions.
Using a deep generation network method based on STRs prior information, a generation sequence containing short tandem repeat sequence features is designed by obtaining the original component sequence and its activity values, and combining the conditional adversarial generation network and multi-scale convolutional attention mechanism to optimize the generation sequence. biological functionality and prediction accuracy.
It improves the biological credibility and diversity of the generated sequences, enhances the accuracy and reliability of the prediction model, and ensures the similarity and biometric consistency of the generated sequence and the natural sequence.
Smart Images

Figure CN119067157A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of synthetic biology regulatory element design, and specifically relates to a deep generative network method based on prior knowledge of flanking sequences and its application. Background Art
[0002] DNA regulatory elements are important DNA regions that regulate gene expression by interacting with molecules such as proteins and RNA. They include promoters, enhancers, terminators, etc., and are usually composed of cis-regulatory sequences and transcription factor binding sites (TFBSs). Promoters are the core elements that regulate gene expression, and designing synthetic promoters with ideal properties is crucial for biosynthetic engineering and gene therapy. At present, promoter design mainly adopts traditional design methods and intelligent computational design methods.
[0003] Traditional methods include: random mutation based on natural elements, that is, mutating a functional promoter to screen out sequences with the desired function; completely random generation, that is, randomly generating a large number of DNA sequences to screen out functional promoter sequences; based on transcription factor binding site design, that is, on the basic promoter skeleton, the placement of transcription factor binding sites is determined based on expert knowledge. These methods rely on a large amount of experimental data, have low design efficiency, and are difficult to accurately optimize for specific needs. Intelligent computational design methods are based on deep learning models, combined with generative models and predictive models, to optimize sequences through gradient propagation, screening, genetic algorithms, and other methods. This method improves design efficiency and reliability, and can achieve customized design without a large amount of experimental data.
[0004] Nevertheless, existing gene sequence generation and analysis methods still have problems, such as ignoring important biological features in the generated sequences, low accuracy of prediction models, and no prior knowledge constraints in the sequence design process. Therefore, it is of great significance to develop a new method that can efficiently generate gene sequences with high diversity and retain important biological features. Summary of the invention
[0005] The present invention aims to solve the problems in the prior art and provide a method for designing DNA regulatory elements based on STRs prior information, so as to improve the biological functionality of the generated sequence and significantly improve the accuracy and reliability of the prediction model, so that the designed DNA regulatory elements are effective in practical applications, thereby improving the problem that the generated sequence ignores important biological features and the prediction model has low accuracy.
[0006] In order to achieve the above-mentioned purpose, the present invention adopts the following technical scheme:
[0007] The characteristic of the DNA regulatory element design method based on STRs prior information of the present invention is that it is carried out according to the following steps:
[0008] Step 1: Obtain the original sequence and the motif position corresponding to each sequence;
[0009] Step 1.1: Get the original element sequence set Nat={n1,n2,…,n i ,…,n N} and its activity value Exp={e1,e2,…,e i ,…,e N}, where n i represents the ith original element sequence, e i Indicates n i The activity value of , N represents the number of original element sequences, i∈[1,N];
[0010] n i The sequence composed of Y motif positions is denoted as mp i ={(a i,1 ,b i,1 ), (a i,2 ,b i,2 ), …,(a i,y ,b i,y ),…, (a i,Y ,b i,Y )}, where (a i,y ,b i,y ) represents the i-th original element sequence n i The yth motif interval, a i,y Represents the i-th original element sequence n i The starting position of the yth motif, b i,y Represents the i-th original element sequence n i The y-th motif end position, y∈[1,Y];
[0011] Step 1.2: Take the sequence outside the motif position in Nat as the flanking sequence, and then replace the ith original element sequence n i The interval of the left wing sequence of the yth motif position is recorded as (b i,y-1 ,a i,y ), n i The interval of the right wing sequence of the yth motif position is recorded as (b i,y ,a i,y+1 );
[0012] Step 2: Set the random noise sequence = {z1,z2,…,z i ,…,z N}, where z i represents the i-th random noise;
[0013] Mask the flanking sequence of Nat to obtain X={x1,x2,…,x i ,…,x N}, where x i Indicates n i Mask of the flanking sequences;
[0014] Input X and Z into the generator for processing, and get the generated sequence V={v1,v2,…,v i ,…,v N}, where v i Represents the i-th original element sequence n i The corresponding generated sequence;
[0015] Step 3: Design elements containing short tandem repeat sequence characteristics to generate sequence S:
[0016] Step 4: Construct a similarity calculation model L to calculate the similarity score T={t1,t2, …,t i ,…,t N}, where t i Indicates n i and i Similarity score of
[0017] Sort T in descending order, and select the generated sequences corresponding to the first K similarity scores to form a generated sequence set TF={tf1,tf2, …,tf k ,…,tf K}, where tf k is the kth generated sequence similar to Nat, k∈[1,K];
[0018] Step 5: Construct a conditional adversarial generation network and use the generator to generate the generated sequence H of the remaining flanking sequences in TF except the motif and short tandem repeat sequence;
[0019] Step 5.1: After masking the flanking sequences in TF except the motif and short tandem repeats, the masked flanking sequences M={m1,m2, …,m k ,…,m K}; where m k represents the kth flanking mask sequence in TF;
[0020] Step 5.2: The masked flanking sequence M is used as a condition and input into the generator in the conditional adversarial generation network together with the random noise Z to obtain the generated sequence H = {h1,h2, …,h k ,…,h K}, where hk represents the kth flanking mask sequence m in TF k The corresponding generated sequence;
[0021] Step 6: Construct a predictor based on the multi-scale convolutional attention mechanism and use it to process Nat and output the predicted activity value P. Then, based on P and Exp, train the predictor to obtain the element sequence activity prediction model.
[0022] Step 7: Discriminate the feedback operation of the discriminator in the conditional adversarial generation network to optimize the activity value of the generated sequence H;
[0023] Step 7.1: Calculate m using equation (7) k With h k The conservative value u k , thus obtaining the conservative value sequence U={u1,u2,…,u k ,…,u K};
[0024] (7)
[0025] In formula (7), Indicates m k and h k The total number of non-masked characters in , Indicates m k and h k The total number of identical characters in all non-masked character positions;
[0026] Step 7.2: When u k When it is 100%, determine whether to perform feedback operation on the discriminator. If so, set h k With m k After splicing, the kth false data pair f is formed k , h k With m k After splicing, the kth real data pair r is formed k Otherwise, h k With m k After splicing, the kth false data pair f is formed k , tf k With m k After splicing, the kth real data pair r is formed k ;
[0027] Step 7.3: Place f k and r k Input to the discriminator for processing and output f k The probability of being identified as a true sample pf k and r kThe probability pr that is identified as a true sample k ;
[0028] Step 7.4: Use equation (2) to construct the discriminator loss function L D , used to identify tf k With h k The differences:
[0029] (2)
[0030] Step 7.5: According to the loss function L D , the recognition results of the discriminator are fed back to the generator for optimization training, thereby obtaining the trained conditional adversarial generation network.
[0031] The method for designing DNA regulatory elements based on STRs prior information of the present invention is also characterized in that step 3 is performed as follows:
[0032] Step 3.1: Obtain a base set B, which consists of four bases, including: guanine, cytosine, adenine, and thymine;
[0033] Step 3.2: Let con represent the number of bases in the base subset of B, and initialize con randomly;
[0034] Step 3.3: Randomly select con bases from B to form a base unit Q, , , Represents the number of elements in Q;
[0035] Step 3.4: Repeat the process of step 3.3 for rep times, thereby obtaining rep base units and splicing them into a short tandem repeat sequence;
[0036] Step 3.5: Follow the process of step 3.4 to obtain a set of J short tandem repeat sequences STR i ={str i,1 , str i,2 ,…,str i,j , …,str i,J}, where str i,j Indicates n i The corresponding generated sequence v i The j-th short tandem repeat sequence, j∈[1,J];
[0037] Step 3.6: Verify str i,j Is the length of less than v i The length of the j-th flanking sequence of , if , then str is converted into i,j Insert into vi The i-th generated sequence s containing short tandem repeat sequence characteristics is obtained from the flanking sequence of i , thus obtaining a generated sequence set S={s1,s2, …,s i ,…,s N}; If not, return to step 3.3 and step 3.4 to regenerate str i,j ;
[0038] s i = [ ( b i , y − 1 , s t r i , j , a i , y ) , ( b i , y , s t r i , j + 1 , a i , y + 1 ) ] (1).
[0039] The predictor in step 6 includes: an encoding layer, a convolutional neural network layer, an attention mechanism module, a gating mechanism module and a prediction module;
[0040] Step 6.1: The encoding layer performs one-hot encoding on Nat to obtain an encoded encoding matrix, which is then input into a convolutional neural network layer with different expansion rates for processing to obtain a local structural feature F of Nat;
[0041] Step 6.2: The attention mechanism module is used to capture the global structural features in F :
[0042] Step 6.3: The gating mechanism module uses the GRU layer to capture Contextual dependencies, output the hidden state of the last time step;
[0043] Step 6.4: The prediction module passes the hidden state through the fully connected layer, ReLU activation function and Dropout operation in sequence, and then through another fully connected layer, and outputs the activity prediction value P={p1,p2,…,p i ,…,p N}, where p i Represents the i-th original element sequence n i The predicted activity value of
[0044] Step 6.5: Use formula (6) to construct the loss function , used to optimize the parameters of the predictor to obtain a prediction model for element sequence activity;
[0045] (6).
[0046] The step 6.2 comprises:
[0047] Step 6.2.1: After F is mapped to different feature tensors A, B, and C through three layers of convolutional neural network, the dot product matrix is calculated , and then use formula (3) to get the attention weight matrix WAB Middle Line Column Weight :
[0048] (3)
[0049] In formula (3), Indicates the first Line Column elements, Represents W AB The number of columns;
[0050] Step 6.2.2: Use formula (4) to get the attention feature F att :
[0051] (4)
[0052] Step 6.2.3: F att After mapping through another convolutional layer, the output feature F is generated out ;
[0053] Step 6.2.4: Use formula (5) to obtain the global structural features of Nat :
[0054] (5)
[0055] In step 7.2, whether to perform feedback operation on the discriminator is determined according to the following process:
[0056] Step a: Get the original element sequence NTF corresponding to TF = {ntf1, ntf2, ..., ntf k ,…,ntf K} and its active value ETF={etf1,etf2,…,etf k ,…,etf K}, where ntf k Represents tf k The corresponding original element sequence, etf k Represents tf k The activity value of the corresponding original sequence;
[0057] Step b: Input H into the element sequence activity prediction model for processing to obtain the optimal activity prediction value P of H * ={p * 1,p * 2,…,p * k ,…,p * K}, where p *k Represents h k The optimal activity prediction value of
[0058] Step c: If p * k > ETFs k , it means that the discriminator is fed back to guide the generator to generate high-activity sequences; otherwise, it means that no feedback operation is performed on the discriminator.
[0059] The electronic device of the present invention includes a memory and a processor, wherein the memory is used to store a program that supports the processor to execute the DNA regulatory element design method, and the processor is configured to execute the program stored in the memory.
[0060] The present invention provides a computer-readable storage medium, wherein a computer program is stored on the computer-readable storage medium, and the computer program executes the steps of the DNA regulatory element design method when executed by a processor.
[0061] Compared with the prior art, the present invention has the following beneficial effects:
[0062] 1. After using cGAN to generate a new gene sequence, the present invention adds specific STRs sequence features to the generated sequence, and then calculates the similarity between the sequence and the natural sequence for screening. This process not only introduces STRs features, but also ensures that the generated sequence is highly consistent with the natural sequence in terms of biological structure features, overcoming the problem of low similarity between the generated sequence and the natural sequence in the prior art, thereby improving the biological credibility of the generated sequence.
[0063] 2. The present invention fixes the flanking STRs region of the screened element sequence, performs masking on the remaining flanking sequences, and inputs the preprocessed sequence into cGAN as a condition. This method can generate highly diverse gene sequences while retaining important biological features, overcoming the problem of single sequence generation in the prior art, thereby improving the biological diversity of the sequence.
[0064] 3. The present invention constructs a component sequence activity predictor based on a multi-scale convolutional attention mechanism. First, the different scale features of the sequence are extracted, and the key areas that have an important impact on the sequence activity are identified and strengthened in combination with the attention mechanism, and a predictor is constructed to predict the activity value of the biological sequence. This process can capture the short-range and long-range dependencies in the sequence, overcome the problem of low prediction accuracy in the prior art, and thus greatly improve the accuracy and reliability of the prediction. BRIEF DESCRIPTION OF THE DRAWINGS
[0065] Figure 1 It is a schematic diagram of the overall process of the present invention;
[0066] Figure 2 The design structure diagram of the improved biological element flanking sequence of the present invention;
[0067] Figure 3 This is the improved deep prediction structure diagram of biological element activity of the present invention. DETAILED DESCRIPTION
[0068] In this embodiment, a DNA regulatory element design method based on STRs prior information generates a new gene sequence through a conditional generative adversarial network (cGAN), adds specific short tandem repeat (STRs) features, and uses them as prior information to more comprehensively simulate the genome structure, provide a more accurate model for in-depth understanding of gene regulatory mechanisms, and improve prediction accuracy and reliability through an element activity prediction module based on a multi-scale convolutional attention mechanism. Specifically, this method is as follows Figure 1 As shown, the steps are as follows:
[0069] Step 1: Obtain the original sequence and the motif position corresponding to each sequence;
[0070] Step 1.1: Get the original element sequence set Nat={n1,n2,…,n i ,…,n N} and its activity value Exp={e1,e2,…,e i ,…,e N}, where n i represents the ith original element sequence, e i Indicates n i The activity value of , N represents the number of original element sequences, i∈[1,N];
[0071] n i The sequence composed of Y motif positions is denoted as mp i ={(a i,1 ,b i,1 ), (a i,2 ,b i,2 ), …,(a i,y ,b i,y ),…, (a i,Y ,b i,Y )}, where (a i,y ,b i,y ) represents the i-th original element sequence n i The yth motif interval, a i,y Represents the i-th original element sequence n i The starting position of the yth motif, b i,y Represents the i-th original element sequence n iThe y-th motif end position, y∈[1,Y];
[0072] Step 1.2: Take the sequence outside the motif position in Nat as the flanking sequence, and then replace the ith original element sequence n i The interval of the left wing sequence of the yth motif position is recorded as (b i,y-1 ,a i,y ), n i The interval of the right wing sequence of the yth motif position is recorded as (b i,y ,a i,y+1 ).
[0073] Step 2: Set the random noise sequence = {z1,z2,…,z i ,…,z N}, where z i represents the i-th random noise;
[0074] Mask the flanking sequence of Nat to obtain X={x1,x2,…,x i ,…,x N}, where x i Indicates n i Mask of the flanking sequences;
[0075] Input X and Z into the generator for processing, and get the generated sequence V={v1,v2,…,v i ,…,v N}, where v i Represents the i-th original element sequence n i The corresponding generated sequence.
[0076] Step 3: Designing element sequences containing short tandem repeat sequences, such as Figure 2 The specific implementation process is as follows:
[0077] Step 3.1: Obtain a base set B, which consists of four bases, including: guanine, cytosine, adenine, and thymine;
[0078] Step 3.2: Let con represent the number of bases in the base subset of B, and randomly initialize con. In this embodiment, con∈[2,4];
[0079] Step 3.3: Randomly select con bases from B to form a base unit Q, , , Represents the number of elements in Q.
[0080] Step 3.4: Repeat the process of step 3.3 for rep times. In this embodiment, rep∈[2,5], thereby obtaining rep base units and splicing them into a short tandem repeat sequence;
[0081] Step 3.5: Follow the process of step 3.4 to obtain a set of J short tandem repeat sequences STR i ={str i,1 , str i,2 ,…,str i,j , …,str i,J}, where str i,j Indicates n i The corresponding generated sequence v i The j-th short tandem repeat sequence, j∈[1,J].
[0082] Step 3.6: Verify str i,j Is the length of less than v i The length of the j-th flanking sequence of , if , then str is converted into i,j Insert into v i The i-th generated sequence s containing short tandem repeat sequence characteristics is obtained from the flanking sequence of i , thus obtaining a generated sequence set S={s1,s2, …,s i ,…,s N}; If not, return to step 3.3 and step 3.4 to regenerate str i,j ;
[0083] s i = [ ( b i , y − 1 , s t r i , j , a i , y ) , ( b i , y , s t r i , j + 1 , a i , y + 1 ) ] (1)
[0084] Step 4: Construct a similarity calculation model L to calculate the similarity score T={t1,t2, …,t i ,…,t N}, where t i Indicates n i and i Similarity score of
[0085] Sort T in descending order, and select the generated sequences corresponding to the first K similarity scores to form a generated sequence set TF={tf1,tf2, …,tf k ,…,tf K}, where tf k is the kth generated sequence similar to Nat, k∈[1,K]. In this embodiment, the K value is the first 50% of the total number of original component sequences.
[0086] Step 5: Construct a conditional adversarial generation network to generate the generated sequence H of the remaining flanking sequences in TF except the motif and short tandem repeat sequence;
[0087] Step 5.1: After masking the flanking sequences in TF except the motif and short tandem repeats, the masked flanking sequences M={m1,m2, …,m k ,…,m K}; where m k represents the kth flanking mask sequence in TF;
[0088] Step 5.2: The masked flanking sequence M is used as a condition and input into the generator in the conditional adversarial generation network together with the random noise Z to obtain the generated sequence H = {h1,h2, …,h k ,…,h K}, where h k represents the kth flanking mask sequence m in TF k The corresponding generated sequence;
[0089] Step 6: Construct a predictor based on a multi-scale convolutional attention mechanism. The structure diagram of this method is as follows Figure 3 As shown, it is used to process Nat and output the predicted activity value P, so as to train the predictor based on P and Exp to obtain the element sequence activity prediction model; wherein the predictor includes: an encoding layer, a convolutional neural network layer, an attention mechanism module, a gating mechanism module and a prediction module. This method can capture the short-range and long-range dependencies in the element sequence, learn the nucleotide structure characteristics of the element sequence, and improve the accuracy of the predictor.
[0090] Step 6.1: The encoding layer performs one-hot encoding on Nat to obtain an encoded encoding matrix, which is then input into a convolutional neural network layer with different expansion rates for processing to obtain a local structural feature F of Nat. In this embodiment, the expansion convolution rates are set to 1, 2, and 4, respectively.
[0091] Step 6.2: Attention mechanism module to capture the global structural features in F :
[0092] Step 6.2.1: After F is mapped to different feature tensors A, B, and C through three layers of convolutional neural network, the dot product matrix is calculated , and then use formula (3) to get the attention weight matrix W AB Middle Line Column Weight In this embodiment, W AB The dimensions are 64×64:
[0093] (3)
[0094] In formula (3), Indicates the first Line Column elements, Represents W AB The number of columns.
[0095] Step 6.2.2: Use formula (4) to get the attention feature F att In this embodiment, F att The dimensions are 64×1×256:
[0096] (4)
[0097] Step 6.2.3: F att After mapping through another convolutional layer, the output feature F is generated out In this embodiment, F out The dimensions are 64×1×256.
[0098] Step 6.2.4: Use formula (5) to integrate the sequence feature matrix to obtain the global structural features of Nat :
[0099] (5)
[0100] Step 6.3: The gate mechanism module uses the GRU layer to capture , and outputs the hidden state of the last time step.
[0101] Step 6.4: The prediction module passes the hidden state through the fully connected layer, ReLU activation function and Dropout operation in sequence, and then through another fully connected layer, and outputs the activity prediction value P={p1,p2,…,p i ,…,p N}, where p i Represents the i-th original element sequence n i The predicted value of activity.
[0102] Step 6.5: Use formula (6) to construct the loss function , used to optimize the parameters of the predictor to obtain a prediction model for element sequence activity;
[0103] (6)
[0104] Step 7: Connect the discriminator in the conditional adversarial generation network through a feedback operation to optimize the activity value of the generated sequence H;
[0105] Step 7.1: Get the original element sequence NTF corresponding to TF = {ntf1, ntf2, …, ntf k ,…,ntf K} and its active value ETF={etf1,etf2,…,etf k ,…,etf K}, where ntf k Represents tf k The corresponding original element sequence, etf k Represents tf k The activity value of the corresponding original sequence;
[0106] Input H into the element sequence activity prediction model for processing to obtain the activity prediction value P of H * ={p * 1,p * 2,…,p * k ,…,p * K}, where p * k Represents h k The activity prediction value of
[0107] Step 7.2: Calculate m using equation (7) k With h k The conservative value u k , thus obtaining the conservative value sequence U={u1,u2,…,u k ,…,u K}, the purpose of calculating the conservation value is to ensure that the motif and short tandem repeat sequence characteristics in the generated sequence H remain unchanged;
[0108] (7)
[0109] In formula (7), Indicates m k and h k The total number of non-masked characters in , Indicates m k and h k The total number of identical characters in all non-masked character positions;
[0110] Step 7.3: When u k If it is 100%, go to step 7.4; otherwise, go to step 7.5;
[0111] Step 7.4: If p * k > ETFs k, After performing feedback operation on the discriminator in the conditional adversarial generation network, execute step 7.6:
[0112] Use h k Replace tf k , and m k After splicing, the kth real data pair r is formed k ; will h k With m k Splicing to form the kth false data pair f k ; Otherwise, no feedback operation is performed and step 7.5 is executed;
[0113] Step 7.5: h k With m k After splicing, the kth false data pair f is formed k , tf k With m k After splicing, the kth real data pair r is formed k ;
[0114] Step 7.6: Place f k and r k Input to the discriminator for processing and output f k The probability of being identified as a true sample pf k and r k The probability pr that is identified as a true sample k ;
[0115] Step 7.7: Use equation (2) to construct the discriminator loss function L D , used to identify tf k With h k The differences:
[0116] (2)
[0117] Step 7.8: According to the loss function L D , the recognition results of the discriminator are fed back to the generator for optimization training, thereby obtaining a trained conditional adversarial generation network, which is used to guide the generator to generate high-activity sequences.
[0118] In this embodiment, an electronic device includes a memory and a processor, wherein the memory is used to store a program that supports the processor to execute the above method, and the processor is configured to execute the program stored in the memory.
[0119] In this embodiment, a computer-readable storage medium stores a computer program on the computer-readable storage medium, and the computer program executes the steps of the above method when executed by a processor.
[0120] To verify the effectiveness of the predictor of the present invention, a network model was constructed in python based on the pytorch framework and the Escherichia coli promoter database was used for activity prediction. Table 1 shows the Spearman correlation coefficients predicted by different methods.
[0121] Table 1 Comparison with other algorithms
[0122]
[0123] Table 1 shows the Spearman correlation coefficients of three different methods for predicting the activity of Escherichia coli promoters. The CNN+SVM method uses a convolutional neural network and a support vector machine to construct a predictor, and the Spearman correlation coefficient is 0.65, showing a medium level of correlation; the DenseNet+LSTM method uses a densely connected convolutional network combined with a long short-term memory network to construct a predictor, and the Spearman correlation coefficient is 0.74, showing a better correlation than CNN+SVM; the OURS method is a predictor constructed by the present invention based on a multi-scale convolutional attention mechanism, and the Spearman correlation coefficient is 0.81, showing a higher level of correlation.
Claims
1. A method for designing DNA regulatory elements based on STRs prior information, characterized in that: The steps are as follows: Step 1: Obtain the original sequence and the motif position corresponding to each sequence; Step 1.1: Get the original element sequence set Nat={n1,n2,…,n i ,…,n N } and its activity value Exp={e1,e2,…,e i ,…,e N }, where n i represents the ith original element sequence, e i Indicates n i The activity value of , N represents the number of original element sequences, i∈[1,N]; n i The sequence composed of Y motif positions is denoted as mp i ={(a i,1 ,b i,1 ), (a i,2 ,b i,2 ), …,(a i,y ,b i,y ),…,(a i,Y ,b i,Y )}, where (a i,y ,b i,y ) represents the i-th original element sequence n i The yth motif interval, a i,y Represents the i-th original element sequence n i The starting position of the yth motif, b i,y Represents the i-th original element sequence n i The y-th motif end position, y∈[1,Y]; Step 1.2: Take the sequence outside the motif position in Nat as the flanking sequence, and then replace the ith original element sequence n i The interval of the left wing sequence of the yth motif position is recorded as (b i,y-1 ,a i,y ), n i The interval of the right wing sequence of the yth motif position is recorded as (b i,y ,a i,y+1 ); Step 2: Set the random noise sequence = {z1,z2,…,z i ,…,z N }, where z i represents the i-th random noise; Mask the flanking sequence of Nat to obtain X={x1,x2,…,x i ,…,x N }, where x i Indicates n i Mask of the flanking sequences; Input X and Z into the generator for processing, and get the generated sequence V={v1,v2,…,v i ,…,v N }, where v i Represents the i-th original element sequence n i The corresponding generated sequence; Step 3: Design elements containing short tandem repeat sequence characteristics to generate sequence S: Step 4: Construct a similarity calculation model L to calculate the similarity score T={t1,t2, …,t i ,…,t N }, where t i Indicates n i and i Similarity score of ; Sort T in descending order, and select the generated sequences corresponding to the first K similarity scores to form a generated sequence set TF={tf1,tf2, …,tf k ,…,tf K }, where tf k is the kth generated sequence similar to Nat, k∈[1,K]; Step 5: Construct a conditional adversarial generation network and use the generator to generate the generated sequence H of the remaining flanking sequences in TF except the motif and short tandem repeat sequence; Step 5.1: After masking the flanking sequences in TF except the motif and short tandem repeats, the masked flanking sequences M={m1,m2, …,m k ,…,m K }; where m k represents the kth flanking mask sequence in TF; Step 5.2: The masked flanking sequence M is used as a condition and input into the generator in the conditional adversarial network together with the random noise Z to process the generated sequence H = {h1,h2, …,h k ,…,h K }, where h k represents the kth flanking mask sequence m in TF k The corresponding generated sequence; Step 6: Construct a predictor based on the multi-scale convolutional attention mechanism and use it to process Nat and output the predicted activity value P. Then, based on P and Exp, train the predictor to obtain the component sequence activity prediction model. Step 7: Discriminate the feedback operation of the discriminator in the conditional adversarial generation network to optimize the activity value of the generated sequence H; Step 7.1: Calculate m using equation (7) k With h k The conservative value u k , thus obtaining the conservative value sequence U={u1,u2,…,u k ,…,u K }; (7) In formula (7), Indicates m k and h k The total number of non-masked characters in , Indicates m k and h k The total number of identical characters in all non-masked character positions; Step 7.2: When u k When it is 100%, determine whether to perform feedback operation on the discriminator. If so, set h k With m k After splicing, the kth false data pair f is formed k , h k With m k After splicing, the kth real data pair r is formed k Otherwise, h k With m k After splicing, the kth false data pair f is formed k , tf k With m k After splicing, the kth real data pair r is formed k ; Step 7.3: Place f k and r k Input to the discriminator for processing and output f k The probability of being identified as a true sample is pf k and r k The probability pr that is identified as a true sample k ; Step 7.4: Use equation (2) to construct the discriminator loss function L D , used to identify tf k With h k The differences: (2) Step 7.5: According to the loss function L D , the recognition results of the discriminator are fed back to the generator for optimization training, thereby obtaining the trained conditional adversarial generation network.
2. A method for designing DNA regulatory elements based on STRs prior information according to claim 1, characterized in that: The step 3 is carried out as follows: Step 3.1: Obtain a base set B, which consists of four bases, including: guanine, cytosine, adenine, and thymine; Step 3.2: Let con represent the number of bases in the base subset of B, and initialize con randomly; Step 3.3: Randomly select con bases from B to form a base unit Q, , , Represents the number of elements in Q; Step 3.4: Repeat the process of step 3.3 for rep times, thereby obtaining rep base units and splicing them into a short tandem repeat sequence; Step 3.5: Follow the process of step 3.4 to obtain a set of J short tandem repeat sequences STR i ={ str i,1 ,str i,2 ,…,str i,j , …,str i,J }, where str i,j Indicates n i The corresponding generated sequence v i The j-th short tandem repeat sequence, j∈[1,J]; Step 3.6: Verify str i,j Is the length of less than v i The length of the j-th flanking sequence of , if , then str is converted into i,j Insert into v i The i-th generated sequence s containing short tandem repeat sequence characteristics is obtained from the flanking sequence of i , thus obtaining a generated sequence set S={s1,s2, …,s i ,…,s N }; If not, return to step 3.3 and step 3.4 to regenerate str i,j ; (1)。 3. A method for designing DNA regulatory elements based on STRs prior information according to claim 2, characterized in that: The predictor in step 6 includes: an encoding layer, a convolutional neural network layer, an attention mechanism module, a gating mechanism module and a prediction module; Step 6.1: The encoding layer performs one-hot encoding on Nat to obtain an encoded encoding matrix, which is then input into a convolutional neural network layer with different expansion rates for processing to obtain a local structural feature F of Nat; Step 6.2: The attention mechanism module is used to capture the global structural features in F : Step 6.3: The gating mechanism module uses the GRU layer to capture Contextual dependencies, output the hidden state of the last time step; Step 6.4: The prediction module passes the hidden state through the fully connected layer, ReLU activation function and Dropout operation in sequence, and then through another fully connected layer, and outputs the activity prediction value P={p1,p2,…,p i ,…,p N }, where p i Represents the i-th original element sequence n i The predicted activity value of Step 6.5: Use formula (6) to construct the loss function , used to optimize the parameters of the predictor to obtain a prediction model for element sequence activity; (6)。 4. A method for designing DNA regulatory elements based on STRs prior information according to claim 3, characterized in that: The step 6.2 comprises: Step 6.2.1: After F is mapped to different feature tensors A, B, and C through three layers of convolutional neural network, the dot product matrix is calculated , and then use formula (3) to get the attention weight matrix W AB Middle Line Column Weight : (3) In formula (3), Indicates the first Line Column elements, Represents W AB The number of columns; Step 6.2.2: Use formula (4) to get the attention feature F att : (4) Step 6.2.3: F att After mapping through another convolutional layer, the output feature F is generated out ; Step 6.2.4: Use formula (5) to obtain the global structural features of Nat : (5)。 5. A method for designing DNA regulatory elements based on STRs prior information according to claim 4, characterized in that: In step 7.2, whether to perform feedback operation on the discriminator is determined according to the following process: Step a: Get the original element sequence NTF corresponding to TF = {ntf1, ntf2, ..., ntf k ,…,ntf K } and its active value ETF={etf1,etf2,…,etf k ,…,etf K }, where ntf k Represents tf k The corresponding original element sequence, etf k Represents tf k The activity value of the corresponding original sequence; Step b: Input H into the element sequence activity prediction model for processing to obtain the optimal activity prediction value P of H * ={p * 1,p * 2,…,p * k ,…,p * K }, where p * k Represents h k The optimal activity prediction value of Step c: If p * k > ETFs k , it means that the discriminator is fed back to guide the generator to generate high-activity sequences; otherwise, it means that no feedback operation is performed on the discriminator.
6. An electronic device, comprising a memory and a processor, characterized in that: The memory is used to store a program that supports the processor to execute the DNA regulatory element design method according to any one of claims 1 to 5, and the processor is configured to execute the program stored in the memory.
7. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method for designing a DNA regulatory element according to any one of claims 1 to 5 are executed.
