soprano.properties.symmetry.symmetry#

Implementation of AtomProperties that relate to symmetry

Classes

SymmetryDataset([name])

Extracts SPGLIB's standard symmetry dataset from a given system, including spacegroup symbol, symmetry operations etc.

WyckoffPoint(fpos, pos, operations, hessian)

Create new instance of WyckoffPoint(fpos, pos, operations, hessian)

WyckoffPoints([name])

Returns a list of the found high symmetry points for a given system, including information about their point group operations, and the properties of Hessian-like quantities at that point, namely, if they are constrained to be isotropic, definite (positive/negative), or can be anything.

class soprano.properties.symmetry.symmetry.SymmetryDataset(name=None, **params)[source]#

Bases: AtomsProperty

Extracts SPGLIB’s standard symmetry dataset from a given system, including spacegroup symbol, symmetry operations etc.

Parameters:
symprec (float): distance tolerance, in Angstroms, applied when
searching symmetry.
Returns:
symm_dataset (dict): dictionary of symmetry information

Initialize an AtomsProperty and set its parameters. The AtomsProperty instance can then be called with a structure as its only argument to get the property with the given parameters.

Args:
name (str): a name to give to this specific instance of the
property (will be used to store it as array if
requested)
params: named arguments specific to this type of property
__call__(s, store_array=False)#

Calling the AtomsProperty returns the value of the property as extracted with the parameters of this specific instance.

Args:
s (ase.Atoms or AtomsCollection): the structure or collection
from which to extract the
property
store_array (bool): if s is a collection, whether to store the
resulting data as an array in the collection
using the given name for this instance

Returns:
property: the value of the property for the given structure or
a list of values if a collection has been passed

static extract(s, symprec)[source]#

Extract the given property with given parameters from an Atoms object.

Args:
s (ase.Atoms): the structure from which to extract the property
params: named arguments specific to this type of property

Returns:
property: the value of the property for the given structure and
parameters

classmethod get(s, store_array=False, **kwargs)#

Extract the given property using the default parameters on an Atoms object s

Args:
s (ase.Atoms or AtomsCollection): the structure or collection
from which to extract the
property
store_array (bool): if s is a collection, whether to store the
resulting data as an array in the collection
using the default name for this property

Returns:
property: the value of the property for the given structure or
a list of values if a collection has been passed

class soprano.properties.symmetry.symmetry.WyckoffPoint(fpos, pos, operations, hessian)#

Bases: tuple

Create new instance of WyckoffPoint(fpos, pos, operations, hessian)

_asdict()#

Return a new dict which maps field names to their values.

classmethod _make(iterable)#

Make a new WyckoffPoint object from a sequence or iterable

_replace(**kwds)#

Return a new WyckoffPoint object replacing specified fields with new values

count(value, /)#

Return number of occurrences of value.

fpos#

Alias for field number 0

hessian#

Alias for field number 3

index(value, start=0, stop=9223372036854775807, /)#

Return first index of value.

Raises ValueError if the value is not present.

operations#

Alias for field number 2

pos#

Alias for field number 1

class soprano.properties.symmetry.symmetry.WyckoffPoints(name=None, **params)[source]#

Bases: AtomsProperty

Returns a list of the found high symmetry points for a given system, including information about their point group operations, and the properties of Hessian-like quantities at that point, namely, if they are constrained to be isotropic, definite (positive/negative), or can be anything.

Parameters:
symprec (float): distance tolerance, in Angstroms, applied when
searching symmetry.
Returns:
wyckoff_points (list): a list of WyckoffPoint named tuples, containing
the members ‘fpos’ (fractional coordinates),
‘pos’ (Cartesian coordinates), ‘operations’
(point group operations) and ‘isotropic’
(whether Hessian-like tensors are isotropic at
the point).

Initialize an AtomsProperty and set its parameters. The AtomsProperty instance can then be called with a structure as its only argument to get the property with the given parameters.

Args:
name (str): a name to give to this specific instance of the
property (will be used to store it as array if
requested)
params: named arguments specific to this type of property
__call__(s, store_array=False)#

Calling the AtomsProperty returns the value of the property as extracted with the parameters of this specific instance.

Args:
s (ase.Atoms or AtomsCollection): the structure or collection
from which to extract the
property
store_array (bool): if s is a collection, whether to store the
resulting data as an array in the collection
using the given name for this instance

Returns:
property: the value of the property for the given structure or
a list of values if a collection has been passed

static extract(s, symprec)[source]#

Extract the given property with given parameters from an Atoms object.

Args:
s (ase.Atoms): the structure from which to extract the property
params: named arguments specific to this type of property

Returns:
property: the value of the property for the given structure and
parameters

classmethod get(s, store_array=False, **kwargs)#

Extract the given property using the default parameters on an Atoms object s

Args:
s (ase.Atoms or AtomsCollection): the structure or collection
from which to extract the
property
store_array (bool): if s is a collection, whether to store the
resulting data as an array in the collection
using the default name for this property

Returns:
property: the value of the property for the given structure or
a list of values if a collection has been passed