What is ænet?
The Atomic Energy NETwork (ænet) package (http://ann.atomistic.net) is a collection of tools for the construction and application of atomic interaction potentials based on artificial neural networks (ANN). The ænet code allows the accurate interpolation of structural energies, e.g., from electronic structure calculations, using ANNs. ANN potentials generated with ænet can then be used in larger scale atomistic simulations and in situations where extensive sampling is required, e.g., in molecular dynamics or Monte-Carlo simulations.
License
Copyright (C) 2012-2022 Nongnuch Artrith ([email protected])
The aenet source code is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the Mozilla Public License, v. 2.0, for more details.
Installation
Short installation summary
-
Compile the L-BFGS-B library
-
Enter the directory “./lib”
$ cd ./lib
-
Adjust the compiler settings in the “Makefile”
-
Compile the library with
$ make
The library file
liblbfgsb.a
, required for compiling ænet, will be created. -
-
Compile the ænet package
-
Enter the directory “./src”
$ cd ./src
-
Compile the ænet source code with
$ make -f makefiles/Makefile.XXX
where
Makefile.XXX
is an approproiate Makefile.To see a list of available Makefiles just type:
$ make
The following executables will be generated in “./bin”:
generate.x
: generate training sets from atomic structure filestrain.x
: train new neural network potentialspredict.x
: use existing ANN potentials for energy/force prediction
-
-
(Optional) Install the Python interface
-
Enter the directory “./python”
$ cd ./python
-
Install the Python module with
$ python setup.py install --user
This will set up the Python ænet module for the current user, and it will also install the user scripts
aenet-predict.py
andaenet-md.py
. -
Detailed installation instructions
Except for a number of Python scripts, ænet is developed in Fortran 95/2003. Generally, the source code is tested with the free GNU Fortran compiler and the commercial Intel Fortran compiler, and the Makefile settings for these two compilers are provided. While the ænet source code should be platform independent, we mainly target Linux and Unix clusters and ænet has not been tested on other operating systems.
ænet requires three external libraries:
- BLAS (Basic Linear Algebra Subprograms),
- LAPACK (Linear Algebra PACKage),
- And the L-BFGS-B optimization routines by Nocedal et al.
Usually, some implementation of BLAS and LAPACK comes with the operating
system or the compiler. If that is not the case, the libraries can be
obtained from Netlib.org. libblas.a
and
liblapack.a
have to be in the system library path in order to compile
ænet.
The L-BFGS-B routines, an implementation of the bounded limited-memory Broyden-Fletcher-Goldfarb-Shanno algorithm, is distributed on the homepage of the authors (Nocedal et al.). For the user’s convenience we have decided to distribute the original L-BFGS-B files along with ænet package, so you do not have to actually download the library yourself. However, each application of ænet should also acknowledge the use of the L-BFGS-B library by citing:
R. H. Byrd, P. Lu and J. Nocedal, SIAM J. Sci. Stat. Comp. 16 (1995) 1190-1208.
ænet’s Python interface further relies on NumPy and on the Atomic simulation Environment, so these dependencies have to available when the ænet Python module is set up.
Compilation of external libraries that are distributed with ænet
All external libraries needed by the ænet code are in the directory “./lib”. Currently, only one external library is distributed with ænet, the L-BFGS-B library (see above).
To compile the external libraries
-
Enter the directory “./lib”
$ cd ./lib
-
Adjust the compiler settings in the “Makefile”
The Makefile contains settings for the GNU Fortran compiler (
gfortran
) and the Intel Fortran compiler (ifort
). Uncomment the section that is appropriate for your system. -
Compile the library with
$ make
The static library “liblbfgsb.a”, required to build ænet, will be created.
Build ænet
The ænet source code is located in “./src”.
-
Enter “./src”
$ cd ./src
-
To see a short explanation of the Makefiles that come with ænet, just run
make
without any options.$ make
Select the Makefile that is appropriate for your computer.
-
Compile with
$ make -f makefiles/Makefile.XXX
where
Makefile.XXX
is the selected Makefile.
Three executables will be generated and stored in “./bin”:
generate.x
: generate training sets from atomic structure filestrain.x
: train new neural network potentialspredict.x
: use existing ANN potentials for energy/force prediction
Set up the Python interface
-
Enter the directory “./python”
$ cd ./python
-
Install the Python module with
$ python setup.py install --user
This will set up the Python ænet module for the current user, and it
will also install the user scripts aenet-predict.py
and aenet-md.py
.