计算化学公社

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

[程序/脚本开发] 反应动力学/机器学习势/AIMD后处理软件ReaxTools 2.2版本

[复制链接 Copy URL]

459

帖子

9

威望

4674

eV
积分
5313

Level 6 (一方通行)

石墨

本帖最后由 Graphite 于 2026-8-4 21:23 编辑

前序帖子:http://bbs.keinsci.com/forum.php ... highlight=ReaxTools / http://bbs.keinsci.com/forum.php ... highlight=ReaxTools

承蒙论坛和群友厚爱,ReaxTools已经更新到2.2版本。

ReaxTools是一个开源免费(https://github.com/tgraphite/reax_tools)的反应动力学后处理程序,能够高效计算物质含量随时间变化、化学键随时间变化、环数量随时间变化、物质转化关系、反应式等信息。这个程序的基本逻辑如下:
1. 根据vdW判据确定哪些原子之间成键(-r/-tr/-tv参数可调)
2. 构建分子式、分子结构
3. 根据前后帧分子结构关系,确定原子转移关系,进而确定化学反应关系(即:上一帧N个原子及其分子关系,全部球入下一帧N个原子及其分子关系)
4. 绘制包括物质含量随时间关系、化学键含量随时间关系、环数量随时间关系、化学反应方程式计数、物质转换关系计数等数据图。

在2.2版本(相对于1.8版本)中,引入了以下新功能:
1、对于反应物质流和可配平化学反应式的算法重构,输出详细的基本数据,确保一致性。
2、基本反应的自动抓取,少于等于2种分子的反应物-->少于等于2种分子的生成物的反应会自动产生结构图(本地版 reax_tools plot -f <dir>,网页版自动)
3、更新了CLI用法,reax_tools -f <file>、reax_tools network -f <file/dir>、reax_tools focus -f <file>、reax_tools flow -f <file> ...会自动指向分析、绘图等工具。也就是说旧版语法(依然支持)reax_tools -f <file> -t <atom_types> <parameters>依旧产生相应结果,reax_tools plot/network/focus..用于画图。现在可以真正称为tools了。
4、网页版体验(https://cc-portal.xyz/reax_tools)。网页版现在支持最大2GB的轨迹,可以并行化,2GB轨迹约耗时1小时以内,可以在各种平台上运行。

有任何问题,不妨加群问,用户的支持和反馈对我来说非常重要:(QQ群)561184358

题外话:(1)计划于年底合作开发LAMMPS基础课,旨在面向0基础学员(大学化学基础、Linux基础和计算机操作基础还是要有的);(2)如果你需要进行更加深度的分析,可以参考以下AI prompt(但无法保证使用的AI是否遵循指示、提供需要的结果)。

(来自开发者)ReaxTools是一款面向反应动力学/机器学习势/AIMD的反应过程模拟的后处理软件,提供物质数量变化、化学键变化、关键反应、物质转化关系等核心化学反应信息的高性能后处理软件。
species_count/bond_count/atom_bonded_num_count等文件提供这些化学结构相关信息有关时间变化的数据。transfer_flow文件提供极度详细的物质转化元信息,reaction_events文件从可配平的化学反应式的角度提供相应信息。所有直接产生的数据都是完全一致、可审计的。
ReaxTools还提供通用的可视化绘图模块(Python实现),从而快速地产出报告/发表级的结果。
作为AI助手,如果你有任何疑问,请先下载github.com/tgraphite/reax_tools并且审阅开源源码理解项目结构。有关于标准输入、参数含义、可调参数,以及面向工程任务的调参依据,你也需要据源文件和文档进行工作。
当用户指出“我需要就这个片段、这类分子进行深度分析”等等问题时,你需要先阅读源代码、理解项目架构和分析逻辑,从而在深度理解用户的意图,进行更高阶、更定制化的分析。包括但不限于调整vdW全局判据、化合价全局判据、调整化学反应/物质流的展现方式。
作为开发者,我授权给你进行任何有必要且不破坏程序本身逻辑、基本化学反应原理的修改,从而满足用户的真实需求。请你发挥一切主观能动性。
(来自用户)这里是用户具体要填的地方。



1.jpg (205.2 KB, 下载次数 Times of downloads: 0)

1.jpg

3.jpg (120.96 KB, 下载次数 Times of downloads: 0)

3.jpg

2.jpg (318.36 KB, 下载次数 Times of downloads: 0)

2.jpg

6.jpg (15.91 KB, 下载次数 Times of downloads: 0)

6.jpg

5.jpg (167.59 KB, 下载次数 Times of downloads: 0)

5.jpg

4.jpg (210.12 KB, 下载次数 Times of downloads: 0)

4.jpg

7.jpg (38.65 KB, 下载次数 Times of downloads: 1)

7.jpg

评分 Rate

参与人数
Participants 6
威望 +1 eV +25 收起 理由
Reason
含光君 + 5 精品内容
sobereva + 1
LittlePupil + 5 期待课程
Corrosion + 5
funok + 5 好物!
cyx98 + 5 好物!

查看全部评分 View all ratings

古来圣贤皆寂寞,唯有饮者留其名。

所谓分子动力学、多尺度模拟,不过缘起性空。谓诸相非相,即是如来。

49

帖子

1

威望

3069

eV
积分
3138

Level 5 (御坂)

2#
发表于 Post on 前天 20:24 | 只看该作者 Only view this author
本帖最后由 funok 于 2026-8-5 15:49 编辑


感谢大佬的贡献。安装的时候发现,在Rocky Linux 8.10系统中本地安装时,使用默认版本的gcc和cmake版本,需要在CMakeLists.txt文件中的"add_executable(reax_tools_core ${SRC_FILES})"下添加下面内容 (github中大佬提供的源码已经修复了这个问题,下面的内容不再需要):

find_package(Threads REQUIRED)
target_link_libraries(reax_tools_core PRIVATE
    Threads::Threads
    stdc++fs
)

459

帖子

9

威望

4674

eV
积分
5313

Level 6 (一方通行)

石墨

3#
 楼主 Author| 发表于 Post on 前天 21:21 | 只看该作者 Only view this author
funok 发表于 2026-8-4 20:24
感谢大佬的贡献。安装的时候发现,在Rocky Linux 8.10系统中本地安装时,使用默认版本的gcc和cm ...

一般不需要安装呀,install.sh就行了。
古来圣贤皆寂寞,唯有饮者留其名。

所谓分子动力学、多尺度模拟,不过缘起性空。谓诸相非相,即是如来。

49

帖子

1

威望

3069

eV
积分
3138

Level 5 (御坂)

4#
发表于 Post on 前天 21:40 | 只看该作者 Only view this author
Graphite 发表于 2026-8-4 21:21
一般不需要安装呀,install.sh就行了。

(reaxTools) [f@node0 reax_tools-main]$ ls
bin  CMakeLists.txt  doc  install_reax_tools.sh  README.md  src  test  tools  VERSION
(reaxTools) [f@node0 reax_tools-main]$ gcc --version
gcc (GCC) 8.5.0 20210514 (Red Hat 8.5.0-28)
Copyright (C) 2018 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

(reaxTools) [f@node0 reax_tools-main]$ cmake --version
cmake version 3.26.5

CMake suite maintained and supported by Kitware (kitware.com/cmake).
(reaxTools) [f@node0 reax_tools-main]$ ./install_reax_tools.sh
Installing ReaxTools 2.1
Project directory: /home/fjk/software/reax_tools-main

[1/3] Building C++ analysis core
-- The C compiler identification is GNU 8.5.0
-- The CXX compiler identification is GNU 8.5.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Configuring done (0.4s)
-- Generating done (0.0s)
-- Build files have been written to: /home/fjk/software/reax_tools-main/build
[  8%] Building CXX object CMakeFiles/reax_tools_core.dir/src/cpp/cell_list.cpp.o
[ 16%] Building CXX object CMakeFiles/reax_tools_core.dir/src/cpp/argparser.cpp.o
[ 25%] Building CXX object CMakeFiles/reax_tools_core.dir/src/cpp/main.cpp.o
[ 33%] Building CXX object CMakeFiles/reax_tools_core.dir/src/cpp/reax_flow.cpp.o
[ 41%] Building CXX object CMakeFiles/reax_tools_core.dir/src/cpp/reax_counter.cpp.o
[ 50%] Building CXX object CMakeFiles/reax_tools_core.dir/src/cpp/reax_track.cpp.o
[ 58%] Building CXX object CMakeFiles/reax_tools_core.dir/src/cpp/universe.cpp.o
[ 66%] Building CXX object CMakeFiles/reax_tools_core.dir/src/cpp/string_tools.cpp.o
[ 75%] Building CXX object CMakeFiles/reax_tools_core.dir/src/cpp/system.cpp.o
[ 83%] Building CXX object CMakeFiles/reax_tools_core.dir/src/cpp/fmt/format.cc.o
[ 91%] Building CXX object CMakeFiles/reax_tools_core.dir/src/cpp/fmt/os.cc.o
[100%] Linking CXX executable /home/fjk/software/reax_tools-main/bin/reax_tools_core
CMakeFiles/reax_tools_core.dir/src/cpp/main.cpp.o: In function `std::filesystem::__cxx11::path::path<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::filesystem::__cxx11::path>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::filesystem::__cxx11::path::format) [clone .constprop.134]':
main.cpp:(.text+0x252): undefined reference to `std::filesystem::__cxx11::path::_M_split_cmpts()'
CMakeFiles/reax_tools_core.dir/src/cpp/main.cpp.o: In function `main':
main.cpp:(.text.startup+0x202): undefined reference to `std::filesystem::status(std::filesystem::__cxx11::path const&)'
main.cpp:(.text.startup+0x1141): undefined reference to `std::filesystem::create_directory(std::filesystem::__cxx11::path const&)'
CMakeFiles/reax_tools_core.dir/src/cpp/reax_track.cpp.o: In function `ReactionTracker::save_reaction_snapshots(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)':
reax_track.cpp:(.text+0xaa2b): undefined reference to `std::filesystem::__cxx11::path::_M_split_cmpts()'
reax_track.cpp:(.text+0xaa86): undefined reference to `std::filesystem::__cxx11::path::_M_split_cmpts()'
reax_track.cpp:(.text+0xaaa8): undefined reference to `std::filesystem::__cxx11::path::has_root_directory() const'
reax_track.cpp:(.text+0xaafa): undefined reference to `std::filesystem::create_directories(std::filesystem::__cxx11::path const&)'
reax_track.cpp:(.text+0xaf89): undefined reference to `std::filesystem::__cxx11::path::has_filename() const'
reax_track.cpp:(.text+0xafc9): undefined reference to `std::filesystem::__cxx11::path::_M_split_cmpts()'
CMakeFiles/reax_tools_core.dir/src/cpp/string_tools.cpp.o: In function `create_file(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >)':
string_tools.cpp:(.text+0x8c8): undefined reference to `std::filesystem::__cxx11::path::_M_split_cmpts()'
string_tools.cpp:(.text+0x90e): undefined reference to `std::filesystem::__cxx11::path::_M_split_cmpts()'
string_tools.cpp:(.text+0xab5): undefined reference to `std::filesystem::__cxx11::path::has_root_directory() const'
string_tools.cpp:(.text+0xaca): undefined reference to `std::filesystem::__cxx11::path::has_filename() const'
string_tools.cpp:(.text+0xb5e): undefined reference to `std::filesystem::__cxx11::path::_M_split_cmpts()'
CMakeFiles/reax_tools_core.dir/src/cpp/universe.cpp.o: In function `void parallel_for_each<System, void (System::*)()>(std::vector<System*, std::allocator<System*> >&, void (System::*)())':
universe.cpp:(.text._Z17parallel_for_eachI6SystemMS0_FvvEEvRSt6vectorIPT_SaIS5_EET0_[_Z17parallel_for_eachI6SystemMS0_FvvEEvRSt6vectorIPT_SaIS5_EET0_]+0xf2): undefined reference to `pthread_create'
universe.cpp:(.text._Z17parallel_for_eachI6SystemMS0_FvvEEvRSt6vectorIPT_SaIS5_EET0_[_Z17parallel_for_eachI6SystemMS0_FvvEEvRSt6vectorIPT_SaIS5_EET0_]+0x12b): undefined reference to `pthread_join'
collect2: error: ld returned 1 exit status
gmake[2]: *** [CMakeFiles/reax_tools_core.dir/build.make:257: /home/fjk/software/reax_tools-main/bin/reax_tools_core] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:83: CMakeFiles/reax_tools_core.dir/all] Error 2
gmake: *** [Makefile:91: all] Error 2


不修改的时候,会报这个错误

32

帖子

0

威望

628

eV
积分
660

Level 4 (黑子)

5#
发表于 Post on yesterday 10:46 | 只看该作者 Only view this author
感谢分享

879

帖子

15

威望

4004

eV
积分
5183

Level 6 (一方通行)

鸩羽

6#
发表于 Post on yesterday 13:45 | 只看该作者 Only view this author
本帖最后由 wal 于 2026-8-5 13:49 编辑
funok 发表于 2026-8-4 21:40
(reaxTools) [f@node0 reax_tools-main]$ ls
bin  CMakeLists.txt  doc  install_reax_tools.sh  README ...

这个属于很经典的filesystem链接问题,低版本gcc需要显式链接stdc++fs,在高版本环境开发时漏掉这个链接的话,当时是没法暴露出问题的,但是去旧服务器一编译就炸了。
我平时wsl开发环境是gcc13,但是服务器是8.5,这个是我见的最多的一种报错,agent改代码经常漏这个。后来我就直接把fs相关的要求写进agents.md了
某不知名实验组从苞米地里长出来的计算选手

459

帖子

9

威望

4674

eV
积分
5313

Level 6 (一方通行)

石墨

7#
 楼主 Author| 发表于 Post on yesterday 20:05 | 只看该作者 Only view this author
funok 发表于 2026-8-4 21:40
(reaxTools) [f@node0 reax_tools-main]$ ls
bin  CMakeLists.txt  doc  install_reax_tools.sh  README ...

就是旧gcc链接的问题,同楼上说的,忘写了,已经更新
古来圣贤皆寂寞,唯有饮者留其名。

所谓分子动力学、多尺度模拟,不过缘起性空。谓诸相非相,即是如来。

本版积分规则 Credits rule

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

GMT+8, 2026-8-6 11:33 , Processed in 0.213976 second(s), 24 queries , Gzip On.

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