A method and device for predicting pH preference value of bacteria
Through the multi-layer perceptron model combined with genome sequence alignment technology, the problem of the time-consuming prediction of bacterial strains is solved, and the rapid and accurate prediction of pH preference is achieved. It is suitable for a variety of bacteria, simplifying the process and improving efficiency .
Patent Information
- Application Number
- CN202410447672.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-15
- Publication Date
- 2024-11-12
- Estimated Expiration
- 2044-04-15
AI Technical Summary
In the prior art, the method for predicting the pH preference value of bacterial strain culture takes a long time and requires laboratory measurements and is used for measurements on a single strain, which has low efficiency.
A multi-layer perceptron model is used to combine genomic sequence and protein sequence alignment technology. By obtaining the genomic sequence of bacteria, mapping it into input vectors, predicting its pH preference value, and using pre-trained models to achieve rapid prediction.
Fast and accurate prediction of the pH preference values of a variety of bacteria is achieved, the laboratory measurement steps are reduced, and it is suitable for different strains, improving prediction efficiency and accuracy.
Smart Images

Figure CN118314952B_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of strain growth environment prediction, and in particular relates to a method and device for predicting pH preference values of bacteria. Background Art
[0002] At present, the research on predicting the pH of bacterial strain culture mainly focuses on the relationship between the pH response of microbial strains and the environmental pH. Among them, most of the research on the pH adaptability of microbial populations relies on collecting strain samples from specific sampling points, and then measuring the pH in the laboratory to predict the pH preference of the strain. The whole process is time-consuming, and each experiment is for a single strain, and different strains need to be tested separately. Summary of the invention
[0003] In order to solve the problem that the method of predicting strain preference values by pH measurement in the laboratory is time-consuming, the present application provides a method and device for predicting the pH preference value of bacteria.
[0004] In a first aspect, a method for predicting the pH preference value of bacteria is provided, comprising the following steps:
[0005] Obtaining a genome sequence of the strain to be detected, and obtaining a protein sequence of the strain to be detected based on the genome sequence of the strain to be detected;
[0006] Obtaining the structural domains contained in the protein sequence of the strain to be detected, and comparing the structural domains contained in the protein sequence of the strain to be detected with a plurality of pfam structural domains related to bacterial pH, respectively, to obtain the best first similarity in the comparison results of the structural domains contained in the protein sequence of each strain to be detected;
[0007] The first similarity is mapped into a first input vector, and the first input vector is used as an input of a pre-trained multi-layer perceptron model to obtain a pH preference value of the strain to be detected.
[0008] Optionally, the multi-layer perceptron model includes an input layer, a hidden layer and an output layer;
[0009] The training method of the multi-layer perceptron model includes:
[0010] Acquire a genome sequence for constructing a model, and obtain a protein sequence for constructing a model based on the genome sequence for constructing the model;
[0011] Obtaining the structural domain contained in the protein sequence of the constructed model, comparing the structural domain contained in the protein sequence of the constructed model with the pfam structural domain related to bacterial pH in the set gene library, obtaining the best second similarity in the comparison results of the structural domain contained in each protein sequence of the constructed model, and dividing the plurality of the second similarities into a training set and a test set;
[0012] Hyperparameter search is performed on the multilayer perceptron model to determine the number of units in the input layer, hidden layer, and output layer with the minimum root mean square error.
[0013] Optionally, the hyperparameter search for the multilayer perceptron model includes: performing a logarithmic search when the learning rate is between 1e-4 and 1e-2.
[0014] Optionally, obtaining the protein sequence of the strain to be detected based on the genome sequence of the strain to be detected includes:
[0015] The protein sequence corresponding to the genome sequence of the strain to be tested was obtained using the online database.
[0016] Optionally, obtaining the protein sequence of the strain to be detected based on the genome sequence of the strain to be detected further includes: if there is no protein sequence corresponding to the genome sequence of the strain to be detected in the online database, predicting the coding gene structure of the genome sequence of the strain to be detected to obtain the protein sequence of the strain to be detected.
[0017] Optionally, each hidden layer is followed by a batch normalization layer and a dropout layer, with the dropout ratio searched between 0.0 and 0.5.
[0018] In a second aspect, a device for predicting pH preference of bacteria is provided, comprising:
[0019] A protein sequence acquisition module, which is used to acquire the genome sequence of the strain to be detected, and obtain the protein sequence of the strain to be detected based on the genome sequence of the strain to be detected;
[0020] An input vector acquisition module is used to obtain the structural domains contained in the protein sequence of the strain to be detected, and compare the structural domains contained in the protein sequence of the strain to be detected with the pfam structural domains related to bacterial pH in the set gene library, so as to obtain the best first similarity in the comparison results of the structural domains contained in the protein sequence of each strain to be detected;
[0021] A prediction module is configured to map a first similarity to a first input vector; the first input vector is used as an input of a pre-trained multi-layer perceptron model to obtain a pH preference value of the strain to be detected.
[0022] Optionally, a model training module is also included, which is used to train the multi-layer perception model. The training method includes:
[0023] Acquire a genome sequence for constructing a model, and obtain a protein sequence for constructing a model based on the genome sequence for constructing the model;
[0024] Obtaining a structural domain contained in the protein sequence of the model, aligning the structural domain contained in the protein sequence of the model with a plurality of pfam structural domains related to bacterial pH, obtaining the best second similarity in the alignment results of each structural domain contained in the protein sequence of the model, and dividing the plurality of second similarities into a training set and a test set;
[0025] Hyperparameter search is performed on the multilayer perceptron model to determine the number of units in the input layer, hidden layer, and output layer with the minimum root mean square error.
[0026] According to a third aspect, an electronic device is provided, the electronic device comprising:
[0027] processor;
[0028] a memory for storing instructions executable by the processor;
[0029] The processor is used to read the executable instructions from the memory and execute the executable instructions to implement the method described in the first aspect.
[0030] According to a fourth aspect, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores a computer program, and the computer program is used to execute the method described in the first aspect.
[0031] Beneficial effect: Through the method for predicting the pH preference value of bacteria provided by this embodiment, the preference value of bacteria can be easily obtained. The pre-trained multi-layer perceptron model has high applicability to various strains. One model can be applied to different strains, that is, the method is suitable for predicting the pH preference value of multiple bacteria, and it can be seen from the prediction results of the test set that the method predicts the pH preference value with high accuracy. This prediction method does not need to rely on the number of strain samples collected from specific sampling points, does not require laboratory pH measurement, and has a fast pH prediction speed and a simple process. BRIEF DESCRIPTION OF THE DRAWINGS
[0032] The present invention is further described in detail below with reference to the accompanying drawings and specific embodiments.
[0033] Figure 1 A workflow diagram of a method for predicting pH preference of bacteria provided for this exemplary embodiment.
[0034] Figure 2A workflow diagram of a method for predicting pH preference of bacteria provided for this exemplary embodiment.
[0035] Figure 3 A scatter plot of the performance of a method for predicting pH preference values of bacteria on a training set and a test set provided in this exemplary embodiment.
[0036] Figure 4 A schematic diagram of the structure of an apparatus 900 provided according to an exemplary embodiment of the present application.
[0037] Figure 5 A schematic diagram of an electronic device provided by an exemplary embodiment of the present application is shown.
[0038] Figure 6 A schematic diagram of a computer-readable medium provided by an exemplary embodiment of the present application is shown. DETAILED DESCRIPTION
[0039] The technical solution of the present invention will be described clearly and completely below in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0040] In the description of the present invention, it should be noted that the terms "center", "upper", "lower", "left", "right", "vertical", "horizontal", "inner", "outer", etc., indicating the orientation or positional relationship, are based on the orientation or positional relationship shown in the drawings, and are only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as limiting the present invention. In addition, the terms "first", "second", and "third" are used for descriptive purposes only, and cannot be understood as indicating or implying relative importance.
[0041] In the description of the present invention, it should be noted that, unless otherwise clearly specified and limited, the terms "installed", "connected" and "connected" should be understood in a broad sense. For example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be indirectly connected through an intermediate medium, or it can be the internal connection of two components. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances. In addition, the technical features involved in the different embodiments of the present invention described below can be combined with each other as long as they do not conflict with each other.
[0042] Example
[0043] like Figure 1 As shown, this embodiment provides a method for predicting the pH preference value of bacteria, comprising the following steps:
[0044] S11, obtaining the genome sequence of the strain to be detected, and obtaining the protein sequence of the strain to be detected based on the genome sequence of the strain to be detected, including:
[0045] Use the online database to obtain the protein sequence corresponding to the genome sequence of the strain to be tested;
[0046] If the online database does not have a protein sequence corresponding to the genome sequence of the strain to be detected, the coding gene structure of the genome sequence of the strain to be detected is predicted to obtain the protein sequence of the strain to be detected.
[0047] S12, obtaining the structural domains contained in the protein sequence of the strain to be detected, and comparing the structural domains contained in the protein sequence of the strain to be detected with the pfam structural domains related to bacterial pH in the set gene library, respectively, to obtain the best first similarity in the comparison results of the structural domains contained in the protein sequence of each strain to be detected;
[0048] S13, mapping the first similarity into a first input vector, and using the first input vector as an input of a pre-trained multi-layer perceptron model to obtain a pH preference value of the strain to be detected.
[0049] The multi-layer perceptron model includes an input layer, a hidden layer and an output layer; each hidden layer is followed by a batch normalization layer and a Dropout layer, and the Dropout ratio is searched between 0.0 and 0.5;
[0050] The training method of the multi-layer perceptron model includes:
[0051] Acquire a genome sequence for constructing a model, and obtain a protein sequence for constructing a model based on the genome sequence for constructing the model;
[0052] Obtaining the structural domain contained in the protein sequence of the constructed model, comparing the structural domain contained in the protein sequence of the constructed model with the pfam structural domain related to bacterial pH in the set gene library, obtaining the best second similarity in the comparison results of the structural domain contained in each protein sequence of the constructed model, and dividing the plurality of the second similarities into a training set and a test set;
[0053] A hyperparameter search is performed on the multilayer perceptron model, specifically including a logarithmic search between 1e-4 and 1e-2 for the learning rate, and the number of units in the input layer, hidden layer, and output layer is determined by the minimum root mean square error.
[0054] like Figure 2As shown, this embodiment provides another method for predicting the pH preference value of bacteria, comprising the following steps:
[0055] S20, build and train a multi-layer perceptron model. Specifically, it includes:
[0056] S201, obtaining training data;
[0057] Based on Python 3.8, the requests library was used to call the API (Application Programming Interface) for the BacDive database (https: / / bacdive.dsmz.de / ) to obtain all species names in the BacDive database. For each species name, an API call was further made to obtain detailed genome sequences, including the 'culture_ph' field (culture pH field) and the 'genome' field (a field defined in the BacDive interface, corresponding to the genome accession number of the strain in NCBI); the records containing the 'culture_ph' and 'genome' fields were written to an Excel file through the openpyx l library to prepare for further analysis. In this step, the genome sequences in the NCBI Refseq database (https: / / www.ncbi.nlm.nih.gov / refseq / ) were preferred, and the NCBI GenBank database (https: / / www.ncbi.nlm.nih.gov / genbank / ) was an alternative.
[0058] Based on the genome field information recorded in the Excel file, the NCBI datasets command line tool (NCBI dataset tool) was used to download the corresponding strain genome sequence. This step was to obtain the genome sequence for building the model, that is, to obtain the genome data of bacteria in the NCBI database, so the culture pH value field was not used. The culture pH value field was used in the subsequent training model.
[0059] The protein sequence of the constructed model is obtained based on the genome sequence of the constructed model, including using an online database to obtain the protein sequence corresponding to the genome sequence of the constructed model. This operation uses a command to check whether the result contains a '.faa' (FASTA Amino Acid, protein amino acid sequence file) protein result file, and exports the '.faa' protein result file as the protein sequence of the constructed model; if the online database cannot obtain the protein sequence corresponding to part of the genome sequence of the constructed model, the Prod i gal tool is used to predict the coding gene structure of the genome sequence of the constructed model to obtain the protein sequence corresponding to the genome sequence of the constructed model.
[0060] 56 pfam (Protein family database) domains related to bacterial pH were obtained. These 56 domains were derived from literature search and were domains of genes that were considered to be related to bacterial pH.
[0061] The hmmscan command of the HMMER (HMMER is a commonly used sequence alignment tool, which is an algorithm based on the hidden Markov model) tool was used to perform functional annotation on the protein sequence corresponding to the genome sequence of the model constructed in the above steps, that is, to align the protein sequence of the model constructed with the 56 pfam domains related to bacterial pH, to obtain the alignment results of each protein sequence of the model constructed with the 56 pfam domains related to bacterial pH, and to use the second similarity with the best alignment result as the numerical representation of the gene feature, so that multiple second similarities can be obtained, and the second similarities are percentage values. The train_test_split function of the sklearn toolkit is used to divide the multiple second similarities into a training set and a test set according to a ratio of 8:2.
[0062] S202, constructing a neural network model. In this step, the highest value of the acc field in the repeated results is selected and used as the input value of this feature.
[0063] In this embodiment, a multi-layer perceptron model is used, and the multi-layer perceptron model includes an input layer, a hidden layer, and an output layer.
[0064] The input layer is a fully connected layer, and the number of units is determined by hyperparameter search, ranging from 8 to 48. The multilayer perceptron model contains 1 to 3 hidden layers, and the number of units in each hidden layer is also determined by hyperparameter search, also ranging from 8 to 48. Each hidden layer is followed by a batch normalization (BatchNorma li zat i on) layer and a Dropout layer (random drop layer), and the Dropout ratio is searched between 0.0 and 0.5, preferably 0.3, to optimize the model structure of the multilayer perceptron and prevent overfitting. The output layer is a single fully connected (Dense) layer, which outputs the pH preference value, and the output layer does not use an activation function.
[0065] In this embodiment, a multi-layer perceptron (MLP) model is selected for prediction because of its strong structural adaptability and its excellent fitting ability for the predetermined data set in preliminary experiments. In addition, the computational efficiency of the MLP model is higher than that of more complex models, making it more suitable for resource-constrained environments. At the same time, considering the specific characteristics of the first input vector, in particular, our first input vector does not contain temporal or spatial relationships, which means that more complex models, such as convolutional neural networks (CNNs) or recurrent neural networks (RNNs), do not provide additional advantages.
[0066] S203, training of multi-layer perceptron model;
[0067] The number of units in the input layer, hidden layer, and output layer of the multi-layer perceptron model is searched for hyperparameters, including using the Adam optimizer to perform a logarithmic search between the learning rate of 1e-4 and 1e-2, preferably between 1e-3 and 1e-4, using the mean squared error (mean_squared_error) as the loss function, configuring the RandomSearch strategy of Keras Tuner, setting the objective function to minimize the mean squared error on the test set, and starting the hyperparameter search. During the hyperparameter search, different hyperparameter combinations are tried, and the total number of attempts is limited to 30-50 times, preferably 50 times, using a random search method to fine-tune the multi-layer perceptron model and achieve the best performance. After the search, the optimal hyperparameter configuration is obtained for the final training and evaluation of the multi-layer perceptron model, and finally the trained multi-layer perceptron model is modeled.
[0068] The prediction results of the training set and the test set in this embodiment are shown in Figure 3 , Figure 3 R2 is an indicator used to measure the degree to which the independent variable explains the change of the dependent variable. The higher the R2 value, the more the regression model can explain the variation of the observed data and the stronger the prediction ability. The root mean square error of the multi-layer perceptron model in the test set prediction result is: 0.792, and the mean absolute error is: 0.613.
[0069] S21. Obtain the genome sequence of the strain to be detected, and obtain the protein sequence of the strain to be detected based on the genome sequence of the strain to be detected; the specific method of obtaining the protein sequence of the strain to be detected is the same as that of obtaining the protein sequence for building the model.
[0070] S22. Obtain the structural domains contained in the protein sequence of the strain to be detected, and compare the structural domains contained in the protein sequence of the strain to be detected with 56 pfam domains related to bacterial pH respectively, to obtain the best first similarity in the comparison results of the structural domains contained in the protein sequence of each strain to be detected, wherein the first similarity is a numerical value of percentage.
[0071] S23, mapping the first similarity into a first input vector; using the first input vector as the input of the trained multi-layer perceptron model to obtain the pH preference value of the strain to be detected.
[0072] This embodiment can use the Snakemake workflow management system to define a series of rules to automatically execute the entire process from gene data acquisition, functional annotation to final pH preference value prediction.
[0073] Through the method for predicting the pH preference value of bacteria provided in this embodiment, the preference value of bacteria can be easily obtained. The pre-trained multi-layer perceptron model has high applicability to various strains. One model can be applied to different strains, that is, the method is suitable for predicting the pH preference value of multiple bacteria, and it can be seen from the prediction results of the test set that the method predicts the pH preference value with high accuracy. This prediction method does not need to rely on the number of strain samples collected from specific sampling points, does not require laboratory pH measurement, and has a fast pH prediction speed and a simple process.
[0074] The method for predicting the pH preference of bacteria provided in this embodiment can be applied to multiple fields, (1) biotechnology and fermentation industry: in the process of microbial fermentation, predicting the preference of microorganisms for specific pH conditions can optimize the production efficiency of fermentation products; it can be used to screen and improve bacterial strains. Select microorganisms with strong adaptability to specific pH environments, or improve strains through genetic engineering to adapt to a wide range of pH conditions. (2) Environmental monitoring and pollution remediation: understanding the adaptability of microorganisms to different pH environments is helpful for environmental monitoring and predicting the response of microorganisms in ecosystems, as well as their application in pollution remediation; in environmental monitoring and pollution remediation, microbial pH preference information can be used to monitor and evaluate microbial pollution in the environment. At the same time, microorganisms can be designed and improved to make them more capable of degrading environmental pollutants under specific pH conditions. (3) Water and wastewater treatment: Microorganisms can degrade organic matter and other pollutants during wastewater treatment. Understanding the adaptability of microorganisms to different pH conditions in water bodies can optimize water and wastewater treatment processes and ensure that the microbial community can better perform wastewater treatment functions in a suitable environment. In water and wastewater treatment, suitable carriers or immobilization supports should be selected to improve the immobilization effect of microorganisms in the water treatment system, ensure the survival and reproduction of microorganisms during the water treatment process, and improve the treatment effect.
[0075] like Figure 4 As shown, this embodiment also provides a device for predicting pH preference values of bacteria, including:
[0076] The protein sequence acquisition module 901 is used to acquire the genome sequence of the strain to be detected, and obtain the protein sequence of the strain to be detected based on the genome sequence of the strain to be detected.
[0077] The input vector acquisition module 902 is used to obtain the structural domains contained in the protein sequence of the strain to be detected, and compare the structural domains contained in the protein sequence of the strain to be detected with the pfam structural domains related to bacterial pH in the set gene library, so as to obtain the best first similarity in the comparison results of the structural domains contained in the protein sequence of each strain to be detected.
[0078] The model training module 903 is used to train the multi-layer perception model. The training method includes:
[0079] Acquire a genome sequence for constructing a model, and obtain a protein sequence for constructing a model based on the genome sequence for constructing the model;
[0080] Obtaining the structural domain contained in the protein sequence of the constructed model, comparing the structural domain contained in the protein sequence of the constructed model with the pfam structural domain related to bacterial pH in the set gene library, obtaining the best second similarity in the comparison results of the structural domain contained in each protein sequence of the constructed model, and dividing the plurality of the second similarities into a training set and a test set;
[0081] Hyperparameter search is performed on the multilayer perceptron model to determine the number of units in the input layer, hidden layer, and output layer with the minimum root mean square error.
[0082] The prediction module 904 maps the first similarity into a first input vector; uses the first input vector as an input of a pre-trained multi-layer perceptron model to obtain a pH preference value of the strain to be detected.
[0083] In some implementations of the embodiments of the present application, the device 900 provided in the embodiments of the present application is based on the same inventive concept as the method provided in the aforementioned embodiments of the present application and has the same beneficial effects.
[0084] An embodiment of the present application also provides an electronic device corresponding to the method provided in the aforementioned embodiment. The electronic device may be an electronic device used for a server, such as a server, including an independent server and a distributed server cluster, etc., to execute the above method; the electronic device may also be an electronic device used for a client, such as a mobile phone, a laptop computer, a tablet computer, a desktop computer, etc., to execute the above method.
[0085] Please refer to Figure 5 , which shows a schematic diagram of an electronic device provided by some embodiments of the present application. Figure 5 As shown, the electronic device 40 includes: a processor 400, a memory 401, a bus 402 and a communication interface 403, and the processor 400, the communication interface 403 and the memory 401 are connected via the bus 402; the memory 401 stores a computer program that can be run on the processor 400, and the processor 400 executes the aforementioned method of the present application when running the computer program.
[0086] The memory 401 may include a high-speed random access memory (RAM), and may also include a non-volatile memory, such as at least one disk memory. The communication connection between the system network element and at least one other network element is realized through at least one communication interface 403 (which may be wired or wireless), and the Internet, wide area network, local area network, metropolitan area network, etc. may be used.
[0087] The bus 402 may be an ISA bus, a PCI bus, or an EISA bus, etc. The bus may be divided into an address bus, a data bus, a control bus, etc. The memory 401 is used to store programs, and the processor 400 executes the programs after receiving execution instructions. The method disclosed in any implementation of the above-mentioned embodiment of the present application may be applied to the processor 400, or implemented by the processor 400.
[0088] The processor 400 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by the hardware integrated logic circuit or software instructions in the processor 400. The above processor 400 can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiments of the present application can be implemented or executed. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor. The steps of the method disclosed in the embodiments of the present application can be directly embodied as a hardware decoding processor to be executed, or the hardware and software modules in the decoding processor can be executed. The software module can be located in a mature storage medium in the field such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory 401, and the processor 400 reads the information in the memory 401 and completes the steps of the above method in combination with its hardware.
[0089] The electronic device provided in the embodiment of the present application and the method provided in the embodiment of the present application are based on the same inventive concept and have the same beneficial effects as the method adopted, operated or implemented by them.
[0090] The present application also provides a computer-readable medium corresponding to the method provided in the above embodiment. Figure 6 The computer-readable storage medium shown is a CD 50 on which a computer program (ie, a program product) is stored. When the computer program is run by a processor, the aforementioned method will be executed.
[0091] It should be noted that the flowcharts and block diagrams in the accompanying drawings show the possible architecture, functions and operations of the systems, methods and computer program products according to multiple embodiments of the present application. In this regard, each box in the flowchart or block diagram can represent a module, a program segment or a part of a code, and the module, a program segment or a part of a code contains one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flowchart, and the combination of the boxes in the block diagram and / or flowchart can be implemented with a dedicated hardware-based system that performs a specified function or action, or can be implemented with a combination of dedicated hardware and computer instructions.
[0092] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0093] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. The device embodiments described above are merely schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some communication interfaces, and the indirect coupling or communication connection of devices or units can be electrical, mechanical or other forms.
[0094] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0095] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0096] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application can be essentially or partly embodied in the form of a software product that contributes to the prior art. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.
[0097] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit it. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein by equivalents. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the scope of the technical solutions of the embodiments of the present application, and they should all be included in the scope of the claims and specification of the present application.
Claims
1. A method for predicting pH preference of bacteria, characterized in that: The following steps are involved: Obtaining a genome sequence of the strain to be detected, and obtaining a protein sequence of the strain to be detected based on the genome sequence of the strain to be detected; Obtaining the structural domains contained in the protein sequence of the strain to be detected, and comparing the structural domains contained in the protein sequence of the strain to be detected with a plurality of pfam structural domains related to bacterial pH, respectively, to obtain the best first similarity in the comparison results of the structural domains contained in the protein sequence of each strain to be detected; Mapping the first similarity into a first input vector, using the first input vector as an input of a pre-trained multi-layer perceptron model, and obtaining a pH preference value of the strain to be detected; The multi-layer perceptron model includes an input layer, a hidden layer and an output layer; The training method of the multi-layer perceptron model includes: Acquire a genome sequence for constructing a model, and obtain a protein sequence for constructing a model based on the genome sequence for constructing the model; Obtaining the structural domain contained in the protein sequence of the constructed model, comparing the structural domain contained in the protein sequence of the constructed model with the pfam structural domain related to bacterial pH in the set gene library, obtaining the best second similarity in the comparison results of the structural domain contained in each protein sequence of the constructed model, and dividing the plurality of the second similarities into a training set and a test set; Hyperparameter search is performed on the multilayer perceptron model to determine the number of units in the input layer, hidden layer, and output layer with the minimum root mean square error.
2. The method for predicting pH preference of bacteria according to claim 1, characterized in that: The hyperparameter search for the multilayer perceptron model includes: performing a logarithmic search when the learning rate is between 1e-4 and 1e-2.
3. The method for predicting pH preference of bacteria according to claim 1, characterized in that: The method of obtaining the protein sequence of the strain to be detected based on the genome sequence of the strain to be detected comprises: The protein sequence corresponding to the genome sequence of the strain to be tested was obtained using the online database.
4. The method for predicting pH preference of bacteria according to claim 3, characterized in that: The step of obtaining the protein sequence of the strain to be detected based on the genome sequence of the strain to be detected further includes: if the online database does not have a protein sequence corresponding to the genome sequence of the strain to be detected, then the genome sequence of the strain to be detected is predicted to obtain the protein sequence of the strain to be detected.
5. The method for predicting pH preference of bacteria according to claim 1, characterized in that: Each hidden layer is followed by a batch normalization layer and a dropout layer, and the dropout ratio is searched between 0.0 and 0.
5.
6. A device for predicting the pH preference value of bacteria according to claim 1, characterized in that: include: A protein sequence acquisition module, which is used to acquire the genome sequence of the strain to be detected, and obtain the protein sequence of the strain to be detected based on the genome sequence of the strain to be detected; An input vector acquisition module is used to obtain the structural domains contained in the protein sequence of the strain to be detected, and compare the structural domains contained in the protein sequence of the strain to be detected with the pfam structural domains related to bacterial pH in the set gene library, so as to obtain the best first similarity in the comparison results of the structural domains contained in the protein sequence of each strain to be detected; A prediction module is configured to map a first similarity to a first input vector; the first input vector is used as an input of a pre-trained multi-layer perceptron model to obtain a pH preference value of the strain to be detected.
7. The device for predicting the pH preference value of bacteria according to claim 6, characterized in that: It also includes a model training module, which is used to train the multi-layer perception model. The training method includes: Acquire a genome sequence for constructing a model, and obtain a protein sequence for constructing a model based on the genome sequence for constructing the model; Obtaining a structural domain contained in the protein sequence of the model, aligning the structural domain contained in the protein sequence of the model with a plurality of pfam structural domains related to bacterial pH, obtaining the best second similarity in the alignment results of each structural domain contained in the protein sequence of the model, and dividing the plurality of second similarities into a training set and a test set; Hyperparameter search is performed on the multilayer perceptron model to determine the number of units in the input layer, hidden layer, and output layer with the minimum root mean square error.
8. An electronic device, characterized in that: The electronic device comprises: processor; a memory for storing instructions executable by the processor; The processor is configured to read the executable instructions from the memory and execute the executable instructions to implement the method according to any one of claims 1 to 5.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and the computer program is used to execute the method according to any one of claims 1 to 5.
