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

bump LAMMPS version to stable_2Aug2023_update1 #2859

Merged
merged 1 commit into from
Sep 25, 2023
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.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 1 addition & 2 deletions backend/dynamic_metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,7 @@ def dynamic_metadata(
"sphinxcontrib-bibtex",
],
"lmp": [
"lammps~=2023.8.2.0.0; platform_system=='Linux'",
"lammps~=2023.8.2.0.0; platform_system!='Linux'",
"lammps~=2023.8.2.1.0",
*find_libpython_requires,
],
"ipi": [
Expand Down
18 changes: 9 additions & 9 deletions doc/install/install-lammps.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ make lammps
DeePMD-kit will generate a module called `USER-DEEPMD` in the `build` directory, which supports either double or single float precision interface. Now download the LAMMPS code, and uncompress it.
```bash
cd /some/workspace
wget https://github.com/lammps/lammps/archive/stable_2Aug2023.tar.gz
tar xf stable_2Aug2023.tar.gz
wget https://github.com/lammps/lammps/archive/stable_2Aug2023_update1.tar.gz
tar xf stable_2Aug2023_update1.tar.gz
```
The source code of LAMMPS is stored in the directory `lammps-stable_2Aug2023`. Now go into the LAMMPS code and copy the DeePMD-kit module like this
The source code of LAMMPS is stored in the directory `lammps-stable_2Aug2023_update1`. Now go into the LAMMPS code and copy the DeePMD-kit module like this
```bash
cd lammps-stable_2Aug2023/src/
cd lammps-stable_2Aug2023_update1/src/
cp -r $deepmd_source_dir/source/build/USER-DEEPMD .
make yes-kspace
make yes-extra-fix
Expand All @@ -46,15 +46,15 @@ Starting from `8Apr2021`, LAMMPS also provides a plugin mode, allowing one to bu
Now download the LAMMPS code (`8Apr2021` or later), and uncompress it:
```bash
cd /some/workspace
wget https://github.com/lammps/lammps/archive/stable_2Aug2023.tar.gz
tar xf stable_2Aug2023.tar.gz
wget https://github.com/lammps/lammps/archive/stable_2Aug2023_update1.tar.gz
tar xf stable_2Aug2023_update1.tar.gz
```

The source code of LAMMPS is stored in the directory `lammps-stable_2Aug2023`. The directory of the source code should be specified as the CMAKE argument `LAMMPS_SOURCE_ROOT` during installation of the DeePMD-kit C++ interface. Now go into the LAMMPS directory and create a directory called `build`
The source code of LAMMPS is stored in the directory `lammps-stable_2Aug2023_update1`. The directory of the source code should be specified as the CMAKE argument `LAMMPS_SOURCE_ROOT` during installation of the DeePMD-kit C++ interface. Now go into the LAMMPS directory and create a directory called `build`

```bash
mkdir -p lammps-stable_2Aug2023/build/
cd lammps-stable_2Aug2023/build/
mkdir -p lammps-stable_2Aug2023_update1/build/
cd lammps-stable_2Aug2023_update1/build/
```
Now build LAMMPS. Note that `PLUGIN` and `KSPACE` packages must be enabled, and `BUILD_SHARED_LIBS` must be set to `yes`. You can install any other package you want.
```bash
Expand Down
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ manylinux-x86_64-image = "quay.io/pypa/manylinux_2_28_x86_64:2022-11-19-1b19e81"
manylinux-aarch64-image = "quay.io/pypa/manylinux_2_28_aarch64:2022-11-19-1b19e81"

[tool.cibuildwheel.macos]
environment = { PIP_PREFER_BINARY="1", DP_LAMMPS_VERSION="stable_2Aug2023", DP_ENABLE_IPI="1" }
environment = { PIP_PREFER_BINARY="1", DP_LAMMPS_VERSION="stable_2Aug2023_update1", DP_ENABLE_IPI="1" }
before-all = [
"""if [[ "$CIBW_BUILD" != *macosx_arm64* ]]; then brew install mpich; fi""",
]
Expand All @@ -129,7 +129,7 @@ repair-wheel-command = """if [[ "$CIBW_BUILD" == *macosx_arm64* ]]; then rm -rf
[tool.cibuildwheel.linux]
repair-wheel-command = "auditwheel repair --exclude libtensorflow_framework.so.2 --exclude libtensorflow_framework.so.1 --exclude libtensorflow_framework.so --exclude _pywrap_tensorflow_internal.so --exclude libtensorflow_cc.so.2 -w {dest_dir} {wheel}"
environment-pass = ["CIBW_BUILD", "DP_VARIANT"]
environment = { PIP_PREFER_BINARY="1", DP_VARIANT="cuda", DP_LAMMPS_VERSION="stable_2Aug2023", DP_ENABLE_IPI="1", MPI_HOME="/usr/lib64/mpich", PATH="/usr/lib64/mpich/bin:$PATH" }
environment = { PIP_PREFER_BINARY="1", DP_VARIANT="cuda", DP_LAMMPS_VERSION="stable_2Aug2023_update1", DP_ENABLE_IPI="1", MPI_HOME="/usr/lib64/mpich", PATH="/usr/lib64/mpich/bin:$PATH" }
before-all = [
"""{ if [ "$(uname -m)" = "x86_64" ] ; then curl https://developer.download.nvidia.com/compute/cuda/11.8.0/local_installers/cuda_11.8.0_520.61.05_linux.run -O && bash cuda_11.8.0_520.61.05_linux.run --silent --toolkit; fi }""",
"yum install -y mpich-devel",
Expand Down
2 changes: 1 addition & 1 deletion source/install/build_cc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ NPROC=$(nproc --all)
BUILD_TMP_DIR=${SCRIPT_PATH}/../build
mkdir -p ${BUILD_TMP_DIR}
cd ${BUILD_TMP_DIR}
cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_PREFIX} -DUSE_TF_PYTHON_LIBS=TRUE ${CUDA_ARGS} -DLAMMPS_VERSION=stable_2Aug2023 ..
cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_PREFIX} -DUSE_TF_PYTHON_LIBS=TRUE ${CUDA_ARGS} -DLAMMPS_VERSION=stable_2Aug2023_update1 ..
cmake --build . -j${NPROC}
cmake --install .

