AutoDock-GPU 实战测评:CUDA 编译、四体系基准与版本沿革

本文收录于专栏 gnina系列 ------ 专栏系统覆盖分子对接引擎选型、GPU 加速虚拟筛选与打分函数评估,点击订阅可跟踪后续更新。

你要把 AutoDock 系的虚拟筛选搬上 GPU,第一个撞上的问题往往不是算法,而是编译:官方 README 一句 make DEVICE=CUDA,实测会直接报 cuda.h: No such file or directory;仓库自带的五个测试体系里还有两个跑不起来。

这篇用一台消费级 GPU(12 GB 显存、sm_86)机器从零走完 AutoDock-GPU v1.6 的编译、修坑与测评:给出四体系基准(nrun=200 时 1.3--26 秒,盒子大小主导耗时)、NUMWI=64 对 128 的调优实测(小体系快约两成)、v1.4 到 v1.6 的版本沿革,以及与 Uni-Dock、Vina-CUDA、Vina CPU 单核的同机横向对照。读完你能直接抄走编译命令,也知道哪些坑该修、哪些体系该剔除。

文章同时交代了软链修复格点图命名冲突的具体命令、GPL-2.0 许可对闭源集成的约束,以及它"加速的是 AutoDock 4 自己"这一与 Vina 系不可直接比分的边界。

