Abstract This study proposes a novel bio-inspired meta-heuristic algorithm, the Python Snake Optimization Algorithm (PySOA), that mimics the hunting behavior of the python snake. These reptiles are not poisonous, but they hunt their prey through ambushes. They can detect their prey using senses such as smell, eyesight, and infrared vision. The hunting mechanism consists of three major phases: searching for prey, scanning for prey, and attacking the prey. The searching-for-prey step contributes to exploration, while attacking prey is dedicated to exploitation, and scanning for attack enhances the balance between the two. The mathematical model of the method improves convergence precision and global search capability by capturing the behavioral dynamics of Pythons. PySOA’s performance was assessed on 23 classical benchmark functions, 29 CEC-2017 benchmark functions, 10 CEC-2019 composite functions, and three real-world engineering problems. The outcomes were confirmed by 14 popular meta-heuristic algorithms (MAs). With an average improvement of 39.2%, the PySOA outperformed the compared algorithms across all 62 test functions, achieving the best mean fitness rank in 43% of test cases. By successfully balancing exploration and exploitation, these findings demonstrate that PySOA is both resilient and competitive in addressing unimodal and multimodal optimization problems. The composite CEC-2019 test fitness functions demonstrated PySOA’s ability to explore and exploit simultaneously. The outcomes of the CEC-2017 benchmark tests show that PySOA has a shortcoming in local search exploration. Based on PySOA’s performance on real-world engineering problems, it is a practical algorithm for achieving optimal results and can be applied to real-world problems. The source code of the PySOA is publicly available at https://www.mathworks.com/matlabcentral/fileexchange/175654-a-novel-bio-inspired-python-snake-optimization-algorithm .
Diab et al. (Mon,) studied this question.