Skip to content
This repository was archived by the owner on Sep 28, 2021. It is now read-only.

Commit f9c0446

Browse files
authored
Merge pull request #124 from votca/stable_bump
Merge 2021-dev into stable
2 parents c153194 + c26bc92 commit f9c0446

File tree

8 files changed

+801
-382
lines changed

8 files changed

+801
-382
lines changed

.gitattributes

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
.gitattributes export-ignore
2+
.gitignore export-ignore
3+
.gitmodules export-ignore
4+
.github export-ignore
5+
.clang-format export-ignore
6+
.codecov.yml export-ignore

.github/workflows/continuous-integration-workflow.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
continue-on-error: ${{ matrix.distro == 'ubuntu:devel' || matrix.distro == 'opensuse:latest' || matrix.distro == 'fedora:rawhide' || matrix.continue-on-error == true }}
1111
strategy:
1212
matrix:
13-
distro: ['fedora:latest', 'fedora:rawhide', 'opensuse:latest', 'ubuntu:18.04']
13+
distro: ['fedora:latest', 'fedora:rawhide', 'opensuse:latest']
1414
toolchain: [gnu]
1515
cmake_build_type: [Release]
1616
minimal: [false]
@@ -58,7 +58,7 @@ jobs:
5858
key: ${{ steps.setup.outputs.cache_key }}
5959
restore-keys: ${{ steps.setup.outputs.cache_restore_key }}
6060
- name: CMake
61-
run: mkdir builddir && cd builddir && cmake ${{ steps.setup.outputs.cmake_args }} ../votca
61+
run: cmake -B builddir ${{ steps.setup.outputs.cmake_args }} votca
6262
- name: Build
6363
run: |
6464
ccache -z

.github/workflows/copyright.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Copyright
2+
on:
3+
issue_comment:
4+
types: [created]
5+
jobs:
6+
edit:
7+
name: Copyright
8+
if: ${{ github.event.comment.body == '@votca-bot copyright' }}
9+
runs-on: ubuntu-latest
10+
steps:
11+
- name: Check if message comes from PR
12+
uses: octokit/[email protected]
13+
id: issue_info
14+
with:
15+
route: GET /repos/:repository/issues/:pull_number
16+
repository: ${{ github.repository }}
17+
pull_number: ${{ github.event.issue.number }}
18+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
19+
- name: Get PR info
20+
if: ${{ fromJSON(steps.issue_info.outputs.data).pull_request }}
21+
uses: octokit/[email protected]
22+
id: pr_info
23+
with:
24+
route: GET /repos/:repository/pulls/:pull_number
25+
repository: ${{ github.repository }}
26+
pull_number: ${{ github.event.issue.number }}
27+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
28+
- name: Checkout head branch from PR
29+
if: ${{ fromJSON(steps.issue_info.outputs.data).pull_request }}
30+
uses: actions/[email protected]
31+
with:
32+
repository: ${{ fromJSON(steps.pr_info.outputs.data).head.repo.full_name }}
33+
ref: ${{ fromJSON(steps.pr_info.outputs.data).head.ref }}
34+
fetch-depth: 0
35+
token: ${{ secrets.VOTCA_BOT_TOKEN }}
36+
- name: Create and commit copyright updates
37+
if: ${{ fromJSON(steps.issue_info.outputs.data).pull_request }}
38+
uses: votca/actions/copyright@master
39+
with:
40+
base: ${{ fromJSON(steps.pr_info.outputs.data).base.sha }}

CMakeLists.txt

Lines changed: 40 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,45 @@
1-
cmake_minimum_required(VERSION 3.1)
1+
cmake_minimum_required(VERSION 3.12)
22

3-
project(csg-tutorials)
3+
project(csg-tutorials LANGUAGES NONE)
44

5-
set(PROJECT_VERSION "1.6.4")
5+
set(PROJECT_VERSION "2021-dev")
66

77
# Cmake modules/macros are in a subdirectory to keep this file cleaner
88
set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/CMakeModules)
99

10+
# not used, but stops GNUInstallDirs.cmake from warning
11+
set(CMAKE_INSTALL_LIBDIR "lib64")
1012
include(GNUInstallDirs)
13+
include(FeatureSummary)
1114

