Skip to content

Commit 1024b65

Browse files
author
Han Wang
committed
merge devel into master
2 parents 90b1f52 + 37af1d1 commit 1024b65

File tree

641 files changed

+538940
-15189
lines changed

Some content is hidden

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

641 files changed

+538940
-15189
lines changed

.github/workflows/build_cc.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
on:
2+
push:
3+
pull_request:
4+
name: Build C++
5+
jobs:
6+
testpython:
7+
name: Build C++
8+
runs-on: ubuntu-20.04
9+
strategy:
10+
matrix:
11+
include:
12+
- variant: cpu
13+
- variant: cuda
14+
steps:
15+
- uses: actions/checkout@master
16+
with:
17+
submodules: true
18+
- run: sudo apt update && sudo apt install g++-7
19+
- run: sudo apt install nvidia-cuda-toolkit
20+
if: matrix.variant == 'cuda'
21+
- run: source/install/build_cc.sh
22+
env:
23+
DP_VARIANT: ${{ matrix.variant }}
24+
CC: gcc-7
25+
CXX: g++-7

.github/workflows/build_wheel.yml

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
name: Build and upload to PyPI
2+
3+
on:
4+
push:
5+
pull_request:
6+
7+
jobs:
8+
build_wheels:
9+
name: Build wheels on ${{ matrix.os }}
10+
runs-on: ${{ matrix.os }}
11+
strategy:
12+
matrix:
13+
os: [ubuntu-18.04] #, windows-latest, macos-latest]
14+
15+
steps:
16+
- uses: actions/checkout@v2
17+
- uses: actions/setup-python@v2
18+
name: Install Python
19+
with:
20+
python-version: '3.8'
21+
22+
- name: Install cibuildwheel
23+
run: |
24+
python -m pip install cibuildwheel
25+
26+
- name: Build wheels
27+
env:
28+
CIBW_BUILD: "cp36-* cp37-* cp38-* cp39-*"
29+
CIBW_MANYLINUX_X86_64_IMAGE: ghcr.io/deepmodeling/manylinux2010_x86_64_tensorflow
30+
CIBW_BEFORE_BUILD: pip install tensorflow
31+
CIBW_SKIP: "*-win32 *-manylinux_i686"
32+
run: |
33+
python -m cibuildwheel --output-dir wheelhouse
34+
- uses: actions/upload-artifact@v2
35+
with:
36+
path: ./wheelhouse/*.whl
37+
38+
build_sdist:
39+
name: Build source distribution
40+
runs-on: ubuntu-latest
41+
steps:
42+
- uses: actions/checkout@v2
43+
- uses: actions/setup-python@v2
44+
name: Install Python
45+
with:
46+
python-version: '3.8'
47+
- run: pip install -U scikit-build tensorflow setuptools_scm
48+
- name: Build sdist
49+
run: python setup.py sdist
50+
51+
- uses: actions/upload-artifact@v2
52+
with:
53+
path: dist/*.tar.gz
54+
55+
upload_pypi:
56+
needs: [build_wheels, build_sdist]
57+
runs-on: ubuntu-latest
58+
if: startsWith(github.event.ref, 'refs/tags/v')
59+
steps:
60+
- uses: actions/download-artifact@v2
61+
with:
62+
name: artifact
63+
path: dist
64+
65+
- uses: pypa/gh-action-pypi-publish@master
66+
with:
67+
user: __token__
68+
password: ${{ secrets.pypi_password }}

.github/workflows/lint_python.yml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
on:
2+
push:
3+
pull_request:
4+
name: Lint Python
5+
jobs:
6+
lintpython:
7+
name: Lint Python
8+
runs-on: ubuntu-20.04
9+
strategy:
10+
matrix:
11+
python-version: [3.8]
12+
13+
steps:
14+
- uses: actions/checkout@v1
15+
- uses: actions/setup-python@v2
16+
with:
17+
python-version: ${{ matrix.python }}
18+
- name: Install requirements
19+
run: pip install -r requirements.txt
20+
- uses: marian-code/[email protected]
21+
with:
22+
python-root-list: "./deepmd/*.py ./deepmd/*/*.py ./source/train/*.py ./source/tests/*.py ./source/op/*.py"
23+
use-black: true
24+
use-isort: true
25+
use-mypy: true
26+
use-pycodestyle: true
27+
use-pydocstyle: true
28+
extra-pycodestyle-options: "--max-line-length=88"
29+
use-pylint: false
30+
use-flake8: false
31+
use-vulture: true
32+
conda-python-version: "3.8"
33+

.github/workflows/mirror_gitee.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: Mirror to Gitee Repo
2+
3+
on: [ push, delete, create ]
4+
5+
# Ensures that only one mirror task will run at a time.
6+
concurrency:
7+
group: git-mirror
8+
9+
jobs:
10+
git-mirror:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: wearerequired/git-mirror-action@v1
14+
env:
15+
SSH_PRIVATE_KEY: ${{ secrets.SYNC_GITEE_PRIVATE_KEY }}
16+
with:
17+
source-repo: "[email protected]:deepmodeling/deepmd-kit.git"
18+
destination-repo: "[email protected]:deepmodeling/deepmd-kit.git"

.github/workflows/test_cc.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
on:
2+
push:
3+
pull_request:
4+
name: Test C++
5+
jobs:
6+
testpython:
7+
name: Test C++
8+
runs-on: ubuntu-latest
9+
steps:
10+
- uses: actions/checkout@master
11+
- run: source/install/test_cc.sh

.github/workflows/test_python.yml

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
on:
2+
push:
3+
pull_request:
4+
name: Test Python
5+
jobs:
6+
testpython:
7+
name: Test Python
8+
runs-on: ubuntu-18.04
9+
strategy:
10+
matrix:
11+
include:
12+
- python: 3.6
13+
gcc: 4.8
14+
tf: 1.8
15+
- python: 3.6
16+
gcc: 4.8
17+
tf: 1.12
18+
- python: 3.6
19+
gcc: 4.8
20+
tf: 1.14
21+
- python: 3.6
22+
gcc: 5
23+
tf: 1.14
24+
- python: 3.6
25+
gcc: 8
26+
tf: 1.14
27+
- python: 3.7
28+
gcc: 5
29+
tf: 1.14
30+
- python: 3.7
31+
gcc: 6
32+
tf: 1.14
33+
- python: 3.7
34+
gcc: 7
35+
tf: 1.14
36+
- python: 3.7
37+
gcc: 8
38+
tf: 1.14
39+
- python: 3.7
40+
gcc: 5
41+
tf:
42+
- python: 3.7
43+
gcc: 8
44+
tf:
45+
- python: 3.8
46+
gcc: 5
47+
tf:
48+
- python: 3.8
49+
gcc: 8
50+
tf:
51+
52+
steps:
53+
- uses: actions/checkout@master
54+
- uses: actions/setup-python@v2
55+
with:
56+
python-version: ${{ matrix.python }}
57+
- name: pip cache
58+
uses: actions/cache@v2
59+
with:
60+
path: ~/.cache/pip
61+
key:
62+
${{ runner.os }}-pip-${{ hashFiles('**/setup.py') }}-${{ hashFiles('**/requirements.txt') }}
63+
restore-keys: |
64+
${{ runner.os }}-pip-
65+
- run: |
66+
sudo apt update
67+
sudo apt install gcc-${{ matrix.gcc }} g++-${{ matrix.gcc }}
68+
- run: pip install -e .[cpu,test] codecov
69+
env:
70+
CC: gcc-${{ matrix.gcc }}
71+
CXX: g++-${{ matrix.gcc }}
72+
TENSORFLOW_VERSION: ${{ matrix.tf }}
73+
- run: dp --version
74+
- run: pytest --cov=deepmd source/tests && codecov

