计算化学公社

 找回密码 Forget password
 注册 Register
Views: 5528|回复 Reply: 20
打印 Print 上一主题 Last thread 下一主题 Next thread

[CP2K] CP2K-2024.2 发布了

[复制链接 Copy URL]

1105

帖子

0

威望

3956

eV
积分
5061

Level 6 (一方通行)


查看了一下 CP2K 的官网,发现三天前更新了 2024.2 版,算是半年更新的常规操作

New Features
  • Many new pages in the methods section of [color=var(--fgColor-accent, var(--color-accent-fg))]the manual
  • ECP nuclear gradients ([color=var(--fgColor-accent, var(--color-accent-fg))]#3210)
  • New basis sets ([color=var(--fgColor-accent, var(--color-accent-fg))]#3266, [color=var(--fgColor-accent, var(--color-accent-fg))]#3276 [color=var(--fgColor-accent, var(--color-accent-fg))]#3460, [color=var(--fgColor-accent, var(--color-accent-fg))]#3561)
  • TDA Kernel methods ([color=var(--fgColor-accent, var(--color-accent-fg))]#3273)
  • Bethe Salpeter equation for molecules ([color=var(--fgColor-accent, var(--color-accent-fg))]#3308, [color=var(--fgColor-accent, var(--color-accent-fg))]#3329)
  • Stress prediction in NequIP & Allegro ([color=var(--fgColor-accent, var(--color-accent-fg))]#3428, [color=var(--fgColor-accent, var(--color-accent-fg))]#3445)
  • GW for small unit cells with full k-points ([color=var(--fgColor-accent, var(--color-accent-fg))]#3448, [color=var(--fgColor-accent, var(--color-accent-fg))]#3505, [color=var(--fgColor-accent, var(--color-accent-fg))]#3513)
  • Hedin shift for G0W0 ([color=var(--fgColor-accent, var(--color-accent-fg))]#3533)
  • i-PI server functionality ([color=var(--fgColor-accent, var(--color-accent-fg))]#3420)
  • Infrastructure for Kpoint symmetries ([color=var(--fgColor-accent, var(--color-accent-fg))]#3482)
New Libraries
  • Machine learning with the [color=var(--fgColor-accent, var(--color-accent-fg))]DeePMD-kit ([color=var(--fgColor-accent, var(--color-accent-fg))]#3145)
  • Dispersion correction with the [color=var(--fgColor-accent, var(--color-accent-fg))]DFTD4 library ([color=var(--fgColor-accent, var(--color-accent-fg))]#3501)
  • GPU support via OpenCL ([color=var(--fgColor-accent, var(--color-accent-fg))]#3321, [color=var(--fgColor-accent, var(--color-accent-fg))]#3315, [color=var(--fgColor-accent, var(--color-accent-fg))]#3375)
Breaking Changes
  • Increase ScaLAPACK default block size to 64 ([color=var(--fgColor-accent, var(--color-accent-fg))]#3184)
  • Remove BROYDEN_MIXING_NEW option ([color=var(--fgColor-accent, var(--color-accent-fg))]#3346)
  • Remove KP_RI_EXTENSION_FACTOR" keyword ([color=var(--fgColor-accent, var(--color-accent-fg))]#3223)
  • Mark support for QUIP and PEXSI as deprecated ([color=var(--fgColor-accent, var(--color-accent-fg))]#3600)
Fixes
  • Fix oscillator strength for TDDFT+SOC within length and velocity representation ([color=var(--fgColor-accent, var(--color-accent-fg))]#3201)
  • External potential: Do not re-parse potential function at each grid-point ([color=var(--fgColor-accent, var(--color-accent-fg))]#3204)
  • PWDFT: Print the band gap and total energy ([color=var(--fgColor-accent, var(--color-accent-fg))]#3211)
  • Fix bug [color=var(--fgColor-accent, var(--color-accent-fg))]#3218 in screening of hfx derivatives ([color=var(--fgColor-accent, var(--color-accent-fg))]#3221)
  • Fix bug [color=var(--fgColor-accent, var(--color-accent-fg))]#3217 in printout of eigenvalues and eigenvectors ([color=var(--fgColor-accent, var(--color-accent-fg))]#3230)
  • Improve element comparison in reftraj ([color=var(--fgColor-accent, var(--color-accent-fg))]#3337)
  • Allegro: Fix parallelization with virials ([color=var(--fgColor-accent, var(--color-accent-fg))]#3445)
  • FFTW: Fix import/export wisdom file ([color=var(--fgColor-accent, var(--color-accent-fg))]#3492, [color=var(--fgColor-accent, var(--color-accent-fg))]#3496)



从 toolchain 里可以看到
  1. install_cp2k_toolchain.sh [options]

  2. OPTIONS:

  3. -h, --help                Show this message.
  4. -j <n>                    Number of processors to use for compilation, if
  5.                           this option is not present, then the script
  6.                           automatically tries to determine the number of
  7.                           processors you have and try to use all of the
  8.                           processors.
  9. --no-check-certificate    If you encounter "certificate verification" errors
  10.                           from wget or ones saying that "common name doesn't
  11.                           match requested host name" while at tarball downloading
  12.                           stage, then the recommended solution is to install
  13.                           the newest wget release. Alternatively, you can use
  14.                           this option to bypass the verification and proceed with
  15.                           the download. Security wise this should still be okay
  16.                           as the installation script will check file checksums
  17.                           after every tarball download. Nevertheless use this
  18.                           option at your own risk.
  19. --install-all             This option will set value of all --with-PKG
  20.                           options to "install". You can selectively set
  21.                           --with-PKG to another value again by having the
  22.                           --with-PKG option placed AFTER this option on the
  23.                           command line.
  24. --mpi-mode                Selects which MPI flavour to use. Available options
  25.                           are: mpich, openmpi, intelmpi, and no. By selecting "no",
  26.                           MPI is not supported and disabled. By default the script
  27.                           will try to determine the flavour based on the MPI library
  28.                           currently available in your system path. For CRAY (CLE)
  29.                           systems, the default flavour is mpich. Note that explicitly
  30.                           setting --with-mpich, --with-openmpi or --with-intelmpi
  31.                           options to values other than no will also switch --mpi-mode
  32.                           to the respective mode.
  33. --math-mode               Selects which core math library to use. Available options
  34.                           are: acml, cray, mkl, and openblas. The option "cray"
  35.                           corresponds to cray libsci, and is the default for CRAY
  36.                           (CLE) systems. For non-CRAY systems, if env variable MKLROOT
  37.                           exists then mkl will be default, otherwise openblas is the
  38.                           default option. Explicitly setting --with-acml, --with-mkl,
  39.                           or --with-openblas options will switch --math-mode to the
  40.                           respective modes.
  41. --gpu-ver                 Selects the GPU architecture for which to compile. Available
  42.                           options are: K20X, K40, K80, P100, V100, Mi50, Mi100, Mi250,
  43.                           and no.
  44.                           This setting determines the value of nvcc's '-arch' flag.
  45.                           Default = no.
  46. --libint-lmax             Maximum supported angular momentum by libint.
  47.                           Higher values will increase build time and library size.
  48.                           Default = 5
  49. --log-lines               Number of log file lines dumped in case of a non-zero exit code.
  50.                           Default = 200
  51. --target-cpu              Compile for the specified target CPU (e.g. haswell or generic), i.e.
  52.                           do not optimize for the actual host system which is the default (native)
  53. --no-arch-files           Do not generate arch files
  54. --dry-run                 Write only config files, but don't actually build packages.

  55. The --enable-FEATURE options follow the rules:
  56.   --enable-FEATURE=yes    Enable this particular feature
  57.   --enable-FEATURE=no     Disable this particular feature
  58.   --enable-FEATURE        The option keyword alone is equivalent to
  59.                           --enable-FEATURE=yes

  60.   --enable-cuda           Turn on GPU (CUDA) support (can be combined
  61.                           with --enable-opencl).
  62.                           Default = no
  63.   --enable-hip            Turn on GPU (HIP) support.
  64.                           Default = no
  65.   --enable-opencl         Turn on OpenCL (GPU) support. Requires the OpenCL
  66.                           development packages and runtime. If combined with
  67.                           --enable-cuda, OpenCL alongside of CUDA is used.
  68.                           Default = no
  69.   --enable-cray           Turn on or off support for CRAY Linux Environment
  70.                           (CLE) manually. By default the script will automatically
  71.                           detect if your system is CLE, and provide support
  72.                           accordingly.

  73. The --with-PKG options follow the rules:
  74.   --with-PKG=install      Will download the package in $PWD/build and
  75.                           install the library package in $PWD/install.
  76.   --with-PKG=system       The script will then try to find the required
  77.                           libraries of the package from the system path
  78.                           variables such as PATH, LD_LIBRARY_PATH and
  79.                           CPATH etc.
  80.   --with-PKG=no           Do not use the package.
  81.   --with-PKG=<path>       The package will be assumed to be installed in
  82.                           the given <path>, and be linked accordingly.
  83.   --with-PKG              The option keyword alone will be equivalent to
  84.                           --with-PKG=install

  85.   --with-gcc              The GCC compiler to use to compile CP2K.
  86.                           Default = system
  87.   --with-intel            Use the Intel compiler to compile CP2K.
  88.                           Default = system
  89.   --with-intel-classic    Use the classic Intel compiler to compile CP2K.
  90.                           Default = no
  91.   --with-cmake            Cmake utilities
  92.                           Default = install
  93.   --with-ninja            Ninja utilities
  94.                           Default = install
  95.   --with-openmpi          OpenMPI, important if you want a parallel version of CP2K.
  96.                           Default = system
  97.   --with-mpich            MPICH, MPI library like OpenMPI. one should
  98.                           use only one of OpenMPI, MPICH or Intel MPI.
  99.                           Default = system
  100.   --with-mpich-device     Select the MPICH device, implies the use of MPICH as MPI library
  101.                           Default = ch4
  102.   --with-intelmpi         Intel MPI, MPI library like OpenMPI. one should
  103.                           use only one of OpenMPI, MPICH or Intel MPI.
  104.                           Default = system
  105.   --with-libxc            libxc, exchange-correlation library. Needed for
  106.                           QuickStep DFT and hybrid calculations.
  107.                           Default = install
  108.   --with-libint           libint, library for evaluation of two-body molecular
  109.                           integrals, needed for hybrid functional calculations
  110.                           Default = install
  111.   --with-libgrpp          libgrpp, library for the evaluation of ECP integrals, needed
  112.                           for any calculations with semi-local ECP pseudopotentials
  113.                           Default = install
  114.   --with-fftw             FFTW3, library for fast fourier transform
  115.                           Default = install
  116.   --with-acml             AMD core maths library, which provides LAPACK and BLAS
  117.                           Default = system
  118.   --with-mkl              Intel Math Kernel Library, which provides LAPACK, and BLAS.
  119.                           If MKL's FFTW3 interface is suitable (no FFTW-MPI support),
  120.                           it replaces the FFTW library. If the ScaLAPACK component is
  121.                           found, it replaces the one specified by --with-scalapack.
  122.                           Default = system
  123.   --with-openblas         OpenBLAS is a free high performance LAPACK and BLAS library,
  124.                           the successor to GotoBLAS.
  125.                           Default = install
  126.   --with-scalapack        Parallel linear algebra library, needed for parallel
  127.                           calculations.
  128.                           Default = install
  129.   --with-libxsmm          Small matrix multiplication library.
  130.                           Default = install
  131.   --with-elpa             Eigenvalue SoLvers for Petaflop-Applications library.
  132.                           Fast library for large parallel jobs.
  133.                           Default = install
  134.   --with-cusolvermp       NVIDIA cusolverMp: CUDA library for distributed dense linear algebra.
  135.                           Default = no
  136.   --with-ptscotch         PT-SCOTCH, only used if PEXSI is used
  137.                           Default = no
  138.   --with-superlu          SuperLU DIST, used only if PEXSI is used
  139.                           Default = no
  140.   --with-pexsi            Enable interface to PEXSI library
  141.                           Default = no
  142.   --with-quip             Enable interface to QUIP library
  143.                           Default = no
  144.   --with-deepmd           Enable interface to DeePMD-kit library.
  145.                           Default = no
  146.   --with-plumed           Enable interface to the PLUMED library.
  147.                           Default = no
  148.   --with-sirius           Enable interface to the plane wave SIRIUS library.
  149.                           This package requires: gsl, libspg, elpa, scalapack, hdf5 and libxc.
  150.                           Default = install
  151.   --with-gsl              Enable the gnu scientific library (required for PLUMED and SIRIUS)
  152.                           Default = install
  153.   --with-libvdwxc         Enable support of Van der Waals interactions in SIRIUS. Support provided by libvdwxc
  154.                           Default = install
  155.   --with-spglib           Enable the spg library (search of symmetry groups)
  156.                           This package depends on cmake.
  157.                           Default = install
  158.   --with-hdf5             Enable the hdf5 library (used by the sirius library)
  159.                           Default = install
  160.   --with-spfft            Enable the spare fft used in SIRIUS (hard dependency)
  161.                           Default = install
  162.   --with-spla             Enable the Specialized Parallel Linear Algebra library (required by SIRIUS)
  163.                           Default = install
  164.   --with-cosma            Enable cosma as a replacement for scalapack matrix multiplication
  165.                           Default = install
  166.   --with-libvori          Enable libvori for the Voronoi integration (and the BQB compressed trajectory format)
  167.                           Default = install
  168.   --with-libtorch         Enable libtorch the machine learning framework needed for NequIP and Allegro
  169.                           Default = no
  170.   --with-dftd4            Enable the DFTD4 package by Grimme
  171.                           This package requires cmake, ninja
  172.                           Default = install
复制代码


默认安装选项(Default = install)里增加了 --with-ninja, --with-dftd4,
可选安装项里增加了 --with-deepmd


另外,从 scripts/stage1/install_openmpi.sh 里可以看到,这次的 openmpi 升级到 5.0.5 版

评分 Rate

参与人数
Participants 3
eV +13 收起 理由
Reason
HAC + 3 好物!
ezez + 5 赞!
John_Tao + 5 谢谢分享

查看全部评分 View all ratings

23

帖子

0

威望

262

eV
积分
285

Level 3 能力者

21#
发表于 Post on 2025-4-30 16:31:15 | 只看该作者 Only view this author
本帖最后由 hahajisuanxuexi 于 2025-4-30 16:34 编辑
cyclex 发表于 2024-12-23 13:14
可以参考我的解决方法:

(1)首先按正常流程执行编译,让程序自然报错,目的是为了在 build 文件夹下 ...

今年mctc-lib、multicharge版本都更新了,根据像“git clone https://github.com/grimme-lab/mctc-lib/”之类的命令下载下来的程序的版本都是最新版,这样的话安装过程会报错“CMake Error at subprojects/multicharge/app/cmake_install.cmake:52 (file):
  file INSTALL cannot find
  "…………/software/cp2k-2025.1/tools/toolchain/build/dftd4-3.6.0/build/subprojects/multicharge/app/multicharge":
  No such file or directory.
Call Stack (most recent call first):
  subprojects/multicharge/cmake_install.cmake:57 (include)

  cmake_install.cmake:62 (include)”,如果要正常安装就不能使用git clone命令下载某些程序的最新版,根据我的测试,mctc用0.3.1版,multicharge使用0.2.0版,mstore使用最新版是可以正常安装的。

而且如果电脑是联网用toolchain自动安装最新版本的CP2K的话,安装DFTD4时也会遇到toolchain下载最新版本的mctc和multicharge导致安装报错的问题,这种情况下也得用上文作者所介绍的方法手动下载老版本的依赖程序才能解决报错的问题。

评分 Rate

参与人数
Participants 1
eV +5 收起 理由
Reason
cyclex + 5 谢谢分享

查看全部评分 View all ratings

6

帖子

0

威望

158

eV
积分
164

Level 3 能力者

20#
发表于 Post on 2025-3-24 00:00:42 | 只看该作者 Only view this author
UW_0728. 发表于 2025-3-23 23:42
不如直接从dftd4官方github仓库自行下载编译一份单独的dftd4,然后toolchain选项里面用--with-dftd4=system ...

但是需要指定setup里面的路径,否则后续make时候会报错

6

帖子

0

威望

158

eV
积分
164

Level 3 能力者

19#
发表于 Post on 2025-3-23 23:42:35 | 只看该作者 Only view this author
不如直接从dftd4官方github仓库自行下载编译一份单独的dftd4,然后toolchain选项里面用--with-dftd4=system,不加--with-ninja(因为前面编译的时候自己要预安装ninja-build的,ubuntu中指令为sudo apt install ninja-build,其他系统应该类似)。这样就完美避开用toolchain安装dftd4时各种层出不穷的错误了,也不用多折腾。

9

帖子

0

威望

227

eV
积分
236

Level 3 能力者

18#
发表于 Post on 2024-12-23 13:14:41 | 只看该作者 Only view this author
南北多歧路 发表于 2024-11-14 01:39
请问这一步的细节是什么?我也卡在了Retrieving mctc-lib revision v0.3.0 from https://github.com/grim ...

可以参考我的解决方法:

(1)首先按正常流程执行编译,让程序自然报错,目的是为了在 build 文件夹下创建出 dftd4-3.6.0 文件夹及子文件夹。

(2)注释掉 toolchain/scripts/stage8/install_dftd4.sh文件中第 48、49 行,否则我们后续所做的所有步骤将会在每次重新执行编译 dftd4 时,由于重新解压 dftd4-3.6.0.tar.gz 文件而覆盖掉,造成所有努力白费。
  1. #[ -d dftd4-${dftd4_ver} ] && rm -rf dftd4-${dftd4_ver}
  2. #tar -xzf dftd4-${dftd4_ver}.tar.gz
复制代码

(3)手动 clone mctc-lib, mstore, multicharge 到本地电脑。
  1. git clone https://github.com/grimme-lab/mctc-lib/
  2. git clone https://github.com/grimme-lab/mstore/
  3. git clone https://github.com/grimme-lab/multicharge/
复制代码

(4)将上述 clone 得到的文件夹上传到 tools/toolchain/build/dftd4-3.6.0/subprojects,文件夹不用重命名。
这里参考了博文:带DFTD4色散修正版本VASP离线编译策略,感谢作者!


(5)重新执行编译即可。
  1. ./install_cp2k_toolchain.sh (加上你自定义的内容)
复制代码


评分 Rate

参与人数
Participants 2
eV +6 收起 理由
Reason
hahajisuanxuexi + 4 谢谢
LittlePupil + 2 谢谢分享

查看全部评分 View all ratings

17

帖子

0

威望

975

eV
积分
992

Level 4 (黑子)

17#
发表于 Post on 2024-11-14 16:23:38 | 只看该作者 Only view this author
牧生 发表于 2024-8-10 10:11
为了装dftd4,同时也需要装mctc-lib。

如果你的网不好,手动去https://github.com/grimme-lab/mctc-lib  ...

您好,按照您的提示这么操作之后仍然提示mctc-lib的相关问题
我才是旅途的终点!

17

帖子

0

威望

975

eV
积分
992

Level 4 (黑子)

16#
发表于 Post on 2024-11-14 01:39:11 | 只看该作者 Only view this author
1305559799 发表于 2024-8-27 13:25
手动下载放到这个目录下没用的,DFTD4不会在这里去找它;目前问题已自行解决了,需要下载解压放到DFTD4的 ...

请问这一步的细节是什么?我也卡在了Retrieving mctc-lib revision v0.3.0 from https://github.com/grimme-lab/mctc-lib 这一步,琢磨您的细节琢磨了一晚上hh
我才是旅途的终点!

51

帖子

0

威望

2590

eV
积分
2641

Level 5 (御坂)

15#
发表于 Post on 2024-9-10 15:49:09 | 只看该作者 Only view this author
昨晚发布的修订版CP2K v2024.3
This is a minor release to fix an issue with the PW environment that can lead to stalls during MD .
Since this only affects MPI jobs, the ssmp binaries from the previous 2024.2 release are still up-to-date.

评分 Rate

参与人数
Participants 1
eV +1 收起 理由
Reason
乐平 + 1 谢谢

查看全部评分 View all ratings

158

帖子

2

威望

3556

eV
积分
3754

Level 5 (御坂)

14#
发表于 Post on 2024-8-28 00:56:08 | 只看该作者 Only view this author
一个包含build的安装包,可用于离线安装CP2K-2024.2

3

帖子

0

威望

13

eV
积分
16

Level 1 能力者

13#
发表于 Post on 2024-8-27 13:25:49 | 只看该作者 Only view this author
乐平 发表于 2024-8-27 11:22
先用自己的电脑在 GitHub 上下载 mctc-lib,
Retrieving mctc-lib revision v0.3.0 from https://github ...

手动下载放到这个目录下没用的,DFTD4不会在这里去找它;目前问题已自行解决了,需要下载解压放到DFTD4的解压后的源码目录里面

1105

帖子

0

威望

3956

eV
积分
5061

Level 6 (一方通行)

12#
 楼主 Author| 发表于 Post on 2024-8-27 11:22:04 | 只看该作者 Only view this author
1305559799 发表于 2024-8-27 09:35
ninja已经安装了,只是在安装DFTD4时需要联网下载mctc-lib,我机器的环境没有网络,不好解决

先用自己的电脑在 GitHub 上下载 mctc-lib,
Retrieving mctc-lib revision v0.3.0 from https://github.com/grimme-lab/mctc-lib
注意,是 0.3.0 版




下载完之后,上传到你的服务器里,放在 cp2k-2024.2/tools/toolchain/build 目录下

然后重新编译,cp2k 会自动解压安装它【前提是,你之前 ninja 安装成功了】

3

帖子

0

威望

13

eV
积分
16

Level 1 能力者

11#
发表于 Post on 2024-8-27 09:35:34 | 只看该作者 Only view this author
本帖最后由 1305559799 于 2024-8-27 09:42 编辑
乐平 发表于 2024-8-26 09:58
安装 DFTD4 的前提是要安装 ninja

ninja已经安装了,只是在安装DFTD4时需要联网下载mctc-lib,我机器的环境没有网络,不好解决

1105

帖子

0

威望

3956

eV
积分
5061

Level 6 (一方通行)

10#
 楼主 Author| 发表于 Post on 2024-8-26 09:58:15 | 只看该作者 Only view this author
1305559799 发表于 2024-8-26 09:15
我也试了,不好使,我的机子没网,现在不知道咋解决

安装 DFTD4 的前提是要安装 ninja

3

帖子

0

威望

13

eV
积分
16

Level 1 能力者

9#
发表于 Post on 2024-8-26 09:15:32 | 只看该作者 Only view this author
wuy069 发表于 2024-8-20 09:15
单独下载压缩包后,放在cp2k的toolchain的build或者dftd4-3.6.0下面的buid文件夹都不好使啊。还是整了个 ...

我也试了,不好使,我的机子没网,现在不知道咋解决

51

帖子

0

威望

2590

eV
积分
2641

Level 5 (御坂)

8#
发表于 Post on 2024-8-20 09:15:02 | 只看该作者 Only view this author
牧生 发表于 2024-8-10 10:11
为了装dftd4,同时也需要装mctc-lib。

如果你的网不好,手动去https://github.com/grimme-lab/mctc-lib  ...

单独下载压缩包后,放在cp2k的toolchain的build或者dftd4-3.6.0下面的buid文件夹都不好使啊。还是整了个能连github的机器安装好的

手机版 Mobile version|北京科音自然科学研究中心 Beijing Kein Research Center for Natural Sciences|京公网安备 11010502035419号|计算化学公社 — 北京科音旗下高水平计算化学交流论坛 ( 京ICP备14038949号-1 )|网站地图

GMT+8, 2025-8-15 20:14 , Processed in 0.203025 second(s), 31 queries , Gzip On.

快速回复 返回顶部 返回列表 Return to list