1215
option(ENABLE_REGRESSION_TESTING "Build and copy regression testing stuff" OFF)
16+
add_feature_info(ENABLE_REGRESSION_TESTING ENABLE_REGRESSION_TESTING "Enable regression tests")
1317
if(ENABLE_REGRESSION_TESTING)
1418
option(ENABLE_EXPERIMENTAL_TESTS "Run more unstable regression tests as well" OFF)
19+
add_feature_info(ENABLE_EXPERIMENTAL_TESTS ENABLE_EXPERIMENTAL_TESTS "Enable experimental regression tests")
20+
enable_language(CXX) # needed by mpi for VOTCA_CSG
1521
enable_testing()
1622
find_package(LMP)
23+
set_package_properties(LMP PROPERTIES TYPE OPTIONAL PURPOSE "Lammps binary needed to run lammps regression tests")
1724
find_package(MDRUN_MPI)
25+
set_package_properties(MDRUN_MPI PROPERTIES TYPE OPTIONAL PURPOSE "gromacs mpi binary needed to run parallel gromacs regression tests")
1826
if(MDRUN_MPI_FOUND)
1927
find_package(MPI)
28+
set_package_properties(MPI PROPERTIES TYPE OPTIONAL PURPOSE "mpiexec binary needed to run parallel gromacs regression tests")
2029
set(NPROCS 4 CACHE STRING "# processes for testing")
2130
if(DEFINED MPIEXEC_MAX_NUMPROCS AND NPROCS GREATER MPIEXEC_MAX_NUMPROCS)
2231
message(WARNING "NPROCS(${NPROCS}) bigger than MPIEXEC_MAX_NUMPROCS(${MPIEXEC_MAX_NUMPROCS}) appending '--oversubscribe'")
2332
set(MPIEXEC_PREFLAGS "${MPIEXEC_PREFLAGS} --oversubscribe")
2433
endif()
2534
endif()
2635
find_package(ESPRESSO)
36+
set_package_properties(ESPRESSO PROPERTIES TYPE OPTIONAL PURPOSE "ESPResSo MD python module needed to run ESPResSo MD regression tests")
2737
find_package(CMA)
38+
set_package_properties(CMA PROPERTIES TYPE OPTIONAL PURPOSE "CMA python module needed to run CMA regression tests")
39+
find_package(Gnuplot)
40+
set_package_properties(Gnuplot PROPERTIES TYPE OPTIONAL PURPOSE "gnuplot needed to run CMA/simplex regression tests")
2841
find_package(VOTCA_CSG NO_MODULE REQUIRED)
42+
set_package_properties(VOTCA_CSG PROPERTIES TYPE REQUIRED PURPOSE "VOTCA csg binaries used in testing")
2943
if(DEFINED VOTCA_CSG_VERSION AND NOT VOTCA_CSG_VERSION STREQUAL PROJECT_VERSION)
3044
message(FATAL_ERROR "Incompatible VOTCA CSG version found (needed ${PROJECT_VERSION}, found ${VOTCA_CSG_VERSION})")
3145
endif()
@@ -58,6 +72,9 @@ if(ENABLE_REGRESSION_TESTING)
5872
if(NOT CMA_FOUND AND DIR MATCHES "cma/")
5973
continue()
6074
endif()
75+
if(NOT Gnuplot_FOUND AND DIR MATCHES "(cma/|simplex|realtime)")
76+
continue()
77+
endif()
6178
if(NOT ENABLE_EXPERIMENTAL_TESTS)
6279
if(DIR MATCHES "some/broken/test")
6380
continue()
@@ -105,23 +122,41 @@ if(ENABLE_REGRESSION_TESTING)
105122
message(STATUS "Use VOTCASHARE=${VOTCA_SHARE} PATH=${VOTCA_PATH}:\$PATH VOTCA_CSG_DEFAULTS=${VOTCA_CSG_DEFAULTS} for out-of-cmake testing")
106123
endif()
107124

