Skip to main content

SIESTAstepper runs SIESTA step by step, designed for constrained calculations.

Project description

SIESTAstepper

PyPI version PyPI pyversions Python package codecov PyPI download month PyPI download week PyPI download day GitHub all releases GitHub contributors CodeFactor PyPI license DOI

SIESTAstepper runs SIESTA step by step, designed for constrained calculations.

Installation

Use the package manager pip to install SIESTAstepper.

$ pip install SIESTAstepper

# to make sure you have the latest version
$ pip install -U SIESTAstepper

# latest available code base
$ pip install -U git+https://github.com/eftalgezer/SIESTAstepper.git

Tutorial

Usage

All SIESTA working directories must be named as i1, i2, i3 ... and so on.

In code

Simple usage

SIESTAstepper.run("graphene")

Advance usage

import SIESTAstepper

# Sets the path of the working directory
SIESTAstepper.update_cwd("path/to/working/directory")

# Sets the name of SIESTA log files (default is "log")
SIESTAstepper.update_log("log")

# Sets number of cores for parallel run
SIESTAstepper.update_cores(4)

# Sets Anaconda environment
SIESTAstepper.update_conda("envir")

# Sets the subfolder name for interrupted calculations (default is "continue")
SIESTAstepper.update_cont("continue")

# Sets the SIESTA command name (default is "siesta")
SIESTAstepper.update_siesta("siesta_p")

# Sets the filenames to copy (useful for interrupted calculations)
SIESTAstepper.contfiles.extend(["file1", "file2"])

# Sets the extensions to copy (useful for interrupted calculations, default is ["psf, "fdf"]
SIESTAstepper.contextensions.extend(["DM", "XV", "CG", "LWF"])

# Runs SIESTA step by step
SIESTAstepper.run("graphene")

# Converts last geometry of an ANI to FDF by using the previous FDF and ANI files
SIESTAstepper.ani_to_fdf("path/to/ANI", "path/to/FDF", "path/to/newFDF")

# Converts XYZ to FDF by using the previous FDF and XYZ files
SIESTAstepper.xyz_to_fdf("path/to/XYZ", "path/to/FDF", "path/to/newFDF")

# Merges ANI files
SIESTAstepper.merge_ani(label = "graphene")

# Merges ANI files by setting a path
SIESTAstepper.merge_ani(label = "graphene", path = "path/to/i*/ANI/files")

# Runs SIESTA for a given step
SIESTAstepper.run_next("1", "graphene")

# Runs SIESTA for a given step without continuing to next step
SIESTAstepper.single_run("1", "graphene")

# Continues to an interrupted calculation without continuing to next step
SIESTAstepper.single_run_interrupted("1", "graphene")

# Continues to an interrupted calculation
SIESTAstepper.run_interrupted("1", "graphene")

# Creates folders named i1, i2, i3, i4, i5, ...
SIESTAstepper.make_directories(5)

# Copies files from i1 to i2
SIESTAstepper.copy_files(["psf", "fdf", "XV", "DM"], "graphene", "path/to/i1", "path/to/i2")

# Plots and returns energies from log files
SIESTAstepper.analysis()

# Returns energies from log files without plotting
SIESTAstepper.analysis(plot_ = False)

# Plots and returns energies from log files by setting a path
SIESTAstepper.analysis(path = "path/to/i*/log/files")

# Calculates the energy differences between minima and maxima
SIESTAstepper.energy_diff()

# Calculates the energy differences between minima and maxima by setting a path
SIESTAstepper.energy_diff(path = "path/to/i*/log/files")

In terminal

Simple usage

$ python -m SIESTAstepper run log graphene

Advance usage

$ python -m SIESTAstepper run log graphene

$ python -m SIESTAstepper run log graphene contfiles=file1,file2 contextensions=DM,XV,CG,LWF

$ python -m SIESTAstepper run log graphene mpirun=4

$ python -m SIESTAstepper run log graphene conda=envir

$ python -m SIESTAstepper run log graphene siesta=siesta_p

$ python -m SIESTAstepper run_next log 1 graphene

$ python -m SIESTAstepper run_next log 1 graphene contfiles=file1,file2 contextensions=DM,XV,CG,LWF

$ python -m SIESTAstepper run_next log 1 graphene mpirun=4

$ python -m SIESTAstepper run_next log 1 graphene conda=envir

$ python -m SIESTAstepper run_next log 1 graphene siesta=siesta_p

$ python -m SIESTAstepper single_run log 1 graphene

$ python -m SIESTAstepper single_run log 1 graphene mpirun=4

$ python -m SIESTAstepper single_run log 1 graphene conda=envir

$ python -m SIESTAstepper single_run log 1 graphene siesta=siesta_p

$ python -m SIESTAstepper run_interrupted log 1 graphene cont=continue