.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,3 +26,9 @@ venv*
2626
.vscode/**
2727
_build
2828
_templates
29+
API_CC
30+
doc/api_py/
31+
dp/
32+
build_lammps/
33+
build_tests/
34+
build_cc_tests

.gitmodules

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
[submodule "source/op/cuda/cub"]
2-
path = source/op/cuda/cub
3-
url = git://github.com/NVlabs/cub.git
1+
[submodule "source/lib/src/cuda/cub"]
2+
path = source/lib/src/cuda/cub
3+
url = git://github.com/NVIDIA/cub.git

.travis.yml

Lines changed: 0 additions & 95 deletions
This file was deleted.

CITATION.cff

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
preferred-citation:
2+
type: article
3+
authors:
4+
- family-names: "Wang"
5+
given-names: "Han"
6+
- family-names: "Zhang"
7+
given-names: "Linfeng"
8+
- family-names: "Han"
9+
given-names: "Jiequn"
10+
- family-names: "E"
11+
given-names: "Weinan"
12+
doi: "10.1016/j.cpc.2018.03.016"
13+
journal: "Computer Physics Communications"
14+
month: 7
15+
start: 178 # First page number
16+
end: 184 # Last page number
17+
title: "DeePMD-kit: A deep learning package for many-body potential energy representation and molecular dynamics"
18+
volume: 228
19+
year: 2018

0 commit comments

Comments
 (0)