125+
if(VOTCA_SPHINX_DIR)
126+
file(GLOB RSTS ${CMAKE_CURRENT_SOURCE_DIR}/guide/*.rst)
127+
set(MANUAL_RST_FILES)
128+
foreach(_RST ${RSTS})
129+
get_filename_component(_FILE "${_RST}" NAME)
130+
add_custom_command(OUTPUT ${VOTCA_SPHINX_DIR}/csg-tutorials/${_FILE}
131+
COMMAND ${CMAKE_COMMAND} -E copy_if_different ${_RST} ${VOTCA_SPHINX_DIR}/csg-tutorials/${_FILE}
132+
DEPENDS ${_RST})
133+
list(APPEND MANUAL_RST_FILES ${VOTCA_SPHINX_DIR}/csg-tutorials/${_FILE})
134+
endforeach()
135+
add_custom_target(doc-csg-tutorials DEPENDS ${MANUAL_RST_FILES} ${MANUAL_PNG_FILES})
136+
endif()
137+
108138
install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/ DESTINATION ${CMAKE_INSTALL_DATADIR}/votca/csg-tutorials
109139
PATTERN ".git*" EXCLUDE PATTERN "step_*" EXCLUDE
110140
PATTERN "CMake*" EXCLUDE PATTERN "cmake_install.cmake" EXCLUDE
111141
PATTERN "install_manifest.txt" EXCLUDE PATTERN "*~" EXCLUDE
112142
PATTERN "inverse.log" EXCLUDE)
113143

114-
configure_file(${CMAKE_MODULE_PATH}/cmake_uninstall.cmake.in ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake IMMEDIATE @ONLY)
144+
configure_file(${PROJECT_SOURCE_DIR}/CMakeModules/cmake_uninstall.cmake.in ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake IMMEDIATE @ONLY)
115145
option(ENABLE_TESTING "Test if cmake worked" OFF)
146+
add_feature_info(ENABLE_TESTING ENABLE_TESTING "Enable unit tests")
116147
if(ENABLE_TESTING)
117148
enable_testing()
118149
add_test(regression_UninstallExists ${CMAKE_COMMAND} -DFileToCheck=${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake
119150
-P ${CMAKE_CURRENT_SOURCE_DIR}/CMakeModules/FileExists.cmake)
120151

121-
set_tests_properties(regression_UninstallExists PROPERTIES LABELS "regression")
152+
set_tests_properties(regression_UninstallExists PROPERTIES LABELS "csg-tutorials;votca")
122153
endif(ENABLE_TESTING)
123154
add_custom_target(uninstall-csg-tutorials COMMAND ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake)
124155
if(NOT TARGET uninstall)
125156
add_custom_target(uninstall)
126157
endif()
127158
add_dependencies(uninstall uninstall-csg-tutorials)
159+
160+
if (CMAKE_CURRENT_SOURCE_DIR STREQUAL CMAKE_SOURCE_DIR)
161+
feature_summary(INCLUDE_QUIET_PACKAGES WHAT ALL)
162+
endif (CMAKE_CURRENT_SOURCE_DIR STREQUAL CMAKE_SOURCE_DIR)

README

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

README.rst

Lines changed: 132 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,132 @@
1+
|Codacy Badge| |codecov| |CI| |DOI|
2+
3+
This is a collection of coarse-graining tutorials using the VOTCA
4+
package. Further information on VOTCA can be found at
5+
http://www.votca.org
6+
7+
The development of VOTCA is mainly funded by academic research grants.
8+
If you use this package, please cite the VOTCA papers:
9+
10+
- | *Relative entropy and optimization-driven coarse-graining methods
11+
in VOTCA*,
12+
| S.Y. Mashayak, M. Jochum, K. Koschke, N.R. Aluru, V. Ruehle, and C.
13+
Junghans,
14+
| `PLoS one 10, e131754
15+
(2015) <http://dx.doi.org/10.1371/journal.pone.0131754>`__.
16+
17+
- | *Hybrid approaches to coarse-graining using the VOTCA package:
18+
liquid hexane*,
19+
| V. Ruehle and C. Junghans,
20+
| `Macromol. Theory Simul. 20, 472
21+
(2011) <http://dx.doi.org/10.1002/mats.201100011>`__.
22+
23+
- | *Versatile Object-oriented Toolkit for Coarse-graining
24+
Applications*,
25+
| V.Ruehle, C. Junghans, A. Lukyanov, K. Kremer, and D. Andrienko,
26+
| `J. Chem. Theo. Comp. 5 (12), 3211
27+
(2009) <http://dx.doi.org/10.1021/ct900369w>`__.
28+
29+
In case of questions, please post them in the google discussion group
30+
for votca at http://groups.google.com/group/votca
31+
32+
You can contact the VOTCA Development Team at [email protected].
33+
34+
The following tutorials (compare with paper above) are included. They
35+
all rely on Gromacs unless specified otherwise:
36+
37+
- ``spce/atomistic``: atomistic reference simulations for SPC/E water
38+
- ``spce/force_matching``: force matching for SPC/E water
39+
- ``spce/ibi``: iterative boltzmann inversion for SPC/E water
40+
- ``spce/ibi_pressure``: iterative boltzmann inversion for SPC/E water
41+
with simple pressure correction
42+
- ``spce/ibi_pressure_wjk``: iterative boltzmann inversion for SPC/E
43+
water with wjk pressure correction
44+
- ``spce/ibi_hoomd-blue``: iterative boltzmann inversion for SPC/E
45+
water using hoomd-blue
46+
- ``spce/ibi_dlpoly``: iterative boltzmann inversion for SPC/E water
47+
using dl\_poly
48+
- ``spce/ibi_espresso``: iterative boltzmann inversion for SPC/E water
49+
using ESPResSo
50+
- ``spce/ibi_espressopp``: iterative boltzmann inversion for SPC/E
51+
water using ESPResSo++
52+
- ``spce/ibi_lammps``: iterative boltzmann inversion for SPC/E water
53+
using LAMMPS
54+
- ``spce/ibi_gromacs-multi``: iterative boltzmann inversion for SPC/E
55+
water using GROMACS' multidir feature
56+
- ``spce/imc`` inverse monte carlo for SPC/E water
57+
- ``spce/re``: relative entropy method for SPC/E water
58+
- ``spce/re_lammps``: relative entropy method for SPC/E water using
59+
LAMMPS
60+
- ``spce/realtime``: iterative boltzmann inversion realtime tutorial
61+
for SPC/E water
62+
- ``spce/realtime_lammps``: iterative boltzmann inversion realtime
63+
tutorial for SPC/E water using LAMMPS
64+
- ``spce/simplex``: simplex optimization for SPC/E water
65+
66+
- ``spce/simplex/simple``: optimizing the rdf
67+
- ``spce/simplex/pressure``: optimizing the rdf and pressure
68+
- ``spce/simplex/density``: optimizing the rdf and density
69+
70+
- ``spce/cma``: cma optimization for SPC/E water
71+
72+
- ``spce/cma/simple``: optimizing the rdf
73+
- ``spce/cma/density``: optimizing the rdf and the density
74+
75+
- ``methanol/atomistic``: atomistic simulations for methanol
76+
- ``methanol/force_matching``: force matching for methanol
77+
- ``methanol/ibi``: iterative boltzmann inversion for methanol
78+
- ``methanol/imc``: inverse monte carlo for methanol
79+
- ``methanol/imc_gromacs-remd``: inverse monte carlo for methanol with
80+
REMD (only for gromacs) during iterations
81+
82+
- ``propane/atomistic``: atomistic simulations for liquid propane
83+
- ``propane/ibi``: iterative boltzmann inversion for nonbonded
84+
interactions of liquid propane
85+
- ``propane/imc``: inverse monte carlo for nonbonded interactions of
86+
liquid propane
87+
- ``propane/single_chain``: atomistic simulations, boltzmann inversion
88+
and force matching for a single chain of propane
89+
90+
- ``hexane/atomistic``: atomistic simulations for liquid hexane
91+
- ``hexane/force_matching``: force matching (bonded and nonbonded
92+
interactions of liquid hexane
93+
- ``hexane/ibi_all``: iterative boltzmann inversion for bonded and
94+
nonbonded interactions of liquid hexane
95+
- ``hexane/ibi_nonbonded``: iterative boltzmann inversion for only
96+
nonbonded interactions of liquid hexane
97+
- ``hexane/hybrid_force_matching``: hybrid force matching of only
98+
nonbonded interactions (with bonded interactions from boltzmann
99+
inversion)
100+
101+
- ``methanol-water``: methanol-water mixture for 3 different
102+
concentrations
103+
104+
- \`methanol-water/\*/atomistic atomistic simulations
105+
- ``methanol-water/*/re``: relative entropy method
106+
- ``methanol-water/*/simplex``: simplex optimizing
107+
108+
- ``urea-water/atomistic``: atomistic reference simulations urea-water
109+
mixture
110+
- ``urea-water/kb-ibi``: Kirkwood-Buff coarse-graining (see Ganguly et
111+
al. J. Chem. Theo. Comp., 8, 1802 (2012) for details)
112+
- ``urea-water/cibi``: Coordination iterative Boltzmann inversion (see
113+
T. E. de Oliveira et al., JCP 144, 174106 (2016) for details) -
114+
different molarity than kb-ibi
115+
- ``urea-water/cibi/pre``: IBI preparation run for cibi
116+
- ``urea-water/ibi``: boltzmann inversion (to compare to kb-ibi)
117+
118+
- ``LJ1-LJ2/imc``: regularization of inverse Monte-Carlo (see
119+
Rosenberger et al. Eur. Phys. J. Special Topics 225, 1323-1345 (2016)
120+
for details)
121+
122+
Each of the tutorials contains a ``run.sh`` which lists all commands
123+
needed to execute the tutorial.
124+
125+
.. |Codacy Badge| image:: https://app.codacy.com/project/badge/Grade/677ff88de55e46ee9411e2eaa6248e0c
126+
:target: https://www.codacy.com/gh/votca/csg-tutorials?utm_source=github.com&utm_medium=referral&utm_content=votca/csg-tutorials&utm_campaign=Badge_Grade
127+
.. |codecov| image:: https://codecov.io/gh/votca/csg-tutorials/branch/master/graph/badge.svg
128+
:target: https://codecov.io/gh/votca/csg-tutorials
129+
.. |CI| image:: https://github.com/votca/votca/workflows/CI/badge.svg?branch=master
130+
:target: https://github.com/votca/votca/actions?query=workflow%3ACI+branch%3Amaster
131+
.. |DOI| image:: https://zenodo.org/badge/DOI/10.5281/zenodo.3902713.svg
132+
:target: https://doi.org/10.5281/zenodo.3902713

0 commit comments

Comments
 (0)