关键字:AutoDock-GPU、分子对接、GPU加速、CUDA编译、虚拟筛选、NUMWI、格点对接、LGA算法
#mermaid-svg-Jh5Tw0yQsZ3PW0HI{font-family:"trebuchet ms",verdana,arial,sans-serif;font-size:16px;fill:#333;}@keyframes edge-animation-frame{from{stroke-dashoffset:0;}}@keyframes dash{to{stroke-dashoffset:0;}}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-animation-slow{stroke-dasharray:9,5!important;stroke-dashoffset:900;animation:dash 50s linear infinite;stroke-linecap:round;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-animation-fast{stroke-dasharray:9,5!important;stroke-dashoffset:900;animation:dash 20s linear infinite;stroke-linecap:round;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .error-icon{fill:#552222;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .error-text{fill:#552222;stroke:#552222;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-thickness-normal{stroke-width:1px;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-thickness-thick{stroke-width:3.5px;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-pattern-solid{stroke-dasharray:0;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-thickness-invisible{stroke-width:0;fill:none;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-pattern-dashed{stroke-dasharray:3;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-pattern-dotted{stroke-dasharray:2;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .marker{fill:#333333;stroke:#333333;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .marker.cross{stroke:#333333;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI svg{font-family:"trebuchet ms",verdana,arial,sans-serif;font-size:16px;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI p{margin:0;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge{stroke-width:3;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section--1 rect,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section--1 path,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section--1 circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section--1 polygon,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section--1 path{fill:hsl(240, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section--1 text{fill:#ffffff;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .node-icon--1{font-size:40px;color:#ffffff;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-edge--1{stroke:hsl(240, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-depth--1{stroke-width:17;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section--1 line{stroke:hsl(60, 100%, 86.2745098039%);stroke-width:3;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:lightgray;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:#efefef;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-0 rect,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-0 path,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-0 circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-0 polygon,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-0 path{fill:hsl(60, 100%, 73.5294117647%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-0 text{fill:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .node-icon-0{font-size:40px;color:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-edge-0{stroke:hsl(60, 100%, 73.5294117647%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-depth-0{stroke-width:14;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-0 line{stroke:hsl(240, 100%, 83.5294117647%);stroke-width:3;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:lightgray;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:#efefef;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-1 rect,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-1 path,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-1 circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-1 polygon,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-1 path{fill:hsl(80, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-1 text{fill:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .node-icon-1{font-size:40px;color:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-edge-1{stroke:hsl(80, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-depth-1{stroke-width:11;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-1 line{stroke:hsl(260, 100%, 86.2745098039%);stroke-width:3;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:lightgray;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:#efefef;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-2 rect,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-2 path,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-2 circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-2 polygon,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-2 path{fill:hsl(270, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-2 text{fill:#ffffff;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .node-icon-2{font-size:40px;color:#ffffff;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-edge-2{stroke:hsl(270, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-depth-2{stroke-width:8;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-2 line{stroke:hsl(90, 100%, 86.2745098039%);stroke-width:3;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:lightgray;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:#efefef;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-3 rect,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-3 path,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-3 circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-3 polygon,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-3 path{fill:hsl(300, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-3 text{fill:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .node-icon-3{font-size:40px;color:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-edge-3{stroke:hsl(300, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-depth-3{stroke-width:5;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-3 line{stroke:hsl(120, 100%, 86.2745098039%);stroke-width:3;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:lightgray;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:#efefef;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-4 rect,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-4 path,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-4 circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-4 polygon,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-4 path{fill:hsl(330, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-4 text{fill:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .node-icon-4{font-size:40px;color:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-edge-4{stroke:hsl(330, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-depth-4{stroke-width:2;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-4 line{stroke:hsl(150, 100%, 86.2745098039%);stroke-width:3;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:lightgray;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:#efefef;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-5 rect,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-5 path,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-5 circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-5 polygon,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-5 path{fill:hsl(0, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-5 text{fill:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .node-icon-5{font-size:40px;color:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-edge-5{stroke:hsl(0, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-depth-5{stroke-width:-1;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-5 line{stroke:hsl(180, 100%, 86.2745098039%);stroke-width:3;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:lightgray;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:#efefef;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-6 rect,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-6 path,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-6 circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-6 polygon,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-6 path{fill:hsl(30, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-6 text{fill:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .node-icon-6{font-size:40px;color:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-edge-6{stroke:hsl(30, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-depth-6{stroke-width:-4;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-6 line{stroke:hsl(210, 100%, 86.2745098039%);stroke-width:3;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:lightgray;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:#efefef;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-7 rect,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-7 path,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-7 circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-7 polygon,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-7 path{fill:hsl(90, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-7 text{fill:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .node-icon-7{font-size:40px;color:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-edge-7{stroke:hsl(90, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-depth-7{stroke-width:-7;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-7 line{stroke:hsl(270, 100%, 86.2745098039%);stroke-width:3;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:lightgray;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:#efefef;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-8 rect,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-8 path,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-8 circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-8 polygon,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-8 path{fill:hsl(150, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-8 text{fill:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .node-icon-8{font-size:40px;color:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-edge-8{stroke:hsl(150, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-depth-8{stroke-width:-10;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-8 line{stroke:hsl(330, 100%, 86.2745098039%);stroke-width:3;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:lightgray;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:#efefef;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-9 rect,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-9 path,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-9 circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-9 polygon,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-9 path{fill:hsl(180, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-9 text{fill:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .node-icon-9{font-size:40px;color:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-edge-9{stroke:hsl(180, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-depth-9{stroke-width:-13;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-9 line{stroke:hsl(0, 100%, 86.2745098039%);stroke-width:3;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:lightgray;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:#efefef;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-10 rect,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-10 path,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-10 circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-10 polygon,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-10 path{fill:hsl(210, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-10 text{fill:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .node-icon-10{font-size:40px;color:black;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-edge-10{stroke:hsl(210, 100%, 76.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge-depth-10{stroke-width:-16;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-10 line{stroke:hsl(30, 100%, 86.2745098039%);stroke-width:3;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:lightgray;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .disabled text{fill:#efefef;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-root rect,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-root path,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-root circle,#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-root polygon{fill:hsl(240, 100%, 46.2745098039%);}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-root text{fill:#ffffff;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-root span{color:#ffffff;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .section-2 span{color:#ffffff;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .icon-container{height:100%;display:flex;justify-content:center;align-items:center;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .edge{fill:none;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI .mindmap-node-label{dy:1em;alignment-baseline:middle;text-anchor:middle;dominant-baseline:middle;text-align:center;}#mermaid-svg-Jh5Tw0yQsZ3PW0HI :root{--mermaid-font-family:"trebuchet ms",verdana,arial,sans-serif;} AutoDock-GPU 实战
它是什么
AutoDock 4 的 GPU 版
OpenCL 与 CUDA 双路径
怎么编
cuda.h 报错根因
TARGETS 与 NUMWI
跑得如何
四体系实测
大盒子主导耗时
坑在哪
rec 星号 map 命名
1ac8 损坏配体

