1 Introduction

The risk of heavy damage or failure of buildings during a seismic event is a significant concern for communities, as the affected area is generally large. For this reason, determining the earthquake risk of structures has become an essential issue among structural engineers (FEMA356). Most losses from earthquakes are associated with the local or total collapse of buildings. In this context, continuous assessment and monitoring of buildings’ seismic safety and vulnerability are challenging, especially when extensive area assessments are required. In addition, examining structural cracks or determining the wall type in a masonry building damaged due to earthquake events is a very dangerous task for site engineers. For this reason, it has become possible to determine the seismic risk of buildings by observations that can be made from outside the building. But, the construction industry is one of the slowest professions to adapt to new technologies, and this situation needs to change. In this study, a contemporary method was proposed to accurately predict the seismic performance of buildings with the help of machine learning algorithms eliminating the need for any technical personnel to enter the building.

The methodologies designed to determine the seismic risk of individual buildings are well matured. However, they necessitate the use of complex analysis tools along with detailed inputs like material testing, plan drawings, quality of material, etc. (FEMA2456, Eurocode 6, TEC2018, GABHR 2019; Dejong 2009; Aldemir et al. 2013; Penna et al. 2014; Beyer et al. 2014; Penna 2015 and Ahmad and Ali 2017). These detailed seismic assessment techniques become dysfunctional if the number of concerned buildings reaches thousands or more. This is mainly because the inputs and procedures take significant time, manpower of experienced engineers, and computational power. Therefore, these methods could not be employed when the seismic risk of the large building stock is aimed to be determined. Consequently, the current state-of-the-art on detailed seismic assessment of structures is limited by human and infrastructure resources. Therefore, Sozen (2014) stated that the seismic risk assessment of building inventories could only be accomplished by changing the strategy from seeking safety to filtering out vulnerable buildings from the large building stock (i.e., low-pass filtering). Thus, a versatile and accurate method should be formulated to enable decisions to be made using inexpensively acquired building data and the evaluation process to be implemented quickly (Sozen 2014).

Although several researchers have tried to generate simple methods to assess the seismic risk of reinforced concrete (RC) structures (Yakut 2004; Yucemen and Ozcebe 2004; Askan and Yucemen 2010; Maziliguney et al. 2012; Al-Nimry et al. 2015; Perrone et al. 2015; Kumar et al. 2017; FEMA P154; Coskun et al. 2020; Harirchian et al. 2020a; b); the literature shows a limited number of efforts to propose rapid screening (or filtering) methods applicable to unreinforced masonry (URM) building stocks (GABHR 2019; D’Ayala 2013; Shah et al. 2016; Achs and Adam 2012; Grünthal 1998; Achs 2011; Rajarathnam and Santhakumar 2015; Aldemir et al. 2020). D’Ayala (2013) attempted to correlate damage states with fragility curves to determine the seismic vulnerability of masonry structures. However, this method requires the fragility curve for the location of the building, which reduces the applicability of this process, as fragility curves are scarce in number. Shah et al. (2016) used a building classification with respect to the masonry material used, the state of the building, construction quality, building shape irregularity, and the level of earthquake-resistant design. They used the European Macroseismic Scale (Grünthal 1998) and applied defined vulnerability classes (A–F) to determine the risk level of masonry structures. However, the outcome of this method still lacked correlation with actual performance. In another approach, Achs and Adams (2012) proposed a rapid visual screening method that used penalty scores for structural parameters, including seismic hazard, regularity in the plan, regularity in elevation, horizontal stiffness, local failure, secondary structures, soil condition, foundation, and state of preservation. The penalty scores were derived from comprehensive preliminary in situ inspections and measurements of Viennese brick masonry buildings (Achs 2011). Rajarathnam and Santhakumar (2015) used aerial photographs on a geographic information system (GIS) platform to accelerate rapid visual screening. However, none of these methods is based on a large database of masonry structures with detailed seismic assessment results. In other words, all previous methods lack a correlation between rapid screening scores and detailed analysis results. Aldemir et al. (2020) proposed a new rapid visual screening method applicable to masonry structures. They aimed to increase the accuracy of the seismic risk estimation by correlating the rapid visual screening scores with the detailed seismic risk analysis results. To this end, they generated a linear relationship between the risk and the considered parameters. They concluded that this approach resulted in a promising method with some accuracy problems in predicting the test database. The complex relationships between the seismic risk estimations and the selected parameters could be resolved by implementing machine learning algorithms. Similarly, researchers have recently given some effort to incorporate the machine learning algorithms 1- to find a better relationship between the observed damage and seismic events (Mangalathu et al. 2020 and Zhang et al. 2018); 2- to propose methods to predict the fragility curves (Kiani et al. 2019; Ruggieri et al. 2021); 3- to estimate the seismic risk (Zhang et al. 2019; Harirchian et al. 2020a; b). However, none of these studies proposed a versatile seismic risk filtering method for masonry structures incorporating machine learning algorithms. In addition, some recent studies tried to propose contemporary strategies to efficiently evaluate the seismic performance of structures (Javidan and Kim 2022a; b).

