In the ANN models, the available database is generally divided into three subsets: training, validation and testing sets. In this study, 70 % of the 246 samples (172 randomly selected data) for training, 15 % of the total data (37 randomly selected data) for validation and also 15 % of the database (37 randomly selected data) for testing were used to predict the compressibility parameters.

In order to evaluate the performance of the proposed ANN model, the correlation coefficient (R) and mean squared error (MSE) were used as statistical measures for comparison of the measured and predicted values. The correlation coefficient (R) and mean squared error (MSE) are given in Eqs. (3)–(4).

$$R = \frac{{\mathop \sum \nolimits_{i = 1}^{n} \left( {C_{i,m} - \overline{{C_{i,m} }} } \right)\left( {C_{i,p} - \overline{{C_{i,p} }} } \right)}}{{\sqrt {\mathop \sum \nolimits_{i = 1}^{n} \left( {C_{i,m} - \overline{{C_{i,m} }} } \right)^{2} \times \mathop \sum \nolimits_{i = 1}^{n} \left( {C_{i,p} - \overline{{C_{i,p} }} } \right)^{2} } }}$$

(3)

$$MSE = \frac{{\mathop \sum \nolimits_{i = 1}^{n} \left( {C_{i,m} - C_{i,p} } \right)^{2} }}{n}$$

(4)

where *C*
_{
i,m
} and *C*
_{
i,p
} are the measured and predicted output values; \(\overline{C_{i,m}}\) and \(\overline{C_{i,p}}\) are the averages of the measured and predicted output values, respectively. n is the number of sample.

The multilayer perceptron neural networks consist of three layers: input layer, hidden layer and output layer. Four basic soil parameters such as natural water content, liquid limit, plasticity index and initial void ratio were used as input parameters for the ANN model. The output layer consists of two neurons which are compression index and recompression index. In this model, ANN model using one hidden layer was preferred. A series of trial-and-error with different number of neuron between 8 and 40 were tried to find the optimum number of neurons in the hidden layer. At the end of these processes, MSE values for different number of neurons were obtained for the training and testing sets as shown in Fig. 4. The optimal architecture of the ANN model was determined based on the minimum mean square error and maximum correlation coefficient. The best performance was obtained from the ANN model with 20 neurons in the hidden layer. Therefore, the 20 neurons in the hidden layer can be considered as optimum value for the ANN model.

The feed-forward with back-propagation algorithm which is the most preferred algorithm (Rumelhart et al. 1986) in neural networks was used during the training stage. Standard Levenberg–Marquardt training function used as a learning algorithm in the developed ANN model. Additionally, a number of multilayer networks with different transfer functions for hidden and output layers were tried to predict the compressibility parameters. The most appropriate results for the network model were obtained from the sigmoid transfer function in the hidden layer and the linear transfer function in the output layer. The selected architecture of the ANN model used to predict the recompression and compression indexes of soil is shown in Fig. 5.

An error histogram can be examined for obtaining contrary data points at the ANN performance. Error histogram indicates that significant errors made on which estimated data and thus a neural network model in higher accuracy designing by purging incorrect data. Figure 6 shows that the error histogram of the obtained simulation results while there were 20 neurons in the hidden layer. The blue bars, the green bars and the red bars represent the training data, the validation data and the test data respectively at the error histogram. Considering the error histogram, the majority of the errors between the measured value and the predicted value are seen on between −0.04 and 0.04. The predicted and measured compression index and recompression index values for both training and test data have been shown in Fig. 7. It is seen that there are minor errors in the compression index data while the majority errors are in the recompression index data considering the differences between the measured and predicted values in the training and testing data.

Figure 8 shows the relationship between measured and predicted values obtained through the training and testing process. The calculated coefficients of determination (R^{2}) for the compression index are 0.8926 and 0.8973 for training and testing stage, respectively. These results show that a quite close relationship between the measured values and the predicted values by ANN model. However, the coefficients of determination (R^{2}) for the recompression index were calculated as 0.6071 and 0.3600 for training and testing, respectively. It is seen that the proposed ANN model obtained well correlation for the compression index compared with the recompression index.