Minerals 12 00455 v2
Minerals 12 00455 v2
Article
Deep-Learning-Based Automatic Mineral Grain Segmentation
and Recognition
Ghazanfar Latif 1, *, Kévin Bouchard 1 , Julien Maitre 1 , Arnaud Back 2 and Léo Paul Bédard 2
1 Department of Computer Sciences and Mathematics, Université du Québec à Chicoutimi, 555 Boulevard de
l’Université, Chicoutimi, QC G7H 2B1, Canada; [email protected] (K.B.);
[email protected] (J.M.)
2 LabMaTer, Sciences de la Terre, Université du Québec à Chicoutimi, 555 Boulevard de l’Université,
Chicoutimi, QC G7H 2B1, Canada; [email protected] (A.B.); [email protected] (L.P.B.)
* Correspondence: [email protected]
2. Literature Review
Currently, there are mainly two distinct methods for grain recognition: traditional
engineering devices [23,24] and computational methods [25].
composition of the mineral. SEM output includes the chemical composition with grain size,
shape, and proportion. Grain counting can be performed using an electron microprobe [32];
however, this method is time consuming [33].
In [34], the authors presented an image processing workflow for characterizing pore-
and grain-size distributions in porous geological samples using SEM images and X-ray
microcomputed tomography (µCT). Their samples included the Buff Berea, Berea, Nugget,
Bentheimer, and Castlegate sandstones and the carbonate Indiana Limestone. The produced
2D distribution from the SEM appeared biased toward smaller sizes. In [35], the authors
developed a grain count technique using a laser particle counter sensor (Wenglor) to count
stainless-steel beads and sand grains of different size classes. They compared the count
with that obtained using high-speed cameras. They found that the Wenglor can count grain
sizes between 210 ± 3 µm and 495 ± 10 µm and that only grains passing through the center
of the beam were counted. In [36], the authors used a less expensive light microscope
able to produce images of grain shape profiles sufficient in quality for identification and
counting. Their key finding was that roundness, sphericity, circularity, ModRatio, and
aspect ratio were the key shape parameters for differentiating grains.
Minerals2022,
Minerals 2022,12,
12,455
x FOR PEER REVIEW 4 of 184 of 18
3.1. Data
3.1. Data SetSet
Acquisition
Acquisition
3.1. Data Set Acquisition
We We collected
collected 1010kgkgofof tilltill
grains
grainsfrom
from the field,
the and
field, and sediments
sediments wereweresieved
sieved toto
less
lessthan
than
We collected 10 kg of till grains from the field, and sediments were sieved to less than
1 1mm.
1 mm.
mm. TheThesamples
samples were
were then
then processed
processed with
with a fluidized
a fluidized bedbedto
The samples were then processed with a fluidized bed to obtain a superconcentrate obtain
to obtain a superconcentrate
a superconcentrate
ofheavy
ofof heavy
heavymineralsminerals(approximately
minerals (approximately
(approximately 100
100
100 mg)
mg)
mg) containing
containing
containing approximately
approximately
approximately 2 2million
2 million million grains
grains
grains
smaller
smaller
smaller than
than
than 505050 µm.
µµm.m. TheThe
The superconcentrate
superconcentrate
superconcentrate was
was
was sprinkled
sprinkled
sprinkled onto
onto
onto carbon
carbon
carbon tape
tape tape
to to to provide
provide
provide a a a
black
black backdrop
backdrop forfor the
the images.
images. Images
Images were
were then
then obtained
obtained
black backdrop for the images. Images were then obtained using a camera mounted onto using
using a a camera
camera mounted
mounted onto
onto a
a abinocular microscope,
microscope, and
and wewe created
created a photomosaic.
a photomosaic.
binocular microscope, and we created a photomosaic. To acquire the groundtruthed ToToacquire
acquire the groundtruthed
the groundtruthed data,
i.e., i.e.,
data,
data, mineral
i.e.,mineralgrain
mineral identities,
grain
grain identities,
identities, we we
acquired
we acquired
acquired a backscattered
aabackscattered
backscattered imageimage
image ofofthe
of grains
thethe using
grains
grains SEM
using
using
SEMwith
SEMwith X-ray
withX-rayfluorescence
X-ray fluorescence [42]. The
fluorescence [42]. The groundtruthed
The groundtruthed data
groundtrutheddata were the
datawere mineral
werethe the map
mineral
mineral and
map referenced
map andand
with the RGB
referenced
referenced withmosaic.
with the RGBThe
the RGB end result,
mosaic.
mosaic. The end
The after
end using
result,
result, theusing
after
after motorized
usingthe conventional
themotorized
motorized microscope
conventional
conventional
and 6-megapixel
microscope
microscope and camera, was
and6-megapixel
6-megapixel an approximate
camera,
camera, was
was an 2 GB mosaic
anapproximate
approximate image
2 2GBGBmosaic (34,674
mosaic image × (34,674
image 33,720
(34,674pixels)
× ×
to bepixels)
33,720
33,720 used
pixels) asto
tothe data
usedset
beused
be for data
as the
as the machine-learning
data set
set for
forthe algorithm.algorithm.
themachine-learning
machine-learning We acquired
algorithm. WeWe 238
acquiredfields of
acquired
238view
238 fieldswith
fields aview
ofof 10%
viewoverlap
with aa 10%
with between adjacent
overlap
overlap fields
between
between in the images.
adjacent
adjacent fieldsinFigure
fields inthethe 2images.
images.shows the
Figure
Figuresample
2 2
of the
shows grains
the sampleand the
of corresponding,
the grains and the annotated
corresponding,
shows the sample of the grains and the corresponding, annotated SEM image. SEM image.
annotated SEM image.
(a) (b)
(a) (b)
Figure 2. Sample segment of the original (a) and SEM-based groundtruth image (b).
Figure 2. 2.
Figure Sample segment
Sample of of
segment thethe
original (a)(a)
original and SEM-based
and groundtruth
SEM-based image
groundtruth (b).
image (b).
Minerals 2022, 12, x FOR PEER REVIEW 5 of 18
Minerals 2022, 12, 455 5 of 18
(a) (b)
Figure 3. Cont.
Minerals 2022, 12, x FOR PEER REVIEW 6 of 18
Minerals 2022, 12, 455 6 of 18
(c) (d)
Figure
Figure 3. Outcome
3. Outcome of of
thethe preprocessing
preprocessing steps.
steps. Images
Images show
show thethe original
original SEMSEM images
images (a),(a),
thethe outliers
outliers
removed using the morphological and contours-based method from the binary converted image (b),(b),
removed using the morphological and contours-based method from the binary converted image
thethe
preprocessed
preprocessed outcome
outcome SEM
SEMimage
imageafter removing
after removingoutliers
outliers(c),(c),
and thethe
and preprocessed
preprocessed outcome
outcomeof of
thethe
original
originalimage after
image removing
after removingoutliers
outliers(d).
(d).Wrong
Wrongformat.
format.
3.3.
3.3. Grain
Grain Segmentation
Segmentation
We We used
used superpixel
superpixel segmentation
segmentation toto separate
separate mineral
mineral grain
grain data
data (see
(see Algorithm
Algorithm 1).1).
The image was first converted to binary, and morphological operations—erosion
The image was first converted to binary, and morphological operations—erosion and di- and
dilation—were applied to the image to separate the grains from each other.
lation—were applied to the image to separate the grains from each other. To convert the To convert the
image into binary, the image threshold was calculated using Otsu’s
image into binary, the image threshold was calculated using Otsu’s method [43]. Using method [43]. Using
the
the resulting
resulting binary
binary image,
image, wewe calculated
calculated thethe total
total number
number ofof external,
external, closed
closed contours
contours toto
represent the possible grains in the image. Contours are closed curves that
represent the possible grains in the image. Contours are closed curves that are calculated are calculated
using
using thethe edges
edges ofof objects
objects withwith the
the same
same values
values oror pixel
pixel intensities.
intensities. The
The contour
contour count
count CC
then serves as a seed for the superpixel segmentation method rather
then serves as a seed for the superpixel segmentation method rather than using a fixed than using a fixed
number K as a seed. We applied Equation (3) to calculate the superpixel center grid interval
number K as a seed. We applied Equation (3) to calculate the superpixel center grid inter-
of approximately equal-sized superpixels of an input image of size N.
val of approximately equal-sized superpixels of an input image of size N.
r
𝑁N
=√ . .
S𝑆 = (3)(3)
𝐶C
TheThesuperpixel
superpixelsegmentation
segmentationmethodmethodrelies
relieson
onoversegmenting
oversegmentingthe theimage
imagewhile
while sim-
simul-
ultaneously
taneously decreasing
decreasing thethe complexity
complexityof ofthe
theimage
imageprocessing
processingtasks.
tasks.WeWeapplied
applied a simple
a simple
linear iterative
linear clustering
iterative clustering (SLIC)
(SLIC)method
method toto
produce
produce high-quality
high-quality segmentation
segmentation inin
a timely
a timely
manner [44]. The method performs local k-mean clustering of the image
manner [44]. The method performs local k-mean clustering of the image pixels using pixels using color
color
similarity and proximity in the subimages. The method also uses the
similarity and proximity in the subimages. The method also uses the five-dimensional five-dimensional
spaces
spaces provided
provided byby
thethelabxy
labxyimage
image plane,
plane,where
where l, a, and
l, a, andb are
b arethe
thepixel
pixelvector
vectorcolors
colors
provided
provided byby
the
theCIELAB
CIELAB color
colorspace, and
space, thethe
and x and
x and y values
y values are
arethe
thecoordinates
coordinates ofofthe
the
pixels
pixelswhich
whichrepresent
representthe thespatial
spatialdistances.
distances.ToTomerge
merge the
thecolor
colorproximity
proximity andandspatial
spatial
proximity
proximity distances,
distances,wewe normalized
normalized the distances
the distances using
using Equations
Equations (4)(4)
and and(5). ToTo
(5). useusethe
the
labxy space to cluster the pixels, we required the distance measure D,
labxy space to cluster the pixels, we required the distance measure D, which considers which considers
approximately
approximately equal-sized
equal-sized superpixels.
superpixels.
The
The segmentation
segmentation provided
provided the the xyxy coordinates
coordinates of each superpixel.
of each superpixel. TheThe method
method was was
The segmentation
further enhanced by provided the
increasing the xy coordinates
contrast of the of each superpixel.
images to allow the The method wasof
discrimination
further enhanced by increasing the contrast of the images to allow the discrimination of the
further
the enhanced
grain borders.byInincreasing
Maitre the
et[22], contrast
al. [22], of the images to allow the discrimination of
grain borders. In Maitre et al. the the superpixel
superpixel method
method waswas applied
applied usingusing a fixed-
a fixed-size
the grain
size
inputinputborders.
seedseed In
valuevalueMaitre et al.
forsuperpixels.
for the [22],
the superpixels. the superpixel
This This approach
approach method
workedworkedwas applied
well
well for using
forcolor
the the color a fixed-
feature-
feature-based
size input
based
method seed value
method
with withfor the superpixels.
classical
classical This
machine-learning
machine-learning approach
methods; worked
methods;
however, wellmethod
however,
this for themethod
this colornot
did feature-
did
relynot
on
based
rely
deeponmethod
learning.with classical
deep learning.
Thus, Thus,
we machine-learning
we proposed
proposed methods;
to automate
to automate however,
the of this
calculation
the calculation method
of
the seed didvalues
thevalues
seed not
in the
rely
in on segmentation
the deep learning.
segmentation method Thus,
method we proposed
to prepare
to prepare the data to
the
for automate
data the calculation
for deep-learning
deep-learning networks. of the
networks.
The seed valuesof
The compar-
comparisons
inisons
the segmentation
the superpixel method
of the superpixel
boundaries to prepare
boundaries
and the outcome the data
and thefor for
outcomedeep-learning networks.
for the grains
the segmented segmented The
grains
for both compar-
for both
methods are
isons of theare
methods
presented superpixel
in Figures 4 boundaries
presented in Figures
and 4and
andthe
5, respectively. outcome for the segmented grains for both
5, respectively.
methods are presented in Figures 4 and 5, respectively.
(a) (b)
(a) (b)
Figure
Figure 4.
4. Visual
Visual comparison
comparison of
of the
the detected
detected superpixel
superpixel boundaries
boundaries of
of grains
grains using
using the
the method
method of
of
Figure 4.etVisual
Maitre al. (a) comparison
and our of the (b)
approach detected
[22]. superpixel boundaries of grains using the method of
Maitre et al. (a) and our approach (b) [22].
Maitre et al. (a) and our approach (b) [22].
(a) (b)
(a) (b)
Figure 5. Samples of the outcome of the segmented grains using the method of Maitre et al. [22] (a)
Figure 5. 5.
Figure
and our Samples of(b).
Samples
approach thethe
of outcome of of
outcome thethe
segmented grains
segmented using
grains thethe
using method of of
method Maitre et et
Maitre al.al.
[22] (a)(a)
[22]
and our
and approach
our approach(b).
(b).
Minerals 2022, 12, 455 8 of 18
Class Label Primary Grain Type Secondary Grain Type Number of Grains
Albite None
Quartz None
Quartz Albite
C1 6879 images
Albite Quartz
Albite Any class > 256 pixels
Quartz Any class > 256 pixels
Augite None
Tschermakite Any class > 256 pixels
C2 Tschermakite Augite 3295 images
Augite Tschermakite
Augite Any class > 256 pixels
Magnetite Any class > 256 pixels
C3 3823 images
Magnetite None
Hypersthene Any class > 256 pixels
C4 988 images
Hypersthene None
C5 Background - 6106 images
The final data set consisted of 21,091 images divided into five classes. Albite grain
and quartz grain images were merged into one class because they are visually similar,
Hypersthene
Hypersthene Any
Any class
class >> 256
256 pixels
pixels
C4
C4 Hypersthene Any class > 256 pixels 988
988 images
images
C4 Hypersthene
Hypersthene None
None 988 images
C5 Hypersthene
Background -None 6106
C5 Background - 6106 images
images
Minerals 2022, 12, 455 C5 Background - 6106 images 9 of 18
The
The final
final data
data set
set consisted
consisted of of 21,091
21,091 images
images divided
divided intointo five
five classes.
classes. Albite
Albite grain
grain
and The final data set consisted of 21,091 images divided into five classes. Albite grain
and quartz
quartz grain
grain images
images were were merged
merged intointo one
one class
class because
because theythey areare visually
visually similar,
similar,
and quartz grain
rock-forming images
minerals. were merged intoofone ofclass because theyquartz
are visually similar,
rock-forming
rock-forming minerals.
minerals. TheThe
The sample
sample
sample images
images
images of albite
albitealbite
grain
graingrain
and and
and quartz
quartz graingrain
grain are are
are shown
shown shown
in
in
rock-forming
in Figure
Figure 6, which minerals.
6, which
clearly The
clearly sample
indicate
indicate images
theirtheir of albite
visual
visual grain
similarity.
similarity. and quartz
Augite
Augite grain
grain
grain and are
and shown in
tschermakite
tschermakite
Figure 6, which clearly indicate their visual similarity. Augite grain and tschermakite
Figure
grain6,images
grain which wereclearlyalsoindicate
merged their
intovisual similarity.
one class, Augite
as aresamples grain and
the samples showntschermakite
in Figure 7,
grain images
images were were also
also merged
merged into
into one
one class,
class, as
as are
are the
the samples shown shown in in Figure
Figure 7, 7, due
due
grain
to due images
their theirwere
tovisual also
visual
similarity. merged
similarity.
The into one class,
The background
background class ascontained
are the
class samples
contained
images shown
images
which in Figure
which
were 7, due
were
either either
en-
to their visual similarity. The background class contained images which were either en-
to entirely
their visual
tirely black similarity.
or contained The background class total
very small grains contained
(the total images
number which were either
of nonblack pixels en-
was
tirely black
black or or contained
contained very very small
small grains
grains (the
(the total number
number of of nonblack
nonblack pixels
pixels was
was less
less
tirely
less
than black
than or
256)contained
or containedvery small
noise grains
in the (the total
background. number
Figure of8nonblack
shows pixels
the samplewas less
images
than 256)
256) oror contained
contained noise
noise inin the
the background.
background. FigureFigure 88 shows
shows thethe sample
sample images
images of of the
the
than
of 256)
background or contained
the background
class. For noise
class.
the in the
For thebackground.
experiments,experiments,
these Figure
five these 8 five
classes’ shows the images
classes’
data set sample images
data set
wereimagesof the
dividedwere
background class. For the experiments, these five classes’ data set images were divided
background
divided
into 20% for class.
into 20%For
training, the
forand experiments,
training,
the remaining these
and the remaining
80% fivedivided
was classes’
80% data
wasagain set
divided
into images
again were
into
80%/20% divided
80%/20%
for valida- for
into 20% for training, and the remaining 80% was divided again into 80%/20% for valida-
validation/training
into 20% for training,
tion/training sets. sets.the remaining 80% was divided again into 80%/20% for valida-
and
tion/training sets.
tion/training sets.
Albite,
Albite, None
None Albite,
Albite, Quartz
Quartz Quartz,
Quartz, Albite
Albite Quartz,
Quartz, None
None
Albite, None Albite, Quartz Quartz, Albite Quartz, None
Figure 6. Sample
Figure images
6. Sample of the
images albite
of the andand
albite quartz mineral
quartz grains.
mineral grains.
Figure 6. Sample images of the albite and quartz mineral grains.
Figure 6. Sample images of the albite and quartz mineral grains.
Augite,
Augite, None
None Augite,
Augite, Tschermakite
Tschermakite Tschermakite,
Tschermakite, Augite
Augite Tschermakite,
Tschermakite, none
none
Augite, None Augite, Tschermakite Tschermakite, Augite Tschermakite, none
Figure 7. Sample images of the augite and tschermakite mineral grains.
Figure 7. Sample
Figure images
7. Sample of the
images augite
of the and
augite tschermakite
and mineral
tschermakite grains.
mineral grains.
Figure 7. Sample images of the augite and tschermakite mineral grains.
Figure 10.
Figure ResNet version
10. ResNet version 22 architecture
architecture for
for mineral
mineral recognition.
recognition.
Note that,ResNet
For both in bothmodels,
ResNetwe 1 and
usedResNet 2, after the initial
experimentation concatenation
to fine-tune of the blocks
the hyperparameters.
in the sequence weights → batch normalization → ReLU, the
The final hyperparameter settings were an activation function (ReLU) learning concatenated sequenced
rate =
block
0.001,isnumber
repeated. The main
of epochs difference
= 50, and batch between
size = the
20. two
These architectures is:
hyperparameters produced the
The sequence
experimental thatdiscussed
results follows the initial weight,
in Section 4. batch normalization, and activation block
differs between the architectures. For ResNet 1, the following sequence is convolutional
block → batch normalization
4. Experimental Results block → activation block, whereas, in ResNet 2, the sequence
is batch normalization block → activation block → convolutional block.
The experimental setup included the use of a high processing computing machine
Postactivation is supported in ResNet 1.
holding 256 GB memory with a graphical processing unit (GPU) Nvidia Tesla-V100 with
Preactivation is supported in ResNet 2.
5120InCUDA
ResNet cores.
1, theWe applied
second ReLU Python 3.8 for the
nonlinearity programming
is added of allF (phases,
after adding X ) to X.including
the preprocessing, classification, and identification. The data set
In ResNet 2, the last ReLU nonlinearity is deleted, thus, allowing output was split so that 80%addi-
of the was
usedoffor
tion training
the residualand the remaining
mapping 20% was
and identity available
mapping to for
be testing. Note,no
passed with however,
changesthat the
to the
80% training portion was actually divided again into an 80% training and 20% validation
split. We tested variable epoch sizes, and the ideal epoch size was chosen to ensure that
the system avoided over- and underfitting. We tested various parameter settings for Res-
Net 1 and ResNet 2 to obtain the optimal results and evaluated their performance against
the better-known deep-learning approaches of LeNet, AlexNet, and GoogleNet.
Minerals 2022, 12, 455 12 of 18
consecutive block. In addition, the gradient value at the output layer is passed back during
backpropagation, as is the input layer, thus, overcoming the vanishing gradient problem
in deep-learning networks that have hundreds or thousands of layers, thereby, improving
their performance and limiting/reducing the associated training errors.
For both ResNet models, we used experimentation to fine-tune the hyperparameters.
The final hyperparameter settings were an activation function (ReLU) learning rate = 0.001,
number of epochs = 50, and batch size = 20. These hyperparameters produced the experi-
mental results discussed in Section 4.
4. Experimental Results
The experimental setup included the use of a high processing computing machine
holding 256 GB memory with a graphical processing unit (GPU) Nvidia Tesla-V100 with
5120 CUDA cores. We applied Python 3.8 for the programming of all phases, including
the preprocessing, classification, and identification. The data set was split so that 80% was
used for training and the remaining 20% was available for testing. Note, however, that the
80% training portion was actually divided again into an 80% training and 20% validation
split. We tested variable epoch sizes, and the ideal epoch size was chosen to ensure that the
system avoided over- and underfitting. We tested various parameter settings for ResNet
1 and ResNet 2 to obtain the optimal results and evaluated their performance against the
better-known deep-learning approaches of LeNet, AlexNet, and GoogleNet.
ResNet 1 and ResNet 2 achieved higher validation accuracies than LeNet, AlexNet,
and GoogleNet (Table 2). The validation accuracy of ResNet 2 was slightly higher than
for ResNet 1. We obtained these scores by applying the segmentation methods presented
in [22]. In the latter paper, they achieved a global accuracy of 89% using a RF classifier;
however, their data were not effective when deep-learning algorithms were applied.
Table 2. Results using minerals segmentation used in [22] with different CNN models.
Training Validation
CNN Model Training Loss Validation Loss
Accuracy (%) Accuracy (%)
LeNet 1.1329 1.5627 66.67 39.29
AlexNet 0.3917 2.8706 88.89 39.88
GoogleNet 0.9911 1.4571 83.33 43.37
ResNet 1 (32) 1.0715 1.3784 72.29 45.61
ResNet 2 (47) 1.0263 1.3269 76.94 49.23
the training time between 29 layers and 47 almost doubled, the increased validation
accuracy justified using the 47 layers for this application.
Table 3. Results using proposed minerals segmentation with different CNN models.
Training Validation
CNN Model Training Loss Validation Loss
Accuracy (%) Accuracy (%)
LeNet 1.063 0.6374 61.60 74.43
AlexNet 0.3425 0.3847 90.00 86.30
GoogleNet 0.7875 0.626 72.40 76.23
ResNet 1 (32) 0.3418 0.3668 90.40 89.80
ResNet 2 (47) 0.3523 0.3621 90.40 90.56
Table 4. Comparison of results using proposed minerals segmentation with different ResNet models
and varying number of layers.
Figure 12.
Figure 12. Training
Training accuracy
accuracycurves
curvesfor
forthe
thevarious
variousResNet
ResNetmodels.
models.
The confusion matrices in Figure 16 show the comparison of each class’s accuracy
for the best proposed model (ResNet version 2 with 47 layers). The left confusion matrix
shows the percentage accuracies for each class, and the right confusion matrix shows
correctly classified grain images for each class. The results in the confusion matrix indicate
that the classes C1 and C5 achieved higher accuracies as they had more grain images for
the training.
Minerals 2022, 12, 455 14 of 18
Figure 12. Training accuracy curves for the various ResNet models.
Figure 12. Training accuracy curves for the various ResNet models.
Figure 13.
Figure 13. Validation
Validation accuracy
accuracycurves
curvesfor
forthe
thevarious
variousResNet models.
ResNet models.
Figure 13. Validation accuracy curves for the various ResNet models.
Figure 14. Training loss curves for the various ResNet models.
Figure 14. Training loss curves for the various ResNet models.
Figure 15.
Figure 15. Validation
Validation loss
losscurves
curvesfor
forvarious
variousResNet
ResNetmodels.
models.
The confusion matrices in Figure 16 show the comparison of each class’s accuracy for
the best proposed model (ResNet version 2 with 47 layers). The left confusion matrix
shows the percentage accuracies for each class, and the right confusion matrix shows cor-
rectly classified grain images for each class. The results in the confusion matrix indicate
that the classes C1 and C5 achieved higher accuracies as they had more grain images for
The confusion matrices in Figure 16 show the comparison of each class’s accuracy for
the best proposed model (ResNet version 2 with 47 layers). The left confusion matrix
shows the percentage accuracies for each class, and the right confusion matrix shows cor-
rectly classified grain images for each class. The results in the confusion matrix indicate
Minerals 2022, 12, 455 that the classes C1 and C5 achieved higher accuracies as they had more grain images 15 offor
18
the training.
Figure16.
Figure 16.Confusion
Confusion matrix
matrix for
forthe
thebest
bestResNet
ResNetversion
version22(47
(47layers)
layers)model.
model.Confusion
Confusionmatrix
matrixofof
percentage accuracies for each class (left) and confusion matrix of correctly classified images (right).
percentage accuracies for each class (left) and confusion matrix of correctly classified images (right).
Whenwe
When wecompared
comparedour ourResNet
ResNet22model
model(47
(47layers)
layers)with
withtechniques
techniquespublished
publishedin
inthe
the
recentliterature—using
recent literature—usingthe thepublished
published method
method onon
ourour grain
grain datadata set—we
set—we observed
observed that that
the
the superpixel-based
superpixel-based grain grain segmentation
segmentation and theand the 2ResNet
ResNet 2 (47
(47 layers) layers)
clearly clearly outper-
outperformed the
existing
formed techniques
the existingand achievedand
techniques theachieved
highest accuracy values
the highest (Tablevalues
accuracy 5). (Table 5).
Table5.5.Comparison
Table Comparisonofofthe
theproposed
proposedmethod
methodwith
withexisting
existingmethods.
methods.
Future work will include developing data sets for the purpose of grain mineral recog-
nition and enhancing new and current methods to achieve a higher recognition rate with
more mineral classes. These advances will include applying various image fusion and
registration techniques to greatly improve the mapping of the original images with the
labeled images. We will also explore other techniques for segmentation that may enhance
accuracy. These may include the region-growing-based method, fuzzy C-means, and
deep-learning segmentation.
Author Contributions: G.L.: Planning, methodology, analysis, experiments, initial draft writing.
K.B.: Supervision, methodology, original draft writing and revision. J.M.: Methodology, review and
editing. A.B.: Data collection. L.P.B.: Funding procurement, supervision, review and editing. All
authors have read and agreed to the published version of the manuscript.
Funding: This research is funded by a Fonds de Recherche du Québec—Nature et Technologies (FRQ-
NT) grant to L.P.B. (Programme de recherche en partenariat sur le développement durable du secteur
minier-II, grant number: 2020-MN-283346) with contributions from IOS Servives Géoscientifiques Inc.
Data Availability Statement: The data presented in this study can be requested from
[email protected].
Acknowledgments: We are thankful to the IOS Servives Géoscientifiques Inc. for providing
technical support.
Conflicts of Interest: The authors declare no conflict of interest.
References
1. Jung, D.; Choi, Y. Systematic Review of Machine Learning Applications in Mining: Exploration, Exploitation, and Reclamation.
Minerals 2021, 11, 148. [CrossRef]
2. Sengupta, S.; Dave, V. Predicting applicable law sections from judicial case reports using legislative text analysis with machine
learning. J. Comput. Soc. Sci. 2021, 1–14. [CrossRef]
3. Zantalis, F.; Koulouras, G.; Karabetsos, S.; Kandris, D. A Review of Machine Learning and IoT in Smart Transportation.
Future Internet 2019, 11, 94. [CrossRef]
4. Latif, G.; Shankar, A.; Alghazo, J.; Kalyanasundaram, V.; Boopathi, C.S.; Jaffar, M.A. I-CARES: Advancing health diagnosis and
medication through IoT. Wirel. Netw. 2019, 26, 2375–2389. [CrossRef]
5. Ali, D.; Frimpong, S. Artificial intelligence, machine learning and process automation: Existing knowledge frontier and way
forward for mining sector. Artif. Intell. Rev. 2020, 53, 6025–6042. [CrossRef]
6. Chow, B.H.Y.; Reyes-Aldasoro, C.C. Automatic Gemstone Classification Using Computer Vision. Minerals 2021, 12, 60. [CrossRef]
7. Girard, R.; Tremblay, J.; Néron, A.; Longuépée, H. Automated Gold Grain Counting. Part 1: Why Counts Matter! Minerals 2021,
11, 337. [CrossRef]
8. Boivin, J.-F.; Bédard, L.P.; Longuépée, H. Counting a pot of gold: A till golden standard (AuGC-1). J. Geochem. Explor. 2021,
229, 106821. [CrossRef]
9. Plouffe, A.; McClenaghan, M.B.; Paulen, R.C.; McMartin, I.; Campbell, J.E.; Spirito, W.A. Processing of glacial sediments for
the recovery of indicator minerals: Protocols used at the Geological Survey of Canada. Geochem. Explor. Environ. Anal. 2013,
13, 303–316. [CrossRef]
10. Xu, C.S.; Hayworth, K.J.; Lu, Z.; Grob, P.; Hassan, A.M.; García-Cerdán, J.G.; Niyogi, K.K.; Nogales, E.; Weinberg, R.J.; Hess, H.F.
Enhanced FIB-SEM systems for large-volume 3D imaging. eLife 2017, 6, e25916. [CrossRef]
11. Nie, J.; Peng, W. Automated SEM–EDS heavy mineral analysis reveals no provenance shift between glacial loess and interglacial
paleosol on the Chinese Loess Plateau. Aeolian Res. 2014, 13, 71–75. [CrossRef]
12. Akcil, A.; Koldas, S. Acid Mine Drainage (AMD): Causes, treatment and case studies. J. Clean. Prod. 2006, 14, 1139–1145.
[CrossRef]
13. Hudson-Edwards, K.A. Sources, mineralogy, chemistry and fate ofheavy metal-bearing particles in mining-affected river systems.
Miner. Mag. 2003, 67, 205–217. [CrossRef]
14. Hobbs, D.W. 4 Structural Effects and Implications and Repair. In Alkali-Silica Reaction in Concrete; Thomas Telford Publishing:
London, UK, 1988; pp. 73–87. [CrossRef]
15. Lawrence, P.; Cyr, M.; Ringot, E. Mineral admixtures in mortars effect of type, amount and fineness of fine constituents on
compressive strength. Cem. Concr. Res. 2005, 35, 1092–1105. [CrossRef]
16. Erlich, E.I.; Hausel, W.D. Diamond Deposits: Origin, Exploration, and History of Discovery; SME: Littleton, CO, USA, 2003.
17. Towie, N.J.; Seet, L.H. Diamond laboratory techniques. J. Geochem. Explor. 1995, 53, 205–212. [CrossRef]
Minerals 2022, 12, 455 17 of 18
18. Chen, Z.; Liu, X.; Yang, J.; Little, E.C.; Zhou, Y. Deep learning-based method for SEM image segmentation in mineral character-
ization, an example from Duvernay Shale samples in Western Canada Sedimentary Basin. Comput. Geosci. 2020, 138, 104450.
[CrossRef]
19. Hyder, Z.; Siau, K.; Nah, F. Artificial Intelligence, Machine Learning, and Autonomous Technologies in Mining Industry.
J. Database Manag. 2019, 30, 67–79. [CrossRef]
20. Dalm, M.; Buxton, M.W.; van Ruitenbeek, F.; Voncken, J.H. Application of near-infrared spectroscopy to sensor based sorting of a
porphyry copper ore. Miner. Eng. 2014, 58, 7–16. [CrossRef]
21. McCoy, J.; Auret, L. Machine learning applications in minerals processing: A review. Miner. Eng. 2018, 132, 95–109. [CrossRef]
22. Maitre, J.; Bouchard, K.; Bedard, L. Mineral grains recognition using computer vision and machine learning. Comput. Geosci. 2019,
130, 84–93. [CrossRef]
23. Makvandi, S.; Pagé, P.; Tremblay, J.; Girard, R. Exploration for Platinum-Group Minerals in Till: A New Approach to the Recovery,
Counting, Mineral Identification and Chemical Characterization. Minerals 2021, 11, 264. [CrossRef]
24. Kim, C.S. Characterization and speciation of mercury-bearing mine wastes using X-ray absorption spectroscopy. Sci. Total Environ.
2000, 261, 157–168. [CrossRef]
25. Baklanova, O.; Shvets, O. Cluster analysis methods for recognition of mineral rocks in the mining industry. In Proceedings of the
2014 4th International Conference on Image Processing Theory, Tools and Applications (IPTA), Paris, France, 14–17 October 2014.
[CrossRef]
26. Iglesias, J.C.A.; Gomes, O.D.F.M.; Paciornik, S. Automatic recognition of hematite grains under polarized reflected light mi-
croscopy through image analysis. Miner. Eng. 2011, 24, 1264–1270. [CrossRef]
27. Gomes, O.D.F.M.; Iglesias, J.C.A.; Paciornik, S.; Vieira, M.B. Classification of hematite types in iron ores through circularly
polarized light microscopy and image analysis. Miner. Eng. 2013, 52, 191–197. [CrossRef]
28. Figueroa, G.; Moeller, K.; Buhot, M.; Gloy, G.; Haberla, D. Advanced Discrimination of Hematite and Magnetite by Auto-
mated Mineralogy. In Proceedings of the 10th International Congress for Applied Mineralogy (ICAM), Trondheim, Norway,
1–5 August 2011; Springer: Berlin/Heidelberg, Germany, 2012; pp. 197–204.
29. Iglesias, J.C.; Santos, R.B.M.; Paciornik, S. Deep learning discrimination of quartz and resin in optical microscopy images of
minerals. Miner. Eng. 2019, 138, 79–85. [CrossRef]
30. Philander, C.; Rozendaal, A. The application of a novel geometallurgical template model to characterise the Namakwa Sands
heavy mineral deposit, West Coast of South Africa. Miner. Eng. 2013, 52, 82–94. [CrossRef]
31. Sylvester, P.J. Use of the Mineral Liberation Analyzer (MLA) for Mineralogical Studies of Sediments and Sedimentary Rocks; Mineralogical
Association of Canada: Quebec City, QC, USA, 2012; Volume 1, pp. 1–16.
32. Goldstein, J. Practical Scanning Electron Microscopy: Electron and Ion Microprobe Analysis; Springer Science & Business Media:
Berlin/Heidelberg, Germany, 2012.
33. Potts, P.J.; Bowles, J.F.; Reed, S.J.; Cave, R. Microprobe Techniques in the Earth Sciences; Springer Science & Business Media:
Berlin/Heidelberg, Germany, 2012.
34. Safari, H.; Balcom, B.J.; Afrough, A. Characterization of pore and grain size distributions in porous geological samples—An
image processing workflow. Comput. Geosci. 2021, 156, 104895. [CrossRef]
35. Duarte-Campos, L.; Wijnberg, K.M.; Gálvez, L.O.; Hulscher, S.J. Laser particle counter validation for aeolian sand transport
measurements using a highspeed camera. Aeolian Res. 2017, 25, 37–44. [CrossRef]
36. Cox, M.R.; Budhu, M. A practical approach to grain shape quantification. Eng. Geol. 2008, 96, 1–16. [CrossRef]
37. Latif, G.; Iskandar, D.A.; Alghazo, J.; Butt, M.M. Brain MR Image Classification for Glioma Tumor detection using Deep
Convolutional Neural Network Features. Curr. Med. Imaging 2021, 17, 56–63. [CrossRef]
38. Alghazo, J.; Latif, G.; Elhassan, A.; Alzubaidi, L.; Al-Hmouz, A.; Al-Hmouz, R. An Online Numeral Recognition System Using
Improved Structural Features—A Unified Method for Handwritten Arabic and Persian Numerals. J. Telecommun. Electron.
Comput. Eng. 2017, 9, 33–40.
39. Wang, Y.; Balmos, A.D.; Layton, A.W.; Noel, S.; Ault, A.; Krogmeier, J.V.; Buckmaster, D.R. An Open-Source Infrastructure for
Real-Time Automatic Agricultural Machine Data Processing; American Society of Agricultural and Biological Engineers: St. Joseph,
MI, USA, 2017.
40. Wójcik, M.; Brinkmann, P.; Zdunek, R.; Riebe, D.; Beitz, T.; Merk, S.; Cieślik, K.; Mory, D.; Antończak, A. Classification of Copper
Minerals by Handheld Laser-Induced Breakdown Spectroscopy and Nonnegative Tensor Factorisation. Sensors 2020, 20, 5152.
[CrossRef] [PubMed]
41. Hao, H.; Guo, R.; Gu, Q.; Hu, X. Machine learning application to automatically classify heavy minerals in river sand by using
SEM/EDS data. Miner. Eng. 2019, 143, 105899. [CrossRef]
42. Vos, K.; Vandenberghe, N.; Elsen, J. Surface textural analysis of quartz grains by scanning electron microscopy (SEM): From
sample preparation to environmental interpretation. Earth-Sci. Rev. 2014, 128, 93–104. [CrossRef]
43. Sundaresan, V.; Zamboni, G.; Le Heron, C.; Rothwell, P.M.; Husain, M.; Battaglini, M.; De Stefano, N.; Jenkinson, M.; Griffanti, L.
Automated lesion segmentation with BIANCA: Impact of population-level features, classification algorithm and locally adaptive
thresholding. NeuroImage 2019, 202, 116056. [CrossRef] [PubMed]
44. Li, Z.; Chen, J. Superpixel Segmentation using Linear Spectral Clustering. In Proceedings of the IEEE Conference on Computer
Vision and Pattern Recognition (CVPR), Boston, MA, USA, 7–12 June 2015; pp. 1356–1363.
Minerals 2022, 12, 455 18 of 18
45. Hechler, E.; Oberhofer, M.; Schaeck, T. Deploying AI in the Enterprise IT Approaches for Design, DevOps, Governance, Change
Management, Blockchain, and Quantum Computing; Springer: Berkeley, CA, USA, 2020.
46. Alghmgham, D.A.; Latif, G.; Alghazo, J.; Alzubaidi, L. Autonomous Traffic Sign (ATSR) Detection and Recognition using Deep
CNN. Procedia Comput. Sci. 2019, 163, 266–274. [CrossRef]
47. Krizhevsky, A.; Sutskever, I.; Hinton, G.E. Imagenet classification with deep convolutional neural networks. Commun. ACM 2012,
60, 84–90. [CrossRef]
48. Szegedy, C.; Liu, W.; Jia, Y.; Sermanet, P.; Reed, S.; Anguelov, D.; Erhan, D.; Vanhoucke, V.; Rabinovich, A. Going Deeper with
Convolutions. arXiv 2014, arXiv:1409.4842v1.
49. Wu, Z.; Shen, C.; Van Den Hengel, A. Wider or deeper: Revisiting the resnet model for visual recognition. Pattern Recognit. 2019,
90, 119–133. [CrossRef]
50. Sinaice, B.; Owada, N.; Saadat, M.; Toriya, H.; Inagaki, F.; Bagai, Z.; Kawamura, Y. Coupling NCA Dimensionality Reduction with
Machine Learning in Multispectral Rock Classification Problems. Minerals 2021, 11, 846. [CrossRef]