Several studies in the literature have succeeded in creating damage maps using unmanned aerial vehicles for post-earthquake damage assessment (Wang et al. 2021; Cooner et al. 2016; Li et al. 2018; Xu et al. 2019; Xu et al. 2018; Sublime and Kalinicheva 2019; Kerle et al. 2020; Stepinac et al. 2020; etc.). These studies have also evolved into studies that include post-earthquake permanent displacement estimations in order to derive new algorithms to accelerate data processing time (Li et al. 2011) and to classify post-earthquake damages (Wang et al. 2020). Finally, studies are carried out to determine the physical properties of buildings and their structural deficiencies, such as soft floors, using unmanned aerial vehicle photographs (Yu et al. 2020). However, none of these studies was designed to be applied before disasters in order to facilitate pre-hazard applications (i.e., to increase preparedness). In addition, machine learning methods have been developed for the estimation of structural systems using photographic data. Geiß et al. (2015) showed in their research that structural systems (masonry, confined masonry, reinforced concrete frame, steel frame, etc.) could be predicted with a high success rate by machine learning methods. In their methods, random forest and support vector machine algorithms are used.

Therefore, this study focused on developing a simple, rapid visual screening method to predict the damage level of masonry buildings using machine learning algorithms. The parameters required for the procedure were aimed to be collectible without the need for the entrance of technical personnel into the risky building. The parameters that could be determined externally are specified as follows:

• Number of Stories (NS)

• Floor system type (FT)

• Visual damage (VD)

• Wall material type (WT)

• Typical story height (TY)

• Vertical irregularity (VI)

• Typical plan area (TA)

• Earthquake zone (EZ)

It should be stated that the age of the structure is not included as an independent parameter in this proposed network. However, the selected parameters managed to correlate the existing physical and mechanical properties with the risk state. Although the age of the building is an important parameter, the visual damage parameter has a significant correlation with the age of the building. Therefore, the proposed network has high accuracy in estimating the risk state. In other words, this study aimed to develop a calculation network based on the properties of any structures from external observations. This network was trained with the known detailed seismic risk analysis results. To this end, machine learning algorithms were trained with a large stock of buildings whose seismic risk analysis results were available (i.e., 543 different real buildings with seismic risk assessment analyses). Then, the seismic risk analysis estimation performance of this algorithm was tested with untrained buildings (i.e., 109 different real buildings with seismic risk assessment analyses). The formed machine learning algorithm estimates the risk and damage level of the analyzed structure during a possible earthquake event.

2 Definition of the URM building database

The database used within the scope of this study was obtained from the Risky Buildings Department of the Ministry of Environment and Urbanization. The earthquake risk analyses of the buildings in the database were determined by the detailed seismic risk analysis calculation method included in the provisions of the Urban Transformation Law No. 6306 (GABHR 2012) or Turkish Earthquake Code (TEC 2007). In this context, the plan drawings, material strengths, etc., of all buildings were available, along with all the physical properties. Therefore, the necessary technical analysis has been done on these structures to train machine learning algorithms. The selected parameters are presented in Table 1. Before using this raw database, data engineering was performed to filter out unnecessary or misleading information by deleting null values, categorizing the selected parameters, etc. In addition, the distribution of parameters is given in Fig. 1. It is known that masonry structures are commonly constructed to have less than four stories in Turkey. However, in some regions of Turkey, the seismicity is low, promoting the use of masonry structures up to 8 stories. In addition, the number of these exceptional cases is low. Thus, the selected database is intentionally formed to have a limited number of masonry buildings with more than four stories (only %25 of the entire database).

Table 1 Selected Parameters and their definitions
Fig. 1
figure 1

Frequency of data set

