Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/statphysandml/MCMCEvaluationLib
Python library for the evaluation of simulation data. The library provides functionalities to load simulation results into Python, to perform standard evaluation algorithms for Markov Chain Monte Carlo algorithms. It further can be used to generate a pytorch dataset from the simulation data.
https://github.com/statphysandml/MCMCEvaluationLib
markov-chain-monte-carlo numerics pytorch-dataset statistics
Last synced: 29 days ago
JSON representation
Python library for the evaluation of simulation data. The library provides functionalities to load simulation results into Python, to perform standard evaluation algorithms for Markov Chain Monte Carlo algorithms. It further can be used to generate a pytorch dataset from the simulation data.
- Host: GitHub
- URL: https://github.com/statphysandml/MCMCEvaluationLib
- Owner: statphysandml
- License: mit
- Created: 2020-12-17T17:21:10.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2024-06-01T14:39:37.000Z (7 months ago)
- Last Synced: 2024-08-06T21:21:09.683Z (5 months ago)
- Topics: markov-chain-monte-carlo, numerics, pytorch-dataset, statistics
- Language: Python
- Homepage:
- Size: 45.9 KB
- Stars: 4
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
MCMCEvaluationLib
=================The MCMCEvaluationLib is a Python library that implements important algorithms for an evaluation of results of a Markov Chain Monte Carlo algorithms. This includes the computation of expectation values, error estimation and the computation of the autocorrelation time. The library is used by the MCMCSimulationLib (https://github.com/statphysandml/MCMCSimulationLib) which provides generic code for Markov Chain Monte Carlo algorithms in C++. Further, the library enables an easy loading of the simulation data and provides a convenient way to convert the data into a PyTorch dataset.
The library currently consists of the following main modules:
- **loading** - Class for loading the simulation data. The simulation data is assumed to be stored columns wise in a .txt file. The ConfigurationLoader supports a simultaneous loading from multiple files and a piecewise loading (chunk by chunk).
- **modes** - Code that is used by the C++ MCMCSimulationLib for the computation of expectation values and further important results of a Markov Chain Monte Carlo Simulation.
- **pytorch** - Classes for a generation of a dataset consisting of samples/configurations of a Markov Chain Monte Carlo simulation. A possible batch-wise loading of the data boosts the computationl performance of the loading process. Samples of simulations with different hyperparameters can be mixed and loaded simultaneously.Examples
--------Examples to the different Python modules can be found here: https://github.com/statphysandml/MCMCSimulationLib/tree/master/examples/python_scripts/examples. Simulation results of the Ising model are discussed as a more detailed example here: https://github.com/statphysandml/MCMCSimulationLib/blob/master/examples/jupyter_notebooks/ising_model_cheat_sheet.ipynb. The example covers almost all functionalities of the library and shows additionally possible ways to make use of the pystatplottools library (https://github.com/statphysandml/pystatplottools) to analyse the data in more detail.
Integration
-----------So far, the library needs to be build locally. This can be done by
```bash
cd path_to_mcmcevaluationlib/python setup.py sdist
pip install -e .
```For virtual enviroments, the library needs to be activate beforehand.
After this step, the different modules of the library can be used, for example, by
```python
import mcmctoolsfrom mcmctools.pytorch.data_generation.configdatagenerator import ConfigDataGenerator
```Dependencies
------------- matplotlib
- numpy
- pandas (version >= 1.1)
- scipy
- pytorch
- (jupyter lab)- pystatplottools (https://github.com/statphysandml/pystatplottools)
Projects using the MCMCEvaluationLib
----------------------------------- MCMCSimulationLib (https://github.com/statphysandml/MCMCSimulationLib)
- LatticeModelSimulationLib (https://github.com/statphysandml/LatticeModelSimulationLib)
- LatticeModelImplementations (https://github.com/statphysandml/LatticeModelImplementations)Support and Development
----------------------For bug reports/suggestions/complaints please file an issue on GitHub.
Or start a discussion on our mailing list: [email protected]