Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update examples readmes and add citation #38

Merged
merged 2 commits into from
Jul 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,3 +76,14 @@ plt.show()
</p>


# Citation
If you use `thermox` in your research, please cite the library using the following BibTeX entry:

```bibtex
@misc{duffield2024thermox,
title={thermox: Exact OU processes with JAX},
author={Duffield, Samuel and Donatella, Kaelan and Melanson, Denis},
howpublished={\url{https://github.com/normal-computing/thermox}},
year={2024}
}
```
8 changes: 6 additions & 2 deletions examples/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
# Examples

You will find two Jupyter notebooks in this folder:
You will find three Jupyter notebooks in this folder:

- `associative_scan.ipynb` plots the speedup of the associative scan algorithm implemented in `thermox` using a GPU.
- `diffrax_comparison.ipynb` runs a simple OU process using `thermox` and [`diffrax`](https://github.com/patrick-kidger/diffrax) and compares runtimes (showing a large benefit from using `thermox` for long simulation times)
- `thermodynamic_linear_algebra.ipynb` is a small tutorial on how to use functions from the `thermox.linalg` module.
- `thermodynamic_linear_algebra.ipynb` is a small tutorial on how to use functions from the `thermox.linalg` module.

Additionally the `matrix_exponentials` folder contains code for reproducing the simulations
in the [thermodynamic matrix exponentials paper](https://arxiv.org/abs/2311.12759).
17 changes: 17 additions & 0 deletions examples/matrix_exponentials/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Thermodynamic Matrix Exponentials Simulations

This folder contains code to replicate the convergence time simulations in the
[thermodynamic matrix exponentials paper](https://arxiv.org/abs/2311.12759).

The script `run.py` contains the code to run the simulations and can be executed with
e.g. the following command from the root of the repository:
```bash
PYTHONPATH=. python examples/matrix_exponentials/run.py --n_repeats=10 --matrix_type=orthogonal --alpha=1.1
```
where `--matrix_type` represents a function in `matrix_generation.py`.

The script `plot.py` contains the code to plot the results of the simulations and can be executed with e.g. the following command from the root of the repository:
```bash
PYTHONPATH=. python examples/matrix_exponentials/plot.py --save_dir=examples/matrix_exponentials/results_orthogonal.pkl
```