atooms


Nameatooms JSON
Version 3.22.1 PyPI version JSON
download
home_pagehttps://framagit.org/atooms/atooms
SummaryA framework for simulations of interacting particles
upload_time2024-10-13 20:35:51
maintainerNone
docs_urlNone
authorDaniele Coslovich
requires_pythonNone
licenseGPLv3
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            Atooms
======

[![pypi](https://img.shields.io/pypi/v/atooms.svg)](https://pypi.python.org/pypi/atooms/)
[![version](https://img.shields.io/pypi/pyversions/atooms.svg)](https://pypi.python.org/pypi/atooms/)
[![license](https://img.shields.io/pypi/l/atooms.svg)](https://en.wikipedia.org/wiki/GNU_General_Public_License)
[![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/git/https%3A%2F%2Fframagit.org%2Fatooms%2Fatooms/HEAD?labpath=docs%2F)
[![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.1183301.svg)](https://doi.org/10.5281/zenodo.1183301)
[![pipeline](https://framagit.org/atooms/atooms/badges/master/pipeline.svg)](https://framagit.org/atooms/atooms/badges/master/pipeline.svg)
[![coverage report](https://framagit.org/atooms/atooms/badges/master/coverage.svg)](https://framagit.org/atooms/atooms/-/commits/master)

**atooms** is a high-level Python framework for simulations of interacting particles, such as molecular dynamics or Monte Carlo.

This is the core package: it provides a consistent interface to the basic objects of particle-based simulations. [Feature packages](Feature packages) are built on top of it and implement complex simulation methods and analysis tools.

Quick start
-----------

Here is a small example for setting up a mixture of two types of particles, A and B, in a periodic elongated cell. The number density is set to unity.
```python
from atooms.system import System

system = System(N=64)
system.replicate(times=4, axis=0)
system.composition = {'A': 128, 'B': 128}
system.density = 1.0
```

Particles in the central part of the cell get a random displacement and are folded back into the simulation cell
```python
import numpy

for p in system.particle:
    if abs(p.position[0]) < system.cell.side[0] / 4:
        p.position += 0.5 * (numpy.random.random() - 0.5)
        p.fold(system.cell)
system.show('ovito')
```

![](https://framagit.org/atooms/atooms/-/raw/master/snapshot.png)

Simulation data are stored in trajectory files, which are easy to manipulate and convert with atooms. Here, we write the system species and positions in a single-frame trajectory file using the [xyz format](https://en.wikipedia.org/wiki/XYZ_format).
```python
from atooms.trajectory import TrajectoryXYZ

with TrajectoryXYZ('input.xyz', 'w') as th:
    th.variables = ['species', 'position']  # actually, this is the default
    th.write(system)
```

The trajectory file can now be used to start a simulation using one the available [simulation backends](https://atooms.frama.io/atooms/tutorial/simulations.html) or your own code.

Features
--------

- Focus on a simple and expressive interface
- API refined over the years towards consistency
- Modular and extensible design via namespace packages
- Semantic versioning - for what is worth
- Easy to interface: in-house codes and custom formats are first-class citizens
- Support for efficient simulation backends, with a focus on GPU codes

Documentation
-------------
Check out the [tutorial](https://atooms.frama.io/atooms/tutorial) for more examples and the [public API](https://atooms.frama.io/atooms/api/atooms) for more details.

Org-mode and jupyter notebooks are available under [docs](https://framagit.org/atooms/atooms/-/blob/master/docs/). You can run them interactively on [Binder](https://mybinder.org/v2/git/https%3A%2F%2Fframagit.org%2Fatooms%2Fatooms/HEAD?labpath=docs%2).

Installation
------------
From the python package index
```
pip install atooms
```

From the code repository
```
git clone https://framagit.org/atooms/atooms.git
cd atooms
make install
```

Contributing
------------
You are welcome to contribute to this project! Please have a look at [these guidelines](https://framagit.org/atooms/atooms/-/blob/master/CONTRIBUTING.md).

Feature packages 
------------------
Atooms is modular: it is easy to add new functionalities, and just those you actually need.

Feature packages are available from the [atooms main repository](https://framagit.org/atooms). They are installed in the `atooms` namespace to prevent name clashing. If you want to add your own feature package to the atooms namespace, structure it this way
```bash
atooms/your_package
atooms/your_package/__init__.py
```

where ```__init__.py``` contains

```python
from pkgutil import extend_path
__path__ = extend_path(__path__, __name__)
```

Install `your_package` and you are ready to go
```python
import atooms.your_package
```

Authors
-------
Daniele Coslovich: https://www.units.it/daniele.coslovich/

Thanks go to Francesco Turci and Geert Kapteijns for their contributions.


            

Raw data

            {
    "_id": null,
    "home_page": "https://framagit.org/atooms/atooms",
    "name": "atooms",
    "maintainer": null,
    "docs_url": null,
    "requires_python": null,
    "maintainer_email": null,
    "keywords": null,
    "author": "Daniele Coslovich",
    "author_email": "daniele.coslovich@umontpellier.fr",
    "download_url": null,
    "platform": null,
    "description": "Atooms\n======\n\n[![pypi](https://img.shields.io/pypi/v/atooms.svg)](https://pypi.python.org/pypi/atooms/)\n[![version](https://img.shields.io/pypi/pyversions/atooms.svg)](https://pypi.python.org/pypi/atooms/)\n[![license](https://img.shields.io/pypi/l/atooms.svg)](https://en.wikipedia.org/wiki/GNU_General_Public_License)\n[![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/git/https%3A%2F%2Fframagit.org%2Fatooms%2Fatooms/HEAD?labpath=docs%2F)\n[![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.1183301.svg)](https://doi.org/10.5281/zenodo.1183301)\n[![pipeline](https://framagit.org/atooms/atooms/badges/master/pipeline.svg)](https://framagit.org/atooms/atooms/badges/master/pipeline.svg)\n[![coverage report](https://framagit.org/atooms/atooms/badges/master/coverage.svg)](https://framagit.org/atooms/atooms/-/commits/master)\n\n**atooms** is a high-level Python framework for simulations of interacting particles, such as molecular dynamics or Monte Carlo.\n\nThis is the core package: it provides a consistent interface to the basic objects of particle-based simulations. [Feature packages](Feature packages) are built on top of it and implement complex simulation methods and analysis tools.\n\nQuick start\n-----------\n\nHere is a small example for setting up a mixture of two types of particles, A and B, in a periodic elongated cell. The number density is set to unity.\n```python\nfrom atooms.system import System\n\nsystem = System(N=64)\nsystem.replicate(times=4, axis=0)\nsystem.composition = {'A': 128, 'B': 128}\nsystem.density = 1.0\n```\n\nParticles in the central part of the cell get a random displacement and are folded back into the simulation cell\n```python\nimport numpy\n\nfor p in system.particle:\n    if abs(p.position[0]) < system.cell.side[0] / 4:\n        p.position += 0.5 * (numpy.random.random() - 0.5)\n        p.fold(system.cell)\nsystem.show('ovito')\n```\n\n![](https://framagit.org/atooms/atooms/-/raw/master/snapshot.png)\n\nSimulation data are stored in trajectory files, which are easy to manipulate and convert with atooms. Here, we write the system species and positions in a single-frame trajectory file using the [xyz format](https://en.wikipedia.org/wiki/XYZ_format).\n```python\nfrom atooms.trajectory import TrajectoryXYZ\n\nwith TrajectoryXYZ('input.xyz', 'w') as th:\n    th.variables = ['species', 'position']  # actually, this is the default\n    th.write(system)\n```\n\nThe trajectory file can now be used to start a simulation using one the available [simulation backends](https://atooms.frama.io/atooms/tutorial/simulations.html) or your own code.\n\nFeatures\n--------\n\n- Focus on a simple and expressive interface\n- API refined over the years towards consistency\n- Modular and extensible design via namespace packages\n- Semantic versioning - for what is worth\n- Easy to interface: in-house codes and custom formats are first-class citizens\n- Support for efficient simulation backends, with a focus on GPU codes\n\nDocumentation\n-------------\nCheck out the [tutorial](https://atooms.frama.io/atooms/tutorial) for more examples and the [public API](https://atooms.frama.io/atooms/api/atooms) for more details.\n\nOrg-mode and jupyter notebooks are available under [docs](https://framagit.org/atooms/atooms/-/blob/master/docs/). You can run them interactively on [Binder](https://mybinder.org/v2/git/https%3A%2F%2Fframagit.org%2Fatooms%2Fatooms/HEAD?labpath=docs%2).\n\nInstallation\n------------\nFrom the python package index\n```\npip install atooms\n```\n\nFrom the code repository\n```\ngit clone https://framagit.org/atooms/atooms.git\ncd atooms\nmake install\n```\n\nContributing\n------------\nYou are welcome to contribute to this project! Please have a look at [these guidelines](https://framagit.org/atooms/atooms/-/blob/master/CONTRIBUTING.md).\n\nFeature packages \n------------------\nAtooms is modular: it is easy to add new functionalities, and just those you actually need.\n\nFeature packages are available from the [atooms main repository](https://framagit.org/atooms). They are installed in the `atooms` namespace to prevent name clashing. If you want to add your own feature package to the atooms namespace, structure it this way\n```bash\natooms/your_package\natooms/your_package/__init__.py\n```\n\nwhere ```__init__.py``` contains\n\n```python\nfrom pkgutil import extend_path\n__path__ = extend_path(__path__, __name__)\n```\n\nInstall `your_package` and you are ready to go\n```python\nimport atooms.your_package\n```\n\nAuthors\n-------\nDaniele Coslovich: https://www.units.it/daniele.coslovich/\n\nThanks go to Francesco Turci and Geert Kapteijns for their contributions.\n\n",
    "bugtrack_url": null,
    "license": "GPLv3",
    "summary": "A framework for simulations of interacting particles",
    "version": "3.22.1",
    "project_urls": {
        "Homepage": "https://framagit.org/atooms/atooms"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "99ffa2bb27fad184e251baa7299ae99919a7c7c775073a3c2ba36acea9746287",
                "md5": "170f1dd5444f80b8516afcc0a8d71fa8",
                "sha256": "bc9baa9e51bdc76b4b2d9dd4aa47d7741a66806e8f8e0342728dc577810cfe83"
            },
            "downloads": -1,
            "filename": "atooms-3.22.1-py2.py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "170f1dd5444f80b8516afcc0a8d71fa8",
            "packagetype": "bdist_wheel",
            "python_version": "py2.py3",
            "requires_python": null,
            "size": 145807,
            "upload_time": "2024-10-13T20:35:51",
            "upload_time_iso_8601": "2024-10-13T20:35:51.038474Z",
            "url": "https://files.pythonhosted.org/packages/99/ff/a2bb27fad184e251baa7299ae99919a7c7c775073a3c2ba36acea9746287/atooms-3.22.1-py2.py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-10-13 20:35:51",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "atooms"
}
        
Elapsed time: 0.36707s