Python interface¶
This is the Python interface generated via pybind11 from the C++ core classes and methods.
Cluster¶
-
class
_icet.
Cluster
¶ -
distances
¶ list of floats – list of distances between sites
-
geometrical_size
¶ float – the geometrical size of the cluster
-
order
¶ int – order of the cluster (= number of sites)
-
print
()¶
-
sites
¶ list of ints – site indices
-
sorted
¶ boolean – True/False if the cluster is sorted/unsorted
-
tag
¶ int – cluster tag (defined for sorted cluster)
-
ClusterCounts¶
ClusterSpace¶
LatticeSite¶
LocalOrbitListGenerator¶
NeighborList¶
-
class
_icet.
NeighborList
¶ -
build
()¶ Build a neighbor list for the given atomic configuration.
Parameters: structure (icet Structure instance) – atomic configuration
-
Orbit¶
-
class
_icet.
Orbit
¶ -
add_equivalent_sites
()¶
-
allowed_permutations
¶ Get the list of equivalent permutations for this orbit.
If this orbit is a triplet and the permutation [0,2,1] exists this means that The lattice sites [s1, s2, s3] are equivalent to [s1, s3, s2] This will have the effect that for a ternary CE the cluster functions (0,1,0) will not be considered since it is equivalent to (0,0,1).
-
equivalent_sites
¶ List of equivalent Lattice Sites
-
geometrical_size
¶ Returns the geometrical size of the representative cluster.
-
get_all_possible_mc_vector_permutations
()¶ Similar to get all permutations but needs to be filtered through the number of allowed elements.
Parameters: - allowed_components (list of int) – The allowed components for the lattice sites, allowed_components[i] correspond to the lattice site self.representative_sites[i].
- all_mc_vectors (returns) –
-
get_allowed_sites_permutations
()¶
-
get_equivalent_sites
()¶
-
get_equivalent_sites_permutations
()¶
-
get_mc_vectors
()¶ Return the mc vectors for this orbit given the allowed components. The mc vectors are returned as a list of tuples
Parameters: allowed_components (list of int) – The allowed components for the lattice sites, allowed_components[i] correspond to the number of allowed compoments at lattice site orbit.representative_sites[i].
-
get_representative_cluster
()¶ The representative cluster represents the geometrical version of what this orbit is.
-
get_representative_sites
()¶
-
get_sites_with_permutation
()¶ Return the permuted to representative sites of equivalent_sites[index].
-
order
¶ Returns the order of the orbit. The order is the same as the number of bodies in the representative cluster or the number of lattice sites per element in equivalent_sites.
-
permutations_to_representative
¶ Get the list of permutations. Where permutations_to_representative[i] takes self.equivalent_sites[i] to the same order as self.representative_sites.
This can be used if you for example want to count elements and are interested in difference between ABB, BAB, BBA and so on. If you count the lattice sites that are permuted according to these permutations then you will get the correct counts.
-
permuted_sites
¶ Get the equivalent sites but permuted to representative site.
-
representative_cluster
¶ The representative cluster represents the geometrical version of what this orbit is.
-
representative_sites
¶ The representative sites is a list of lattice sites that are uniquely picked out for this orbit which can be used to represent and distinguish between orbits.
-
sort
()¶ Sort the equivalent sites list.
-
OrbitList¶
PermutationMap¶
Structure¶
-
class
_icet.
Structure
¶ This class stores the cell metric, positions, chemical symbols, and periodic boundary conditions that describe a structure. It also holds information pertaining to the components that are allowed on each site and provides functionality for computing distances between sites.
-
atomic_numbers
¶ list of ints – atomic numbers of species on each site
-
cell
¶ 3x3 array – cell metric
-
chemical_symbols
¶ list of strings – chemical symbols of species on each site
-
find_lattice_site_by_position
()¶ Returns the lattice site that matches the position.
Parameters: position (list/NumPy array) – position in Cartesian coordinates Returns: lattice site Return type: LatticeSite object
-
find_lattice_sites_by_positions
()¶ Returns the lattice sites that match the positions.
Parameters: positions (list of lists/NumPy arrays) – list of positions in Cartesian coordinates Returns: list of lattice sites Return type: list of LatticeSite object
-
find_site_by_position
()¶ Returns the index of the site that matches the position.
Parameters: position (list/NumPy array) – position in Cartesian coordinates Returns: site index Return type: int
-
classmethod
from_atoms
(conf)¶ Creates an icet Structure object from an ASE Atoms object.
Parameters: conf (ASE Atoms object) – input configuration Returns: output configuration Return type: icet Structure object
-
get_atomic_numbers
()¶ Returns a list of the species occupying each site by atomic number.
-
get_cell
()¶ Returns the cell metric.
-
get_chemical_symbols
()¶ Returns a list of the species occupying each site by chemical symbol.
-
get_distance
()¶ Returns the distance between two sites
Parameters: Returns: distance in length units
Return type:
-
get_pbc
()¶ Returns the periodic boundary conditions.
-
get_position
()¶ Returns the position of a specified site
Parameters: site (LatticeSite object) – site of interest Returns: position in Cartesian coordinates Return type: vector
-
get_positions
()¶ Returns the positions in Cartesian coordinates.
Returns: Return type: list of NumPy arrays
-
get_unique_site
()¶ Returns the unique site.
Parameters: index (int) – index of site of interest Returns: index of unique site Return type: int
-
get_unique_sites
()¶ Returns the unique sites.
Returns: Return type: list of ints
-
pbc
¶ 3-dimensional vector – periodic boundary conditions
-
positions
¶ list of lists – atomic positions in Cartesian coordinates
-
set_atomic_numbers
()¶ Sets the species occupying each site by atomic number.
Parameters: atomic_numbers (list of ints) – new species by atomic number
-
set_cell
()¶ Sets the cell metric.
-
set_chemical_symbols
()¶ Sets the species occupying each site by chemical symbol.
Parameters: chemical_symbols (list of strings) – new species by chemical symbol
-
set_pbc
()¶ Sets the periodic boundary conditions.
-
set_positions
()¶ Set the positions in Cartesian coordinates.
Parameters: positions (list of NumPy arrays) – new positions in Cartesian coordinates
-
set_unique_sites
()¶ Set unique sites.
This method allows one to specify for each site in the structure the unique site it is related to.
Parameters: unique_sites (list of ints) – site of interest
-
to_atoms
()¶ Returns the structure as an ASE Atoms object.
Returns: atomic configuration Return type: ASE Atoms object
-
unique_sites
¶ list of ints – unique sites
-