Skip to content

fix fatals when 'max_seqlen_q' is 'numpy.int32'#796

Merged
sgjzfzzf merged 1 commit intoflagos-ai:masterfrom
sgjzfzzf:master
Jul 17, 2025
Merged

fix fatals when 'max_seqlen_q' is 'numpy.int32'#796
sgjzfzzf merged 1 commit intoflagos-ai:masterfrom
sgjzfzzf:master

Conversation

@sgjzfzzf
Copy link
Collaborator

@sgjzfzzf sgjzfzzf commented Jul 17, 2025

PR Category

Operator

Type of Change

Bug Fix

Description

max_seqlen_q could be np.int32, but it only checks whether it's torch.Tensor now.

Issue

PR #781, #789

Progress

  • Change is properly reviewed (1 reviewer required, 2 recommended).
  • Change is responded to an issue.
  • Change is fully covered by a UT.

Performance

@sgjzfzzf sgjzfzzf requested a review from 0x45f July 17, 2025 07:30
@sgjzfzzf sgjzfzzf changed the title fix fatals when 'max_seqlen_q' is 'numpy.ndarray' fix fatals when 'max_seqlen_q' is 'numpy.int32' Jul 17, 2025
@iclementine
Copy link
Collaborator

triton jit function 目前对于参数的处理方式非常 ad-hoc. numpy scalar 和 python scalar 是不同的东西,需要额外的逻辑才能处理。

@sgjzfzzf sgjzfzzf merged commit 4b86823 into flagos-ai:master Jul 17, 2025
12 of 14 checks passed
nicelynice pushed a commit to nicelynice/FlagGems that referenced this pull request Feb 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants