Skip to content

Commit 69a9086

Browse files
Merge branch 'master' into D0814_debug_c_nlist
2 parents af2411d + 2b193ee commit 69a9086

759 files changed

Lines changed: 56369 additions & 10766 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.devcontainer/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ The following packages are installed into the Python environment `.venv`:
1313
- LAMMPS
1414
- MPICH
1515
- CMake
16-
- pre-commit (including hooks)
16+
- prek (including hooks)
1717
- Test packages including pytest
1818
- Doc packages including sphinx
1919

.devcontainer/build_cxx.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ cmake -D ENABLE_TENSORFLOW=ON \
1313
-D ENABLE_PYTORCH=ON \
1414
-D ENABLE_PADDLE=ON \
1515
-D CMAKE_INSTALL_PREFIX=${SCRIPT_PATH}/../dp/ \
16-
-D LAMMPS_VERSION=stable_22Jul2025 \
16+
-D LAMMPS_VERSION=stable_22Jul2025_update2 \
1717
-D CMAKE_BUILD_TYPE=Debug \
1818
-D BUILD_TESTING:BOOL=TRUE \
1919
-D TENSORFLOW_ROOT=${TENSORFLOW_ROOT} \

.devcontainer/build_py.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ SCRIPT_PATH=$(dirname $(realpath -s $0))
55
cd ${SCRIPT_PATH}/..
66

77
uv sync --dev --python 3.12 --extra cpu --extra torch --extra jax --extra lmp --extra test --extra docs
8-
pre-commit install
8+
prek install

