Closed
[Requirement|需求建议]: 新增swigluMode=3支持模型变体SwiGLU #4812
east_yangAdd on  Aug 14Closed at  Aug 17
east_yangCollaborators
Aug 14 Create

Thanks for sending an requirement! Please fill in the following template to help quickly solve your problem.

Backgroud(背景信息)

当前部分新增模型使用变体的SwiGLU公式,在silu后面进行clamp计算,与当前的DequantSwigluQuant算子公式有差异,需要进行支持。
def forward_native(x, limit) -> torch.Tensor:
gate, up = x.chunk(2, dim=-1)
gate = F.silu(gate)
gate = gate.clamp(max=limit)
up = up.clamp(min=-limit, max=limit)
return gate * up

Origin(信息来源)

HW

Benefit / Necessity (价值/作用)

Design(设计方案)

likedislike
Eeast_yangCollaborators
Aug 14 Added label: requirement
Eeast_yangCollaborators
Aug 14 Modify description of issue
Eeast_yangCollaborators
Aug 14 Assign east_yang as responsible person
Eeast_yangCollaborators
Aug 14 Associated pull request
CANN-robotCANN-robotCollaborators
Aug 15 Close issue
east_yangCollaborators
Aug 15 Comments:

/open

likedislike
Eeast_yangCollaborators
Aug 15 Associated pull request
Eeast_yangCollaborators
Aug 15 changed custom state from 进行中 to 已确认
Eeast_yangCollaborators
Aug 15 Reopen issue
CANN-robotCANN-robotCollaborators
Aug 17 Close issue
CANN-robotCANN-robotCollaborators
Aug 17 Added label: resolved
Eeast_yangCollaborators
Aug 25 Associated pull request