Skip to content

Conversation

@pengcheng888
Copy link
Contributor

@pengcheng888 pengcheng888 commented Jun 30, 2025

issue/207 添加了 Sigmoid算子的头文件、cpu实现、cuda实现、python测试用例、gguf测试用例。
https://github.com/InfiniTensor/InfiniCore/issues/207
环境:
cuda11.8 pytorch2.6 nvidia 4070ti

rebase新代码,增加了bf16格式数据:

  • bf16格式没有指数函数,所以将bf16转为fp32,使用了__expf函数;
  • 除法丢失精度较多,bf16格式的10^3误差测试不通过,改为了10^2。

image
image
image
image

@PanZezhong1725
Copy link
Collaborator

为什么这个算子的文档没提交pr?

@PanZezhong1725
Copy link
Collaborator

pytorch测试已更新,需要rebase到最新并支持bf16

@pengcheng888
Copy link
Contributor Author

pytorch测试已更新,需要rebase到最新并支持bf16

文档和新代码已更新。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants