Skip to content

[Triton/Gluon] Use absolute imports under ops/triton and triton_tests - #5382

Merged
Boss2002n merged 1 commit into
mainfrom
satya/refactor/absolute-imports
Sep 10, 2026
Merged

Boss2002n merged 1 commit into
mainfrom
satya/refactor/absolute-imports

Conversation

@Boss2002n

Copy link
Copy Markdown
Contributor

No description provided.

The instructions file allows only absolute imports; 96 relative imports in 45 files
were rewritten against each file's package path (no behaviour change).
@Boss2002n
Boss2002n requested review from a team and a lite review from Copilot September 9, 2026 17:29
@github-actions

github-actions Bot commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

🏷️ CI Guide

Runs automatically on every PR:

  • ✅ Pre-checks (submodule verification, code formatting)
  • ✅ Aiter op tests (gfx942 + gfx950)
  • ✅ Triton tests on MI35X (only when aiter/ops/triton/** or related paths are changed)

Extended tests (opt-in via labels):

Label Tests
ci:gfx1250-ffm-triton Run the five-shard gfx1250 FFM Triton test suite
ci:triton-300x Run an additional Triton test job on MI300X in PRs; main branch always runs both MI35X and MI300X
multigpu Aiter multi-GPU tests on the 8-GPU runner
ci:sglang SGLang integration tests: DeepSeek-R1-MXFP4 accuracy, Qwen 3.5 accuracy
ci:atom ATOM benchmark: DeepSeek-R1-0528, GPT-OSS-120B
ci:atom_full ATOM accuracy suite for PR and main models from ATOM models_accuracy.json
ci:vllm vLLM benchmark: GPT-OSS-120B, DeepSeek-R1-0528, Kimi-K2.5
ci:all All standard extended tests (excludes ci:atom_full)

Only add ci:atom_full for FlyDSL or Triton upgrades.
Add labels via the sidebar or gh pr edit 5382 --add-label <label>

PR title tags & labels:
Component tags ([Triton/Gluon], [HIP], [CK], [ASM], ...) are added to the PR title and as PR labels automatically from the changed files and re-synced on every push — change-type tags like [fix]/[Perf], op tags like [MLA], and human labels (ci:*) are left untouched. Add the no-auto-title label to opt this PR out.

@github-actions github-actions Bot changed the title Use absolute imports under ops/triton and triton_tests [Triton/Gluon] Use absolute imports under ops/triton and triton_tests Sep 9, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The changes are mechanical import-path updates that align with the absolute-import convention and appear consistent with the existing package layout.

Pull request overview

This PR standardizes import style by replacing relative imports with absolute imports across aiter/ops/triton internals and op_tests/triton_tests, aligning with the repo’s “absolute-import-only” convention for these areas.

Changes:

  • Replace relative imports with absolute imports in Triton/Gluon kernel modules under aiter/ops/triton/_triton_kernels/.
  • Replace relative imports with absolute imports throughout op_tests/triton_tests (including torch_compile and conv tests).
  • Update aiter/ops/triton/__init__.py to use absolute imports for optional submodules and re-exports.
File summaries
File Description
op_tests/triton_tests/utils/init.py Switch utils package exports to absolute imports.
op_tests/triton_tests/torch_compile/test_compile_topk.py Import _get_compiled via absolute package path.
op_tests/triton_tests/torch_compile/test_compile_softmax.py Import _get_compiled via absolute package path.
op_tests/triton_tests/torch_compile/test_compile_rope.py Import _get_compiled via absolute package path.
op_tests/triton_tests/torch_compile/test_compile_rmsnorm.py Import _get_compiled via absolute package path.
op_tests/triton_tests/torch_compile/test_compile_quant_per_token.py Import _get_compiled via absolute package path.
op_tests/triton_tests/torch_compile/test_compile_quant_per_tensor.py Import _get_compiled via absolute package path.
op_tests/triton_tests/torch_compile/test_compile_moe_routing.py Import _get_compiled via absolute package path.
op_tests/triton_tests/torch_compile/test_compile_gemm_a16w16.py Import _get_compiled via absolute package path.
op_tests/triton_tests/torch_compile/test_compile_fused_mul_add.py Import _get_compiled via absolute package path.
op_tests/triton_tests/torch_compile/test_compile_constexpr_mutation.py Import _get_compiled via absolute package path.
op_tests/triton_tests/torch_compile/test_compile_activation.py Import _get_compiled via absolute package path.
op_tests/triton_tests/conv/test_conv2d.py Replace relative helper import with absolute import.
op_tests/triton_tests/init.py Export triton_tests utils via absolute import.
aiter/ops/triton/_triton_kernels/quant/fused_mxfp8_quant.py Replace relative quant helper import with absolute import.
aiter/ops/triton/_triton_kernels/quant/fused_mxfp4_quant.py Replace relative quant helper import with absolute import.
aiter/ops/triton/_triton_kernels/gated_delta_rule/utils/wy_representation.py Convert gated-delta-rule internal imports to absolute imports.
aiter/ops/triton/_triton_kernels/gated_delta_rule/utils/solve_tril.py Convert gated-delta-rule internal imports to absolute imports.
aiter/ops/triton/_triton_kernels/gated_delta_rule/utils/op.py Convert gated-delta-rule internal imports to absolute imports.
aiter/ops/triton/_triton_kernels/gated_delta_rule/utils/l2norm.py Convert gated-delta-rule internal imports to absolute imports.
aiter/ops/triton/_triton_kernels/gated_delta_rule/utils/index.py Convert gated-delta-rule internal imports to absolute imports.
aiter/ops/triton/_triton_kernels/gated_delta_rule/utils/cumsum.py Convert gated-delta-rule internal imports to absolute imports.
aiter/ops/triton/_triton_kernels/gated_delta_rule/utils/init.py Convert utility re-exports to absolute imports.
aiter/ops/triton/_triton_kernels/gated_delta_rule/prefill/fused_solve_tril_recompute.py Convert prefill module imports to absolute imports.
aiter/ops/triton/_triton_kernels/gated_delta_rule/prefill/fused_cumsum_kkt.py Convert prefill module imports to absolute imports.
aiter/ops/triton/_triton_kernels/gated_delta_rule/prefill/chunk.py Convert prefill orchestration imports to absolute imports.
aiter/ops/triton/_triton_kernels/gated_delta_rule/prefill/chunk_o.py Convert prefill kernel imports to absolute imports.
aiter/ops/triton/_triton_kernels/gated_delta_rule/prefill/chunk_delta_h.py Convert prefill kernel imports to absolute imports.
aiter/ops/triton/_triton_kernels/gated_delta_rule/prefill/init.py Convert prefill package exports to absolute imports.
aiter/ops/triton/_triton_kernels/gated_delta_rule/decode/fused_sigmoid_gating_recurrent.py Convert decode module imports to absolute imports.
aiter/ops/triton/_triton_kernels/gated_delta_rule/decode/init.py Convert decode package exports to absolute imports.
aiter/ops/triton/_triton_kernels/gated_delta_rule/init.py Convert gated_delta_rule package exports to absolute imports.
aiter/ops/triton/_triton_kernels/flash_attn_triton_amd/interface_v3.py Convert flash-attn interface imports to absolute imports.
aiter/ops/triton/_triton_kernels/flash_attn_triton_amd/interface_v2.py Convert flash-attn interface imports to absolute imports.
aiter/ops/triton/_triton_kernels/flash_attn_triton_amd/fwd_prefill.py Convert forward prefill imports to absolute imports.
aiter/ops/triton/_triton_kernels/flash_attn_triton_amd/fwd_decode.py Convert forward decode imports to absolute imports.
aiter/ops/triton/_triton_kernels/flash_attn_triton_amd/common.py Convert common helper imports to absolute imports.
aiter/ops/triton/_triton_kernels/flash_attn_triton_amd/bwd.py Convert backward imports to absolute imports.
aiter/ops/triton/_triton_kernels/flash_attn_triton_amd/init.py Convert flash-attn package exports to absolute imports.
aiter/ops/triton/_triton_kernels/conv/conv_general.py Convert activation helper import to absolute import.
aiter/ops/triton/_triton_kernels/conv/conv_3x3.py Convert activation helper import to absolute import.
aiter/ops/triton/_triton_kernels/conv/conv_3x3_winograd_f4x3.py Convert activation helper import to absolute import.
aiter/ops/triton/_triton_kernels/conv/conv_1x1.py Convert activation helper import to absolute import.
aiter/ops/triton/_triton_kernels/activation.py Convert quant helper imports to absolute imports.
aiter/ops/triton/init.py Convert optional module imports and re-exports to absolute imports.
Review details
  • Files reviewed: 45/45 changed files
  • Comments generated: 0
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@vgokhale vgokhale left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice thanks for catching these...

@Boss2002n
Boss2002n merged commit a415156 into main Sep 10, 2026
68 of 73 checks passed
@Boss2002n
Boss2002n deleted the satya/refactor/absolute-imports branch September 10, 2026 02:05
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.

4 participants