site_analysis.spherical_site

class SphericalSite(frac_coords: numpy.ndarray, rcut: float, label: Optional[str] = None)[source]

Bases: site_analysis.site.Site

as_dict() → Dict[KT, VT][source]

Json-serializable dict representation of this Site.

Parameters:None
Returns:(dict)
centre() → numpy.ndarray[source]

Returns the centre point of this site.

This method should be implemented in the derived subclass.

Parameters:None
Returns:None
contains_atom(atom: site_analysis.atom.Atom, lattice: Optional[pymatgen.core.lattice.Lattice] = None, *args, **kwargs) → bool[source]

Test whether this site contains a specific atom.

Parameters:atom (Atom) – The atom to test.
Returns:(bool)
contains_point(x: numpy.ndarray, lattice: Optional[pymatgen.core.lattice.Lattice] = None, *args, **kwargs) → bool[source]

Test whether the fractional coordinate x is contained by this site.

This method should be implemented in the derived subclass

Parameters:x (np.array) – Fractional coordinate.
Returns:(bool)

Note

Specific Site subclasses may require additional arguments to be passed.

classmethod from_dict(d: Dict[KT, VT]) → site_analysis.spherical_site.SphericalSite[source]

Create a Site object from a dict representation.

Parameters:d (dict) – The dict representation of this Site.
Returns:(Site)