Skip to content

Commit

Permalink
website restructured; plot.particles and plot.fields type hint corrected
Browse files Browse the repository at this point in the history
  • Loading branch information
hechtprojects committed Oct 22, 2024
1 parent b901ad2 commit 03ff184
Show file tree
Hide file tree
Showing 12 changed files with 26 additions and 519 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ simulation data.


| Observable | Particles | Fields |
|:----------:|:---------:|:------:|
|:-----------|:---------:|:------:|
| **Spatial Correlation Functions:** |||
| RDF (radial pair distribution function) |||
| PCF2d (2d pair correlation function) |||
Expand Down
13 changes: 2 additions & 11 deletions amep/load.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
import os
import h5py

from .reader import LammpsReader, H5amepReader, ContinuumReader, GSDReader
from .reader import LammpsReader, H5amepReader, ContinuumReader
from .trajectory import ParticleTrajectory,FieldTrajectory
from .base import TRAJFILENAME, BaseEvalData, BaseDatabase, LOADMODES
from .base import check_path, get_module_logger
Expand Down Expand Up @@ -226,16 +226,7 @@ def traj(
**kwargs
)
return FieldTrajectory(reader)
elif mode == 'gsd':
reader = GSDReader(
directory,
savedir,
trajfile = trajfile,
deleteold = deleteold,
verbose = verbose,
**kwargs
)
return ParticleTrajectory(reader)

# here one has to check both the amep version with which the file has been
# created (reader.version) and the data type (particles or fields) -
# the latter is needed to decide whether a ParticleTrajectory or a
Expand Down
4 changes: 2 additions & 2 deletions amep/plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -909,7 +909,7 @@ def box(axis: mpl.axes.Axes, box_boundary: np.ndarray, **kwargs) -> None:


def particles(
ax: mpl.axes, coords: np.ndarray, box_boundary: np.ndarray,
ax: mpl.axes.Axes, coords: np.ndarray, box_boundary: np.ndarray,
radius: np.ndarray | float, scalefactor: float = 1.0,
values: np.ndarray | None = None,
cmap: list | str = 'viridis', set_ax_limits: bool = True,
Expand Down Expand Up @@ -1081,7 +1081,7 @@ def particles(


def field(
ax: mpl.axes, density: np.ndarray, X: np.ndarray, Y: np.ndarray,
ax: mpl.axes.Axes, density: np.ndarray, X: np.ndarray, Y: np.ndarray,
cmap: list | str = 'plasma', box_boundary: np.ndarray | None = None,
vmin: float | None = None, vmax: float | None = None,
cscale: str = 'lin', verbose: bool = False, **kwargs
Expand Down
470 changes: 1 addition & 469 deletions amep/reader.py

Large diffs are not rendered by default.

18 changes: 13 additions & 5 deletions doc/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
project = 'AMEP'
copyright = '2023-2024, Lukas Hecht, Kay-Robert Dormann, Kai Luca Spanheimer'
author = 'Lukas Hecht, Kay-Robert Dormann, Kai Luca Spanheimer'
release = '1.0.2'
release = '1.0.3'

# -- General configuration ---------------------------------------------------
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration
Expand Down Expand Up @@ -51,7 +51,7 @@
"url": "https://github.com/amepproject/amep", # required
# Icon class (if "type": "fontawesome"), or path to local image (if "type": "local")
"icon": "fa-brands fa-square-github",
# The type of image to be used (see below for details)
# The type of image to be used
"type": "fontawesome",
},
{
Expand All @@ -61,8 +61,16 @@
"url": "https://pypi.org/project/amep/", # required
# Icon class (if "type": "fontawesome"), or path to local image (if "type": "local")
"icon": "fa-brands fa-python",
# The type of image to be used (see below for details)
# The type of image to be used
"type": "fontawesome",
}
]
}
],
#"switcher": {
# "json_url": "https://amepproject.de/switcher.json",
# "version_match": release
#},
#"check_switcher": True,
#"navbar_persistent": ["search-button.html", "theme-switcher.html"],
#"navbar_end": ["version-switcher.html", "icon-links.html"]
# "navbar_start": ["navbar_logo", "version-switcher"]
}
20 changes: 0 additions & 20 deletions doc/source/datastructures/particle_data_reader.md

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
=====================
How to cite **AMEP**
=====================
============
How to Cite
============

If you use **AMEP** for a project that leads to a scientific publication, please acknowledge
the use of **AMEP** within the body of your publication for example by copying or adapting
Expand Down
6 changes: 3 additions & 3 deletions doc/source/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
:align: center


AMEP documentation
==================
AMEP 1.0.3 documentation
========================

.. include:: ../../README.md
:parser: myst_parser.sphinx_
Expand All @@ -17,7 +17,7 @@ Table of Contents
:maxdepth: 2

gettingstarted/index
datastructures/index
howto_cite
user_guide/index
api

Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,3 @@ the sections below.
.. toctree::

field_data

.. toctree::

particle_data_reader
2 changes: 1 addition & 1 deletion doc/source/user_guide/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ your research.

.. toctree::

howto_cite
datastructures/index

.. toctree::

Expand Down

0 comments on commit 03ff184

Please sign in to comment.