目录 :[§0. 相关教程与核心文献](#§0. 相关教程与核心文献) | [§1. 软件介绍与版本沿革](#§1. 软件介绍与版本沿革) | [§2. 原理:三级并行与格点插值](#§2. 原理:三级并行与格点插值) | [§3. 特点与边界](#§3. 特点与边界) | [§4. 文献测评口径](#§4. 文献测评口径) | [§5. 本地安装实测](#§5. 本地安装实测) | [§6. 四体系基准与调优](#§6. 四体系基准与调优) | [§7. 结论与选型建议](#§7. 结论与选型建议)

§0. 相关教程与核心文献

资源 链接 与本文关系
AutoDock-GPU 官方仓库 --- 编译入口与测试体系来源
Santos-Martins 等, JCTC 2021, 10.1021/acs.jctc.0c01006 --- 方法论文(17 卷 1060--1073 页)
AutoDock-GPU v1.6 Release --- 版本线与更新日志
Tang 等, Molecules 2022, 10.3390/molecules27093041 --- 350× 口径的转引出处

§1. 软件介绍与版本沿革

AutoDock-GPU 是 Scripps 研究所 ccSb 团队对经典 AutoDock 4.2.6 的 GPU 移植:打分函数、力场参数与 PDBQT 输入格式全部继承 AutoDock 4,只把计算内核搬上加速器。它同时维护 OpenCL 与 CUDA 两条实现路径,前者可跑 NVIDIA、AMD、Intel 乃至国产 DCU 与多核 CPU,后者专门深挖 N 卡;同一份代码编译期用 DEVICE= 切换。

版本沿革(GitHub Release 时间线):v1.4(2021-05,加入柔性残基 flexres)→ v1.5(2021-08,大版本)→ v1.5.3(2021-12,Apple M1 适配与硼原子类型)→ v1.6(2024-11,当前 Major release)。本文实测基于 v1.6(commit be06a13,2026-08)。许可证为 GPL-2.0------比 Vina 生态常见的 Apache 2.0 严格,闭源商用集成前要过合规。

§2. 原理:三级并行与格点插值

AutoDock 4 的搜索算法是拉马克遗传算法(Lamarckian Genetic Algorithm, LGA):种群内每个个体做 Solis-Wets 局部搜索,能量评估占掉绝大部分耗时。GPU 化利用了三层天然并行:run 之间 (nrun 次独立对接互不依赖)、个体之间 (种群内个体互不依赖)、个体内部(单次能量评估的原子对循环向量化)。能量评估本身靠预计算的格点图(grid map)做三线性插值,GPU 上再叠加纹理内存加速------这是它移植成本低、跨平台好的根本原因:没有改变打分函数,只改了执行位置。

编译期参数 NUMWI 决定每个工作组放多少工作项,直接影响占用率;官方对现代显卡的建议是"试 128 或 64"------本文 §6 给了实测对照。

§3. 特点与边界

特点 :跨厂商可移植性是对接引擎里最好的(OpenCL 路径覆盖非 N 卡);支持批量模式(--filelist)与柔性残基(--flexres);输出兼容 DLG/XML 双格式,XML 可回转 DLG 做接触分析。

边界 :它的打分是 AutoDock 4 数值体系,与 Vina 系(vina/vinardo 打分)分数不可直接比较,命令行也不兼容 Vina 语法------同一批分子想跨引擎对比,要分别准备 map 与 pdbqt。另外它是"单受体多配体"模型,每次切换受体都要重新生成格点图。

§4. 文献测评口径

官方 README 的口径:相比串行 AutoDock 4.2(Solis-Wets),四核 CPU 提速约 4 倍、GPU 提速约 56 倍。JCTC 2021 论文口径:三级并行下最高 350 倍(对单线程 CPU 实现)。两个数字都真实,差异来自基准与并行档位------引用时注明"对谁、开几级并行"。需要注意的是,这些倍数的分母都是 AutoDock 4 自己,不能拿去和 Vina 系的千倍加速(分母是 Vina 单核)直接排序。

§5. 本地安装实测

实测环境(specs):

项 值
操作系统 Ubuntu 22.04 LTS
GPU 消费级 GPU,12 GB 显存,sm_86 架构
驱动 / CUDA Toolkit 580.178.04 / 12.4(装在 /usr/local/cuda)
编译器与构建 gcc/g++ 11.4 + make(本引擎不需要 cmake)
OpenCL 头文件与 ICD opencl-headers + ocl-icd-opencl-dev(仅 OpenCL 路径需要)

第 0 步:系统依赖 。CUDA Toolkit 的安装不展开(官方 runfile 或 deb 包均可),装完确认 /usr/local/cuda/bin/nvcc 存在即可:

bash 复制代码
sudo apt-get install -y build-essential
# 走 OpenCL 路径再加装(CUDA 路线可不装):
sudo apt-get install -y opencl-headers ocl-icd-opencl-dev

第 1 步:获取源码:

bash 复制代码
git clone https://github.com/ccsb-scripps/AutoDock-GPU.git
cd AutoDock-GPU

第 2 步:编译 CUDA 版(关键:显式传 GPU_INCLUDE_PATH/GPU_LIBRARY_PATH,见坑 1;TARGETS=86 对应 sm_86,其他卡换成自己的算力号):

bash 复制代码
export PATH=/usr/local/cuda/bin:$PATH
make DEVICE=CUDA NUMWI=128 TARGETS=86 \
     GPU_INCLUDE_PATH=/usr/local/cuda/include \
     GPU_LIBRARY_PATH=/usr/local/cuda/lib64
# 产物: bin/autodock_gpu_128wi
# OpenCL 跨厂商版: 把 DEVICE=CUDA 换成 DEVICE=GPU, 其余参数不变, 产物同名

第 3 步:冒烟验证(仓库自带 1stp 体系,10 次 LGA 应在 1 秒内出结果):

bash 复制代码
./bin/autodock_gpu_128wi -M input/1stp/derived/1stp_protein.maps.fld \
  -L input/1stp/derived/1stp_ligand.pdbqt --nrun 10 --resnam smoke
# 预期输出含: "Job #1 took 0.27 sec ..." 与 "best inter + intra  -9.99 kcal/mol" 量级

坑 1(必踩):host 侧编译报 cuda.h: No such file or directory。 根因是 Makefile 通过 GPU_INCLUDE_PATH/GPU_LIBRARY_PATH 两个变量把 CUDA 头文件传给 host 编译器,裸 make DEVICE=CUDA 时它们为空。显式传入即解(见上命令)。

坑 2:--res 参数不存在。 不少旧教程用 --res out.xml,v1.6 已改名为 --resnam;参数写错时程序直接打印 usage 退出,耗时 0.2 秒,容易被误以为"跑完了"。

坑 3:仓库自带测试体系五个里两个跑不起来。 3tmn/7cpa 的 fld 文件引用 rec.*.map,实际文件名是 <pdb>_rec.*.map,报 Can't open grid map rec.A.map;修法是补软链:

bash 复制代码
cd input/3tmn/derived
for f in 3tmn_rec.*.map; do ln -sf "$f" "rec.${f#3tmn_rec.}"; done
ln -sf 3tmn_protein.maps.xyz rec.maps.xyz

坑 4:1ac8 体系配体损坏。 1ac8_ligand.pdbqt 触发 HETATM or ATOM line is too short,属于仓库数据问题,直接剔除出基准集。

§6. 四体系基准与调优

四个体系(配体 18--43 原子,盒子 9.4×8.6×12.4 Å 至 22.9³ Å,spacing 0.375),CUDA 路径、NUMWI=128,Job 纯计算耗时:

体系 配体原子 nrun=200 nrun=1000 最佳能量 (kcal/mol)
1stp 18 1.34 s 1.60 s -8.25
3ce3 37 2.01 s 2.43 s ---
3tmn 27 1.43 s 1.48 s -9.75
7cpa 43 26.2 s 29.8 s ---

一、盒子大小主导耗时 ------7cpa 与 3tmn 同为 22.9³ 大盒子,但 7cpa 慢 18 倍,格点数与评估数才是瓶颈,nrun 从 200 加到 1000 也只多 4%--21% 的时间(3tmn 仅 +4%、3ce3 约 +21%);

二、NUMWI=64 比 128 略优 (1stp 1.09 对 1.34 s,7cpa 24.9 对 26.4 s),验证了官方"现代卡试 64"的建议;二点五、OpenCL 与 CUDA 两条编译路径性能打平 ------同卡重编 OpenCL 版(make DEVICE=GPU)跑同一批体系为 1.37/2.14/1.54/27.4 s,与 CUDA 版差距在 8% 以内,跨厂商可移植性几乎是免费的;

三、同机横向对照(同配体同盒子、各自打分体系):Uni-Dock v1.2.0 跑 1stp 2.44 s、Vina-CUDA v1.1 跑 1.17 s、AutoDock Vina 1.2.7 CPU 单核 12.3 s------AutoDock-GPU 的定位是"AD4 生态的加速器",追求吞吐时应优先 Vina 系(详见本系列其余篇)。

§7. 结论与选型建议

如果你的存量流程是 AutoDock 4(map、dpf、pdbqt 全套),AutoDock-GPU 是零迁移成本的选择:编译两分钟、坑集中在文件命名与参数改名,修完即用。

如果你是从零搭虚拟筛选管线、且不绑定 AD4 打分,直接上 Vina 系 GPU 引擎更快------本系列后续篇会给出同机对照。跨厂商算力(AMD/国产卡)场景下,它是目前唯一成熟的开源选项。


系列导航 :专栏全集 gnina系列 ------ 下一篇:Uni-Dock 实战测评。

更多专栏:

我的专栏

蛋白 / 抗体 / 多肽 / 核酸 分子模拟 / 动力学 / 对接 药物 / 设计 / 案例 AI / Agent / 大模型
开源蛋白结构预测 分子模拟基础 小分子药物设计案例 AI Agent系列
开源蛋白生成方法实践 分子动力学模拟-Amber 蛋白药物设计案例 化学大模型
开源多肽设计模型 分子动力学模拟-Gromacs 多肽药物设计案例 《AI Agent原理与实战》
开源多肽性质预测 分子动力学模拟-OpenMM 开源小分子生成设计 CADD中的机器学习模型
DNA/RNA药物设计 結合自由能 高效计算配置 《MCP 入门实战》
siRNA药物设计模型 UCSF DOCK系列 我胡师兄说药 《AI入门实战2026》
ASO药物设计模型 rDock系列 LeDock系列 gnina系列 《经典机器学习实战》
相关推荐
Blockbuater_drug6 天前
GPU加速分子对接软件横评:把加速比逐源核对后,再谈选型
分子对接·gpu加速·gnina·autodock-gpu·uni-dock·vina-gpu·diffdock
追风少年ii7 天前
内容补充--辅酶 / 配体分子的 Gaussian RESP 电荷与 GAFF2 参数化
数据分析·空间·分子动力学·单细胞·分子对接
Blockbuater_drug1 个月前
UCSF DOCK 分子对接详细案例(06)- 共价分子对接
分子对接·dock·共价对接·脚本化·covalent
追风少年ii2 个月前
课前准备--3D-QSAR与药物结构优化
数据分析·分子动力学·分子对接·结构生物学
追风少年ii2 个月前
课前准备--分子动力学Gromacs参数的详细介绍与选择(一)
数据分析·分子动力学·分子对接·结构生物学
追风少年ii2 个月前
课前准备--蛋白建模AlphaFold 2与AlphaFold 3
数据分析·分子动力学·分子对接·结构生物学
追风少年ii2 个月前
课前准备--蛋白质PDB文件与PDBQT文件的格式与区别
数据库·数据分析·分子动力学·分子对接
KJ_BioMed4 个月前
深度长文:AlphaFold3+AutoDock Vina高通量虚拟筛选自动化流水线实践
生物医学·虚拟筛选·科研干货·科研神器
KJ_BioMed4 个月前
AI驱动药物设计:如何利用Evobind2与AutoDock Vina从头设计高亲和力环肽?
分子对接·生物医药·生物科研·科研干货·科晶生物·环肽药物