Prediction of COVID-19 Cases Using Constructed Features by Grammatical Evolution
Abstract
:1. Introduction
2. Method Description
2.1. Grammatical Evolution
- N is the set of the non-terminal symbols, used to produce a series of terminal symbols through production rules.
- T is the set of terminal symbols of grammar. For example, terminal symbols could be the digits in an arithmetic expression of the operators.
- S is the starting non-terminal symbol of grammar. The production of a valid expression is initiated from this symbol.
- P is the set of production rules. Every rule is in the form or .
- Retrieve the next element from the given chromosome and denote it as V.
- The next production rule R is calculated by
- Divide the chromosome into parts. Each part will construct a separate feature.
- A feature is constructed for every using the grammar given in Figure 2.
- Construct a mapping function
2.2. Feature Creation Step
- Initialization step
- (a)
- Set iter= 0, the current number of generations.
- (b)
- Consider the set , the original training set.
- (c)
- Set as the number of chromosomes in the genetic population.
- (d)
- Set as the number of constructed features.
- (e)
- Initialize randomly in range every element of each chromosome.
- (f)
- Set as the maximum number of generations.
- (g)
- Set as the selection rate.
- (h)
- Set as the mutation rate.
- Termination check step. If iter >= terminate.
- Calculate the fitness of every chromosome with the following procedure:
- (a)
- Create features using the mapping procedure of Section 2.1.
- (b)
- Construct the mapped training set
- (c)
- Train an RBF neural network C with H processing units on the new set and obtain the following training error:
- (d)
- Set
- Genetic Operators
- (a)
- Selection procedure: The chromosomes are sorted according to their fitness. The best are copied intact to the next generation. The genetic operations of crossover and mutation are applied to rest of the chromosomes.
- (b)
- Crossover procedure: During this process , offspring will be created. For every couple of produced offspring, two parents are selected using the well-known procedure of tournament selection. For every pair of parents, two offspring and are produced through one-point crossover. An example of one-point crossover is shown in Figure 3.
- (c)
- Mutation procedure: For each element of every chromosome, a random number is produced. Subsequently, we randomly change the corresponding element if .
- Set iter = iter + 1 and goto Step 2.
2.3. Feature Evaluation Step
- Initialization step.
- (a)
- Set as , the number of chromosomes that will participate.
- (b)
- Set as the maximum number of allowed generations.
- (c)
- Set as , the mutation rate.
- (d)
- Set as the selection rate.
- (e)
- Set, a small positive number, i.e., .
- (f)
- Randomly initialize the chromosomes . For the case of neural networks, every element of each chromosome is considered as a double precision number. Additionally, the size of each chromosome is
- (g)
- Set iter = 0
- Check for termination.
- (a)
- Obtain the best fitness
- (b)
- Terminate if OR
- Calculate fitness.
- (a)
- Fordo
- i.
- Create a neural network using the chromosome as a parameter vector.
- ii.
- Calculate the fitness value using Equation (4).
- (b)
- EndFor
- Application of genetic operators.
- (a)
- Selection operation. During selection, the chromosomes are classified according to their fitness. The first are copied without changes to the next generation of the population. The rest will be replaced by chromosomes that will be produced at the crossover.
- (b)
- Crossover operation. In the crossover operation, chromosomes are produced. For every couple of produced offspring, two parents are selected using tournament selection. For every pair of parents, two offspring and are produced according to the following equations:
- (c)
- Mutation operation. For each element of every chromosome, a random number is produced, and the element is altered if .
- (d)
- Set iter = iter + 1.
- Goto step 2.
3. Experimental Results
- The number of cases was divided by .
- The number of deaths was divided by .
- The column COUNTRY contains the name of the country.
- The column ADAM stands for the Adam optimization method [53] used to train a neural network with 10 processing nodes. The ADAM method is implemented in OptimLib, and it is available from https://github.com/kthohr/optim (accessed on 10 September 2022).
- The column MLPPSO represents the results using a neural network trained with the help of Particle Swarm Optimization method [54,55]. The number of PSO particles was set to , and the maximum number of allowed iterations was set to . The values for thes parameters are shown in the Table 2. Additionally, the BFGS method [56] was applied to the best particle of the swarm when the PSO finished, in order to enhance the results.
- The column MLPGEN stands for the results obtained by a neural network with ten processing units that was trained using a genetic algorithm [17,18]. The parameters for this algorithm are listed in the Table 2. Additionally, the BFGS was applied to the best chromosome after the termination of the genetic algorithm.
- The column FC1 stands for the results obtained by the proposed method with one constructed feature .
- The column FC2 stands for the results obtained by the proposed method with two constructed features .
- The column FC3 stands for the results obtained by the proposed method with three constructed features .
Parameter | Value |
---|---|
500 | |
200 | |
H | 10 |
0.10 | |
0.05 | |
Country | ADAM | MLPPSO | MLPGEN | FC1 | FC2 | FC3 |
---|---|---|---|---|---|---|
Algeria | 0.31 | 0.08 | 0.286 | 0.0025 | 0.0006 | 0.0002 |
Argentina | 178.60 | 21.03 | 69.20 | 3.21 | 0.81 | 0.91 |
Australia | 144.46 | 20.33 | 30.96 | 1.52 | 0.37 | 0.34 |
Brazil | 198.26 | 81.94 | 75.79 | 11.93 | 8.97 | 6.50 |
Bulgaria | 4.01 | 1.29 | 2.67 | 0.037 | 0.0098 | 0.01 |
Canada | 27.68 | 6.12 | 20.65 | 0.33 | 0.20 | 0.15 |
Germany | 274.34 | 135.15 | 92.50 | 25.05 | 25.11 | 14.36 |
Greece | 25.07 | 12.08 | 9.25 | 3.62 | 1.60 | 2.75 |
Egypt | 0.24 | 0.13 | 0.44 | 0.005 | 0.029 | 0.003 |
Japan | 271.11 | 95.56 | 75.76 | 8.92 | 2.15 | 1.82 |
Average | 112.41 | 37.37 | 37.75 | 5.46 | 3.92 | 2.68 |
Country | ADAM | PSOGEN | MLPGEN | FC1 | FC2 | FC3 |
---|---|---|---|---|---|---|
Algeria | 0.40 | 0.15 | 0.66 | 0.009 | 0.002 | 0.002 |
Argentina | 18.50 | 19.70 | 25.81 | 2.03 | 1.35 | 1.70 |
Australia | 1.69 | 0.44 | 1.00 | 0.05 | 0.03 | 0.03 |
Brazil | 416.54 | 282.46 | 230.52 | 52.42 | 16.75 | 16.57 |
Bulgaria | 3.80 | 2.76 | 16.50 | 0.15 | 0.10 | 0.08 |
Canada | 9.12 | 4.78 | 18.12 | 0.27 | 0.15 | 0.15 |
Germany | 116.56 | 37.06 | 40.49 | 3.03 | 2.07 | 4.17 |
Greece | 3.29 | 2.97 | 2.86 | 0.74 | 0.08 | 0.07 |
Egypt | 2.57 | 0.79 | 8.88 | 0.07 | 0.03 | 0.02 |
Japan | 43.10 | 22.07 | 13.74 | 0.32 | 0.12 | 0.13 |
Average | 61.56 | 37.32 | 35.86 | 5.91 | 2.07 | 2.29 |
4. Conclusions
- The incorporation of more advanced stopping rules for the genetic algorithms of the two phases.
- The usage of other machine-learning models instead of the RBF network, to evaluate the constructed features.
- The usage of parallel techniques to speed up the feature-creation process.
- The use of a data technique that will also contain the demographic characteristics of each country, in order to establish whether there is a correlation of the rate of cases or mortality with the particular characteristics of some countries.
Author Contributions
Funding
Data Availability Statement
Acknowledgments
Conflicts of Interest
References
- Andersen, K.G.; Rambaut, A.; Lipkin, W.I.; Holmes, E.C.; Garry, R.F. The proximal origin of sars-cov-2. Nat. Med. 2020, 26, 450–452. [Google Scholar] [CrossRef] [PubMed] [Green Version]
- Wang, L.; Li, J.; Guo, S.; Xie, N.; Yao, L.; Cao, Y.; Day, S.W.; Howard, S.C.; Gra, J.C.; Gu, T.; et al. Real-time estimation and prediction of mortality caused by covid-19 with patient information based algorithm. Sci. Total Environ. 2020, 727, 138394. [Google Scholar] [CrossRef] [PubMed]
- Tomar, A.; Gupta, N. Prediction for the spread of covid- 19 in india and eectiveness of preventive measures. Sci. Total Environ. 2020, 728, 138762. [Google Scholar] [CrossRef] [PubMed]
- Zhang, X.; Ma, R.; Wang, L. Predicting turning point, duration and attack rate of covid-19 outbreaks in major western countries. Chaos Solitons Fractals 2020, 135, 109829. [Google Scholar] [CrossRef] [PubMed]
- Pinter, G.; Felde, I.; Mosavi, A.; Ghamisi, P.; Gloaguen, R. COVID-19 pandemic prediction for hungary; a hybrid machine learning approach. Mathematic 2020, 8, 890. [Google Scholar]
- Smith, M.; Alvarez, F. Identifying mortality factors from machine learning using shapley values a case of covid19. Expert. Appl. 2021, 176, 114832. [Google Scholar] [CrossRef] [PubMed]
- Loey, M.; Manogaran, G.; Taha, M.H.N.; Khalifa, N.E.M. A hybrid deep transfer learning model with machine learning methods for face mask detection in the era of the covid-19 pandemic. Measurement 2021, 167, 108288. [Google Scholar] [CrossRef]
- Mundial, I.Q.; Ul Hassan, M.S.; Tiwana, M.I.; Qureshi, W.S.; Alanazi, E. Towards facial recognition problem in COVID-19 pandemic. In Proceedings of the 2020 4rd International Conference on Electrical, Telecommunication and Computer Engineering (ELTICOM), Medan, Indonesia, 3–4 September 2020; pp. 210–214. [Google Scholar]
- Gavrilis, D.; Tsoulos, I.G.; Dermatas, E. Selecting and constructing features using grammatical evolution. Pattern Recognit Lett. 2008, 29, 1358–1365. [Google Scholar]
- O’Neill, M.; Ryan, C. grammatical evolution. IEEE Trans. Evol. Comput. 2001, 5, 349–358. [Google Scholar] [CrossRef] [Green Version]
- Gavrilis, D.; Tsoulos, I.G.; Dermatas, E. Neural recognition and genetic features selection for robust detection of e-mail spam. In Hellenic Conference on Articial Intelligence; Springer: Berlin/Heidelberg, Germany, 2006; pp. 498–501. [Google Scholar]
- Georgoulas, G.; Gavrilis, D.; Tsoulos, I.G.; Stylios, C.; Bernardes, J.; Groumpos, P.P. Novel approach for fetal heart rate classication introducing grammatical evolution. Biomed. Signal Process. Control 2007, 2, 69–79. [Google Scholar] [CrossRef]
- Smart, O.; Tsoulos, I.G.; Gavrilis, D.; Georgoulas, G. Grammatical evolution for features of epileptic oscillations in clinical intracranial electroencephalograms. Expert Syst. Appl. 2011, 38, 9991–9999. [Google Scholar] [CrossRef] [PubMed] [Green Version]
- Tsoulos, I.G. QFC: A Parallel Software Tool for Feature Construction, Based on grammatical evolution. Algorithms 2022, 15, 295. [Google Scholar] [CrossRef]
- Bishop, C. Neural Networks for Pattern Recognition; Oxford University Press: Oxford, UK, 1995. [Google Scholar]
- Cybenko, G. Approximation by superpositions of a sigmoidal function. Math. Control. Signals Syst. 1989, 2, 303–314. [Google Scholar] [CrossRef]
- Goldberg, D. Genetic Algorithms in Search, Optimization and Machine Learning; Addison-Wesley Publishing Company: Reading, MA, USA, 1989. [Google Scholar]
- Michaelewicz, Z. Genetic Algorithms + Data Structures = Evolution Programs; Springer: Berlin, Germany, 1996. [Google Scholar]
- Ghosh, S.C.; Sinha, B.P.; Das, N. Channel assignment using genetic algorithm based on geometric symmetry. IEEE Trans. Veh. Technol. 2003, 52, 860–875. [Google Scholar] [CrossRef]
- Liu, Y.; Zhou, D. An Improved Genetic Algorithm with Initial Population Strategy for Symmetric TSP. Math. Probl. Eng. 2015, 2015, 212794. [Google Scholar]
- Han, S.; Barcaro, G.; Fortunelli, A.; Lysgaard, S.; Vegge, T.; Hansen, H.A. Unfolding the structural stability of nanoalloys via symmetry-constrained genetic algorithm and neural network potential. npj Comput. Mater. 2022, 8, 121. [Google Scholar] [CrossRef]
- Krippendorf, S.; Syvaeri, M. Detecting symmetries with neural networks. Mach. Learn. Sci. Technol. 2020, 2, 015010. [Google Scholar] [CrossRef]
- Qiao, Z.; Welborn, M.; Anandkumar, A.; Manby, F.R.; Miller, T.F., III. OrbNet: Deep learning for quantum chemistry using symmetry-adapted atomic-orbital features. J. Chem. Phys. 2020, 153, 124111. [Google Scholar] [CrossRef]
- Xi, B.; Tse, K.F.; Kok, T.F.; Chan, H.M.; Chan, H.M.; Chan, M.K.; Chan, H.Y.; Wong, K.Y.C.; Yuen, S.H.R.; Zhu, J. Machine-Learning-Assisted Acceleration on High-Symmetry Materials Search: Space Group Predictions from Band Structures. J. Phys. Chem. C 2022, 126, 12264–12273. [Google Scholar] [CrossRef]
- Selvaratnam, B.; Koodali, R.T.; Miró, P. Application of Symmetry Functions to Large Chemical Spaces Using a Convolutional Neural Network. J. Chem. Inf. Model. 2020, 60, 1928–1935. [Google Scholar] [CrossRef] [PubMed]
- Wang, Z.; Wang, C.; Zhao, S.; Du, S.; Xu, Y.; Gu, B.L.; Duan, W. Symmetry-adapted graph neural networks for constructing molecular dynamics force fields. Sci. China Phys. Mech. Astron. 2021, 64, 117211. [Google Scholar] [CrossRef]
- Tuan, N.H.; Mohammadi, H.; Rezapour, S. A mathematical model for COVID-19 transmission by using the Caputo fractional derivative. Chaos Solitons Fractals 2020, 140, 110107. [Google Scholar] [CrossRef] [PubMed]
- Panwar, V.S.; Uduman, P.S.; Gómez-Aguilar, J.F. Mathematical modeling of coronavirus disease COVID-19 dynamics using CF and ABC non-singular fractional derivatives. Chaos Solitons Fractals 2021, 145, 110757. [Google Scholar] [CrossRef]
- Shaikh, A.S.; Shaikh, I.N.; Nisar, K.S. A mathematical model of COVID-19 using fractional derivative: Outbreak in India with dynamics of transmission and control. Adv. Differ. Equ. 2020, 373. [Google Scholar] [CrossRef] [PubMed]
- Huzaifa, E.; Khan, A.; Shah, M.; Khan, M. Taylor Series Expansion Method To Compute Approximate Solution for Nonlinear Dynamical System. J. Fract. Calc. Nonlinear Syst. 2022, 3, 20–29. [Google Scholar] [CrossRef]
- Park, J.; Sandberg, I.W. Universal Approximation Using Radial-Basis-Function Networks. Neural Comput. 1991, 3, 246–257. [Google Scholar] [CrossRef] [PubMed]
- Backus, J.W. The Syntax and Semantics of the Proposed International Algebraic Language of the Zurich ACM-GAMM Conference. In Proceedings of the International Conference on Information Processing, UNESCO, Paris, France, 15–20 June 1959; pp. 125–132. [Google Scholar]
- Ryan, C.; Collins, J.; O’Neill, M. grammatical evolution: Evolving programs for an arbitrary language. In Genetic Programming. EuroGP 1998; Lecture Notes in Computer Science; Banzhaf, W., Poli, R., Schoenauer, M., Fogarty, T.C., Eds.; Springer: Berlin/Heidelberg, Germany, 1998; Volume 1391. [Google Scholar]
- O’Neill, M.; Ryan, M.C. Evolving Multi-line Compilable C Programs. In Genetic Programming. EuroGP 1999; Lecture Notes in Computer Science; Poli, R., Nordin, P., Langdon, W.B., Fogarty, T.C., Eds.; Springer: Berlin/Heidelberg, Germany, 1999; Volume 1598. [Google Scholar]
- Ryan, C.; O’Neill, M.; Collins, J.J. Grammatical evolution: Solving trigonometric identities. In Proceedings of the Mendel, 4th International Mendel Conference on Genetic Algorithms, Optimization Problems, Fuzzy Logic, Neural Networks, Rough Sets, Brno, Czech Republic, 24–26 June 1998. [Google Scholar]
- Puente, A.O.; Alfonso, R.S.; Moreno, M.A. Automatic composition of music by means of grammatical evolution. In Proceedings of the 2002 Conference on APL: Array Processing Languages: Lore, Problems, and Applications (APL ′02), Madrid, Spain, 22–25 July 2002; pp. 148–155. [Google Scholar]
- De Campos, L.M.L.; de Oliveira, R.C.L.; Roisenberg, M. Optimization of neural networks through grammatical evolution and a genetic algorithm. Expert Syst. Appl. 2016, 56, 368–384. [Google Scholar] [CrossRef]
- Soltanian, K.; Ebnenasir, A.; Afsharchi, M. Modular grammatical evolution for the Generation of Artificial Neural Networks. Evol. Comput. 2022, 30, 291–327. [Google Scholar] [CrossRef]
- Dempsey, I.; O’ Neill, M.; Brabazon, A. Constant creation in grammatical evolution. Int. J. Innov. Appl. 2007, 1, 23–38. [Google Scholar] [CrossRef]
- Galván-López, E.; Swafford, J.M.; O’Neill, M.; Brabazon, A. Evolving a Ms. PacMan Controller Using grammatical evolution. In Applications of Evolutionary Computation. EvoApplications 2010; Lecture Notes in Computer Science; Springer: Berlin/Heidelberg, Germany, 2010; Volume 6024. [Google Scholar]
- Shaker, N.; Nicolau, M.; Yannakakis, G.N.; Togelius, J.; O’Neill, M. Evolving levels for Super Mario Bros using grammatical evolution. In Proceedings of the 2012 IEEE Conference on Computational Intelligence and Games (CIG), Granada, Spain, 11–14 September 2012; pp. 304–331. [Google Scholar]
- Martínez-Rodríguez, D.; Colmenar, J.M.; Hidalgo, J.I.; Villanueva Micó, R.J.; Salcedo-Sanz, S. Particle swarm grammatical evolution for energy demand estimation. Energy Sci. Eng. 2020, 8, 1068–1079. [Google Scholar] [CrossRef]
- Sabar, N.R.; Ayob, M.; Kendall, G.; Qu, R. Grammatical Evolution Hyper-Heuristic for Combinatorial Optimization Problems. IEEE Trans Evol. Comput. 2013, 17, 840–861. [Google Scholar] [CrossRef] [Green Version]
- Ryan, C.; Kshirsagar, M.G.; Vaidya, G.; Cunningham, A.; Sivaraman, R. Design of a cryptographically secure pseudo random number generator with grammatical evolution. Sci. Rep. 2022, 12, 8602. [Google Scholar] [CrossRef] [PubMed]
- Tsoulos, I.G.; Gavrilis, D.; Glavas, E. Neural network construction and training using grammatical evolution. Neurocomputing 2008, 72, 269–277. [Google Scholar] [CrossRef]
- Haupt, R.L. An introduction to genetic algorithms for electromagnetics. Antennas Propag. Mag. 1995, 37, 7–15. [Google Scholar] [CrossRef] [Green Version]
- Grefenstette, J.J.; Gopal, R.; Rosmaita, B.J.; Van Gucht, D. Genetic Algorithms for the Traveling Salesman Problem. In Proceedings of the 1st International Conference on Genetic Algorithms, Pittsburgh, PA, USA, 24–26 July 1985; pp. 160–168. [Google Scholar]
- Savic, D.A.; Walters, G.A. Genetic Algorithms for Least-Cost Design of Water Distribution Networks. J. Water Resources Plan. Manag. 1997, 123, 67–77. [Google Scholar] [CrossRef]
- Leung, F.H.F.; Lam, H.K.; Ling, S.H.; Tam, P.K.S. Tuning of the structure and parameters of a neural network using an improved genetic algorithm. IEEE Trans. Neural Netw. 2003, 14, 79–88. [Google Scholar] [CrossRef] [PubMed] [Green Version]
- Sedki, A.; Ouazar, D.; El Mazoudi, E. Evolving neural network using real coded genetic algorithm for daily rainfall–runoff forecasting. Expert Syst. Appl. 2009, 36, 4523–4527. [Google Scholar] [CrossRef]
- Majdi, A.; Beiki, M. Evolving neural network using a genetic algorithm for predicting the deformation modulus of rock masses. Int. J. Rock Mech. Min. Sci. 2010, 47, 246–253. [Google Scholar] [CrossRef]
- Kaelo, P.; Ali, M.M. Integrated crossover rules in real coded genetic algorithms. Eur. J. Oper. 2007, 176, 60–76. [Google Scholar] [CrossRef]
- Kingma, D.P.; Ba, J.L. ADAM: A method for stochastic optimization. In Proceedings of the 3rd International Conference on Learning Representations (ICLR 2015), San Diego, CA, USA, 7–9 May 2015; pp. 1–15. [Google Scholar]
- Kennedy, J.; Eberhart, R.C. The particle swarm: Social adaptation in information processing systems. In New Ideas in Optimization; Corne, D., Dorigo, M., Glover, F., Eds.; McGraw-Hill: Cambridge, UK, 1999; pp. 11–32. [Google Scholar]
- Marini, F.; Walczak, B. Particle swarm optimization (PSO). A tutorial. Chemom. Intell. Lab. Syst. 2015, 149, 153–165. [Google Scholar] [CrossRef]
- Powell, M.J.D. A Tolerant Algorithm for Linearly Constrained Optimization Calculations. Math. Program. 1989, 45, 547–566. [Google Scholar] [CrossRef]
String | Chromosome | Operation |
---|---|---|
<expr> | 9,8,6,4,16,10,17,23,8,14 | |
(<expr><op><expr>) | 8,6,4,16,10,17,23,8,14 | |
(<terminal><op><expr>) | 6,4,16,10,17,23,8,14 | |
(<xlist><op><expr>) | 4,16,10,17,23,8,14 | |
(x2<op><expr>) | 16,10,17,23,8,14 | |
(x2+<expr>) | 10,17,23,8,14 | |
(x2+<func>(<expr>)) | 17,23,8,14 | |
(x2+cos(<expr>)) | 23,8,14 | |
(x2+cos(<terminal>)) | 8,14 | |
(x2+cos(<xlist>)) | 14 | |
(x2+cos(x3)) |
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations. |
© 2022 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Tsoulos, I.G.; Tzallas, A.T.; Tsalikakis, D. Prediction of COVID-19 Cases Using Constructed Features by Grammatical Evolution. Symmetry 2022, 14, 2149. https://doi.org/10.3390/sym14102149
Tsoulos IG, Tzallas AT, Tsalikakis D. Prediction of COVID-19 Cases Using Constructed Features by Grammatical Evolution. Symmetry. 2022; 14(10):2149. https://doi.org/10.3390/sym14102149
Chicago/Turabian StyleTsoulos, Ioannis G., Alexandros T. Tzallas, and Dimitrios Tsalikakis. 2022. "Prediction of COVID-19 Cases Using Constructed Features by Grammatical Evolution" Symmetry 14, no. 10: 2149. https://doi.org/10.3390/sym14102149
APA StyleTsoulos, I. G., Tzallas, A. T., & Tsalikakis, D. (2022). Prediction of COVID-19 Cases Using Constructed Features by Grammatical Evolution. Symmetry, 14(10), 2149. https://doi.org/10.3390/sym14102149