https://github.com/bjmorgan/site-analysis

Analysing molecular dynamics simulations of crystalline materials using site occupations

https://github.com/bjmorgan/site-analysis

Science Score: 46.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
    Links to: joss.theoj.org
  • Committers with academic emails
    1 of 3 committers (33.3%) from academic institutions
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (14.6%) to scientific vocabulary
Last synced: 7 months ago · JSON representation

Repository

Analysing molecular dynamics simulations of crystalline materials using site occupations

Basic Info
  • Host: GitHub
  • Owner: bjmorgan
  • License: mit
  • Language: Python
  • Default Branch: main
  • Homepage:
  • Size: 12.8 MB
Statistics
  • Stars: 18
  • Watchers: 1
  • Forks: 4
  • Open Issues: 1
  • Releases: 16
Created over 6 years ago · Last pushed 7 months ago
Metadata Files
Readme Contributing License

README.md

site-analysis

Build Status Coverage Status Documentation Status PyPI version status

site-analysis is a Python module for analysing molecular dynamics simulations of solid-state ion transport, by assigning positions of mobile ions to specific “sites” within the host structure.

The code is built on top of pymatgen and takes VASP XDATCAR files as molecular dynamics trajectory inputs.

The code can use the following definitions for assigning mobile ions to sites: 1. Spherical cutoff: Atoms occupy a site if they lie within a spherical cutoff from a fixed position. 2. Voronoi decomposition: Atoms are assigned to sites based on a Voronoi decomposition of the lattice into discrete volumes. 3. Polyhedral decomposition: Atoms are assigned to sites based on occupation of polyhedra defined by the instantaneous positions of lattice atoms. 4. Dynamic Voronoi sites: Sites using Voronoi decomposition but with centres calculated dynamically based on framework atom positions.

Quick Start

```python from site_analysis.builders import TrajectoryBuilder from pymatgen.io.vasp import Xdatcar

Load MD trajectory from VASP XDATCAR file

xdatcar = Xdatcar("XDATCAR") md_structures = xdatcar.structures

Define multiple sites and track Li+ ion movements between them

trajectory = (TrajectoryBuilder() .withstructure(mdstructures[0]) # Use first frame as reference .withmobilespecies("Li") .withsphericalsites(centres=[[0.0, 0.0, 0.0], [0.5, 0.5, 0.5], [0.0, 0.5, 0.0]], radii=1.5) .build())

trajectory.trajectoryfromstructures(md_structures)

Get site occupancies over time

print(trajectory.atomstrajectory) # Which site each atom occupies print(trajectory.sitestrajectory) # Which atoms in each site ```

For detailed examples and tutorials, see the documentation.

Installation

Standard Installation

bash pip install site-analysis

Development Installation

For development or to access the latest features:

```bash

Clone the repository

git clone https://github.com/bjmorgan/site-analysis.git cd site-analysis

Install in development mode with dev dependencies

pip install -e ".[dev]" ```

Documentation

Complete documentation, including tutorials, examples, and API reference, is available at Read the Docs.

Testing

Automated testing of the latest build happens on GitHub Actions.

To run tests locally:

```bash

Using pytest (recommended)

pytest

Using unittest

python -m unittest discover ```

The code requires Python 3.10 or above.

Owner

  • Name: Benjamin Morgan
  • Login: bjmorgan
  • Kind: user
  • Location: Bath, UK
  • Company: University of Bath

Computational Chemistry at the University of Bath, UK.

GitHub Events

Total
  • Create event: 19
  • Issues event: 19
  • Release event: 17
  • Watch event: 8
  • Delete event: 9
  • Issue comment event: 1
  • Push event: 204
  • Pull request review event: 6
  • Pull request review comment event: 3
  • Pull request event: 26
Last Year
  • Create event: 19
  • Issues event: 19
  • Release event: 17
  • Watch event: 8
  • Delete event: 9
  • Issue comment event: 1
  • Push event: 204
  • Pull request review event: 6
  • Pull request review comment event: 3
  • Pull request event: 26

Committers

Last synced: about 3 years ago

All Time
  • Total Commits: 145
  • Total Committers: 3
  • Avg Commits per committer: 48.333
  • Development Distribution Score (DDS): 0.11
Top Committers
Name Email Commits
Benjamin Morgan b****2@g****m 129
Benjamin b****n@b****k 15
Benjamin Morgan B****n 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 11 months ago

All Time
  • Total issues: 0
  • Total pull requests: 2
  • Average time to close issues: N/A
  • Average time to close pull requests: 4 days
  • Total issue authors: 0
  • Total pull request authors: 2
  • Average comments per issue: 0
  • Average comments per pull request: 0.0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 1
  • Average time to close issues: N/A
  • Average time to close pull requests: about 10 hours
  • Issue authors: 0
  • Pull request authors: 1
  • Average comments per issue: 0
  • Average comments per pull request: 0.0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • bjmorgan (11)
Pull Request Authors
  • bjmorgan (13)
  • ChrisDavi3s (2)
  • PatrickJTaylor (1)
Top Labels
Issue Labels
enhancement (6) documentation (4) bug (2)
Pull Request Labels

Dependencies

docs/requirements.txt pypi
  • nbsphinx *
  • recommonmark *
  • sphinx >=1.6.3
  • sphinx-rtd-theme *
requirements.txt pypi
  • codeclimate-test-reporter *
  • coverage ==4.3.4
  • monty *
  • numpy *
  • pymatgen >=2022.0.3
  • scipy *
  • tqdm *
.github/workflows/build.yml actions
  • actions/checkout v2 composite
  • actions/setup-python v2 composite
  • coverallsapp/github-action 1.1.3 composite
setup.py pypi