$ python -m SIESTAstepper run_interrupted log 1 graphene cont=continue contfiles=file1,file2 contextensions=DM,XV,CG,LWF

$ python -m SIESTAstepper run_interrupted log 1 graphene mpirun=4 cont=continue

$ python -m SIESTAstepper run_interrupted log 1 graphene conda=envir cont=continue

$ python -m SIESTAstepper run_interrupted log 1 graphene siesta=siesta_p cont=continue

$ python -m SIESTAstepper single_run_interrupted log 1 graphene cont=continue

$ python -m SIESTAstepper single_run_interrupted log 1 graphene mpirun=4 cont=continue

$ python -m SIESTAstepper single_run_interrupted log 1 graphene conda=envir cont=continue

$ python -m SIESTAstepper single_run_interrupted log 1 graphene siesta=siesta_p cont=continue

$ python -m SIESTAstepper make_directories 5

$ python -m SIESTAstepper copy_files graphene path/to/i1 path/to/i2 psf fdf XV DM

$ python -m SIESTAstepper copy_files graphene path/to/i1 path/to/i2 psf fdf XV DM

$ python -m SIESTAstepper ani_to_fdf path/to/ANI path/to/FDF path/to/newFDF

$ python -m SIESTAstepper xyz_to_fdf path/to/XYZ path/to/FDF path/to/newFDF

$ python -m SIESTAstepper merge_ani graphene

$ python -m SIESTAstepper merge_ani graphene cont=continue

$ python -m SIESTAstepper merge_ani graphene path=path/to/i*/ANI/files

$ python -m SIESTAstepper analysis log

$ python -m SIESTAstepper analysis log cont=continue

$ python -m SIESTAstepper analysis log noplot

$ python -m SIESTAstepper analysis log path=path/to/i*/log/files

$ python -m SIESTAstepper energy_diff log

$ python -m SIESTAstepper energy_diff log cont=continue

$ python -m SIESTAstepper energy_diff log path=path/to/i*/log/files

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

Citation

If you are using SIESTAstepper, please citate relevant version. You can find the relevant citation here.

@software{eftal_gezer_2022_7094002,
  author       = {Eftal Gezer},
  title        = {eftalgezer/SIESTAstepper: v1.2.3},
  month        = sep,
  year         = 2022,
  publisher    = {Zenodo},
  version      = {v1.2.3},
  doi          = {10.5281/zenodo.7094002},
  url          = {https://doi.org/10.5281/zenodo.7094002}
}

License

GNU General Public License v3.0

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

SIESTAstepper-1.2.3.tar.gz (24.2 kB view details)

Uploaded Source

Built Distributions

SIESTAstepper-1.2.3-py3.10.egg (24.5 kB view details)

Uploaded Source

SIESTAstepper-1.2.3-py3-none-any.whl (22.9 kB view details)

Uploaded Python 3

File details

Details for the file SIESTAstepper-1.2.3.tar.gz.

File metadata

  • Download URL: SIESTAstepper-1.2.3.tar.gz
  • Upload date:
  • Size: 24.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.6

File hashes

Hashes for SIESTAstepper-1.2.3.tar.gz
Algorithm Hash digest
SHA256 f162c914eb1759b9fe7e16a1c7ce981a1a93c82224f9955ecedb30bac2d19faf
MD5 9a101da7521eb8b97188a399d22af27b
BLAKE2b-256 76e6ef1dfd8019cbf41bdcf4baa42a7973d8c71db31b89afe8b263e8aac3f8b1

See more details on using hashes here.

File details

Details for the file SIESTAstepper-1.2.3-py3.10.egg.

File metadata

  • Download URL: SIESTAstepper-1.2.3-py3.10.egg
  • Upload date:
  • Size: 24.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.6

File hashes

Hashes for SIESTAstepper-1.2.3-py3.10.egg
Algorithm Hash digest
SHA256 eb7687a206d2fb752766f653ee339a2a0b21371a2f1f5f75966fb7c34f5227f0
MD5 0dba2b864cc79c7c667e6c5c169c9dc3
BLAKE2b-256 265f6e5b600422ba0696a8cbe2271b6f1b4e9c2fc6d5f1e3cebab2a20578b09b

See more details on using hashes here.

File details

Details for the file SIESTAstepper-1.2.3-py3-none-any.whl.

File metadata

File hashes

Hashes for SIESTAstepper-1.2.3-py3-none-any.whl
Algorithm Hash digest
SHA256 e7a69621484ce677b0aa77e7232d36ee94e03b5ddc739722ed40e0de93ed4e7b
MD5 8cee032b766189df95f15bf672a0887d
BLAKE2b-256 e9c2714d3f32488367031fd4354026f1134b49c520244db9118231b8b80edf57

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page