You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/quick_start/easy_install.md
+97-89Lines changed: 97 additions & 89 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# Easy Installation
2
2
3
-
This guide helps you install ABACUS with basic features. **For DeePKS, DeePMD and Libxc support, or building with `make`, please refer to [the advanced installation guide](../advanced/install.md)** after going through this page. We recommend building ABACUS with `cmake` to avoid dependency issues. We recommend compiling ABACUS (and possibly its requirements) from the source code using the latest compiler for the best performace. You can try[toolchain](#install-requirements-by-toolchain) to install ABACUS and dependencies in a source-code compilation way with convience. You can also deploy ABACUS **without building** by [Docker](#container-deployment) or [conda](#install-by-conda). Please note that ABACUS only supports Linux; for Windows users, please consider using [WSL](https://learn.microsoft.com/en-us/windows/wsl/) or docker.
3
+
This guide helps you install ABACUS with basic features. **For DeePKS, DeePMD and Libxc support, or building with `make`, please refer to [the advanced installation guide](../advanced/install.md)** after going through this page. We recommend building ABACUS with `cmake` to avoid dependency issues. We recommend compiling ABACUS (and possibly its requirements) from the source code using the latest compiler for the best performace. You can use[toolchain](#install-requirements-by-toolchain) to install ABACUS and dependencies in a source-code compilation way with convience. You can also deploy ABACUS **without building** by [Docker](#container-deployment) or [conda](#install-by-conda). Please note that ABACUS only supports Linux; for Windows users, please consider using [WSL](https://learn.microsoft.com/en-us/windows/wsl/) or docker.
4
4
5
5
## Get ABACUS source code
6
6
@@ -12,6 +12,34 @@ ABACUS source code can be obtained via one of the following choices:
12
12
- Get the source code of a stable version [here](https://github.com/deepmodeling/abacus-develop/releases)
13
13
- If you have connection issues accessing GitHub, please try out our official [Gitee repo](https://gitee.com/deepmodeling/abacus-develop/): e.g. `git clone https://gitee.com/deepmodeling/abacus-develop.git`. This Gitee repo is updated synchronously with GitHub.
14
14
15
+
## Update to latest release by git
16
+
17
+
Please check the [release page](https://github.com/deepmodeling/abacus-develop/releases) for the release note of a new version.
18
+
19
+
It is OK to download the new source code from beginning following the previous step.
20
+
21
+
You can update your cloned git repo (from Github or Gitee) in-place with the following commands:
We offer a set of [toolchain](https://github.com/deepmodeling/abacus-develop/tree/develop/toolchain)
68
+
scripts to compile and install all the requirements
69
+
automatically and suitable for machine characteristic in an online or offline way.
70
+
The toolchain can be downloaded with ABACUS repo, and users can easily compile the requirements by running *toolchain_[gnu,intel,gcc-aocl,aocc-aocl].sh* and ABACUS itself by running *build_abacus_[gnu,intel,gcc-aocl,aocc-aocl].sh* script in the toolchain directory in `GNU`, `Intel-oneAPI` , `GCC-AMD AOCL` and `AMD AOCC-AOCL` toolchain.
71
+
Sometimes, ABACUS by toolchain installation may have better efficient performance due to the suitable compiled dependencies. One should read the [README in toolchain](https://github.com/deepmodeling/abacus-develop/tree/develop/toolchain/README.md) for most of the information before use, and related tutorials can be accessed via ABACUS WeChat platform.
72
+
73
+
## Install by conda
38
74
39
-
Some of these packages can be installed with popular package management system, such as `apt` and `yum`:
75
+
Conda is a package management system with a separated environment, not requiring system privileges.
76
+
You can refer to [DeepModeling conda FAQ](https://docs.deepmodeling.com/faq/conda.html) for how to setup a conda environment.
77
+
A pre-built ABACUS binary with all requirements is available at [conda-forge](https://anaconda.org/conda-forge/abacus). It supports advanced features including Libxc, LibRI, and DeePKS. Conda will install the GPU-supported version of ABACUS if a valid GPU driver is present. Please refer to [the advanced installation guide](../advanced/install.md) for more details.
> Installing ELPA by apt only matches requirements on Ubuntu 22.04. For earlier linux distributions, you should build ELPA from source.
84
+
# Run
85
+
conda activate abacus_env
86
+
OMP_NUM_THREADS=1 mpirun -n 4 abacus
46
87
47
-
We recommend [Intel® oneAPI toolkit](https://software.intel.com/content/www/us/en/develop/tools/oneapi/commercial-base-hpc.html) (former Intel® Parallel Studio) as toolchain. The [Intel® oneAPI Base Toolkit](https://software.intel.com/content/www/us/en/develop/tools/oneapi/all-toolkits.html#base-kit) contains Intel® oneAPI Math Kernel Library (aka `MKL`), including `BLAS`, `LAPACK`, `ScaLAPACK` and `FFTW3`. The [Intel® oneAPI HPC Toolkit](https://software.intel.com/content/www/us/en/develop/tools/oneapi/all-toolkits.html#hpc-kit) contains Intel® MPI Library, and C++ compiler(including MPI compiler).
48
-
> Please note that building `elpa` with a different MPI library may cause conflict.
49
-
> Don't forget to [set environment variables](https://software.intel.com/content/www/us/en/develop/documentation/get-started-with-intel-oneapi-render-linux/top/configure-your-system.html) before you start! `cmake` will use Intel MKL if the environment variable `MKLROOT` is set.
88
+
# Update
89
+
conda update -n abacus_env abacus -c conda-forge
90
+
```
50
91
51
-
Please refer to our [guide](https://github.com/deepmodeling/abacus-develop/wiki/Building-and-Running-ABACUS) on installing requirements.
92
+
> If OpenBLAS gives warning about OpenMP threads, please install conda package `"openblas=*=openmp*"` or `"libblas=*=*mkl"`. See [switching BLAS implementation in conda](https://conda-forge.org/docs/maintainer/knowledge_base.html#switching-blas-implementation).
52
93
53
-
## Install requirements by toolchain
94
+
> ABACUS supports `OpenMPI` and `MPICH` variant. Install `mpich` or `openmpi` package to switch MPI library if required.
54
95
55
-
We offer a set of [toolchain](https://github.com/deepmodeling/abacus-develop/tree/develop/toolchain)
56
-
scripts to compile and install all the requirements
57
-
automatically and suitable for machine characteristic in an online or offline way.
58
-
The toolchain can be downloaded with ABACUS repo, and users can easily compile the requirements by running *toolchain_[gnu,intel].sh* and ABACUS itself by running *build_abacus_[gnu,intel].sh* script in the toolchain directory in both `GNU` and `Intel-oneAPI` toolchain.
59
-
Sometimes, ABACUS by toolchain installation may have better efficient performance due to the suitable compiled dependencies.
96
+
For more details on building a conda package of ABACUS locally, please refer to the [conda recipe file](https://github.com/deepmodeling/abacus-develop/blob/develop/conda/meta.yaml).
60
97
61
-
Users should read the README in toolchain directory for most of the information before use, and a tutorial for using this toolchain can be accessed in [bohrium-notebook](https://nb.bohrium.dp.tech/detail/5215742477) as reference.
98
+
> Note: The [deepmodeling conda channel](https://anaconda.org/deepmodeling/abacus) offers historical versions of ABACUS.
62
99
63
-
> Notice: the toolchain is under development, please let we know if you encounter any problem in using this toolchain by raising issue or contacting us.
100
+
### Developing with conda
64
101
102
+
It is possible to build ABACUS from source based on the conda environment.
> Installing ELPA by apt only matches requirements on Ubuntu 22.04. For earlier linux distributions, you should build ELPA from source.
133
+
134
+
We recommend [Intel® oneAPI toolkit](https://software.intel.com/content/www/us/en/develop/tools/oneapi/commercial-base-hpc.html) (former Intel® Parallel Studio) as toolchain. The [Intel® oneAPI Base Toolkit](https://software.intel.com/content/www/us/en/develop/tools/oneapi/all-toolkits.html#base-kit) contains Intel® oneAPI Math Kernel Library (aka `MKL`), including `BLAS`, `LAPACK`, `ScaLAPACK` and `FFTW3`. The [Intel® oneAPI HPC Toolkit](https://software.intel.com/content/www/us/en/develop/tools/oneapi/all-toolkits.html#hpc-kit) contains Intel® MPI Library, and C++ compiler(including MPI compiler).
135
+
> Please note that building `elpa` with a different MPI library may cause conflict.
136
+
> Don't forget to [set environment variables](https://software.intel.com/content/www/us/en/develop/documentation/get-started-with-intel-oneapi-render-linux/top/configure-your-system.html) before you start! `cmake` will use Intel MKL if the environment variable `MKLROOT` is set.
137
+
138
+
Please refer to our [guide](https://github.com/deepmodeling/abacus-develop/wiki/Building-and-Running-ABACUS) on installing requirements.
You can change the number after `-j` on your need: set to the number of CPU cores(`nproc`) to reduce compilation time.
152
198
153
-
## Run
199
+
## Run ABACUS
200
+
201
+
### Load ABACUS
154
202
155
203
If ABACUS is installed into a custom directory using `CMAKE_INSTALL_PREFIX`, please add it to your environment variable `PATH` to locate the correct executable.
156
204
*(Note: `my-install-dir` should be changed to the location of your installed abacus:`/home/your-path/abacus/bin/`.)*
@@ -165,6 +213,14 @@ If ABACUS is installed by toolchain, there will be an environment script in the
165
213
source /path/to/abacus/toolchain/abacus_env.sh
166
214
```
167
215
216
+
If ABACUS is installed by conda, please make sure the conda environment is activated before running ABACUS.
217
+
218
+
```bash
219
+
conda activate abacus_env
220
+
```
221
+
222
+
### Run with Parallelism Setting
223
+
168
224
Please set OpenMP threads by setting environment variable:
169
225
170
226
```bash
@@ -215,64 +271,16 @@ For online development environment, we support [GitHub Codespaces](https://githu
215
271
216
272
We also support [Gitpod](https://www.gitpod.io/): [Open in Gitpod](https://gitpod.io/#https://github.com/deepmodeling/abacus-develop)
217
273
218
-
## Install by conda
219
-
220
-
Conda is a package management system with a separated environment, not requiring system privileges.
221
-
You can refer to [DeepModeling conda FAQ](https://docs.deepmodeling.com/faq/conda.html) for how to setup a conda environment.
222
-
A pre-built ABACUS binary with all requirements is available at [conda-forge](https://anaconda.org/conda-forge/abacus). It supports advanced features including Libxc, LibRI, and DeePKS. Conda will install the GPU-supported version of ABACUS if a valid GPU driver is present. Please refer to [the advanced installation guide](../advanced/install.md) for more details.
223
-
224
-
```bash
225
-
# Install
226
-
# We recommend installing ABACUS in a new environment to avoid potential conflicts:
> If OpenBLAS gives warning about OpenMP threads, please install conda package `"openblas=*=openmp*"` or `"libblas=*=*mkl"`. See [switching BLAS implementation in conda](https://conda-forge.org/docs/maintainer/knowledge_base.html#switching-blas-implementation).
238
-
239
-
> ABACUS supports `OpenMPI` and `MPICH` variant. Install `mpich` or `openmpi` package to switch MPI library if required.
240
-
241
-
For more details on building a conda package of ABACUS locally, please refer to the [conda recipe file](https://github.com/deepmodeling/abacus-develop/blob/develop/conda/meta.yaml).
242
-
243
-
> Note: The [deepmodeling conda channel](https://anaconda.org/deepmodeling/abacus) offers historical versions of ABACUS.
244
-
245
-
### Developing with conda
246
-
247
-
It is possible to build ABACUS from source based on the conda environment.
# By default OpenBLAS is used; run `conda install "blas=*=mkl" mkl_fft mkl-devel -c conda-forge` to switch implementation.
255
-
export MKLROOT=$CONDA_PREFIX# If Intel MKL is required.
256
-
257
-
export CMAKE_PREFIX_PATH=`python -c 'import torch;print(torch.utils.cmake_prefix_path)'`:$CMAKE_PREFIX_PATH# If DEEPKS support is required;
258
-
# usually expands to `$CONDA_PREFIX/lib/python3.1/site-packages/torch/share/cmake`
259
-
```
260
-
261
-
And, follow the instructions in [Build and Install](#build-and-install) part above withou manually setting paths to dependencies.
262
-
See [the advanced installation guide](../advanced/install.md) for more features.
263
-
Make sure the environment variables are set before running `cmake`.
264
-
Possible command: `cmake -B build -DENABLE_MLALGO=ON -DENABLE_LIBXC=ON -DENABLE_LIBRI=ON`.
265
-
266
274
## Command line options
267
275
268
276
Users can check the version of ABACUS by running the command `abacus --version`, the result will be like:
269
277
```
270
-
ABACUS version v3.6.5
278
+
ABACUS version v3.9.0.2
271
279
```
272
280
273
281
Users may check the correctness of the setting of parameters in the `INPUT` file by running the command `abacus --check-input`, the result will be like:
274
282
```
275
-
ABACUS v3.6.5
283
+
ABACUS v3.9.0.2
276
284
277
285
Atomic-orbital Based Ab-initio Computation at UStc
0 commit comments