Skip to content

Commit

Permalink
Merge branch 'master' of github.com:CompPhysVienna/n2p2 into 4G-HDNNP…
Browse files Browse the repository at this point in the history
…-training
  • Loading branch information
singraber committed Nov 24, 2024
2 parents 9f320e1 + e51667a commit 5a8be09
Show file tree
Hide file tree
Showing 38 changed files with 761 additions and 171 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/n2p2-ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,13 @@ jobs:
pip install breathe
# pynnp
pip install cython
pip install cython==3.0.11
# python tests
pip install pytest
pip install pytest-cov
pip install coverage==4.5.4
pip install pytest #==7.1.3
pip install pytest-cov #==4.0.0
pip install coverage #==7.6.1
- name: Build n2p2 libraries and applications
run: make MODE=test -j4
working-directory: ./src
Expand All @@ -66,7 +66,7 @@ jobs:
working-directory: ./src

- name: Build LAMMPS with n2p2 support
run: make MODE=test lammps-nnp
run: make MODE=test lammps-hdnnp
working-directory: ./src

- name: Run C++ tests and coverage
Expand Down
30 changes: 30 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,36 @@ Changelog

All notable changes to this project will be documented in this file.

Version 2.3.0 - 2024-11-23
--------------------------

New features
^^^^^^^^^^^^

* Allow manual definition of train/test set (add ``set=train/test`` after ``begin`` in
input.data).
* Additional symmetry function log output, extra column ``spread``.
* Structure ``remap()`` function is now available in pynnp.

Maintenance
^^^^^^^^^^^

* Fixed CI: Cython updated to version 3.0+, added ``__rmul__`` to ``Vec3D`` in
pynnp.

Important changes
^^^^^^^^^^^^^^^^^

* Synchronized LAMMPS developer build with LAMMPS-distributed source: Finally
switched to pair style ``hdnnp`` everywhere.

Documentation
^^^^^^^^^^^^^

* Removed old ``nnp`` pair style description page.
* Updated LAMMPS interface build instructions page.
* Added train/test set split documentation.

Version 2.2.0 - 2022-05-23
--------------------------

Expand Down
12 changes: 6 additions & 6 deletions examples/interface-LAMMPS/Cu2S_PBE/md.lmp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
###############################################################################
# MD simulation for NN copper sulfide
# MD simulation for HDNNP copper sulfide
###############################################################################

###############################################################################
Expand All @@ -12,8 +12,8 @@ variable cfgFile string "cu2s_144_low-chalcocite_Evans-1979_PBE.data"
variable numSteps equal 100
variable dt equal 0.001
# NN
variable nnpCutoff equal 6.01
variable nnpDir string "nnp-data"
variable hdnnpCutoff equal 6.01
variable hdnnpDir string "hdnnp-data"
# Masses
variable mass_S equal 32.065 # mass for element 1 (S) (g/mol)
variable mass_Cu equal 63.546 # mass for element 2 (Cu) (g/mol)
Expand All @@ -31,10 +31,10 @@ timestep ${dt}
thermo 10

###############################################################################
# NN
# HDNNP
###############################################################################
pair_style nnp dir ${nnpDir} showew no showewsum 100 resetew no maxew 100 cflength 1.0 cfenergy 1.0 emap "1:S,2:Cu"
pair_coeff * * ${nnpCutoff}
pair_style hdnnp ${hdnnpCutoff} dir ${hdnnpDir} showew no showewsum 100 resetew no maxew 100 cflength 1.0 cfenergy 1.0
pair_coeff * * S Cu

###############################################################################
# INTEGRATOR
Expand Down
12 changes: 6 additions & 6 deletions examples/interface-LAMMPS/H2O_RPBE-D3/md.lmp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
###############################################################################
# MD simulation for NN water
# MD simulation for HDNNP water
###############################################################################

###############################################################################
Expand All @@ -12,8 +12,8 @@ variable cfgFile string "h2o_8640_liquid_NpT_RPBE-D3.data"
variable numSteps equal 5
variable dt equal 0.0005
# NN
variable nnpCutoff equal 6.36
variable nnpDir string "nnp-data"
variable hdnnpCutoff equal 6.36
variable hdnnpDir string "hdnnp-data"
# Masses
variable mass_H equal 1.00794
variable mass_O equal 15.9994
Expand All @@ -31,10 +31,10 @@ timestep ${dt}
thermo 1

###############################################################################
# NN
# HDNNP
###############################################################################
pair_style nnp dir ${nnpDir} showew no showewsum 10 resetew no maxew 100 cflength 1.8897261328 cfenergy 0.0367493254 emap "1:H,2:O"
pair_coeff * * ${nnpCutoff}
pair_style hdnnp ${hdnnpCutoff} dir ${hdnnpDir} showew no showewsum 5 resetew no maxew 100 cflength 1.8897261328 cfenergy 0.0367493254
pair_coeff * * H O

###############################################################################
# INTEGRATOR
Expand Down
2 changes: 1 addition & 1 deletion src/doc/doxygen/Doxyfile
Original file line number Diff line number Diff line change
Expand Up @@ -915,7 +915,7 @@ RECURSIVE = YES
# Note that relative paths are relative to the directory from which doxygen is
# run.

EXCLUDE = ../../interface/lammps-nnp
EXCLUDE = ../../interface/lammps-hdnnp

# The EXCLUDE_SYMLINKS tag can be used to select whether or not files or
# directories that are symbolic links (a Unix file system feature) are excluded
Expand Down
4 changes: 2 additions & 2 deletions src/doc/sphinx/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@

# General information about the project.
project = u'n2p2 - A neural network potential package'
copyright = u'2022, Andreas Singraber'
copyright = u'2024, Andreas Singraber'
author = u'Andreas Singraber'

# The version info for the project you're documenting, acts as replacement for
Expand All @@ -133,7 +133,7 @@
#
# This is also used if you do content translation via gettext catalogs.
# Usually you set "language" from the command line for these cases.
language = None
language = 'en'

# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
Expand Down
3 changes: 1 addition & 2 deletions src/doc/sphinx/source/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ components are required:

* :ref:`libnnp <libnnp>`
* `libnnpif`
* :ref:`lammps-nnp <if_lammps>` (for LAMMPS)
* :ref:`lammps-hdnnp <if_lammps>` (for LAMMPS)

Training a new neural network potential
---------------------------------------
Expand Down Expand Up @@ -180,7 +180,6 @@ list of keywords is provided :ref:`here <keywords>`.
:caption: Interfaces

interfaces/if_lammps
interfaces/pair_nnp
interfaces/if_cabanamd

.. toctree::
Expand Down
Loading

0 comments on commit 5a8be09

Please sign in to comment.