Abstract
Machine learning algorithms are sensitive to hyperparameters, and hyperparameter optimization techniques are often computationally expensive, especially for complex deep neural networks. In this paper, we use Q-learning algorithm to search for good hyperparameter configurations for neural networks, where the learning agent searches for the optimal hyperparameter configuration by continuously updating the Q-table to optimize hyperparameter tuning strategy. We modify the initial states and termination conditions of Q-learning to improve search efficiency. The experimental results on hyperparameter optimization of a convolutional neural network and a bidirectional long short-term memory network show that our method has higher search efficiency compared with tree of Parzen estimators, random search and genetic algorithm and can find out the optimal or near-optimal hyperparameter configuration of neural network models with minimum number of trials.
Similar content being viewed by others
Data availability
All accompanying data are provided in the manuscript.
References
Krizhevsky, A., Sutskever, I., Hinton, G.E.: Imagenet classification with deep convolutional neural networks. In: NIPS (2012)
Reddy, A.H., Kolli, K., Kiran, Y.L.: Deep cross feature adaptive network for facial emotion classification. SIViP 16(2), 369–376 (2022)
Redmon, J., Divvala, S., Girshick, R., et al.: You only look once: Unified, real-time object detection. In: CVPR (2016)
Hutter, F., Kotthoff, L., Vanschoren, J.: Automated Machine Learning: Methods, Systems, Challenges. Springer Nature, Berlin (2019)
Abreu, S.: Automated architecture design for deep neural networks. arXiv preprint arXiv:1908.10714. (2019)
Luo, G.: A review of automatic selection methods for machine learning algorithms and hyper-parameter values. Netw. Model. Anal. Health Inform. Bioinform. 5(1), 1–16 (2016)
Kohavi, R., John, G.H.: Automatic parameter selection by minimizing estimated error. In: Kohavi, R., John, G.H.: Machine Learning Proceedings 1995, pp. 304–312. Elsevier (1995)
Bergstra, J., Bengio, Y.: Random search for hyper-parameter optimization. J. Mach. Learn. Res. 13(2) (2012)
Hinz, T., Navarro-Guerrero, N., Magg, S., et al.: Speeding up the hyperparameter optimization of deep convolutional neural networks. Int. J. Comput. Intell. Appl. 17(02), 1850008 (2018)
Klein, A., Falkner, S., Bartels, S., et al.: Fast Bayesian optimization of machine learning hyperparameters on large datasets. In: AISTATS (2017)
Swersky, K., Snoek, J., Adams, R.P.: Multi-task bayesian optimization. In: NIPS (2013)
Bergstra, J., Bardenet, R., Bengio, Y., et al.: Algorithms for hyper-parameter optimization. In: NIPS (2011)
Hutter, F., Hoos, H.H., Leyton-Brown, K.: Sequential model-based optimization for general algorithm configuration. In: LION (2011)
Xie, L., Yuille, A.: Genetic cnn. In: ICCV (2017)
Miikkulainen, R., Liang, J., Meyerson, E., et al.: Evolving deep neural networks. In: Miikkulainen, R., Liang, J., Meyerson, E., et al. (eds) Artificial Intelligence in the Age of Neural Networks and Brain Computing, pp. 293–312. Elsevier (2019)
Xiao, X., Yan, M., Basodi, S., et al.: Efficient hyperparameter optimization in deep learning using a variable length genetic algorithm. arXiv preprint arXiv:2006.12703 (2020)
Lorenzo, P.R., Nalepa, J., Kawulok, M., et al.: Particle swarm optimization for hyper-parameter selection in deep neural networks. In: GECCO (2017)
Guo, Y., Li, J.-Y., Zhan, Z.-H.: Efficient hyperparameter optimization for convolution neural networks in deep learning: A distributed particle swarm optimization approach. Cybern. Syst. 52(1), 36–57 (2020)
Li, L., Jamieson, K., DeSalvo, G., et al.: Hyperband: A novel bandit-based approach to hyperparameter optimization. J. Mach. Learn. Res. 18(1), 6765–6816 (2017)
Falkner, S., Klein, A., Hutter, F.: BOHB: Robust and efficient hyperparameter optimization at scale. In: ICML (2018)
Awad, N., Mallik, N., Hutter, F.: DEHB: Evolutionary Hyperband for Scalable, Robust and Efficient Hyperparameter Optimization. arXiv preprint arXiv:2105.09821 (2021)
Misra, U., Liaw, R., Dunlap, L., et al. RubberBand: cloud-based hyperparameter tuning. In: Proceedings of the Sixteenth European Conference on Computer Systems (2021)
Zoph, B., Le, Q.V.: Neural architecture search with reinforcement learning. arXiv preprint arXiv:1611.01578. (2016)
Baker, B., Gupta, O., Naik, N., et al.: Designing neural network architectures using reinforcement learning. arXiv preprint arXiv:1611.02167. (2016)
Zhong, Z., Yan, J., Wu, W., et al.: Practical block-wise neural network architecture generation. In: CVPR (2018)
Dong, X., Shen, J., Wang, W., et al.: Dynamical hyperparameter optimization via deep reinforcement learning in tracking. IEEE Trans. Pattern Anal. Mach. Intell. 43(5), 1515–1529 (2019)
Wu, J., Chen, S., Liu, X.: Efficient hyperparameter optimization through model-based reinforcement learning. Neurocomputing 409, 381–393 (2020)
Jomaa, H.S., Grabocka, J., Schmidt-Thieme, L.: Hyp-rl: Hyperparameter optimization by reinforcement learning. arXiv preprint arXiv:1906.11527 (2019)
Chen, S., Wu, J., Liu, X.: EMORL: Effective multi-objective reinforcement learning method for hyperparameter optimization. Eng. Appl. Artif. Intell. 104, 104315 (2021)
Liu, X., Wu, J., Chen, S.: A context-based meta-reinforcement learning approach to efficient hyperparameter optimization. Neurocomputing 478, 89–103 (2022)
Howard, R.A.: Dynamic programming and markov processes (1960)
LeCun, Y., Boser, B., Denker, J.S., et al.: Backpropagation applied to handwritten zip code recognition. Neural Comput. 1(4), 541–551 (1989)
Krizhevsky, A., Hinton, G.: Learning multiple layers of features from tiny images (2009)
Graves, A., Schmidhuber, J.: Framewise phoneme classification with bidirectional LSTM and other neural network architectures. Neural Netw. 18(5–6), 602–610 (2005)
Hochreiter, S., Schmidhuber, J.: Long short-term memory. Neural Comput. 9(8), 1735–1780 (1997)
Sutton, R.S., Barto, A.G.: Reinforcement Learning: An Introduction. MIT Press, Cambridge (2018)
Funding
Received no external funding.
Author information
Authors and Affiliations
Contributions
Conceptualization was contributed by X.Q. and B.X.; Methodology and experiments were contributed by X.Q.; Formal analysis were contributed by X.Q. and B.X.; Writing of the original draft was contributed by X.Q.; Review and editing were contributed by B.X.; This work was completed under the supervision of B.X.
Corresponding author
Ethics declarations
Competing interests
The authors declare no competing interests.
Ethics approval and consent to participate
Not applicable.
Consent for publication
Not applicable.
Additional information
Publisher's Note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Rights and permissions
Springer Nature or its licensor holds exclusive rights to this article under a publishing agreement with the author(s) or other rightsholder(s); author self-archiving of the accepted manuscript version of this article is solely governed by the terms of such publishing agreement and applicable law.
About this article
Cite this article
Qi, X., Xu, B. Hyperparameter optimization of neural networks based on Q-learning. SIViP 17, 1669–1676 (2023). https://doi.org/10.1007/s11760-022-02377-y
Received:
Revised:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s11760-022-02377-y