sisl.io.siesta.siesta module

Sile object for reading/writing SIESTA binary files

class sisl.io.siesta.siesta.ncSileSiesta(filename, mode='r', lvl=0, access=1, _open=True)[source]

Bases: sisl.io.siesta.sile.SileCDFSIESTA

SIESTA file object

Attributes

file Filename of the current Sile

Methods

ArgumentParser(*args, **kwargs) Returns the arguments that is available for this Sile
ArgumentParser_out([parser]) Appends additional arguments based on the output of the file
grids() Return a list of available grids in this file.
isDataset(obj) Return true if obj is an instance of the NetCDF4 Dataset type
isDimension(obj) Return true if obj is an instance of the NetCDF4 Dimension type
isGroup(obj) Return true if obj is an instance of the NetCDF4 Group type
isRoot(obj) Return true if obj is an instance of the NetCDF4 Dataset type
isVariable(obj) Return true if obj is an instance of the NetCDF4 Variable type
iter([group, dimension, variable, levels, root]) Iterator on all groups, variables and dimensions.
read(*args, **kwargs) Generic read method which should be overloaded in child-classes
read_density_matrix(**kwargs) Returns a density matrix from the underlying NetCDF file
read_energy_density_matrix(**kwargs) Returns energy density matrix from the underlying NetCDF file
read_es(*args, **kwargs) Deprecated function which is superseeded by read_hamiltonian
read_geom(*args, **kwargs) Deprecated function which is superseeded by read_geometry
read_geometry() Returns Geometry object from a SIESTA.nc file
read_grid(name[, idx]) Reads a grid in the current SIESTA.nc file
read_hamiltonian(**kwargs) Returns a tight-binding model from the underlying NetCDF file
read_hessian(**kwargs) Returns a tight-binding model from the underlying NetCDF file
read_sc(*args, **kwargs) Deprecated function which is superseeded by read_supercell
read_supercell() Returns a SuperCell object from a SIESTA.nc file
write(*args, **kwargs) Generic write method which should be overloaded in child-classes
write_es(*args, **kwargs) Deprecated function which is superseeded by write_hamiltonian
write_geom(*args, **kwargs) Deprecated function which is superseeded by write_geometry
write_geometry(geom) Creates the NetCDF file and writes the geometry information
write_hamiltonian(H, **kwargs) Writes Hamiltonian model to file
write_hessian(H, **kwargs) Writes Hessian model to file
write_sc(*args, **kwargs) Deprecated function which is superseeded by write_supercell

Creates/Opens a SileCDF

Opens a SileCDF with mode and compression level lvl. If mode is in read-mode (r) the compression level is ignored.

The final access parameter sets how the file should be open and subsequently accessed.

  1. means direct file access for every variable read
  2. means stores certain variables in the object.

Attributes

file Filename of the current Sile

Methods

ArgumentParser(*args, **kwargs) Returns the arguments that is available for this Sile
ArgumentParser_out([parser]) Appends additional arguments based on the output of the file
grids() Return a list of available grids in this file.
isDataset(obj) Return true if obj is an instance of the NetCDF4 Dataset type
isDimension(obj) Return true if obj is an instance of the NetCDF4 Dimension type
isGroup(obj) Return true if obj is an instance of the NetCDF4 Group type
isRoot(obj) Return true if obj is an instance of the NetCDF4 Dataset type
isVariable(obj) Return true if obj is an instance of the NetCDF4 Variable type
iter([group, dimension, variable, levels, root]) Iterator on all groups, variables and dimensions.
read(*args, **kwargs) Generic read method which should be overloaded in child-classes
read_density_matrix(**kwargs) Returns a density matrix from the underlying NetCDF file
read_energy_density_matrix(**kwargs) Returns energy density matrix from the underlying NetCDF file
read_es(*args, **kwargs) Deprecated function which is superseeded by read_hamiltonian
read_geom(*args, **kwargs) Deprecated function which is superseeded by read_geometry
read_geometry() Returns Geometry object from a SIESTA.nc file
read_grid(name[, idx]) Reads a grid in the current SIESTA.nc file
read_hamiltonian(**kwargs) Returns a tight-binding model from the underlying NetCDF file
read_hessian(**kwargs) Returns a tight-binding model from the underlying NetCDF file
read_sc(*args, **kwargs) Deprecated function which is superseeded by read_supercell
read_supercell() Returns a SuperCell object from a SIESTA.nc file
write(*args, **kwargs) Generic write method which should be overloaded in child-classes
write_es(*args, **kwargs) Deprecated function which is superseeded by write_hamiltonian
write_geom(*args, **kwargs) Deprecated function which is superseeded by write_geometry
write_geometry(geom) Creates the NetCDF file and writes the geometry information
write_hamiltonian(H, **kwargs) Writes Hamiltonian model to file
write_hessian(H, **kwargs) Writes Hessian model to file
write_sc(*args, **kwargs) Deprecated function which is superseeded by write_supercell
ArgumentParser(*args, **kwargs)[source]

Returns the arguments that is available for this Sile

grids()[source]

Return a list of available grids in this file.

read_density_matrix(**kwargs)[source]

Returns a density matrix from the underlying NetCDF file

read_energy_density_matrix(**kwargs)[source]

Returns energy density matrix from the underlying NetCDF file

read_geometry()[source]

Returns Geometry object from a SIESTA.nc file

NOTE: Interaction range of the Atoms are currently not read.

read_grid(name, idx=0)[source]

Reads a grid in the current SIESTA.nc file

Enables the reading and processing of the grids created by SIESTA

read_hamiltonian(**kwargs)[source]

Returns a tight-binding model from the underlying NetCDF file

read_hessian(**kwargs)[source]

Returns a tight-binding model from the underlying NetCDF file

read_supercell()[source]

Returns a SuperCell object from a SIESTA.nc file

write_geometry(geom)[source]

Creates the NetCDF file and writes the geometry information

write_hamiltonian(H, **kwargs)[source]

Writes Hamiltonian model to file

Parameters:

H : Hamiltonian model

the model to be saved in the NC file

Ef : double=0

the Fermi level of the electronic structure (in eV)

write_hessian(H, **kwargs)[source]

Writes Hessian model to file

Parameters:

H : Hessian model

the model to be saved in the NC file