Skip to main content

2DMAT -- Data-analysis software of quantum beam diffraction experiments for 2D material structure

2DMAT is a framework for applying a search algorithm to a direct problem solver to find the optimal solution. As the standard direct problem solver, the experimental data analysis software for two-dimensional material structure analysis is prepared. The direct problem solver gives the deviation between the experimental data and the calculated data obtained under the given parameters such as atomic positions as a loss function used in the inverse problem. The optimal parameters are estimated by minimizing the loss function using a search algorithm. For further use, the original direct problem solver or the search algorithm can be defined by users. 2DMAT offers wrappers of direct problem solvers for some of quantum beam diffraction experiments such as the total-reflection high-energy positron diffraction (TRHEPD) experiment. As algorithms, it offers some minimizers such as the Nelder-Mead method and some samplers such as the population annealing Monte Carlo method. In the future, we plan to add other direct problem solvers and search algorithms in 2DMAT.

Branch Build status Documentation
master (latest, stable) master doc_en doc_ja
develop (latest, unstable) -- doc_en doc_ja

py2dmat

py2dmat is a python framework library for solving inverse problems. It also offers a driver script to solve the problem with predefined optimization algorithms and direct problem solvers (py2dmat also means this script).

Prerequists

  • Required
    • python >= 3.6.8
    • numpy >= 1.14
    • tomli >= 1.2.0
  • Optional
    • scipy
      • for minsearch algorithm
    • mpi4py
      • for exchange algorithm
    • physbo >= 1.0
      • for bayes algorithm

Install

  • From PyPI (Recommended)
    • python3 -m pip install -U py2dmat
      • If you install them locally, use --user option like python3 -m pip install -U --user
  • From Source (For developers)
    1. update pip >= 19 by python3 -m pip install -U pip
    2. python3 -m pip install 2DMAT_ROOT_DIRECTORY to install py2dmat package and py2dmat command
    • 2DMAT_ROOT_DIRECTORY means the directory including this README.md file.

Simple Usage

  • py2dmat input.toml (use the installed script)
  • python3 src/py2dmat_main.py input.toml (use the raw script)
  • For details of the input file, see the document.

Files and directories of 2DMAT

  • src/
    • source codes
  • script/
    • utility scripts
  • sample/
    • sample usages
  • doc/
    • source codes of documents (manuals)
  • tests/
    • for automatic test
  • LICENSE
    • license terms (GNU GPL v3)
  • README.md
    • this file
  • pyproject.toml
    • metadata for py2dmat

License

This package is distributed under GNU General Public License version 3 (GPL v3) or later.

We hope that you cite the following references when you publish the results using 2DMAT: “Data-analysis software framework 2DMAT and its application to experimental measurements for two-dimensional material structures”, Y. Motoyama, K. Yoshimi, I. Mochizuki, H. Iwamoto, H. Ichinose, and T. Hoshi, Computer Physics Communications 280, 108465 (2022).

Bibtex:

@article{MOTOYAMA2022108465, title = {Data-analysis software framework 2DMAT and its application to experimental measurements for two-dimensional material structures}, journal = {Computer Physics Communications}, volume = {280}, pages = {108465}, year = {2022}, issn = {0010-4655}, doi = {https://doi.org/10.1016/j.cpc.2022.108465}, url = {https://www.sciencedirect.com/science/article/pii/S0010465522001849}, author = {Yuichi Motoyama and Kazuyoshi Yoshimi and Izumi Mochizuki and Harumichi Iwamoto and Hayato Ichinose and Takeo Hoshi} }

Copyright

© 2020- The University of Tokyo. All rights reserved. This software was developed with the support of "Project for advancement of software usability in materials science" of The Institute for Solid State Physics, The University of Tokyo.

Metadata

Release files for py2dmat 2.2.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for py2dmat 2.2.1
File Size Uploaded
py2dmat-2.2.1.tar.gz 52.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for py2dmat 2.2.1
File Interpreter ABI Platform
py2dmat-2.2.1-py3-none-any.whl Python 3 none any Details

Total release size: 126.7 kB

Release files / py2dmat-2.2.1.tar.gz

Download URL py2dmat-2.2.1.tar.gz
Size 52.1 kB
Tags Source
SHA-256 checksum
How to use checksums
28005b3b192c78b1eaa00484c7400eae06c236fff613ea352132d1f08bd8b6be
BLAKE2b-256 checksum
How to use checksums
ffa9606aeff89b31b553230798621dc4c4afb37bc285cfe12256fa319f9f140f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.1.1 CPython/3.9.21 Linux/5.15.0-1079-azure

Release files / py2dmat-2.2.1-py3-none-any.whl

Download URL py2dmat-2.2.1-py3-none-any.whl
Size 74.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a5a46b695f97bf0437ec143fe126dd4ab14bf14316652f9908cb2ac3a5ccf1c9
BLAKE2b-256 checksum
How to use checksums
9d7a6a29fca87ea3b074a87fda23dd9380222595f6052eac901ed2f81b951c03
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.1.1 CPython/3.9.21 Linux/5.15.0-1079-azure

Release history Release notifications | RSS feed

This release

2.2.1 This release

2 release files

2.2.0

2 release files

2.1.0

2 release files

2.0.0

2 release files

1.0.1

2 release files

1.0.0

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page