This section describes the deep learning algorithm used for predicting the sand fineness modulus (FM) in this study. A pre-trained CNN model for determining sand (FM) is the primary focus of this study.
3.1 Proposed System
The study's suggested system has two components: one for training and one for assessment. Each portion is divided into five fundamental processes, discussed below: picture capture, image preprocessing, feature extraction, feed to CNN models, and image prediction. The pictures should be separated into training sets and testing sets. The majority of the photos were used for training, while the remaining 30% were used for testing. A diagram of our proposed system can be found in Fig. 1.
3.1.1 Image Acquisition
This study primarily used sand images obtained from the Civil Engineering Lab at Barisal Engineering College in Barisal Division, Bangladesh. Some of these images of sand were taken from the internet. The images of the sand in this article were taken using a Samsung smartphone. To classify the sand images, we have broken them down into seven groups: FM-1 = 0.57, FM-2 = 0.61, FM-3 = 1.74, FM-4 = 2.61, FM-5 = 2.07, FM-6 = 1.57, and FM-7 = 3.02. There are 100 photos in each class in this sand dataset. As a result, the early sand dataset has 7×100 = 700 photos.
Table 1
Sand FM Quality | Range of Fineness Modulus | No. sand samples |
FM-1 | 0.57 | 100 |
FM-2 | 0.61 | 100 |
FM-3 | 1.74 | 100 |
FM-4 | 2.61 | 100 |
FM-5 | 2.07 | 100 |
FM-6 | 1.57 | 100 |
FM-7 | 3.02 | 100 |
Total sand samples | 700 |
3.1.2 Image pre-processing
In this stage, we prepared the sand image data for categorization. We have collected a large number of sand photos from various locations with varying resolutions and levels of noise. Because the initially acquired image may contain varying noise levels and sizes, picture preprocessing is required. The CNN models, however, require input photos that measure 224 by 224 by 3. We suggested CNN models automatically resize and transform RGB (red, green, and blue) images into grayscale before receiving input from the network. Figures 3, 4, and 5 show the original RGB image, the preprocessed 224-224-3 image, and the grayscale image.
3.1.3 Automatic Features Extraction
A crucial step in the categorization of images is the automatic extraction of features from the images. As a result of the CNN model, crucial details from the input photos can be collected. To categorize pictures, CNN uses these signals[11]. The automated feature extraction was shown in Fig. 6 to illustrate the process.
3.1.4 Residual Network (ResNet-50)
A pre-trained residual network also has 50 layers. It can categorize photos into 1000 different item categories, including animals, crops, and fruits. This network needs an image input of 224x224 pixels. Pre-trained deep networks can extract highly detailed information from input images. After 49 convolutional layers, this ResNet 50 model has a fully connected layer[12]. To conserve computational resources and training time, ResNet-50 was selected.
3.1.5 CNN Setting
An artificial neural network (ANN) is a convolutional neural network (CNN). Each layer learns to extract certain visual features directly. Many key properties are learned directly from training and testing photographs, avoiding manual feature extraction. Training images are subjected to a variety of resolution filters, and the output of each convolutional layer is used as input. Filters can start with simple features, such as brightness and edge detection, and move to item-specific features. Input, convolution, pooling, fully connected, and output layers are common components of the CNN algorithm [14], and they show the outcome when the image characteristics reach the fully connected layer.
3.1.6 Sand FM Determination
Using sand images of varying types, CNN algorithms are learned after automatic feature extraction is complete. When the training is complete, we test a single sand picture from the testing dataset. Pre-trained models are used to forecast sand fineness modulus (FM) varietals. In light of this, we evaluated our pre-trained model using standard evaluation techniques, including group interpretation (3.1.7).
3.1.7 Evaluation
To evaluate the performance of our suggested model, we compared the accuracy, precision, sensitivity, specificity, and F-score. To assess the quality of training models, test data is used. Here is a mathematical equation describing the five quality rating indicators.
Accuracy
We evaluated the model's accuracy using an accuracy metric. We used ten iterations to gauge the model's accuracy. It displays the proportion of correctly identified samples calculated by the accuracy metric. As a result,
\({A}{c}{c}{u}{r}{a}{c}{y}=\frac{\mathbf{T}\mathbf{P}+\mathbf{T}\mathbf{N}}{\mathbf{T}\mathbf{P}+\mathbf{T}\mathbf{N}+\mathbf{F}\mathbf{P}+\mathbf{F}\mathbf{N}}\) (Eq. 1)
TP stands for "true positive cases," TN for "true negative cases," FP stands for "false positive cases," meaning "the number of instances correctly classified," and FN stands for "false negative cases," meaning "the number of instances incorrectly classified."
Precision
It is the ratio of accurately predicted true positives to total positives. The model's correctness is also described. As a result,
\({P}{r}{e}{c}{i}{s}{i}{o}{n}=\frac{{T}{P}}{{T}{P}+{F}{P}}\) (Eq. 2)
Sensitivity
The ability to determine the number of positive instances is generally accurate. The model is also described as perfect. As a result,
\({S}{e}{n}{s}{i}{t}{i}{v}{i}{t}{y}{o}{r}{R}{e}{c}{a}{l}{l}=\frac{{T}{P}}{{T}{P}+{F}{N}}\) (Eq. 3)
Specificity
There is a general misclassification of the ability to determine the number of negative instances. In addition, it describes the model's effectiveness. Based on statistics
\(\mathbf{S}\mathbf{p}\mathbf{e}\mathbf{c}\mathbf{i}\mathbf{f}\mathbf{i}\mathbf{c}\mathbf{i}\mathbf{t}\mathbf{y}=\frac{{T}{N}}{{T}{N}+{F}{P}}\) (Eq. 4)
F-Score
The F-score is a measure of the harmonic mean of precision and recall. Based on statistics,
\({F}-{S}{c}{o}{r}{e}=\frac{2{*}\left({r}{e}{c}{a}{l}{l}{*}{p}{r}{e}{c}{i}{s}{i}{o}{n}\right)}{{r}{e}{c}{a}{l}{l}+{p}{r}{e}{c}{i}{s}{i}{o}{n}}\) (Eq. 5)