.devcontainer/devcontainer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"features": {
77
"ghcr.io/devcontainers/features/github-cli:1": {}
88
},
9-
"postCreateCommand": ".devcontainer/build_py.sh && .devcontainer/download_libtorch.sh && .devcontainer/build_cxx.sh && pre-commit install-hooks",
9+
"postCreateCommand": ".devcontainer/build_py.sh && .devcontainer/download_libtorch.sh && .devcontainer/build_cxx.sh && prek install-hooks",
1010
"remoteEnv": {
1111
"PATH": "${containerEnv:PATH}:${containerWorkspaceFolder}/.venv/bin",
1212
"DP_ENABLE_PYTORCH": "1",

.github/ISSUE_TEMPLATE/bug-report.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ body:
3737
- docker
3838
- pip
3939
- Built from source
40+
- dp1s
4041
- Others (write below)
4142
validations:
4243
required: true

.github/dependabot.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,7 @@ updates:
44
directory: "/"
55
schedule:
66
interval: "weekly"
7-
target-branch: "devel"
7+
- package-ecosystem: "pip"
8+
directory: "/"
9+
schedule:
10+
interval: "weekly"

.github/workflows/build_cc.yml

Lines changed: 62 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@ on:
22
push:
33
branches-ignore:
44
- "gh-readonly-queue/**"
5+
- "copilot/**"
6+
- "dependabot/**"
7+
- "pre-commit-ci-update-config"
58
pull_request:
69
merge_group:
710
concurrency:
@@ -15,78 +18,69 @@ jobs:
1518
strategy:
1619
matrix:
1720
include:
18-
- variant: cpu
19-
dp_variant: cpu
20-
- variant: cuda
21-
dp_variant: cuda
22-
- variant: cuda120
23-
dp_variant: cuda
24-
- variant: rocm
25-
dp_variant: rocm
26-
- variant: clang
27-
dp_variant: clang
21+
- variant: cpu
22+
dp_variant: cpu
23+
- variant: cuda120
24+
dp_variant: cuda
25+
- variant: rocm
26+
dp_variant: rocm
27+
- variant: clang
28+
dp_variant: clang
2829
steps:
29-
- uses: actions/checkout@v5
30-
- uses: actions/setup-python@v5
31-
with:
32-
python-version: '3.11'
33-
- uses: lukka/get-cmake@latest
34-
- run: python -m pip install uv
35-
- run: source/install/uv_with_retry.sh pip install --system tensorflow
36-
- run: source/install/uv_with_retry.sh pip install --system 'torch==2.8.*' --index-url https://download.pytorch.org/whl/cpu
37-
- run: |
38-
wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2204/x86_64/cuda-keyring_1.0-1_all.deb \
39-
&& sudo dpkg -i cuda-keyring_1.0-1_all.deb \
40-
&& sudo apt-get update \
41-
&& sudo apt-get -y install cuda-cudart-dev-11-8 cuda-nvcc-11-8
42-
if: matrix.variant == 'cuda'
43-
- run: |
44-
wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2204/x86_64/cuda-keyring_1.0-1_all.deb \
45-
&& sudo dpkg -i cuda-keyring_1.0-1_all.deb \
46-
&& sudo apt-get update \
47-
&& sudo apt-get -y install cuda-cudart-dev-12-2 cuda-nvcc-12-2
48-
if: matrix.variant == 'cuda120'
49-
env:
50-
DEBIAN_FRONTEND: noninteractive
51-
- run: |
52-
echo 'deb [arch=amd64] https://repo.radeon.com/rocm/apt/6.3/ jammy main' | sudo tee /etc/apt/sources.list.d/rocm.list \
53-
&& printf 'Package: *\nPin: release o=repo.radeon.com\nPin-Priority: 600' | sudo tee /etc/apt/preferences.d/rocm-pin-600 \
54-
&& curl -s https://repo.radeon.com/rocm/rocm.gpg.key | sudo apt-key add - \
55-
&& sudo apt-get update \
56-
&& sudo apt-get install -y rocm-dev hipcub-dev
57-
if: matrix.variant == 'rocm'
58-
- run: |
59-
source/install/build_cc.sh
60-
env:
61-
DP_VARIANT: ${{ matrix.dp_variant }}
62-
DOWNLOAD_TENSORFLOW: "FALSE"
63-
CMAKE_GENERATOR: Ninja
64-
if: matrix.variant != 'clang'
65-
- run: |
66-
source/install/build_cc.sh
67-
env:
68-
DP_VARIANT: cpu
69-
DOWNLOAD_TENSORFLOW: "FALSE"
70-
CC: clang
71-
CXX: clang++
72-
CMAKE_GENERATOR: Ninja
73-
if: matrix.variant == 'clang'
74-
- name: Test files exist
75-
run: |
76-
test -f dp/bin/dp_ipi &&
77-
test -f dp/lib/libdeepmd_cc.so &&
78-
test -f dp/lib/libdeepmd_c.so &&
79-
test -f dp/lib/libdeepmd_op.so &&
80-
test -f dp/lib/libdeepmd_ipi.so &&
81-
test -f dp/lib/libdeepmd_lmp.so &&
82-
test -f dp/lib/libdeepmd.so
30+
- uses: actions/checkout@v6
31+
- uses: actions/setup-python@v6
32+
with:
33+
python-version: "3.11"
34+
- uses: lukka/get-cmake@latest
35+
- run: python -m pip install uv
36+
- run: source/install/uv_with_retry.sh pip install --system --group pin_tensorflow_cpu --group pin_pytorch_cpu --torch-backend cpu
37+
- run: |
38+
wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2204/x86_64/cuda-keyring_1.0-1_all.deb \
39+
&& sudo dpkg -i cuda-keyring_1.0-1_all.deb \
40+
&& sudo apt-get update \
41+
&& sudo apt-get -y install cuda-cudart-dev-12-2 cuda-nvcc-12-2
42+
if: matrix.variant == 'cuda120'
43+
env:
44+
DEBIAN_FRONTEND: noninteractive
45+
- run: |
46+
echo 'deb [arch=amd64] https://repo.radeon.com/rocm/apt/6.3/ jammy main' | sudo tee /etc/apt/sources.list.d/rocm.list \
47+
&& printf 'Package: *\nPin: release o=repo.radeon.com\nPin-Priority: 600' | sudo tee /etc/apt/preferences.d/rocm-pin-600 \
48+
&& curl -s https://repo.radeon.com/rocm/rocm.gpg.key | sudo apt-key add - \
49+
&& sudo apt-get update \
50+
&& sudo apt-get install -y rocm-dev hipcub-dev
51+
if: matrix.variant == 'rocm'
52+
- run: |
53+
source/install/build_cc.sh
54+
env:
55+
DP_VARIANT: ${{ matrix.dp_variant }}
56+
DOWNLOAD_TENSORFLOW: "FALSE"
57+
CMAKE_GENERATOR: Ninja
58+
if: matrix.variant != 'clang'
59+
- run: |
60+
source/install/build_cc.sh
61+
env:
62+
DP_VARIANT: cpu
63+
DOWNLOAD_TENSORFLOW: "FALSE"
64+
CC: clang
65+
CXX: clang++
66+
CMAKE_GENERATOR: Ninja
67+
if: matrix.variant == 'clang'
68+
- name: Test files exist
69+
run: |
70+
test -f dp/bin/dp_ipi &&
71+
test -f dp/lib/libdeepmd_cc.so &&
72+
test -f dp/lib/libdeepmd_c.so &&
73+
test -f dp/lib/libdeepmd_op.so &&
74+
test -f dp/lib/libdeepmd_ipi.so &&
75+
test -f dp/lib/libdeepmd_lmp.so &&
76+
test -f dp/lib/libdeepmd.so
8377
pass:
8478
name: Pass building C++
8579
needs: [buildcc]
8680
runs-on: ubuntu-latest
8781
if: always()
8882
steps:
89-
- name: Decide whether the needed jobs succeeded or failed
90-
uses: re-actors/alls-green@release/v1
91-
with:
92-
jobs: ${{ toJSON(needs) }}
83+
- name: Decide whether the needed jobs succeeded or failed
84+
uses: re-actors/alls-green@release/v1
85+
with:
86+
jobs: ${{ toJSON(needs) }}

.github/workflows/build_wheel.yml

Lines changed: 32 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ on:
44
push:
55
branches-ignore:
66
- "gh-readonly-queue/**"
7+
- "copilot/**"
8+
- "dependabot/**"
9+
- "pre-commit-ci-update-config"
710
tags:
811
- "v*"
912
pull_request:
@@ -26,15 +29,9 @@ jobs:
2629
python: 311
2730
platform_id: manylinux_x86_64
2831
dp_variant: cuda
29-
cuda_version: 12.2
30-
- os: ubuntu-latest
31-
python: 311
32-
platform_id: manylinux_x86_64
33-
dp_variant: cuda
34-
cuda_version: 11.8
35-
dp_pkg_name: deepmd-kit-cu11
32+
cuda_version: 12.8
3633
# macos-x86-64
37-
- os: macos-13
34+
- os: macos-15-intel
3835
python: 311
3936
platform_id: macosx_x86_64
4037
dp_variant: cpu
@@ -54,46 +51,38 @@ jobs:
5451
platform_id: manylinux_aarch64
5552
dp_variant: cpu
5653
steps:
57-
- uses: actions/checkout@v5
54+
- uses: actions/checkout@v6
5855
with:
5956
# https://github.com/pypa/setuptools_scm/issues/480
6057
fetch-depth: 0
6158
- name: Install uv
6259
run: curl --proto '=https' --tlsv1.2 -LsSf https://github.com/astral-sh/uv/releases/download/0.2.24/uv-installer.sh | sh
6360
if: runner.os != 'Linux'
64-
- uses: docker/setup-qemu-action@v3
65-
name: Setup QEMU
66-
if: matrix.platform_id == 'manylinux_aarch64' && matrix.os == 'ubuntu-latest'
67-
# detect version in advance. See #3168
68-
- run: |
69-
echo "SETUPTOOLS_SCM_PRETEND_VERSION=$(pipx run uv tool run --from setuptools_scm python -m setuptools_scm)" >> $GITHUB_ENV
70-
rm -rf .git
71-
if: matrix.dp_pkg_name == 'deepmd-kit-cu11'
7261
- name: Build wheels
73-
uses: pypa/cibuildwheel@v3.1
62+
uses: pypa/cibuildwheel@v3.3
7463
env:
7564
CIBW_BUILD_VERBOSITY: 1
7665
CIBW_ARCHS: all
7766
CIBW_BUILD: cp${{ matrix.python }}-${{ matrix.platform_id }}
7867
DP_VARIANT: ${{ matrix.dp_variant }}
7968
CUDA_VERSION: ${{ matrix.cuda_version }}
8069
DP_PKG_NAME: ${{ matrix.dp_pkg_name }}
81-
CIBW_BUILD_FRONTEND: 'build[uv]'
82-
- uses: actions/upload-artifact@v4
70+
CIBW_BUILD_FRONTEND: "build[uv]"
71+
- uses: actions/upload-artifact@v6
8372
with:
8473
name: cibw-cp${{ matrix.python }}-${{ matrix.platform_id }}-cu${{ matrix.cuda_version }}-${{ strategy.job-index }}
8574
path: ./wheelhouse/*.whl
8675
build_sdist:
8776
name: Build source distribution
8877
runs-on: ubuntu-latest
8978
steps:
90-
- uses: actions/checkout@v5
79+
- uses: actions/checkout@v6
9180
with:
9281
fetch-depth: 0
9382
- name: Build sdist
9483
run: pipx run uv tool run --with build[uv] --from build python -m build --installer uv --sdist
9584

96-
- uses: actions/upload-artifact@v4
85+
- uses: actions/upload-artifact@v6
9786
with:
9887
name: cibw-sdist
9988
path: dist/*.tar.gz
@@ -106,7 +95,7 @@ jobs:
10695
id-token: write
10796
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/v')
10897
steps:
109-
- uses: actions/download-artifact@v5
98+
- uses: actions/download-artifact@v7
11099
with:
111100
pattern: cibw-*
112101
path: dist
@@ -123,13 +112,19 @@ jobs:
123112
include:
124113
- variant: ""
125114
cuda_version: "12"
126-
- variant: "_cu11"
127-
cuda_version: "11"
128115
steps:
129-
- name: Delete huge unnecessary tools folder
130-
run: rm -rf /opt/hostedtoolcache
131-
- uses: actions/checkout@v5
132-
- uses: actions/download-artifact@v5
116+
- name: Free Disk Space (Ubuntu)
117+
uses: insightsengineering/disk-space-reclaimer@v1
118+
with:
119+
tools-cache: true
120+
android: true
121+
dotnet: true
122+
haskell: true
123+
large-packages: true
124+
swap-storage: true
125+
docker-images: true
126+
- uses: actions/checkout@v6
127+
- uses: actions/download-artifact@v7
133128
with:
134129
path: source/install/docker/dist
135130
pattern: cibw-*-manylinux_x86_64-cu${{ matrix.cuda_version }}*
@@ -162,15 +157,15 @@ jobs:
162157
needs: [build_wheels, build_sdist]
163158
runs-on: ubuntu-latest
164159
steps:
165-
- uses: actions/download-artifact@v5
160+
- uses: actions/download-artifact@v7
166161
with:
167162
path: dist/packages
168163
pattern: cibw-*
169164
merge-multiple: true
170-
- uses: actions/setup-python@v5
165+
- uses: actions/setup-python@v6
171166
name: Install Python
172167
with:
173-
python-version: '3.11'
168+
python-version: "3.11"
174169
- run: pip install dumb-pypi
175170
- run: |
176171
ls dist/packages > package_list.txt
@@ -188,7 +183,7 @@ jobs:
188183
name: github-pages
189184
url: ${{ steps.deployment.outputs.page_url }}
190185
runs-on: ubuntu-latest
191-
if: github.event_name == 'push' && github.ref == 'refs/heads/devel' && github.repository_owner == 'deepmodeling'
186+
if: github.event_name == 'push' && github.ref == 'refs/heads/master' && github.repository_owner == 'deepmodeling'
192187
steps:
193188
- name: Deploy to GitHub Pages
194189
id: deployment
@@ -200,7 +195,7 @@ jobs:
200195
runs-on: ubuntu-latest
201196
if: always()
202197
steps:
203-
- name: Decide whether the needed jobs succeeded or failed
204-
uses: re-actors/alls-green@release/v1
205-
with:
206-
jobs: ${{ toJSON(needs) }}
198+
- name: Decide whether the needed jobs succeeded or failed
199+
uses: re-actors/alls-green@release/v1
200+
with:
201+
jobs: ${{ toJSON(needs) }}

0 commit comments

Comments
 (0)