The detailed seismic assessment analysis of buildings was performed as per GABHR (2012). In the numerical models, all piers were simulated using 2-node 3-D frame elements, whereas all slabs were modeled with 4-node thin shell elements. In the numerical models, the modulus of elasticity was calculated using the expression (i.e., 200 fm) given in GABHR (2012). In each story, a rigid diaphragm was defined, provided that a reinforced concrete slab existed. After that, a response spectrum analysis was performed under the effect of a reduced design spectrum (i.e., R = 2). The analysis was performed for two orthogonal directions separately. During the response spectrum analysis, 95% of mass participation was satisfied in each orthogonal direction. In the detailed seismic assessment analysis, the performance limits for slab elements were not calculated. The performance of each pier was determined as Minimum Damage (MD) provided that the pier had enough capacity to resist the reduced design spectrum and gravity demands. On the contrary, the performance of each pier was classified as Collapse Damage (CD) if the pier did not have enough capacity to resist the reduced design spectrum and gravity demands. The capacity of each pier was estimated by considering all the failure modes given in TEC (2018) (i.e., diagonal tension and base sliding). Also, the axial load demands were compared with the axial load capacities of each pier. In these calculations, a correction was made depending on the slenderness ratio. The correction factor was taken as 1 for slenderness ratios less than 6, 0.8 for slenderness ratios between 6 and 10, 0.7 for slenderness ratios between 10 and 15, and 0.5 for slenderness ratios greater than 15. If the pier was found to have less axial load capacity than the demand, it would be classified as Collapse Damage (CD). The performance of each masonry building was claimed to be satisfying the life safety performance level provided that less than 50% of the total base shear at the first story is resisted by masonry piers with a Collapse Damage (CD) performance level.

3 Correlation of parameters with detailed seismic assessment analysis results

Detailed seismic assessment analysis of buildings is critical in determining the behavior of the building during seismic events. For this reason, detailed seismic assessment analysis is generally required for the safety check of all buildings over 20 years old and located in close proximity to earthquake zones. On the contrary, rapid screening methods should be used in countries where the filtering of risky buildings is aimed to be performed to take action about retrofitting operations. Therefore, this filtering operation is vital as structures at risk of collapse should be strengthened immediately, or new earthquake-resistant structures should be built instead of these structures. However, current rapid screening methods in the literature have a minimal correlation with the detailed assessment analysis results as none of the methods was calibrated with the detailed analysis results. Thus, it is difficult to depend on the risk estimations of the rapid screening methods while taking actions at the seismic risk mitigation level. Consequently, in this study, it was aimed to form a network to correlate the seismic risk with the properties of buildings. For this reason, it was important to determine the most influential variables to be used in the detection of risky or non-risky structures in correlation with the seismic risk results from the detailed analysis. This operation could yield to dissociate the unnecessary parameters from the network and reduce the bias. The correlation of the variables in the available data set with the class (i.e., the risk state from the detailed analysis, RS) is shown below (Table 2 and Fig. 2). In addition, the relationships between parameters, i.e., visual damage, vertical irregularity, number of stories and typical plan area, and the detailed seismic assessment analysis results are shown in Fig. 3. In Fig. 3, it is apparent that the risk state probability has a robust correlation with the increasing values of story number, vertical irregularity, and visual damage. In addition, total floor area has some limited correlation with the risk state determined from detailed analysis.

Table 2 Correlation of variables with the risk state
Fig. 2
figure 2

Correlation relationship of parameters

Fig. 3
figure 3

Relationships between a visual damage, b vertical irregularity, c number of stories, and d typical plan area and the detailed seismic assessment analysis results

In Table 2, the correlation coefficients were calculated using “grouping and mean value determination processes” proposed by McKinney (2011). Grouping and mean value determination processes are used to group the subject data according to some identifiers, to examine the effect of input parameters on the output, to combine these data, or to transform data. This process is called learning through groups (McKinney 2011). In this method, only one independent variable is selected in each case (i.e., vertical irregularities), and the dependent variable is always the state of risk (i.e., 0 or 1). Then, the correlation coefficient for each subcategory in each independent variable is calculated by dividing the number of risky structures with subcategory i to the total number of risky structures. In Table 2, values above 0.5 contribute to the risk of the building, while values below 0.5 contribute to the non-risk of the building. For example, if there is vertical irregularity (VI = 1), the RS value will increase to 0.899, indicating that the building contributes to its risky nature. If there is no vertical irregularity (VI = 0), the RS value will decrease by 0.678, contributing less to the building’s risk. Since vertical irregularity in structures is an undesirable situation as it adversely affects load transfer, this obtained result could be claimed to be reasonable. When the heat map is examined (Fig. 2), the parameters with the highest correlation that affect the detailed seismic assessment analysis result are vertical irregularity (VI), visual damage (VD), and the number of floors (NF). The correlation of these parameters is also technically rational. Because the likelihood that the structure becomes risky for seismic disturbances will increase if the structure is damaged. Likewise, as the number of floors increases, the horizontal drift demands of the building will increase inherently, which increases the seismic risk. Besides, the presence of structural cracks and vertical irregularities in the structure (i.e., VD = 1, VI = 1) causes the risk state (RS) to converge to 1. In contrast, the absence of structural damages (VD = 0, VI = 0) causes the RS to converge to 0.