Expand Down
2 changes: 1 addition & 1 deletion source/install/build_from_c.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ NPROC=$(nproc --all)
BUILD_TMP_DIR=${SCRIPT_PATH}/../build
mkdir -p ${BUILD_TMP_DIR}
cd ${BUILD_TMP_DIR}
cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_PREFIX} -DDEEPMD_C_ROOT=${DEEPMD_C_ROOT} -DLAMMPS_VERSION=stable_2Aug2023 ..
cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_PREFIX} -DDEEPMD_C_ROOT=${DEEPMD_C_ROOT} -DLAMMPS_VERSION=stable_2Aug2023_update1 ..
cmake --build . -j${NPROC}
cmake --install .
cmake --build . --target=lammps
Expand Down
2 changes: 1 addition & 1 deletion source/install/build_lammps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ BUILD_TMP_DIR=${SCRIPT_PATH}/../build_lammps
mkdir -p ${BUILD_TMP_DIR}
cd ${BUILD_TMP_DIR}
# download LAMMMPS
LAMMPS_VERSION=stable_2Aug2023
LAMMPS_VERSION=stable_2Aug2023_update1
if [ ! -d "lammps-${LAMMPS_VERSION}" ]; then
curl -L -o lammps.tar.gz https://github.com/lammps/lammps/archive/refs/tags/${LAMMPS_VERSION}.tar.gz
tar vxzf lammps.tar.gz
Expand Down
2 changes: 1 addition & 1 deletion source/install/test_cc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ INSTALL_PREFIX=${SCRIPT_PATH}/../../dp_test
BUILD_TMP_DIR=${SCRIPT_PATH}/../build_tests
mkdir -p ${BUILD_TMP_DIR}
cd ${BUILD_TMP_DIR}
cmake -DINSTALL_TENSORFLOW=TRUE -DCMAKE_INSTALL_PREFIX=${INSTALL_PREFIX} -DTENSORFLOW_ROOT=${INSTALL_PREFIX} -DBUILD_TESTING:BOOL=TRUE -DLAMMPS_VERSION=stable_2Aug2023 ${CUDA_ARGS} ..
cmake -DINSTALL_TENSORFLOW=TRUE -DCMAKE_INSTALL_PREFIX=${INSTALL_PREFIX} -DTENSORFLOW_ROOT=${INSTALL_PREFIX} -DBUILD_TESTING:BOOL=TRUE -DLAMMPS_VERSION=stable_2Aug2023_update1 ${CUDA_ARGS} ..
cmake --build . -j${NPROC}
cmake --install .
ctest --output-on-failure
2 changes: 1 addition & 1 deletion source/install/test_cc_local.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ INSTALL_PREFIX=${SCRIPT_PATH}/../../dp_test
BUILD_TMP_DIR=${SCRIPT_PATH}/../build_tests
mkdir -p ${BUILD_TMP_DIR}
cd ${BUILD_TMP_DIR}
cmake -DINSTALL_TENSORFLOW=FALSE -DUSE_TF_PYTHON_LIBS=TRUE -DCMAKE_INSTALL_PREFIX=${INSTALL_PREFIX} -DBUILD_TESTING:BOOL=TRUE -DLAMMPS_VERSION=stable_2Aug2023 ${CUDA_ARGS} ..
cmake -DINSTALL_TENSORFLOW=FALSE -DUSE_TF_PYTHON_LIBS=TRUE -DCMAKE_INSTALL_PREFIX=${INSTALL_PREFIX} -DBUILD_TESTING:BOOL=TRUE -DLAMMPS_VERSION=stable_2Aug2023_update1 ${CUDA_ARGS} ..
cmake --build . -j${NPROC}
cmake --install .
ctest --output-on-failure