## 3 Proposed Methodology
### CatBoost Hurdle Model  
The standard hurdle model, employed in crash frequency analysis, traditionally features a binary component that determines crash occurrence and a subsequent count data component to assess crash frequency. Conventional models that rely on traditional statistical models often struggle to capture the complex and non-linear interactions present in crash data. CatBoost is an advanced machine learning algorithm that excels in both classification and regression tasks, making it adept at not only discerning the likelihood of crash occurrences through its binary classification capabilities but also predicting the frequency of crashes more accurately with its regression prowess [30]. CatBoost overcomes the limitations of parametric models by efficiently processing categorical features and capturing non-linear relationships, without the need to rely on rigid assumptions (as often required with traditional statistical models). Its capacity for direct optimization of loss functions enables a more nuanced adaptation to the data, enhancing the model's ability to capture the underlying patterns. CatBoost is a sophisticated variant of Gradient Boosting Trees (GBT), which is an advanced machine learning approach that is suitable for both regression and classification tasks, leveraging an ensemble of decision trees. The concept revolves around sequentially correcting the prediction errors of an aggregation of simple models, typically decision trees, using a gradient descent optimization approach. In a decision tree, which forms the base learner in GBT, each internal node represents a test on an attribute, branches denote the outcome of the test, and leaf nodes correspond to output values. In regression scenarios, these outputs are continuous values, often the average of the target values of the instances within that leaf. For classification, leaf nodes represent class labels, usually determined by the majority class among instances in that region. The GBT model is built iteratively, with each tree constructed to correct the errors made by the ensemble of previously built trees. This process is guided by the gradient of a loss function, which quantifies the difference between the observed and predicted values. In each iteration of the GBT algorithm, the negative gradient of this loss function is computed for each instance. These gradients serve as the target values for training the subsequent tree in the ensemble. CatBoost further refines this model, particularly excelling in handling categorical data and complex datasets. It employs an ordered boosting technique to reduce the risk of overfitting, a common challenge in standard boosting methods. In this technique, for each tree, CatBoost uses a random permutation of the dataset, training each tree on a different subset of data defined by the permutation. This method ensures that the tree's training is influenced only by the part of the data that precedes each point in the permutation, making it effective for both regression and classification. Moreover, CatBoost introduces an innovative approach to process categorical features. It converts categorical variables into numerical values during training, using a target-based statistic. This transformation is mathematically represented as follows:  
\[\hat{x}_{\sigma(j),p}=\frac{\sum_{i=1}^{p-1}\left[x_{\sigma(i)}=x_{\sigma(p)} \right]y_{\sigma(j)}+qH}{\sum_{i=1}^{p-1}\left[x_{\sigma(i)}=x_{\sigma(p)} \right]+q}\text{j},\text{p}=1,2,3,\ldots,\text{n} \tag{5}\]  
where \(\hat{x}_{\sigma(j),p}\) is the numerical representation of the \(i^{\text{th}}\) feature in permutation \(p\); \(\left[x_{\sigma(j)}=x_{\sigma(p)}\right]\) is the Iverson bracket that serves as an indicator function, with output 1 in case \(x_{\sigma(j)}=x_{\sigma(p)}\), and 0 otherwise; \(y_{\sigma(j)}\) is the target variable; \(H\) is the a priori distribution term; and \(q\) is the weight coefficient of the a priori distribution term.