In order to further investigate the selected parameters from different perspectives, another graph representing the relation between buildings with vertical irregularities and visual damage is plotted (Fig. 4a). From Fig. 4a, it could be inferred that vertical irregularity (VI = 1) is observed more in risky and structurally undamaged structures (i.e., RS = 1 and VD = 0) than in non-risky and structurally undamaged structures (RS = 0 and VD = 0). This leads to the conclusion that vertical irregularity and visual damage correlate well with each other. Figure 4b shows the distributions of the risk states of buildings, the number of stories, and visual damage parameters and their interrelationships. The structures with no structural damage and no risk (i.e., VD = 0 and RS = 0) in the data set are usually one story. Therefore, it is understood that the probability of single-story masonry buildings being non-risky is high, and this situation may change toward risky as the number of floors increases. Higher lateral displacement in high-rise buildings may be the reason for this situation.

Fig. 4
figure 4

Relationship between a visual damage—vertical irregularities and b number of stories—visual damage and the detailed seismic analysis results

4 Machine learning algorithms

Machine learning (ML) is concerned with the ability of data-driven models to learn information about a system from directly observed data without predetermining the mechanical relationships. ML algorithms can adaptively improve their performance with each new data sample, update their differentiable weights according to the new data and discover relationships in complex heterogeneous and high-dimensional data (Shaikhina et al. 2019). In this study, instead of sticking to a single method, it was preferred to use multiple machine learning methods (i.e., ensemble learning) in order to achieve the highest success percentage. As part of ensemble learning, different supervised machine learning algorithms were utilized since supervised machine learning algorithms rely on labeled input data to learn a function that produces an appropriate output when given new unlabeled data (Fig. 5a). Logistic regression (Peng et al. 2002); decision tree classifier (Kotsiantis et al. 2007); random forest classifier (Shaikhina et al. 2019); support vector machine (SVM) classifier (Widodo and Yang 2007); and K-neighbors classifier (Imandoust and Bolandraftar 2013) are used to predict building damage levels. To this end, the dataset was divided into training and test datasets first. Then, the statistical measures, like the correlation of parameters, are determined along with the feature engineering operations, i.e., categorical variable definitions. Then, the ensemble learning algorithms were codified to perform the necessary learning operations. Finally, the performance of the ML network on the estimation of the risk state was checked with the test database (Fig. 5b).

Fig. 5
figure 5

a Supervised learning example and b Flowchart of the method used in this study

5 Performance metrics

The seismic risk distribution of a large building stock was aimed to be accurately estimated using the aforementioned machine learning algorithms. In all networks, the risk state from the machine learning algorithm was taken as risky (non-risky) if the risk score became 1 (0). In this part, the performances of the used algorithms will be evaluated not only by the success percentage but also by the metrics like true positives (TP), true negatives (TN), false positives (FP), and false negatives (FN). These metrics were transformed into precision, recall, and the combined measure (i.e., Fmeasure) given in Eqs. (13) (Saito and Rehmsmeier 2015).

$${\text{Precision}}\; = \;\frac{TP}{{TP + FP}}$$
(1)
$${\text{Recall}}\; = \frac{TP}{{TP + FN}}$$
(2)
$$F_{{{\text{measure}}}} \; = \;\frac{{2\;\Pr {\text{ecision}}\; \times {\text{Re}} {\text{call}}}}{{\Pr {\text{esicion}}\; + \;{\text{Re}} {\text{call}}}}$$
(3)

