Predicting extreme waves can foresee the hydrodynamic environment of marine engineering, critical for avoiding disaster risks. Till now, there are barely any available models that can rapidly and accurately predict the occurrence probability of freak waves in a given state. This paper develops a trained model based on the Back Propagation (BP) neural network, with wave parameters of unidirectional sea state fed into the model, such as significant wave height, wave period, spectral type, and the intermodal distance of the peak frequencies. A rapid and accurate model optimized for predicting the occurrence probability of freak waves in a unidirectional sea state, from unimodal to bimodal configuration, is achieved by iterating to reduce accumulation errors. Compared to the regression and least-squares boosting trees, the optimized model performs much better in accurately predicting the occurrence probability of freak waves. Irrespective of whether in unimodal or bimodal sea state, this optimized model is competitive in calculation accuracy compared to theoretical models such as Rayleigh prediction and MER prediction, improved by at least 41%. The established model based on the BP neural network can quickly predict the threshold of freak waves in a given sea state, guiding practical engineering applications.