References
-
Time evolution algorithm of MPS
Population dynamics
-
Spectroscopy
Anharmonic potential
Local mode vibration
-
Grid-based MPO
DVR-MPS
nMR
-
MCTDH paper
DVR is also written.
Installation
The easiest way to install
pytdscf
is to usepip
.Prepare Python 3.10 or later and execute;
$ python -m venv pytdscf-env $ source pytdscf-env/bin/activate $ pip install git+https://github.com/QCLovers/PyTDSCF
We recommend install
pytdscf
from source using uv$ git clone https://github.com/QCLovers/PyTDSCF.git $ cd PyTDSCF $ uv version uv 0.5.4 (c62c83c37 2024-11-20) $ uv sync --all-extras
will install all dependencies including development tools. If you need only the runtime dependencies, you can use
uv sync --no-dev
.Then, you can execute
pytdscf
by$ uv run python xxx.py
or
$ souce .venv/bin/activate $ python >>> import pytdscf
For jupyter notebook tutorials, you can use
$ uv run jupyter lab
For GPU users
pytdscf
works both on CPU and GPU. If you treat large-scale batch or
model, we recommend using GPU. See also JAX’s GPU
support.
Make sure the latest NVIDIA driver is installed.
$ /usr/local/cuda/bin/nvcc -V nvcc: NVIDIA (R) Cuda compiler driver Copyright (c) 2005-2024 NVIDIA Corporation Built on Wed_Apr_17_19:19:55_PDT_2024 Cuda compilation tools, release 12.5, V12.5.40 Build cuda_12.5.r12.5/compiler.34177558_0
Install GPU-supported JAX in your virtual envirionment.
$ uv pip install -U "jax[cuda12]" $ uv run python -c "import jax; print(jax.default_backend())" 'gpu'
Testing
$ cd tests/build
$ uv run pytest ..
For developers
You should install pre-commit hooks including ruff formatting and linting, mypy type checking, pytest testing, and so on.
$ uv run pre-commit install
$ git add .
$ uv run pre-commit
Before push, you must fix problems!!
Please feel free to give us feedback or pull requests.
How to run
See quick-start example in
documentation
or test
directory.