Huaizhong
Zhang
a and
Kristen A.
Fichthorn
*b
aDepartment of Chemical Engineering, The Pennsylvania State University, University Park, PA 16802, USA
bDepartment of Chemical Engineering and Department of Physics, The Pennsylvania State University, University Park, PA 16802, USA. E-mail: fichthorn@psu.edu
First published on 23rd August 2024
We use machine learning (ML) to classify the structures of mono-metallic Cu and Ag nanoparticles. Our datasets comprise a broad range of structures – both crystalline and amorphous – derived from parallel-tempering molecular dynamics simulations of nanoparticles in the 100–200 atom size range. We construct nanoparticle features using common neighbor analysis (CNA) signatures, and we utilize principal component analysis to reduce the dimensionality of the CNA feature set. To sort the nanoparticles into structural classes, we employed both K−means clustering and the Gaussian mixture model (GMM). We evaluated the performance of the clustering algorithms through the gap statistic and silhouette score, as well as by analysis of the CNA signatures. For Ag, we found five structural classes, with 14 detailed sub-classes, while for Cu, we found two broad classes (crystalline and amorphous), with the same five classes as for Ag, and 15 detailed sub-classes. Our results demonstrate that these ML methods are effective in identifying and categorizing nanoparticle structures to different levels of complexity, enabling us to classify nanoparticles into distinct and physically relevant structural classes with high accuracy. This capability is important for understanding nanoparticle properties and potential applications.
The shapes of nanoparticles are typically quantified in terms of perfect morphologies: FCC, icosahedron (Ih), decahedron (Dh), etc., but such shapes only arise for certain “magic numbers” of atoms that give the crystal a perfect shape.29,30 Given the vast materials processing space available in nanoparticle synthesis, there are many more imperfect nanoparticle shapes than ideal shapes. If we could precisely quantify both ideal and non-ideal morphologies, we could identify growth trajectories that lead to them and prescribe strategies for synthesizing them with high selectivity. In this work, we analyze and quantify both ideal and non-ideal nanoparticle morphologies using machine learning (ML).
Efforts to classify nanoparticle shapes using ML have been underway for at least a decade30–35 and there have been efforts at inverse design of nanoparticles for applications in catalysis.34,36,37 Recently, Ferrando and co-workers have focused on using ML for shape classification and analysis of metal nanoparticles. For example, Roncaglia and Ferrando utilized unsupervised learning algorithms, such as K−means and Gaussian mixture model (GMM) clustering38 to classify AgCu, Au, Ag, and AuPd nanoparticles into structural classes using common neighbor analysis (CNA) signatures as descriptors. In another study, this team combined support vector regression and unsupervised clustering to predict the mixing energy and classify the shapes of AgCu nanoalloys, offering insights into their stability and temperature-dependent behavior.39 Telari et al. demonstrated the high accuracy of convolutional neural networks in mapping and classifying nanoparticle shapes, using radial distribution functions as descriptors.40 Interestingly, there are also efforts to use ML to classify nanoparticle shapes from experimental transmission electron microscopy images41–46 and it would be beneficial to combine innovations in analysis of in silico shapes with those in experiments to close gaps in this field.
In this paper, we adopt a combined approach of ML methods and CNA for unsupervised clustering of datasets composed of Ag and Cu nanoparticles in the 100–200 atom size range generated from parallel tempering molecular dynamics (PTMD).47,48 This process entails four essential steps: first, converting the structures obtained from PTMD simulations into a dataset with CNA signature features; second, extracting the most relevant information from this complex description through dimensionality reduction based on principal component analysis (PCA); third, selecting the best clustering output from two different clustering algorithms (K−means and GMM) by calculating two different clustering scores (the silhouette score and the gap statistic); and finally, analysis of the CNA signatures of nanoparticles in each class to obtain physical meaning from the clustering and to ensure that overfitting did not occur. We demonstrate that this protocol can provide effective, hierarchical clustering of both types of particles into five basic classes, with numerous, physically meaningful sub-classes.
Atom type | C N | {i, j, k}(#) | {i, j, k}(#) | {i, j, k}(#) | {i, j, k}(#) | {i, j, k}(#) |
---|---|---|---|---|---|---|
FCC bulk | 12 | {4,2,1}(12) | ||||
HCP bulk | 12 | {4,2,1}(6) | {4,2,2}(6) | |||
FCC{111} surface | 9 | {4,2,1}(3) | {3,1,1}(6) | |||
FCC vertex | 6 | {4,2,1}(1) | {3,1,1}(2) | {2,1,1}(2) | {2,0,0}(1) | |
FCC {111}–{100} edge | 7 | {4,2,1}(2) | {3,1,1}(2) | {2,1,1}(3) | ||
FCC {111}–{111} edge | 7 | {4,2,1}(1) | {3,1,1}(4) | {2,0,0}(2) | ||
Ih spine | 12 | {4,2,2}(10) | {5,5,5}(2) | |||
Ih surface edge | 8 | {4,2,2}(2) | {3,2,2}(2) | {3,1,1}(4) | ||
Dh–Ih notch vertex | 7 | {4,2,2}(1) | {3,2,2}(1) | {3,1,1}(2) | {3,0,0}(1) | {2,0,0}(2) |
Dh notch edge | 10 | {4,2,2}(2) | {4,2,1}(2) | {3,1,1}(4) | {3,0,0}(2) | |
Twisted Ih surface edge | 9 | {4,2,2}(2) | {4,2,1}(2) | {3,2,2}(2) | {3,1,1}(2) | {2,1,1}(1) |
Twisted Ih surface vertex | 6 | {4,2,2}(1) | {3,2,2}(1) | {3,1,1}(1) | {2,1,1}(1) | {2,0,0}(2) |
In previous work, we classified nanocrystals by exclusively relying on the CNA signatures extracted from bulk environments.47,48 In these studies, we could effectively differentiate between shapes such as FCC single crystals, single crystals with stacking faults (SCSF), decahedra (Dh), icosahedra (Ih), and a hybrid Dh–Ih structure. As seen in Tables 1 and S1,† we also obtain surface CNA signatures and these proved to be valuable in delineating fine nanocrystal structures.
Each dataset for the Ag and Cu nanoparticles was described by a collection of 33-dimensional vectors, that is, an (n × 33) matrix, where n is the number of structures in the dataset. Each vector represents the percentage of atoms with a specific CNA signature in a nanoparticle. We compiled this list of 33 different CNA signatures by combining commonly used signatures from the literature,52 unique signatures related to Dh–Ih and Ih shapes defined in our previous studies on Ag and Cu nanoparticle,47,48 listed in Table S1.† Types 1, 2, and 3 were defined in this study. For both Ag and Cu datasets, the last component of the vector was dedicated to all unclassified atoms most likely residing in an amorphous environment. In the ESI,† we provide files containing the 207 and 176 data points we used for Ag and Cu, respectively. Each row in the file represents a distinct nanoparticle structure, each column represents a CNA signature we used as a feature, and each number represents a percentage of the atoms from each atomic environment.
![]() | (1) |
![]() | (2) |
Here, n is the number of samples in the dataset and X is the centered data matrix. The principal components are then given by
![]() | (3) |
By retaining the principal components that capture the majority of the variance in the data, PCA enables a more concise representation suitable for subsequent analysis and reduces the risk of over-fitting.
![]() | (4) |
GMM represents each cluster as a probability distribution defined by a Gaussian distribution, allowing for flexible cluster shapes and capturing complex data distributions. The probability density function of the GMM is given by
![]() | (5) |
In both the K−means and GMM clustering methods, we limited the complexity of our models by setting a minimum cluster size to at least five data points. This approach ensured that the clustering model did not become overly complex, which could otherwise lead to overfitting.
![]() | (6) |
Additionally, we computed the gap statistic, which compares the within-cluster dispersion to that of a reference null distribution, aiding in the determination of the optimal number of clusters. The gap statistic is defined as:
![]() | (7) |
By assessing these metrics, we quantified the performance of the clustering models and identified the optimal number of clusters for shape classification of the metal nanoparticles.
![]() | ||
Fig. 1 Explained variance ratios for Ag and Cu datasets as a function of the number of principal components. |
It is of interest to discern which structural features are retained in each principal component (PC). Fig. 2 shows the break-down of each PC into its characteristic CNA indices for Ag (see Table 1). In this figure, we specify all structural features that contribute ∼5% or more to a given PC and the category of “others” contains the combined percentage of all structural features that contributed less than 5% each. PC1 captured 57.17% of the variance. Here, the most prominent structural feature is “unclassified”, which is typically associated with amorphous atoms from particles that are (partially) melted. Other notable contributions are from features such as “FCC bulk”, “FCC vertex”, and “FCC (111) surface”. PC2, retaining 32.82% of the variance, had the most significant contribution from “Ih surface edge” atoms and other important contributions from “FCC bulk”, “FCC vertex”, and “Ih spine”. PC3 retains ca. 3.26% of the variance, with major contributions from “HCP bulk”, “Ih surface edge”, “Dh–Ih notch vertex”, and “FCC bulk”, while PC4 comprises 1.77% of the variance, with a distribution of structural components across multiple categories. It is interesting that in prior studies, we classified Ih as nanocrystals possessing an Ih center.47,48 However, an Ih usually possesses only one Ih center, so this feature is in the minority here and it does not show up in Fig. 2. Nevertheless, as we will demonstrate below, unsupervised learning does identify several types of Ih as characteristic shapes of these nanocrystals.
![]() | ||
Fig. 2 Pie charts (PC1) to (PC4) illustrating the contribution of each original feature to the principal components retained after PCA for the Ag dataset. Each pie chart represents the proportion of variance explained by individual features within the respective principal component. Features that contribute ∼5% or more to a given component are designated (see Table 1) and the rest of the features are lumped together as “others”. |
Fig. 3 shows the break-down of each PC into its characteristic CNA indices for Cu (see Table 1). Similar to Ag, PC1 retained 71.13% of the variance, with the most significant contribution from “unclassified” atoms. Also prominent are contributions from “HCP bulk” and “Ih surface edge”, which distinguishes Cu from Ag. PC2, retaining 20.68% of the variance, has the most significant contribution from “Ih surface edge” atoms and important contributions from “FCC bulk”, “FCC vertex”, and “Ih spine” – similar to what we see for Ag. Comprising 2.99% of the variance, PC3 has the most significant contribution from “Dh/Ih notch vertex” and important contributions from “Ih surface edge”, “HCP bulk”, and “FCC bulk”. PC4 comprises 1.81% of the variance and contains significant contributions from “Dh/Ih notch vertex” and “twisted Ih surface vertex” atoms.
![]() | ||
Fig. 3 Pie charts (PC1) to (PC4) illustrating the contribution of each original feature to the principal components retained after PCA for the Cu dataset. Each pie chart represents the proportion of variance explained by individual features within the respective principal component. Features that contribute ∼5% or more to a given component are designated (see Table 1) and the rest of the features are lumped together as “others”. |
To use the silhouette score and the gap statistic to identify optimal numbers of nanoparticle shape classes, we used two different evaluation measures: the maximum values and plateau values. To obtain plateau values, a moving average was computed for each sequence of silhouette and gap statistic scores to smoothen fluctuations and highlight overall trends. The slope at each value of N on the moving average curves was then calculated. Plateau values were identified as points where the absolute value of the slope is less than 0.01. Beyond this point, we often observed clusters containing only one or two data points since we set the number of clusters too high, especially using PCA + GMM. For unsupervised clustering, the algorithm may begin fitting to the noise in the data rather than capturing meaningful structure when N is too large. This occurs when some clusters have very few data points, which are essentially outliers or noise points. To avoid overfitting, we kept the number of clusters such that the smallest cluster contains at least five data points for both the Ag and Cu datasets. Recognizing the inherent limitations of clustering and evaluation methods, we consistently analyzed the CNA structures of nanoparticles in each class within the optimal cluster counts.
We observed plateau values in the silhouette score at N = 16 and 18 for the PCA + K−means [Fig. 4(a)] and PCA + GMM [Fig. 4(b)] methods, respectively. The gap statistic score calculated for the PCA + K−means [Fig. 4(c)] and the PCA + GMM [Fig. 4(d)] methods reaches a plateau after N = 14 and 18, respectively. The elbow point in the gap statistic at N = 6 suggests that this number of clusters balances model complexity and within-cluster variance well, but the larger gap statistic scores at N = 14 and 18 indicate that 14 and 18 clusters still provide a better fit than 6 clusters in terms of reducing within-cluster variance. Given the statistical results, using 14 to 18 clusters appears to be a reasonable and justified decision. By characterizing the detailed structures of nanoparticles within each cluster using CNA analysis, we determined that the K−means method best distinguished between 14 structural classes for this dataset, with at least five data points in each class and the fewest mis-classifications. These classes are indicated in Fig. 5.
The first three classes in Fig. 5 pertain to FCC and SCSF structures: class 1 contains single-crystal structures (FCC) across the entire size range. Class 2 and class 3 each contain SCSF structures with one layer of stacking fault and multiple layers of stacking faults, respectively. Each of these two classes contain SCSF for almost the entire size range. Class 4 consists of Dh with different lengths of the five icosahedral surface edges, while class 5 consists of Dh with five icosahedral surface edges of identical lengths. These two classes also include nanoparticles across the entire size range.
The next four classes pertain to various types of Dh–Ih nanocrystals. The major difference between them is the percentage of unclassified atoms. Class 6, 7, 8 and 9 each consists of Dh–Ih with less than 10%, 10–20%, 20–25%, and 25–30% of unclassified atoms, respectively. Here, we note that 116 atoms is a magic size for a Dh–Ih.47 Class 6 contains Dh–Ih nanocrystals close to this magic size, consisting of perfect Ag116 Dh–Ih structures with both missing and extra surface atoms, ranging from Ag114 to Ag117. This is the only class of Dh–Ih structures observed over a small size range.
There are three classes for Ih structures. Class 10 contains Ih with less than 7% of atoms from the Ih/Dh notch vertex environment and more than 23% of atoms from Ih surface edge environment. Class 11 is the only Ih class containing structures with more than 20% of atoms from the HCP bulk environment. It is also the only Ih class containing structures with 140 atoms, close to the magic size of a perfect Ih with 147 atoms. Class 12 contains Ih with 7–20% of atoms from the Ih/Dh notch vertex environment and less than 23% of atoms from Ih surface edge environment. Class 13 and 14 are amorphous structures with different proportions of ordered atoms (30–40% for class 13 and less than 30% for class 14). Representative structures for each cluster are shown in Fig. 5.
Fig. 6 illustrates the fraction of each relevant CNA environment for each of the FCC/SCSF nanocrystals in classes 1–3 in Fig. 5. Here, we see a distinct CNA grouping for each class, with no HCP atoms in class 1, and an increasing fraction of HCP atoms in going from class 2 to class 3 – consistent with an increasing number of stacking faults. We also see an increasing cumulative fraction of “other” atoms, that contribute less than 5% each to the total, as we go from class 1 to class 3. We show a similar CNA breakdown for the other classes for Ag in the ESI, in Fig. S1–S4.†
![]() | ||
Fig. 6 Fraction of atomic CNA environments (see Table 1) for the three FCC/SCSF classes in Fig. 5. The category labeled “others” contains the sum of fractions of individual CNA environments that contribute less than 5% to the total. |
Telari et al. used convolutional neural networks based on radial distribution functions to classify the structures of Ag nanoparticles containing 147 atoms, generated with PTMD.40 Their description of Ag interactions was given by the Gupta potential,59 which is different than the EAM potential that we used for the structures in this study. Overall, they distinguished five broad classes for these structures, with 17 different fine classes. Similar to us, their broad classes contained Ih, FCC/SCSF, Dh-like and amorphous structures. However, they introduced a different class denoted “distorted” and it is unclear whether this class has good agreement with our Dh–Ih class.
Their fine structural classes contained four types of Ih, while we found three types – however, they probed a magic size for an Ih in their study, so finding four Ih is perhaps not surprising. Similar to us, they found three different classes of FCC/SCSF. They found a single Dh-like class, while we found two Dh classes. However, they identified seven different classes of amorphous nanoparticles (to our two) and two “distorted” structures. In addition to differences between the ML methods and interatomic potentials employed, they studied only Ag147, while we probed an entire size range. We also note that the results in Fig. 4 indicate that N = 14–18 is an adequate size range for classifying the nanoparticle structures in our study and when we use N > 15, the “extra” structures are classified as amorphous.
Roncaglia and Ferrando also studied Ag147 nanoparticles using ML methods similar to ours.38 They generated their nanoparticle structures using a combination of optimization and MD simulations run at temperatures around the solid–liquid transition. Similar to Telari et al., they used the Gupta potential to describe Ag interactions. They found that three PCs captured more than 99% of their variance (we found four captured greater than 95%) and they identified 14 different structural classes. Most of the structures they identified were Ih-like, which is perhaps not surprising, given that 147 atoms is a magic size for an Ih. However, Telari et al. also studied Ag147 based on the Gupta potential and their ML classification contained a broad range of structures comparable to the range that we identified by studying different nanoparticle sizes. These differences highlight the importance of the ML method and perhaps also the method for structural generation in establishing a comprehensive shape classification.
The gap statistic calculated for the PCA + K−means and PCA + GMM methods reaches a plateau after N = 17 and 18, respectively. We also observed that the silhouette score plateaued at N = 15 and 16 for the PCA + K−means and PCA + GMM methods, respectively. By analyzing the detailed CNA signatures within each cluster, we determined that the K−means method best distinguished between 15 structural classes for this dataset. These 15 clusters are more detailed sub-clusters within the 5 major clusters described above.
Fig. 8 shows the hierarchy of structural classes observed for the Cu nanoparticles. At the most basic level, unsupervised learning distinguishes between crystalline and amorphous nanoparticles (N = 2). It is interesting that this clustering was not seen for Ag – though the silhouette score for K−means clustering with N = 2 has the second-highest value for Ag. Similar to Ag, we find five different structural classes for Cu, with 15 detailed classes within the five major classes. Fig. S5–S9† show the CNA signatures for each structure in each of the five classes, along with their delineation into the 15 sub-classes.
Delving into the fine structural classes, the first two classes pertain to FCC structures: class 1 consists of pure FCC single crystal structures and SCSF structures with one stacking-fault, while class 2 consists of SCSF structures with multiple stacking faults. It appears the delineation between FCC and SCSF structures is more distinct for Ag than for Cu.
Classes 3 and 4 deal with Dh structures: Dh structures in class 3 possess less than 1% of atoms from the Ih/Dh surface vertex environment, while Dh structures in class 4 have 1–2% of atoms from the Ih/Dh surface vertex environment. Neither of these classes is restricted to a specific size range.
Classes 5–8 pertain to various types of Dh–Ih structures. Class 5 consists of Dh–Ih structures with two half-sets of perfect Ih-spine, ranging in size from 180–200 atoms. Classes 6, 7, and 8 contain Dh–Ih nanocrystals close to the magic size at 116 atoms,47 but each having its own characteristic atomic environment. Dh–Ih nanocrystals from class 6 possess a perfect five-fold ring formed by Ih spine atoms, while Dh–Ih nanocrystals from class 7 also have the five-fold ring-like structure but with missing atoms. Dh–Ih structures from class 8 have a linear Ih spine, similar to a Dh.
There are four classes for Ih structures. Class 9 is the only Ih class containing structures with a complete set of perfect Ih spines, with a number of atoms ranging from 150 to 160. Classes 10 and 11 contain Ih structures across the entire size range. The major difference between these classes is that the percentage of atoms from the Ih/Dh notch vertex environment is greater than 5% and smaller than 10% in class 10, while it is smaller than 5% in class 11. Class 12 contains Ih nanocrystals similar to a “twisted”, anti-Mackay Ih with 116 atoms,48 with both extra and missing surface atoms. Classes 13, 14, and 15 are amorphous structures with different proportions of ordered atoms (10–20% for class 13, 20–30% for class 14, and 30–40% for class 15).
Telari et al. used convolutional neural networks based on radial distribution functions to classify the structures of Cu nanoparticles containing 147 atoms, generated with PTMD based on the Gupta potential. Overall, they distinguished six broad classes for these structures, with 22 different finer classes. Similar to us, their broad classes contained Ih, FCC/SCSF, Dh-like, and amorphous structures. However, they found a class consisting of pure HCP structures and introduced a different class denoted “intermediate”, which may correspond to the Dh–Ih structure that we find here.
Their fine structural classes contained seven types of Ih, while we found four types. This may reflect that their study was conducted at a magic size for an Ih. They found four different classes of FCC/SCSF, while we found two. In both our study and theirs, two Dh classes were identified. They identified six different classes of amorphous nanoparticles, while we found three. They also found one HCP class, which we did not observe, and two “intermediate” structures, which may correspond to our Dh–Ih. It seems possible that some of the differences between our studies arise from the sizes probed in their study (Cu147) vs. ours (Cu100–Cu200), as well as from differences in the potentials used and ML methods in the two studies.
Overall, comparing our shape classifications for Ag and Cu nanocrystals, we see that FCC and SCSF shapes tend to be more emphasized for Ag and Ih shapes tend to be more prominent for Cu. This is consistent with PTMD results for the two systems,47,48 which employed just the five inner/middle shapes classes in Fig. 5 and 8. Doye, Wales, and Berry studied the effect of the energetically preferred shape of a cluster on the range of the inter-atomic pair potential (a Morse potential) and the size of the cluster.60 For sufficiently large clusters in their study (an admittedly small size range of 25–80 atoms), they found that the structure of the global minimum changed from Ih to Dh to FCC as the range of the potential was decreased. The argument is that strain (that is found in Ih structures but not in FCC) is better accommodated in a long-ranged potential than in a short-ranged one. We note that the cut-off distance is greater for the EAM potential for Cu61 than it is for Ag,51 even though the lattice constant is larger for Ag. These observed differences between Ag and Cu await experimental confirmation.
The methodology we use here could be easily extended to larger systems with appropriate adjustments. For larger nanoparticles, it is possible that additional structural motifs could emerge, and the complexity of the nanoparticle shapes might increase. To adapt our methodology for larger systems, the feature set would need to be expanded to include new CNA signatures that account for these additional motifs. Similarly, these studies could be extended to bimetallic systems using adaptive CNA.62 Since CNA only depends on the capability to define a set of atomic coordinates (and identities, in the case of multi-metallic nanocrystals), such techniques could be applied to experimental data. In all cases, the computational requirements of the ML methods are relatively modest, and these calculations can be performed on a laptop or a desktop computer.
We obtained different classification results than those in prior studies of Ag and Cu,38,40 which could be due to the wider size range probed in our study, as well as the different atomic potentials – EAM in our study vs. Gupta in theirs. However, the studies of Roncaglia38 and Telari40 probed Ag nanocrystals of the same size and with the same inter-atomic potential, but different ML methods, and they achieved significantly different classification results.
The differences between all our results highlight the need for consistent nomenclature in categorizing nanocrystals and the need to better evaluate the ML methods employed. Since differences between our results and those of Roncaglia and Telari may indicate a sensitivity to the atomic potential, there is room for the application of more accurate atomic potentials with higher fidelity to first principles, such as ML force fields. Differences between these three studies may also indicate that structural classification with ML methods is highly sensitive to the ways in which structures are generated. Differences in structural generation could explain the differences between the study of Roncaglia38 and Telari40 and why the structures in our study are similar to those found by Telari et al. This indicates the possibility that ML methods can link fine structural details to materials processing methods. The methods applied here could conceivably be applied in experiments, which would allow for detailed testing of the level of theory that needs to be applied to describe nanocrystals accurately. Further research in this direction would be fruitful.
Footnote |
† Electronic supplementary information (ESI) available: CNA signatures used in this study; detailed CNA analysis of all the structures in this study; input for machine learning for all the Cu and Ag nanoparticles. See DOI: https://doi.org/10.1039/d4nr02531h |
This journal is © The Royal Society of Chemistry 2024 |