The utilized data set consisted of 543 buildings and was analyzed using multiple machine learning algorithms. All the calculations were made in the Jupyter environment (i.e., formally known as IPython). Initially, the dataset was divided into 434 trains and 49 tests with the “Train Test Split” function from the “Sklearn model selection” library. Next, another dataset with additional 60 buildings excluded from the initial stage was formed for the second test stage. In other words, the total training dataset (i.e., the training dataset plus validation dataset) was equal to 483 buildings, whereas the test dataset comprised 60 buildings. In addition, K-fold cross-validation was applied at the validation stage, which prevents the trained data set from being overfitted by the algorithm. As explained before, logistic regression, decision tree classifier, random forest classifier, support vector machine (SVM) classifier, and K-neighbors classifier were all used in this study. The accuracy of each method is presented in Table 3. In addition, the confusion matrices are summarized in Table 4.

Table 3 Correlation of variables with the risk state
Table 4 Confusion matrices of each algorithm

It should be noted that it is essential to choose the correct hyperparameters of the logistic regression to increase the percentage of accuracy. There were many hyperparameters for each model, so an excellent way to identify the best set of hyperparameters was to try different combinations and compare the results. The penalty value of l2 is chosen because l2 provides a better prediction when the output variable is a function of all input properties. The coefficient value, on the other hand, was chosen as one of the values providing the highest percentage of success in the graph in Fig. 6a. In the decision tree algorithm, there are many parameters that affect the success percentage. Of these, one of the values “maximum depth”, providing the highest percentage of success, was selected from Fig. 6b. In the random forest algorithm, there are many parameters that affect the success percentage. Of these, “minimum samples split” was chosen as one of the values that provide the high success percentage in the graph in Fig. 6c. It should be noted that this algorithm has many parameters that affect the results. While applying the KNN algorithm in this study, the “number of data points: k” parameter is one of the most important parameters in increasing the success percentage. Therefore, it was clear from Fig. 6d that the worst neighbor values for the dataset were k < 2, 3 < k < 4, and k > 13. In this case, these values should be avoided in choosing the k value. It has been observed that all values do not change the percentage of success in the penalty parameter selection of the Support Vector Machine Classifier algorithm (Fig. 6e). In this study, the optimum values required to increase the success percentage of each algorithm were determined by the grid search method.

Fig. 6
figure 6

Effect of algorithm parameters: a LR, b DTC, c RFC, d KNN and e SVMC

Finally, the number of possible outcomes of the variable RS that lead to the most accurate estimations was investigated. To this end, the Euclidian distances were plotted against the data points (i.e., dendrogram). The least number of possible outcomes could be determined by counting the least number of intersecting points with any possible horizontal lines drawn on the dendrogram. For the risk state variable, this number equaled two (Fig. 7). Therefore, this cross-check also verified the validity of the selected possible outcomes of the RS variable (i.e., risky or non-risky). In other words, the formed machine learning network could only distinguish between the risky and non-risky buildings. It could not classify the buildings according to their possible damage rates like minor damage, moderate damage, or collapse.

Fig. 7
figure 7

Dendrogram representing the least number of outcomes for the variable RS

In Ensemble Learning, voting is one of the simplest ways of combining the predictions from multiple machine learning algorithms. In this study, a single machine learning algorithm was not used to estimate the seismic analysis result. By using more than one machine learning algorithm, the majority of their predictions are based on votes. For this method, “hard” or “soft” voting can be done. Here, the algorithms give the seismic analysis result with two options: 1–0 (hard) or percentage ratio estimates (soft). In the proposed methodology, it was decided to use hard voting for the data set. Components of the ensemble learning, performance results, and schematic representations are shown in Figs. 8 and 9. In addition, the success rate of this machine learning algorithm is shown in Table 5. In Fig. 9, the mean accuracy is obtained by taking the mean accuracy across k-folds for each algorithm.

Fig. 8
figure 8

Comparison of scores algorithms

Fig. 9
figure 9

Mean accuracy results of each algorithm

Table 5 Confusion matrix of ensemble learning

6 Performance of the proposed method with damage observations after dinar EQ and elazig-kovancilar EQ in Turkey

