Skip to content

Commit

Permalink
Release py4vasp version 0.7 (#77)
Browse files Browse the repository at this point in the history
* Add conversion specification for documentation
* Remove upper limits on dependencies
* Update install.yml
* Update installation instructions
* Update version number
* Update link to website
* Update copyright
  • Loading branch information
martin-schlipf authored Feb 14, 2023
1 parent 0c00d6e commit c9aaaed
Show file tree
Hide file tree
Showing 9 changed files with 1,506 additions and 1,061 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

> Please note that this document is intended mostly for developers that want to use
> the version of py4vasp provided on Github. If you just want to install py4vasp to
> use it, please follow the [official documentation](https://vasp.at/py4vasp).
> use it, please follow the [official documentation](https://vasp.at/py4vasp/latest).
## Installation

Expand Down
2 changes: 1 addition & 1 deletion docs/calculation.rst → docs/Calculation.rst
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
calculation
Calculation
===========

.. autoclass:: py4vasp.Calculation
Expand Down
4 changes: 2 additions & 2 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,11 @@
# -- Project information -----------------------------------------------------

project = "py4vasp"
copyright = "2022, VASP Software GmbH"
copyright = "2023, VASP Software GmbH"
author = "VASP Software GmbH"

# The full version, including alpha/beta/rc tags
release = "0.6.0"
release = "0.7.0"


# -- General configuration ---------------------------------------------------
Expand Down
13 changes: 13 additions & 0 deletions docs/convert.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
latest:
- dirhtml
- Calculation:
- dirhtml/Calculation
- raw:
- dirhtml/raw
- dirhtml/api/py4vasp.raw.*
- data:
- dirhtml/data
- dirhtml/api/py4vasp.data.*
- exception:
- dirhtml/exception
- dirhtml/api/py4vasp.exception.*
14 changes: 12 additions & 2 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,16 @@ the simple installation above fails, you may need to use *conda* to install *mdt
conda install -c conda-forge mdtraj
pip install py4vasp
Alternatively, you can obtain the code from GitHub and install it. This will give you
the most recent version with all bugfixes. However, some features may only work once
the next VASP version is released.

.. code-block:: bash
git clone https://github.com/vasp-dev/py4vasp.git
cd py4vasp
pip install .
If these commands succeed, you should be able to use *py4vasp*. You can make a quick
test of your installation running the following command

Expand Down Expand Up @@ -91,7 +101,7 @@ a single line of code
Under the hood, this will access the *vaspout.h5* file, because *py4vasp* knows where
the output is stored after you ran VASP. It will read the relevant tags from
the file and store them all in a Python dictionary. If you want to access particular
orbital projections, let's say the *p* orbitals, you can pass a ``select = "p"`` as
orbital projections, let's say the *p* orbitals, you can pass a ``selection = "p"`` as
an argument to the routine. More generally, you can check how to use a function with

>>> help(calc.dos.read)
Expand Down Expand Up @@ -123,7 +133,7 @@ how you can apply *py4vasp* in your research.
:maxdepth: 1
:caption: Contents:

calculation
Calculation
control
raw
data
Expand Down
2,462 changes: 1,440 additions & 1,022 deletions poetry.lock

Large diffs are not rendered by default.

43 changes: 23 additions & 20 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "py4vasp"
version = "0.6.0"
version = "0.7.0"
description = "Tool for assisting with the analysis and setup of VASP calculations."
authors = [
"VASP Software GmbH <[email protected]>",
Expand All @@ -11,33 +11,36 @@ authors = [
]
license = "Apache-2.0"
readme = "README.md"
homepage = "https://vasp.at/py4vasp"
homepage = "https://vasp.at/py4vasp/latest"
repository = "https://github.com/vasp-dev/py4vasp"

[tool.poetry.urls]
"Support Forum" = "https://vasp.at/forum/"

[tool.poetry.dependencies]
python = "^3.8"
numpy = "^1.23.0"
h5py = "^3.7.0"
pandas = "^1.4.3"
nglview = "^3.0.3"
ase = "^3.22.1"
mdtraj = "!=1.9.7,^1.9.6"
mrcfile = "^1.3.0"
plotly = "^5.9.0"
kaleido = "!=0.2.1.post1,^0.2.1"
# We actually do not want the <4 restriction here. This is due to requests 2.28.2 having
# this restriction, which will hopefully be released in a future release there
#python = ">=3.8"
python = ">=3.8,<4"
numpy = ">=1.23.0"
h5py = ">=3.7.0"
pandas = ">=1.4.3"
nglview = ">=3.0.3"
ase = ">=3.22.1"
mdtraj = "!=1.9.7,>=1.9.6"
mrcfile = ">=1.3.0"
plotly = ">=5.9.0"
kaleido = "!=0.2.1.post1,>=0.2.1"

[tool.poetry.dev-dependencies]
pytest = "^7.1.2"
pytest-cov = "^3.0.0"
pylint = "^2.14.3"
Sphinx = "^5.0.2"
black = "^22.6.0"
hypothesis = "^6.48.1"
isort = "^5.10.1"
sphinx-automodapi = "^0.14.1"
pytest = ">=7.1.2"
pytest-cov = ">=3.0.0"
pylint = ">=2.14.3"
Sphinx = ">=5.0.2"
black = ">=22.6.0"
hypothesis = ">=6.48.1"
isort = ">=5.10.1"
sphinx-automodapi = ">=0.14.1"

[tool.poetry.scripts]
error-analysis = "py4vasp.scripts.error_analysis:main"
Expand Down
2 changes: 1 addition & 1 deletion src/py4vasp/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
from py4vasp._third_party.graph import plot
from py4vasp._third_party.interactive import set_error_handling

__version__ = "0.6.0"
__version__ = "0.7.0"
set_error_handling("Minimal")
25 changes: 13 additions & 12 deletions src/py4vasp/_calculation.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,5 @@
# Copyright © VASP Software GmbH,
# Licensed under the Apache License 2.0 (http://www.apache.org/licenses/LICENSE-2.0)
"""Provide the tools to manage VASP calculations.
This is the main user interface if you want to simply investigate the results of VASP
calculations. Create a Calculation object associated with the VASP calculation that you
run. Then you can access the properties of that calculation via the attributes of the
object. For example you may use
>>> calc = Calculation.from_path("path_to_your_calculation")
>>> calc.dos.plot() # to plot the density of states
>>> calc.magnetism.read() # to read the magnetic moments
>>> calc.structure.print() # to print the structure in a POSCAR format
"""
import inspect
import pathlib

Expand All @@ -22,6 +10,19 @@
class Calculation:
"""Manage access to input and output of VASP calculations.
This is the main user interface if you want to simply investigate the results of VASP
calculations. Create a Calculation object associated with the VASP calculation that you
run. Then you can access the properties of that calculation via the attributes of the
object.
Examples
--------
>>> calc = Calculation.from_path("path_to_your_calculation")
>>> calc.dos.plot() # to plot the density of states
>>> calc.magnetism.read() # to read the magnetic moments
>>> calc.structure.print() # to print the structure in a POSCAR format
Notes
-----
To create new instances, you should use the classmethod :meth:`from_path` or
Expand Down

0 comments on commit c9aaaed

Please sign in to comment.