Skip to content

Conversation

@yao-fengchen
Copy link
Collaborator

No description provided.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes accuracy issues in the dlinfer backend by improving numerical precision in rotary embeddings, updating tensor type conversions, and upgrading dependencies to stable releases.

  • Refactored rotary embedding inverse frequency calculation to use native float types and eliminate unnecessary type conversions
  • Updated Ascend NPU backend tensor operations to use explicit int32 conversions for improved compatibility
  • Added support for grouped MoE routing with n_groups parameter
  • Upgraded CANN and torch-npu dependencies from release candidates to stable versions

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
lmdeploy/pytorch/backends/dlinfer/rotary_embedding.py Improved numerical precision by changing base parameter to float and refactoring inv_freq calculation to avoid intermediate int64 conversions
lmdeploy/pytorch/backends/dlinfer/moe.py Added n_groups parameter support to align with base SoftmaxTopKBuilder interface
lmdeploy/pytorch/backends/dlinfer/ascend/op_backend.py Updated tensor type conversions to explicitly use int32 for Ascend NPU compatibility
docker/Dockerfile_ascend_a3 Upgraded CANN from 8.3.rc1.alpha002 to 8.3.rc1 and torch-npu from 2.8.0rc1 to 2.8.0
docker/Dockerfile_ascend_a2_300i Upgraded CANN from 8.3.rc1.alpha002 to 8.3.rc1 and torch-npu from 2.8.0rc1 to 2.8.0

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@jinminxi104 jinminxi104 changed the title fix accuracy fix qwen3-30-a3b lcb-code score Nov 26, 2025
@jinminxi104 jinminxi104 marked this pull request as ready for review November 26, 2025 02:48
@lvhan028 lvhan028 merged commit 21c22f0 into InternLM:main Nov 26, 2025
14 of 15 checks passed
@yao-fengchen yao-fengchen deleted the fix_accuracy branch November 28, 2025 08:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants