Download Latest Version PaddlePaddle 3.1.0 Release Note source code.tar.gz (17.8 MB)
Email in envelope

Get an email when there's a new version of PaddlePaddle

Home / v3.1.0
Name Modified Size InfoDownloads / Week
Parent folder
PaddlePaddle 3.1.0 Release Note source code.tar.gz 2025-06-25 17.8 MB
PaddlePaddle 3.1.0 Release Note source code.zip 2025-06-25 31.1 MB
README.md 2025-06-25 76.4 kB
Totals: 3 Items   49.0 MB 4

重要更新

飞桨框架 3.1 版本,针对核心功能自动并行进一步优化打磨,提升易用性和性能表现;同时提供FP8低精度训练支持,提升大模型训练速度提升10-20%;完善硬件扩展机制,降低类 cuda 类硬件适配成本,用户仅需注册kernel;同时对于框架基础能力进行增强,提升框架稳定性。重点更新功能如下:

  • 自动并行架构: 自动并行架构进一步打磨,以提高自动并行核心机制易用性和动态图性能。完善了自动并行核心机制,包括新增了多个算子的切分推导规则,支持分布式张量的同一维度被多个mesh维度切分,支持动态图并行策略(PP,CP,SEP,TP-CONV)等。同时,对动态图自动并行系统地做了性能优化,在 Llama2 Qwen Baichuan 等系列模型上性能基本持平手动并行的性能。
  • 低精度训练: 基于blockwise 的fp8 gemm算子,支持低精度训练,训练精度媲美BF16,大模型训练速度提速 10-20%。
  • 异构多芯适配: 提供类 cuda 算子复用机制,仅需注册即可使用对应 kernel。
  • 框架稳定性增强: 系统修复算子在0-Size 和大维度情况计算结果错误。

1. 用户体验升级

API功能增强、Bug修复与改进,旨在提升用户体验和API的易用性。新增了paddle.randn_like API,修复了多个API的功能缺陷,并增强了对复数类型和0-Size Tensor的支持。文档和代码也进行了相应的更新和优化,以提升整体的准确性和专业性。

新特性

  • 新增paddle.randn_like API。#72492

Bug 修复

功能增强

文档

  • 修正了文档中的错误,提高了文档的可用性和用户体验。#72549, #73036

开发者相关

废弃代码清理

2. 基础执行架构

支持FP8矩阵运算,提升模型训练效率,同时对多个模型进行增强,提升稳定性; 提供是C_ops的方式调用反向接口,方便显存优化和功能实验。

新特性

Bug 修复

功能增强

性能提升

废弃

开发者相关

其他

  • 其他:新增CPU 部分kernel对FP16/BF16数据类型的内核支持,优化测试模块错误处理与容差配置等。 #71764, #71951, #72944

3. 编译器架构

优化编译器性能和增加稳定性

性能优化

  • 支持训练场景的Layout自动转换优化。(#71891
  • 后端新增了argmin、argmax、arange等算子的Kernel编译优化。(#71956, #72598))
  • 支持矩阵乘的融合优化。(#72846)
  • 优化部分算子 Kernel 计算性能。(#72871)

Bug修复

修复各类场景下的一些处理逻辑 Bug。(#71813, #71886, #71927, #71915, #71946, #71949, #71955, #71942, #71939, #71973, #72001, #72020, #72014, #72021, #72027, #72061, #72025, #72095, #72108, #72132, #71985, #72106, #72140, #72167, #72037, #72178, #72143, #72175, #72191, #72213, #72189, #72214, #72166, #72180, #72284, #72267, #72348, #72332, #72307, #72353, #72204, #72457, #72426, #72536, #72541, #72365, #72621, #72630, #72669, #72682, #72732, #72811, #72941, #72795, #73536

4. 自动并行架构

在3.1 版本中,我们对自动并行架构进一步打磨,以提高自动并行易用性和动态图性能。具体地,我们完善了自动并行核心机制,包括新增了多个算子的切分推导规则,支持分布式张量的同一维度被多个mesh维度切分,支持动态图并行策略(PP,CP,SEP,TP-CONV)等。同时,对动态图自动并行系统地做了性能优化,在Llama等系列模型上性能基本持平手动并行的性能。

功能改进

性能优化

Bug 修复

  • 修复虚拟流水线并行策略在H卡上通信hang的bug。#71104, #73470
  • 修复 save/load 的bug。 #72023
  • 修复 linear_fused_grad_add 策略在动态图模式下跑不通的bug。 #72708)
  • 修复 fused_rms_norm 算子跑不通和精度bug。 #72663
  • 修复 expand 算子切分推导规则的bug。#73154

其他

5. 算子机制

新特性

  • 梯度与自动微分优化:初步支持put_along_axis及repeat_interleave操作的双重梯度计算,提升复杂算子在自动微分场景下的数值稳定性,实现masked_fill操作的算子分解。 #72789, #73056, #73225
  • 运算符机制扩展:新增对__radd__和__rmul__的自定义支持,增强框架对非对称运算符的重载能力。 #73119
  • FP8模块支持及算子开发:新增FP8块量化GEMM支持,引入多个融合算子,为混合专家(MoE)模型提供高效算子级实现,提升训推性能。 #73228, #73285, #73133, #73364, #73520, #73531

Bug 修复

功能增强

  • 新增int64_t版本的快速除法取模实现,提升大整数场景下的计算性能与数值稳定性, #72530
  • 优化带步长张量拷贝kernel,改进非连续内存布局下的数据拷贝效率。 #72662

-统一动态图与静态图模式下量化API的使用方式,简化量化模型开发流程, #73100

性能提升

  • 优化gelu算子分解性能,提升计算效率。 #72812

其他

6. 框架性能优化

新特性

支持sharding_overlapacc_steps可配置。 #72395

Bug 修复

  • 修复算子c_softmax_with_cross_entropy_gradinplace问题。 #72366

功能增强

  • 性能优化与加速:启用深度卷积的cuDNN支持,提升卷积运算效率。更新池化操作策略并优化permute内存操作,减少CUDA内存占用。优化打印速度,加速调试与日志输出流程。 #71796, #73442, #73563
  • 功能增强与操作支持:新增masked_fill操作及布尔索引优化,增强张量掩码处理能力。实现index_elementwise操作,支持基于索引的元素级运算。添加池化与reshape执行策略,提升模型操作的灵活性。 #72788, #72942
  • 错误修复与稳定性提升:修复fused_rms_norm在SPMD并行模式下的部分状态支持问题。修正slice操作中输出维度计算及IndexGetStride的索引错误,确保计算正确性。 #72118, #72223, #73184, #73237, #73054

性能提升

功能增强与修复:- 优化算子索引和内核调度逻辑。 #72625, #72741, #73082, #73501

  • 模型与操作支持:支持NHWC格式的深度卷积,适配更多硬件内存布局。 #72121

7. 硬件适配

优化硬件机制,提供类cuda硬件kernel复用方案。

新特性

以customdevice接入方案为基础,增加低成本支持类cuda后端硬件的支持方案。类cuda后端可以以插件式方式接入paddle,低成本复用paddle中多数nv生态中的cuda kernel,且可以与paddle框架中的特性feature升级解耦,大大降低硬件后端接入与迭代成本,提升用户接入意愿,形成paddle与硬件厂商共建生态的良好合作关系。 #[72604](https://github.com/PaddlePaddle/Paddle/pull/72604)[#72668](https://github.com/PaddlePaddle/Paddle/pull/72668))[#72758](https://github.com/PaddlePaddle/Paddle/pull/72758)[#72865](https://github.com/PaddlePaddle/Paddle/pull/72865)[#72910](https://github.com/PaddlePaddle/Paddle/pull/72910)[#73033](https://github.com/PaddlePaddle/Paddle/pull/73033))[#73145](https://github.com/PaddlePaddle/Paddle/pull/73145)[#73281](https://github.com/PaddlePaddle/Paddle/pull/73281)[#73079](https://github.com/72604#72668)#72758#72865#72910#73033)#73145#73281/issues/73079)

补充XPU 基础能力:XPU 环境下增加kernel ,扩展数据类型,补充分支 #[71424](https://github.com/PaddlePaddle/Paddle/pull/71424)[#71809](https://github.com/PaddlePaddle/Paddle/pull/71809)[#71594](https://github.com/PaddlePaddle/Paddle/pull/71594)[#71779](https://github.com/PaddlePaddle/Paddle/pull/71779)[#71756](https://github.com/PaddlePaddle/Paddle/pull/71756)[#71573](https://github.com/PaddlePaddle/Paddle/pull/71573)[#71883](https://github.com/PaddlePaddle/Paddle/pull/71883)[#71954](https://github.com/PaddlePaddle/Paddle/pull/71954)[#71931](https://github.com/PaddlePaddle/Paddle/pull/71931)[#72280](https://github.com/PaddlePaddle/Paddle/pull/72280)[#72361](https://github.com/PaddlePaddle/Paddle/pull/72361)[#72406](https://github.com/PaddlePaddle/Paddle/pull/72406)[#72528](https://github.com/PaddlePaddle/Paddle/pull/72528)[#72752](https://github.com/PaddlePaddle/Paddle/pull/72752)[#72852](https://github.com/PaddlePaddle/Paddle/pull/72852)[#72982](https://github.com/PaddlePaddle/Paddle/pull/72982)[#73357](https://github.com/PaddlePaddle/Paddle/pull/73357)[#73414](https://github.com/PaddlePaddle/Paddle/pull/73414)[#73464](https://github.com/PaddlePaddle/Paddle/pull/73464)[#73234](https://github.com/PaddlePaddle/Paddle/pull/73234)[#71776](https://github.com/71424#71809#71594#71779#71756#71573#71883#71954#71931#72280#72361#72406#72528#72752#72852#72982#73357#73414#73464#73234/issues/71776)

DCU kernel 扩展数据类型 #73129

Bug 修复

修复xpu执行问题 #[71852](https://github.com/PaddlePaddle/Paddle/pull/71852)[#71966](https://github.com/PaddlePaddle/Paddle/pull/71966)[#72005](https://github.com/PaddlePaddle/Paddle/pull/72005)[#71908](https://github.com/PaddlePaddle/Paddle/pull/71908)[#72431](https://github.com/PaddlePaddle/Paddle/pull/72431)[#72519](https://github.com/PaddlePaddle/Paddle/pull/72519)[#72734](https://github.com/PaddlePaddle/Paddle/pull/72734)[#72763](https://github.com/PaddlePaddle/Paddle/pull/72763)[#72762](https://github.com/PaddlePaddle/Paddle/pull/72762)[#72890](https://github.com/PaddlePaddle/Paddle/pull/72890)[#72867](https://github.com/PaddlePaddle/Paddle/pull/72867)[#73071](https://github.com/PaddlePaddle/Paddle/pull/73071)[#73004](https://github.com/PaddlePaddle/Paddle/pull/73004)[#72726](https://github.com/PaddlePaddle/Paddle/pull/72726)[#73113](https://github.com/PaddlePaddle/Paddle/pull/73113)[#73127](https://github.com/PaddlePaddle/Paddle/pull/73127)[#73025](https://github.com/PaddlePaddle/Paddle/pull/73025)[#73301](https://github.com/PaddlePaddle/Paddle/pull/73301)[#73292](https://github.com/PaddlePaddle/Paddle/pull/73292)[#73272](https://github.com/PaddlePaddle/Paddle/pull/73272)[#73305](https://github.com/PaddlePaddle/Paddle/pull/73305)[#73356](https://github.com/PaddlePaddle/Paddle/pull/73356)[#73438](https://github.com/PaddlePaddle/Paddle/pull/73438)[#72041](https://github.com/PaddlePaddle/Paddle/pull/72041)[#72275](https://github.com/PaddlePaddle/Paddle/pull/72275)[#72787](https://github.com/PaddlePaddle/Paddle/pull/72787)[#73504](https://github.com/PaddlePaddle/Paddle/pull/73504)[#73290](https://github.com/71852#71966#72005#71908#72431#72519#72734#72763#72762#72890#72867#73071#73004#72726#73113#73127#73025#73301#73292#73272#73305#73356#73438#72041#72275#72787#73504/issues/73290)

8. 安装环境适配

优化了框架的稳定性和跨平台兼容性,修复了不同平台上的编译安装失败问题;升级CUDA等关键依赖,进一步优化CI/CD流程,提升构建速度并增强系统整体稳定性;停止对Python3.8环境下的编译安装维护。

Bug 修复

  • 修复使用clang17编译第三方库时的编译错误。#72524
  • 修复使用CUDA12.9时的编译问题。 #72808, #72841, #72978, #73360
  • 修复使用GCC13.3时的编译问题。#73144
  • 修复WITH_PIP_CUDA_LIBRARIES=ON时的编译问题。#72907
  • 修复WITH_NVSHMEM=ON时的编译问题。#73368

功能增强

  • 避免自定义算子编译产生的临时文件的拷贝。#73196
  • Warning信息优化。#72877

开发者相关

废弃

  • 停止支持Python3.8环境下的编译。#72827

9. 贡献者名单

0x3878f, A-nnonymous, AndSonder, ApricityXX, aquagull, author, baoqiwen, BeingGod, blacksheep-Aristotle, BoShen5, bukejiyu, cangtianhuang, carryyu, chang-wenbin, changeyoung98, chen2016013, ckl117, co63oc, cqulilujia, crashbussy, cszdrg, Cutelemon6, cyy536, DanielSun11, danleifeng, datutu-L, deepllz, Dmovic, DrRyanHuang, dynamicheart, Eddie-Wang1120, eggman-1024, emmanuel-ferdman, Enigmatisms, enkilee, fangfangssj, feixi21, FeixLiu, ForFishes, Function-Samuel, ggggxm, GITD245, Glencsa, GoldenStain, gongshaotian, gouzil, gzy19990617, hanlintang, Hongqing-work, houj04, huangjiyi, hxzd5568, HydrogenSulfate, jzhang533, LCStayingdullCircuit, leon062112, lifulll, linkk08, LittleHeroZZZX, liufengwei0103, Liujie0926, liuruyan, lixinqi, LiYuRio, lizexu123, lizhenyun01, lj970926, lshpku, megemini, mikethegoblin, ming1753, mzj104, NKNaN, ooooo-create, pesionzhao, phlrain, pkuzyc, PolaKuma, Qin-sx, RichardWooSJTU, risemeup1, runzhech, RuohengMa, sasaya123, shanjiang7, SigureMo, sneaxiy, swgu98, SylarTiaNII, tianhaodongbd, tianshuo78520a, timminator, tizhou86, umiswing, waliwali777, wanghuancoder, Waynezee, Wennie396, xiaoguoguo626807, XieYunshen, Xing-lil, xkkkkkk23, Xreki, xuxinyi389, Yeenyeong, yongqiangma, YqGe585, yuanlehome, YuanRisheng, yulangz, yuwu46, zeroRains, zhangbo9674, zhanghonggeng, zhangting2020, ZhangX-21, zhangyk0314, zhangyuqin1998, zhink, zhiqiu, zhouquan32, zhoutianzi666, zhupengyang, zrr1999, zty-king, zyfncg

Source: README.md, updated 2025-06-25