In this part, the risk status estimations of the buildings whose actual damages after real earthquakes in Turkey were compared. For this purpose, the Dinar earthquake (ML = 6.1) and the Elazig-Kovancilar earthquake (Mw = 6.1) were utilized. During the Dinar EQ, it was reported that 2,043 buildings were completely destroyed, and approximately 4,500 buildings were severely damaged (EERI 1995). It was also reported that 2,549 buildings collapsed, and approximately 50 buildings were severely damaged (Akkar et al. 2011). The pseudo-spectral accelerations in the constant acceleration region for the Dinar EQ and the Elazig-Kovancilar EQ were reported as 0.90 g and 0.82 g, respectively. To test the prediction performance of the machine learning algorithms proposed in this study, 13 buildings (5 buildings from the Elazig-Kovancilar EQ and eight buildings from the Dinar EQ) were used. Details on risk estimates are presented in Tables 6,7. From Tables 6,7, it could be concluded that the seismic risk status of 11 out of 13 buildings was correctly estimated by the proposed method. In summary, the machine learning algorithm gave correct results by estimating six undamaged structures as non-risky and five damaged structures as risky. But, it failed to classify two damaged structures as non-risky (i.e., Building 1 in Table 6 and Building 3 in Table 8). With these results, the proposed ML algorithms correctly estimated the damage status of 13 buildings and achieved 84.6% accuracy.

Table 6 Comparison of Risk Estimations of the proposed method with the actual damage observations from Elazig-Kovancilar EQ
Table 7 Comparison of risk estimations of the proposed method with the actual damage observations from Dinar EQ: Set 2
Table 8 Comparison of Risk Estimations of the proposed method with the actual damage observations from Dinar EQ: Set 1

7 Discussion of results

Rapid screening methods in the literature classify the earthquake risk of large building stocks by penalizing the existence of some physical deficiencies of structures. The decision is made depending on these penalty scores, which have no intended or calculated correlation to detailed seismic risk analysis. Therefore, in this proposed approach, new insight was brought to the rapid screening method. To this end, a large database is utilized to correlate the seismic risk analysis results to the rapid screening scores. Therefore, unlike the literature-available rapid screening methods, the proposed method is useful for generating a risk distribution map of large building stocks having a significant correlation with the detailed seismic risk analysis results. Consequently, the proposed machine learning network could be employed while generating seismic risk mitigation systems. The confidence in the proposed machine learning network is enhanced by examining the performance of the proposed network with both post-earthquake reconnaissance and numerical seismic analysis results.

The performance of the proposed network is improved by implementing ensemble learning depending on the hard voting scheme. This manipulation significantly enhanced both the estimation success rate of the training and test database. In addition, the risk state estimation after EQs is aimed to be accurately predicted by the proposed method. To this end, the proposed network’s performance was investigated by comparing its risk state estimations with damage states of buildings after real earthquakes. Thirteen buildings damaged during the Dinar EQ (ML = 6.1) and the Elazig-Kovancilar EQ (Mw = 6.1) were utilized. The risk estimation performance of the proposed network was found to be as large as 84.6%. This observation also increased the confidence in the proposed network.

In Table 5, it is apparent that the false-negative ratio of the proposed model is 3.33%, whereas false-positive ratio is 0% for the test database. However, the observation for the real EQ application of the proposed method is different. The model estimated two damaged structures as non-risky, which could be a drawback in the practical application of this model. Therefore, the false-positive ratio of the proposed model should be improved in order to have a more dependable model.

8 Conclusion

It is essential to determine the most vulnerable buildings and take precautions before major earthquakes hit in order to eliminate the loss of lives. However, the available detailed procedures require too much human power and resources to be possibly applied in large stocks of buildings. In addition, current rapid visual screening methods used to estimate the risk state of large building stocks do not result in reliable and accurate filtering. Therefore, in this study, it was aimed to bring a new perspective to the building seismic risk filtration. To this end, a calculation network based on the properties of any structures from external observations was collected. This network was trained with the known detailed seismic risk analysis results. Then, the seismic risk analysis estimation performance of this algorithm was tested with untrained buildings.

In this study, instead of depending on the estimation of a single method, it was preferred to use ensemble learning in order to achieve the highest success rate. As part of ensemble learning, different supervised machine learning algorithms were utilized. Logistic regression, decision tree classifier, random forest classifier, support vector machine classifier, and K-neighbors classifier are used to predict building damage levels. Then, hard voting was utilized as the outcome of the proposed method was designed to be composed of risky and non-risky buildings (i.e., 1–0). The successful percentage estimations of the proposed ensemble learning for the training and test database were 96.7% and 95.9%, respectively.

The proposed network’s performance was also investigated by comparing real EQ damages. In summary, the proposed ML algorithm gave correct results by classifying six undamaged structures as non-risky and five damaged structures as risky. However, the method failed to estimate the risk state of two damaged structures by defining them as non-risky (i.e., Building 1 in Table 6 and Building 3 in Table 8). Therefore, the proposed ML algorithm achieved 84.6% accuracy. This methodology could serve better, provided that mobile applications or web-based software are designed to enable data entry in the field.