Futhark 中按索引归约与扫描的逆模式自动微分
编程语言
2023-10-06 v1 分布式、并行与集群计算
性能
摘要
我们提出并评估了 Futhark 对并行编程基本构件——归约(reduce)、前缀和(scan)与按索引归约(reduce by index)——的逆模式自动微分(AD)实现。我们首先给出通用情形算法的推导,然后讨论若干特化,这些特化使得大多数实际感兴趣的情形的微分高效化。我们报告了一项实验,该实验在 GPU 执行背景下评估了微分代码的性能,并凸显了所提特化的影响,以及在高层次与低层次(即“对内存求导”)进行微分的优劣。
引用
@article{arxiv.2310.03568,
title = {Reverse-Mode AD of Reduce-by-Index and Scan in Futhark},
author = {Lotte Maria Bruun and Ulrik Stuhr Larsen and Nikolaj Hinnerskov and Cosmin Oancea},
journal= {arXiv preprint arXiv:2310.03568},
year = {2023}
}
备注
Presented at IFL'23 (i.e., 35th Symposium on Implementation and Application of Functional Languages, Aug. 29th - 31st, 2023, Braga, Portugal)