文件最后提交记录最后更新时间
【UT】补充Qwen3-VL-4B模型调优测试UT Co-authored-by: z00564833<zhumo@huawei.com> # message auto-generated for no-merge-commit merge: !122 merge master into master 【UT】补充Qwen3-VL-4B模型调优测试UT Created-by: zhumoon Commit-by: z00564833 Merged-by: ascend-robot Description: 【UT】补充Qwen3-VL-4B模型调优测试UT # 背景 为 Qwen3-VL-4B 适配相关改动补充单元测试,覆盖 save 层 deq_scale 处理、AscendV1 保存逻辑、safetensors 共享存储去重,以及 model 层 get_global_model_torch_dtype、Qwen3-VL QuaRot 与 tie_word_embeddings 等行为。 # 变更说明 - save 层 - test_deqscale.py:deqscale2int64、deqscale2int64_by_dtype 的 1D 输入、dtype、roundtrip 及 is_bf16 分支。 - test_ascendv1.py:_resolve_is_bf16_from_adapter(bf16/float32/非接口),以及 W8A8 写入时 deq_scale 在 bf16 下为 float32、非 bf16 下为 int64。 - test_safetensors_writer.py:_dedupe_shared_storage 无共享不变、有共享时 embed_tokens 保留原 tensor、lm_head 以 clone 写入。 - model 层 - test_transformers.py:TransformersModel.get_global_model_torch_dtype(config 为 None / bfloat16 / str bfloat16、str float32)。 - test_vlm_base.py:VLMBaseModelAdapter.get_global_model_torch_dtype(config 为 None、bfloat16、text_config fallback)。 - test_model_adapter_qwen3_vl.py:get_rotate_map 在 tie_word_embeddings=True 时抛出 UnsupportedError。 # 影响范围 - 仅新增测试用例,不修改业务代码。 - 涉及目录:test/cases/core/quant_service/modelslim_v1/save/、test/cases/model/common/、test/cases/model/qwen3_vl/。 See merge request: Ascend/msmodelslim!1222 个月前
【feature】 支持FA3的混合量化配置及保存 Co-authored-by: wangsihao<wangsihao5@h-partners.com> # message auto-generated for no-merge-commit merge: !483 merge master into master 【feature】 支持FA3的混合量化配置及保存 Created-by: wangsihao Commit-by: wangsihao Merged-by: ascend-robot Description: 感谢您贡献的Pull Request! 在提交之前,请务必阅读 [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md)。 ## PR描述 (What this PR does / why we need it?) 支持FA3量化中的不同策略和粒度的混合配置 如:fa_q 动态量化,fa_k/fa_v 静态量化 量化粒度支持FP8/INT8,其中INT8仅支持静态量化 ## 功能验证 (How was this patch tested?) - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 See merge request: Ascend/msmodelslim!4838 小时前
【msmodelslim】刷新文件头部声明和版权 Co-authored-by: caishengcheng<caishengcheng@huawei.com> # message auto-generated for no-merge-commit merge: !28 merge license into master 【msmodelslim】刷新文件头部声明和版权 Created-by: caishengcheng Commit-by: caishengcheng Merged-by: ascend-robot Description: 【msmodelslim】刷新文件头部声明和版权 See merge request: Ascend/msmodelslim!284 个月前
【ut】补充deepseek_v4相关测试 Co-authored-by: zhangz200102<zhangzheng183@huawei.com> # message auto-generated for no-merge-commit merge: !497 merge ut/for_ds_v4 into master 【ut】补充deepseek_v4相关测试 Created-by: zhangz200102 Commit-by: zhangz200102 Merged-by: ascend-robot Description: 感谢您贡献的Pull Request! 在提交之前,请务必阅读 [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md)。 Thanks for sending a pull request! BEFORE SUBMITTING, PLEASE READ [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md). ## PR描述 (What this PR does / why we need it?) - 请明确说明您提交PR的变更内容。本部分旨在概述所做的变更,以及此PR是如何解决该问题的。请尽可能地提供有助于评审人员更高效、更快速完成检视审查的实用说明。 补充deepseek_v4相关ut - 请说明为何需要这些更改,例如具体的使用场景或bug描述。 - 关联issue号(如果有)。 - Please clarify what changes you are proposing. The purpose of this section is to outline the changes and how this PR fixes the issue. If possible, please consider writing useful notes for better and faster reviews in your PR. - Please clarify why the changes are needed. For instance, the use case and bug description. - Related issue number (if any) ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!4979 小时前
【feature】一键量化开箱即用 Co-authored-by: SuperMeixc<meixiaocun1@huawei.com> # message auto-generated for no-merge-commit merge: !103 merge master into master 【feature】一键量化开箱即用 Created-by: SuperMeixc Commit-by: SuperMeixc Merged-by: ascend-robot Description: 【feature】一键量化开箱即用 See merge request: Ascend/msmodelslim!1033 个月前
【UT】补充model/flux1和util/security单元测试 Co-authored-by: xyxin_006<xyxin_hit@163.com> # message auto-generated for no-merge-commit merge: !499 merge ut/add_ut into master 【UT】补充model/flux1和util/security单元测试 Created-by: xyxin_006 Commit-by: xyxin_006 Merged-by: ascend-robot Description: 感谢您贡献的Pull Request! 在提交之前,请务必阅读 [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md)。 Thanks for sending a pull request! BEFORE SUBMITTING, PLEASE READ [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md). ## PR描述 (What this PR does / why we need it?) - 请明确说明您提交PR的变更内容。本部分旨在概述所做的变更,以及此PR是如何解决该问题的。请尽可能地提供有助于评审人员更高效、更快速完成检视审查的实用说明。 - 请说明为何需要这些更改,例如具体的使用场景或bug描述。 - 关联issue号(如果有)。 - Please clarify what changes you are proposing. The purpose of this section is to outline the changes and how this PR fixes the issue. If possible, please consider writing useful notes for better and faster reviews in your PR. - Please clarify why the changes are needed. For instance, the use case and bug description. - Related issue number (if any) ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!4994 小时前
【fix】fix-pre-commit-for-glm Co-authored-by: sunny<sunyu_0904@163.com> # message auto-generated for no-merge-commit merge: !463 merge fix/fix-pre-commit-for-glm into master 【fix】fix-pre-commit-for-glm Created-by: sunny_infra Commit-by: sunny Merged-by: ascend-robot Description: 感谢您贡献的Pull Request! 在提交之前,请务必阅读 [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md)。 Thanks for sending a pull request! BEFORE SUBMITTING, PLEASE READ [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md). ## PR描述 (What this PR does / why we need it?) - - Please clarify what changes you are proposing. The purpose of this section is to outline the changes and how this PR fixes the issue. If possible, please consider writing useful notes for better and faster reviews in your PR. - Please clarify why the changes are needed. For instance, the use case and bug description. - Related issue number (if any) ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!4631 天前
【fix】fix-pre-commit-for-glm Co-authored-by: sunny<sunyu_0904@163.com> # message auto-generated for no-merge-commit merge: !463 merge fix/fix-pre-commit-for-glm into master 【fix】fix-pre-commit-for-glm Created-by: sunny_infra Commit-by: sunny Merged-by: ascend-robot Description: 感谢您贡献的Pull Request! 在提交之前,请务必阅读 [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md)。 Thanks for sending a pull request! BEFORE SUBMITTING, PLEASE READ [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md). ## PR描述 (What this PR does / why we need it?) - - Please clarify what changes you are proposing. The purpose of this section is to outline the changes and how this PR fixes the issue. If possible, please consider writing useful notes for better and faster reviews in your PR. - Please clarify why the changes are needed. For instance, the use case and bug description. - Related issue number (if any) ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!4631 天前
【UT】补充GLM-5 单元测试 Co-authored-by: LeeQT<liqitong@huawei.com> # message auto-generated for no-merge-commit merge: !461 merge glm5_UT into master 【UT】补充GLM-5 单元测试 Created-by: LeeQT Commit-by: LeeQT Merged-by: ascend-robot Description: 感谢您贡献的Pull Request! 在提交之前,请务必阅读 [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md)。 Thanks for sending a pull request! BEFORE SUBMITTING, PLEASE READ [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md). ## PR描述 (What this PR does / why we need it?) - 补充GLM-5模型UT,按照“test_对象_断言_when_条件”规范看护 ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) ![image.png](https://raw.gitcode.com/user-images/assets/8444818/f3117c8f-2087-460e-81cb-1a4370565885/image.png 'image.png') 行覆盖率0.86,分支覆盖率0.67 See merge request: Ascend/msmodelslim!4613 天前
【重构】多模态生成模型量化服务重构wan2.2/hunyuanvideo【hunyuanvideo重构】 Co-authored-by: xiaoheng181<eudemoniaxh@163.com> # message auto-generated for no-merge-commit merge: !494 merge sd_refactor_hunyuan_video_refactor into master 【重构】多模态生成模型量化服务重构wan2.2/hunyuanvideo【hunyuanvideo重构】 Created-by: xiaoheng181 Commit-by: xiaoheng181 Merged-by: ascend-robot Description: 感谢您贡献的Pull Request! 在提交之前,请务必阅读 [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md)。 Thanks for sending a pull request! BEFORE SUBMITTING, PLEASE READ [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md). ## PR描述 (What this PR does / why we need it?) - 请明确说明您提交PR的变更内容。本部分旨在概述所做的变更,以及此PR是如何解决该问题的。请尽可能地提供有助于评审人员更高效、更快速完成检视审查的实用说明。 本 PR 是多模态生成(multimodal_sd_modelslim_v1)重构的第四笔,依赖已合入(或同栈基于)前置多模态 SD 重构提交(至少含 sd_refactor_multimodal_sd_core;堆叠合入时 base 为 sd_refactor_wan2_2_refactor)。将 HunyuanVideo 从主仓 Legacy 单体适配器重构为 MultimodalPipelineInterface 标准路径。 model_adapter.py HunyuanVideoModelAdapter 实现新 pipeline:HunyuanVideoInferenceConfig(Pydantic,extra=forbid)、handle_dataset(VlmCalibSample)、configure_runtime / init_model / prepare_calib_data / quantization_context;权重路径与 hyvideo 推理仓对齐。 constants.py(新) 默认分辨率/尺寸、HYVIDEO_CLI_LIST_FIELDS(如 video_size → --video-size)、权重相对路径等常量集中管理。 CLI 桥接 _namespace_to_argv:仅将注册为 CLI list 的字段展开为 argv;其它 list/tuple/dict 跳过,与 hyvideo 侧能力一致。 UT 大幅整理 test_model_adapter_hunyuan_video.py;新增 test_namespace_to_argv.py 看护 argv 展开与跳过逻辑。 - 请说明为何需要这些更改,例如具体的使用场景或bug描述。 原 Hunyuan 适配器与 model_config、单体 run_calib_inference 强耦合,无法使用 inference_config + dataset 及核心 PR 的双路径量化编排。本 PR 与 Wan2.2 无文件交叉,可在 Legacy 合入后与 Wan2.2 PR 并行评审(堆叠分支上仍建议按 core → legacy → wan2_2 → hunyuan 顺序合入)。 依赖:sd_refactor_multimodal_sd_core(必选);若走完整堆叠,还须包含 sd_refactor_legacy_model_adapters、sd_refactor_wan2_2_refactor 中与本分支无冲突的提交。 - 关联issue号(如果有)。 - Please clarify what changes you are proposing. The purpose of this section is to outline the changes and how this PR fixes the issue. If possible, please consider writing useful notes for better and faster reviews in your PR. - Please clarify why the changes are needed. For instance, the use case and bug description. - Related issue number (if any) ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 有(在核心 PR 已合入前提下)。 hunyuan_video 量化改走 inference_config + dataset(校准 prompt 来自 dataset,不再混在宽泛 model_config 里)。 推理参数经 HunyuanVideoInferenceConfig 校验后桥接到 hyvideo CLI(如 video_size、infer_steps、cfg_scale 等)。 对外 CLI 入口不变;YAML 字段语义与后续文档 PR(usage.md、lab yaml)一致。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!4941 天前
[test]增加kimi k2 单元测试用例 Co-authored-by: 李明宇<limingyu35@h-partners.com> # message auto-generated for no-merge-commit merge: !475 merge master-ut0601 into master [test]增加kimi k2 单元测试用例 Created-by: code_mingming Commit-by: 李明宇 Merged-by: ascend-robot Description: 感谢您贡献的Pull Request! 在提交之前,请务必阅读 [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md)。 Thanks for sending a pull request! BEFORE SUBMITTING, PLEASE READ [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md). ## PR描述 (What this PR does / why we need it?) 对模型适配器kimi k2的工具类增加单元测试用例 ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!4751 天前
添加kimi k2.5 UT Co-authored-by: 李明宇<limingyu35@h-partners.com> # message auto-generated for no-merge-commit merge: !334 merge master-kimi-ut into master 【UT】增加kimi k2.5 UT Created-by: code_mingming Commit-by: code_mingming;李明宇 Merged-by: ascend-robot Description: 感谢您贡献的Pull Request! 在提交之前,请务必阅读 [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md)。 Thanks for sending a pull request! BEFORE SUBMITTING, PLEASE READ [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md). ## PR描述 (What this PR does / why we need it?) - 请明确说明您提交PR的变更内容。本部分旨在概述所做的变更,以及此PR是如何解决该问题的。请尽可能地提供有助于评审人员更高效、更快速完成检视审查的实用说明。 - 请说明为何需要这些更改,例如具体的使用场景或bug描述。 - 关联issue号(如果有)。 1.增加kimi k2.5模型的UT测试用例 2.补充扩展的LayerWiseOffloadOptionalInterface接口测试用例 - Please clarify what changes you are proposing. The purpose of this section is to outline the changes and how this PR fixes the issue. If possible, please consider writing useful notes for better and faster reviews in your PR. - Please clarify why the changes are needed. For instance, the use case and bug description. - Related issue number (if any) ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!3341 个月前
【bugfix】补充qwen3-vl-moe的依赖信息,精简依赖校验失败警告信息 Co-authored-by: libarry<870390541@qq.com> # message auto-generated for no-merge-commit merge: !508 merge bugfix/req into master 【bugfix】补充qwen3-vl-moe的依赖信息,精简依赖校验失败警告信息 Created-by: libarry Commit-by: libarry Merged-by: ascend-robot Description: ## PR描述 (What this PR does / why we need it?) 1、补充qwen3-vl-moe的依赖信息,与资料一致 2、精简警告提示的信息 3、只提示检查失败的依赖信息 ![image.png](https://raw.gitcode.com/user-images/assets/8444818/577eb1af-da4c-4334-88fa-58254c372795/image.png 'image.png') ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!5081 小时前
【bugfix】补充qwen3-vl-moe的依赖信息,精简依赖校验失败警告信息 Co-authored-by: libarry<870390541@qq.com> # message auto-generated for no-merge-commit merge: !508 merge bugfix/req into master 【bugfix】补充qwen3-vl-moe的依赖信息,精简依赖校验失败警告信息 Created-by: libarry Commit-by: libarry Merged-by: ascend-robot Description: ## PR描述 (What this PR does / why we need it?) 1、补充qwen3-vl-moe的依赖信息,与资料一致 2、精简警告提示的信息 3、只提示检查失败的依赖信息 ![image.png](https://raw.gitcode.com/user-images/assets/8444818/577eb1af-da4c-4334-88fa-58254c372795/image.png 'image.png') ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!5081 小时前
【feature】一键量化开箱即用 Co-authored-by: SuperMeixc<meixiaocun1@huawei.com> # message auto-generated for no-merge-commit merge: !103 merge master into master 【feature】一键量化开箱即用 Created-by: SuperMeixc Commit-by: SuperMeixc Merged-by: ascend-robot Description: 【feature】一键量化开箱即用 See merge request: Ascend/msmodelslim!1033 个月前
【bugfix】修复Qwen Omni使用非预期校准数据时的错误日志提示和标准错误码 Co-authored-by: xiaoheng181<eudemoniaxh@163.com> # message auto-generated for no-merge-commit merge: !230 merge master_vlm_bugfix into master 【bugfix】修复Qwen Omni使用非预期校准数据时的错误日志提示和标准错误码 Created-by: xiaoheng181 Commit-by: xiaoheng181 Merged-by: ascend-robot Description: ## 问题背景 关联 issue [#96](https://gitcode.com/Ascend/msmodelslim/issues/96) ## 修复内容 Qwen Omni由于本身网络结构和前向特点,visual部分前向传播被image数据和video数据复用处理,与逐层量化配合时必须保证generate_model_visit和generate_model_forward访问顺序与次数完全一致,因此当前仅支持text+image+video+audio的逐层量化校准(当image或video不同时存在时,会导致generate_model_visit与generate_model_forward处理不一致)。 此处更改数据模态缺失时的错误日志,统一为InvalidDatasetError日志和对应错误码。 msmodelslim/model/qwen3_omni_moe/model_adapter.py msmodelslim/model/qwen2_5_omni_thinker/model_adapter.py ## 测试说明 数据缺失video字段场景 ![image.png](https://raw.gitcode.com/user-images/assets/8444818/e89348be-fa0c-45bc-bc0e-bb12cabb9bab/image.png 'image.png') 正常抛出InvalidDatasetError日志 ![image.png](https://raw.gitcode.com/user-images/assets/8444818/c4974dee-ae1d-497b-855b-a367d4ea6b43/image.png 'image.png') See merge request: Ascend/msmodelslim!2302 个月前
【feature】预检失败由error改为warning,后续适配器报错再提供版本依赖 Co-authored-by: libarry<870390541@qq.com> # message auto-generated for no-merge-commit merge: !485 merge bugfix/precheck into master 【feature】预检失败由error改为warning,后续适配器报错再提供版本依赖 Created-by: libarry Commit-by: libarry Merged-by: ascend-robot Description: ## PR描述 (What this PR does / why we need it?) 1、依赖检查报错改为警告,所有版本依赖改为==或范围约束 2、当依赖检查失败后,适配器方法增加装饰器exception_handler,确保后续使用过程的适配器内任何报错会提示安装推荐的依赖版本号。 3、由于TimeoutError和内置TimeoutError重名,改名为ModelslimTimeoutError 4、修改UnexpectedError,增加两个方法,分别是注入tips和清理tips,支持提前注入外部Tips的能力,应用于warning后报错场景 ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? 用户环境依赖不符时,直接报错改为警告 ## 功能验证 (How was this patch tested?) 模型适配器问题注入tips: ![image.png](https://raw.gitcode.com/user-images/assets/8444818/3874cd20-89b6-4da6-83a1-dfa7a4a63bd6/image.png 'image.png') 模型forward报错触发UnexpectedError注入tips: ![image.png](https://raw.gitcode.com/user-images/assets/8444818/969dacf1-0479-442e-a0af-ba397cabfb46/image.png 'image.png') 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!4858 小时前
【feature】一键量化开箱即用 Co-authored-by: SuperMeixc<meixiaocun1@huawei.com> # message auto-generated for no-merge-commit merge: !103 merge master into master 【feature】一键量化开箱即用 Created-by: SuperMeixc Commit-by: SuperMeixc Merged-by: ascend-robot Description: 【feature】一键量化开箱即用 See merge request: Ascend/msmodelslim!1033 个月前
【test】add test_model_adapter_qwen3_5_moe.py Co-authored-by: sunny<sunyu_0904@163.com> # message auto-generated for no-merge-commit merge: !470 merge feature/supplement-unit-tests-qwen3_5_moe-part2 into master 【test】add test_model_adapter_qwen3_5_moe.py Created-by: sunny_infra Commit-by: sunny Merged-by: ascend-robot Description: 感谢您贡献的Pull Request! 在提交之前,请务必阅读 [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md)。 Thanks for sending a pull request! BEFORE SUBMITTING, PLEASE READ [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md). ## PR描述 (What this PR does / why we need it?) - 请明确说明您提交PR的变更内容。本部分旨在概述所做的变更,以及此PR是如何解决该问题的。请尽可能地提供有助于评审人员更高效、更快速完成检视审查的实用说明。 - 请说明为何需要这些更改,例如具体的使用场景或bug描述。 - 关联issue号(如果有)。 - Please clarify what changes you are proposing. The purpose of this section is to outline the changes and how this PR fixes the issue. If possible, please consider writing useful notes for better and faster reviews in your PR. - Please clarify why the changes are needed. For instance, the use case and bug description. - Related issue number (if any) ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!4701 天前
【feature】FlexSmooth & FlexAwqSSZ 算法多卡量化支持并接入DistributedTaskScheduler Co-authored-by: sunny<sunyu_0904@163.com> # message auto-generated for no-merge-commit merge: !435 merge feature/flexbaseprocessor_support_dts into master 【feature】FlexSmooth & FlexAwqSSZ 算法多卡量化支持并接入DistributedTaskScheduler Created-by: sunny_infra Commit-by: sunny Merged-by: ascend-robot Description: 感谢您贡献的Pull Request! 在提交之前,请务必阅读 [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md)。 Thanks for sending a pull request! BEFORE SUBMITTING, PLEASE READ [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md). ## PR描述 (What this PR does / why we need it?) - PR的变更内容。 (1)FlexAwqSSZ 算法适配支持多卡量化,实现完备性支持; (2)FlexSmooth & FlexAwqSSZ 接入DistributedTaskScheduler,通过共享任务池进行子任务下发,避免各rank执行重复的子任务,从而提升该离群值抑制算法的计算效率 (3)由于接入DTS的逻辑几乎相同,将相关逻辑提取到FlexSmoothBaseProcessor基类 - 变更原因。 当前多卡量化方法各rank执行重复的子任务,在离群值抑制场景下量化效率有待提升 - 关联issue号(如果有)。 https://gitcode.com/Ascend/msmodelslim/issues/232 https://gitcode.com/Ascend/msmodelslim/issues/231 ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? 暂无 ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [x] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 See merge request: Ascend/msmodelslim!4356 天前
【feature】一键量化开箱即用 Co-authored-by: SuperMeixc<meixiaocun1@huawei.com> # message auto-generated for no-merge-commit merge: !103 merge master into master 【feature】一键量化开箱即用 Created-by: SuperMeixc Commit-by: SuperMeixc Merged-by: ascend-robot Description: 【feature】一键量化开箱即用 See merge request: Ascend/msmodelslim!1033 个月前
[bugfix]修复Qwen Omni模块导入问题 Co-authored-by: xiaoheng181<eudemoniaxh@163.com> # message auto-generated for no-merge-commit merge: !234 merge master_omni_bugfix into master [bugfix]修复Qwen Omni模块导入问题 Created-by: xiaoheng181 Commit-by: xiaoheng181 Merged-by: ascend-robot Description: ## 问题背景 关联 issue [#101](https://gitcode.com/Ascend/msmodelslim/issues/101) ## 修复内容 Qwen Omni 修改依赖预检bug,模块导入位置有误,调整模块导入位置 msmodelslim/model/qwen3_omni_moe/model_adapter.py msmodelslim/model/qwen2_5_omni_thinker/model_adapter.py test/cases/model/qwen3_omni_moe/test_model_adapter_qwen3_omni_moe.py test/cases/model/qwen2_5_omni_thinker/test_model_adapter_qwen2_5_omni.py ## 测试说明 配置transformers非4.57.3版本,如4.51.0或4.57.0,正常抛出依赖预检错误 配置transformers4.57.3版本,正常量化 See merge request: Ascend/msmodelslim!2342 个月前
【bugfix】补充qwen3-vl-moe的依赖信息,精简依赖校验失败警告信息 Co-authored-by: libarry<870390541@qq.com> # message auto-generated for no-merge-commit merge: !508 merge bugfix/req into master 【bugfix】补充qwen3-vl-moe的依赖信息,精简依赖校验失败警告信息 Created-by: libarry Commit-by: libarry Merged-by: ascend-robot Description: ## PR描述 (What this PR does / why we need it?) 1、补充qwen3-vl-moe的依赖信息,与资料一致 2、精简警告提示的信息 3、只提示检查失败的依赖信息 ![image.png](https://raw.gitcode.com/user-images/assets/8444818/577eb1af-da4c-4334-88fa-58254c372795/image.png 'image.png') ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!5081 小时前
【UT】补充core目录UT Co-authored-by: joejoezhou<zhourongchen1@huawei.com> # message auto-generated for no-merge-commit merge: !487 merge feature/core-ut into master 【UT】补充core目录UT Created-by: joejoezhou Commit-by: joejoezhou Merged-by: ascend-robot Description: ## PR描述 (What this PR does / why we need it?) 补充msmodelslim/core单测 ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? 无 ## 功能验证 (How was this patch tested?) - [x] 功能自验 - [x] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [x] 新增/变更内容是否已新增/适配UT测试用例看护 See merge request: Ascend/msmodelslim!4871 天前
【UT】补充core目录UT Co-authored-by: joejoezhou<zhourongchen1@huawei.com> # message auto-generated for no-merge-commit merge: !487 merge feature/core-ut into master 【UT】补充core目录UT Created-by: joejoezhou Commit-by: joejoezhou Merged-by: ascend-robot Description: ## PR描述 (What this PR does / why we need it?) 补充msmodelslim/core单测 ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? 无 ## 功能验证 (How was this patch tested?) - [x] 功能自验 - [x] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [x] 新增/变更内容是否已新增/适配UT测试用例看护 See merge request: Ascend/msmodelslim!4871 天前
qwq32B w8a8 量化 Co-authored-by: ylzzz<yelinzhong@huawei.com> # message auto-generated for no-merge-commit merge: !262 merge ylzzz_qwq32b into master qwq32B w8a8 量化 Created-by: ylzzz Commit-by: ylzzz Merged-by: ascend-robot Description: ![image.png](https://raw.gitcode.com/user-images/assets/8444818/5821963f-47d0-4d36-bd7a-a44d6b903ee5/image.png 'image.png') ![image.png](https://raw.gitcode.com/user-images/assets/8444818/d40e17d2-3de9-4c1b-9881-3b9eda6a0e23/image.png 'image.png') See merge request: Ascend/msmodelslim!2622 个月前
【ut】补充step3.5测试 Co-authored-by: zhangz200102<zhangzheng183@huawei.com> # message auto-generated for no-merge-commit merge: !496 merge ut/for_step3_5_flash into master 【ut】补充step3.5测试 Created-by: zhangz200102 Commit-by: zhangz200102 Merged-by: ascend-robot Description: 感谢您贡献的Pull Request! 在提交之前,请务必阅读 [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md)。 Thanks for sending a pull request! BEFORE SUBMITTING, PLEASE READ [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md). ## PR描述 (What this PR does / why we need it?) - 请明确说明您提交PR的变更内容。本部分旨在概述所做的变更,以及此PR是如何解决该问题的。请尽可能地提供有助于评审人员更高效、更快速完成检视审查的实用说明。 补充存量代码ut - 请说明为何需要这些更改,例如具体的使用场景或bug描述。 - 关联issue号(如果有)。 - Please clarify what changes you are proposing. The purpose of this section is to outline the changes and how this PR fixes the issue. If possible, please consider writing useful notes for better and faster reviews in your PR. - Please clarify why the changes are needed. For instance, the use case and bug description. - Related issue number (if any) ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!4969 小时前
【重构】多模态生成模型量化服务重构wan2.2/hunyuanvideo【多模态生成量化兼容旧逻辑】 Co-authored-by: xiaoheng181<eudemoniaxh@163.com> # message auto-generated for no-merge-commit merge: !492 merge sd_refactor_legacy_model_adapters into master 【重构】多模态生成模型量化服务重构wan2.2/hunyuanvideo【多模态生成量化兼容旧逻辑】 Created-by: xiaoheng181 Commit-by: xiaoheng181 Merged-by: ascend-robot Description: 感谢您贡献的Pull Request! 在提交之前,请务必阅读 [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md)。 Thanks for sending a pull request! BEFORE SUBMITTING, PLEASE READ [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md). ## PR描述 (What this PR does / why we need it?) - 请明确说明您提交PR的变更内容。本部分旨在概述所做的变更,以及此PR是如何解决该问题的。请尽可能地提供有助于评审人员更高效、更快速完成检视审查的实用说明。 本 PR 是多模态生成(multimodal_sd_modelslim_v1)重构的第二笔,依赖已合入(或同栈基于)sd_refactor_multimodal_sd_core 的双路径量化框架。在 Legacy 路径上,将主仓已接入的多模态生成模型适配器对齐 LegacyMultimodalPipelineInterface,使 multimodal_sd_modelslim_v1 可继续走 model_config + load_pipeline / run_calib_inference / apply_quantization 流程。 flux1/model_adapter.py 实现 LegacyMultimodalPipelineInterface;init_model 仅返回权重字典,pipeline 加载迁至 load_pipeline;校准与量化上下文与框架一致。 wan2_1/model_adapter.py 同上,保留 Wan2.1 校准推理与 load_pipeline / _setup_cache 行为。 qwen_image_edit/model_adapter.py 声明实现 LegacyMultimodalPipelineInterface(接口对齐,改动极小)。 对应 UT 更新 test_model_adapter_flux1.py、test_model_adapter_wan2_1.py(如 apply_quantization、load_pipeline 等用例)。 - 请说明为何需要这些更改,例如具体的使用场景或bug描述。 核心 PR 仅提供 Legacy / 新 pipeline 分发能力,未改具体模型适配器。本 PR 让 Flux1、Wan2.1、Qwen-Image-Edit 在重构后仍可通过 Legacy 分支完成量化,避免主仓已支持模型回归;Wan2.2 / Hunyuan 等重构适配器在后续 PR 合入。 依赖:请先合入 sd_refactor_multimodal_sd_core(或本 PR 的 base 已包含该提交)。 - 关联issue号(如果有)。 - Please clarify what changes you are proposing. The purpose of this section is to outline the changes and how this PR fixes the issue. If possible, please consider writing useful notes for better and faster reviews in your PR. - Please clarify why the changes are needed. For instance, the use case and bug description. - Related issue number (if any) ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 无。 不改变一键量化 CLI 与对外 YAML 字段;在核心 PR 已合入前提下,上述模型仍使用既有 model_config + Legacy 流程,行为与重构前主仓路径对齐(由 UT 看护)。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!4921 天前
【重构】多模态生成模型量化服务重构wan2.2/hunyuanvideo【Wan2.2任务场景拆分、专家子网络拆分】 Co-authored-by: xiaoheng181<eudemoniaxh@163.com> # message auto-generated for no-merge-commit merge: !493 merge sd_refactor_wan2_2_refactor into master 【重构】多模态生成模型量化服务重构wan2.2/hunyuanvideo【Wan2.2任务场景拆分、专家子网络拆分】 Created-by: xiaoheng181 Commit-by: xiaoheng181 Merged-by: ascend-robot Description: 感谢您贡献的Pull Request! 在提交之前,请务必阅读 [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md)。 Thanks for sending a pull request! BEFORE SUBMITTING, PLEASE READ [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md). ## PR描述 (What this PR does / why we need it?) - 请明确说明您提交PR的变更内容。本部分旨在概述所做的变更,以及此PR是如何解决该问题的。请尽可能地提供有助于评审人员更高效、更快速完成检视审查的实用说明。 本 PR 是多模态生成(multimodal_sd_modelslim_v1)重构的第三笔,依赖已合入(或同栈基于)sd_refactor_multimodal_sd_core、sd_refactor_legacy_model_adapters。在 新 pipeline(MultimodalPipelineInterface)下完成 Wan2.2 场景化重构,并与保留的 Legacy 单体适配器(Wan2Point2Adapter)共存。 base_model_adapter.py(新) 实现标准 pipeline:get_inference_config_class / configure_runtime / init_model / handle_dataset / prepare_calib_data / inference_dump_calib_data / quantization_context;双专家 get_expert_adapter + expert_sub_adapter;与 Wan generate.py CLI 桥接(_namespace_to_argv 等)。 t2v/、i2v/、ti2v/ Wan2_2T2VModelAdapter、Wan2_2I2VModelAdapter、Wan2_2TI2VModelAdapter(如 Wan2.2-T2V-A14B);各场景独立 InferenceConfig 与校准规则(T2V 禁图、I2V 强制图等);配套 loader.py。 model_adapter.py Wan2Point2Adapter 仍走 LegacyMultimodalPipelineInterface,与 Legacy PR 行为一致;新量化路径走场景化类。 其它 constants.py(含 DUAL_EXPERT_SCENE_TASKS)、expert_sub_adapter.py、__init__.py 导出。 UT 新增/更新 test_scene_model_adapters.py、test_get_expert_adapter.py、test_inference_config.py、test_expert_sub_adapter.py、test_base_model_adapter_argv.py,并适配 test_model_adapter_wan2_2.py。 - 请说明为何需要这些更改,例如具体的使用场景或bug描述。 Wan2.2 需按 T2V/I2V/TI2V 分场景配置与校准,双专家需按专家分别 dump/量化;单体 Legacy 适配器无法满足 inference_config + dataset 的标准 pipeline。本 PR 与 Flux/Wan2.1 Legacy、Hunyuan 解耦,便于分步评审。 依赖:请先合入 sd_refactor_multimodal_sd_core、sd_refactor_legacy_model_adapters(本 PR base 须包含上述提交)。 - 关联issue号(如果有)。 - Please clarify what changes you are proposing. The purpose of this section is to outline the changes and how this PR fixes the issue. If possible, please consider writing useful notes for better and faster reviews in your PR. - Please clarify why the changes are needed. For instance, the use case and bug description. - Related issue number (if any) ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 有(在核心 PR 已合入前提下)。 可通过新 model_type(如 Wan2.2-T2V-A14B、Wan2.2-I2V-A14B、Wan2.2-TI2V-5B)走重构路径:YAML 使用 inference_config + dataset,不再依赖单体 model_config 塞满推理参数。 原 Wan2Point2Adapter Legacy 路径仍可用(model_config + load_pipeline),由量化服务按适配器类型自动分发。 完整配置说明与示例 YAML 在 PR5 文档 PR 合入;本 PR 以代码与 UT 为主。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!4931 天前
fix: move QuaRot rotation matrix to NPU to eliminate per-layer transfer Co-authored-by: rookie_hongchuan<hongchuan6@h-partners.com> # message auto-generated for no-merge-commit merge: !373 merge fix/quarot-npu into master fix: move QuaRot rotation matrix to NPU to eliminate per-layer transfer Created-by: rookie_hongchuan Commit-by: rookie_hongchuan Merged-by: ascend-robot Description: ### 动机 rotate_linear() 将旋转矩阵与 Linear 层权重对齐后执行矩阵乘。Linear 层权重通常在 NPU 上,而 create_rot() 生成的旋转矩阵始终位于 CPU。对于每个需要旋转的 Linear 层,rotate_linear() 内部都会触发一次 rot.to(weight_data) 的跨设备传输:旋转矩阵先从 CPU 传到 NPU,matmul 完成后结果再拷回。 这一开销对普通 Dense 模型不明显,但对 **MoE 结构** 会被显著放大 —— 每层有大量独立的 Expert Linear 层(如 DeepSeek-V4 为 384 个 Expert × 3 个矩阵/Expert = 1152 次旋转/层),跨设备传输次数与 Expert 数量成正比。 ### 修改方案 QuaRotInterface.get_rotate_command() 在 CPU 生成旋转矩阵后,立即通过 .to() 将其移至 NPU + GLOBAL_DTYPE(float32),对调用方完全透明。由于矩阵已在 NPU 上,rotate_linear() 内不再触发跨设备传输,仅在各模型适配器最初调用处执行一次 .to()。 - create_rot() 调用签名不变 - 受益范围:所有使用 QuaRot 且涉及大量独立旋转操作的结构,典型为 **MoE 模型**(DeepSeek-V3/V4/Qwen3-MoE/GLM-4-MoE/Kimi-K2 等) - 对非 MoE 模型同样有效,线性受益 ### 实测性能 DeepSeek-V4-Pro 4 卡 W8A8 量化:QuaRot 单层权重旋转耗时从 ~60s 降至 ~2s。 ## 功能验证 (How was this patch tested?) - 4 NPU DeepSeek-V4-Pro W8A8 量化,5+ 层正常执行 - 旋转矩阵 CPU → NPU 结果完全一致(CPU 生成,仅 .to() 传输) - 单卡 DeepSeek-V4-Flash 对比验证前后 QuaRot 结果一致 See merge request: Ascend/msmodelslim!3734 天前
【msmodelslim】刷新文件头部声明和版权 Co-authored-by: caishengcheng<caishengcheng@huawei.com> # message auto-generated for no-merge-commit merge: !28 merge license into master 【msmodelslim】刷新文件头部声明和版权 Created-by: caishengcheng Commit-by: caishengcheng Merged-by: ascend-robot Description: 【msmodelslim】刷新文件头部声明和版权 See merge request: Ascend/msmodelslim!284 个月前
【bugfix】补充qwen3-vl-moe的依赖信息,精简依赖校验失败警告信息 Co-authored-by: libarry<870390541@qq.com> # message auto-generated for no-merge-commit merge: !508 merge bugfix/req into master 【bugfix】补充qwen3-vl-moe的依赖信息,精简依赖校验失败警告信息 Created-by: libarry Commit-by: libarry Merged-by: ascend-robot Description: ## PR描述 (What this PR does / why we need it?) 1、补充qwen3-vl-moe的依赖信息,与资料一致 2、精简警告提示的信息 3、只提示检查失败的依赖信息 ![image.png](https://raw.gitcode.com/user-images/assets/8444818/577eb1af-da4c-4334-88fa-58254c372795/image.png 'image.png') ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!5081 小时前
【feature】依赖存在性预检 Co-authored-by: libarry<870390541@qq.com> # message auto-generated for no-merge-commit merge: !414 merge feature/precheck_pr into master 【feature】依赖存在性预检 Created-by: libarry Commit-by: libarry Merged-by: ascend-robot Description: 感谢您贡献的Pull Request! 在提交之前,请务必阅读 [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md)。 Thanks for sending a pull request! BEFORE SUBMITTING, PLEASE READ [CONTRIBUTING.md](https://gitcode.com/Ascend/msmodelslim/blob/master/CONTRIBUTING.md). ## PR描述 (What this PR does / why we need it?) 新增模型适配器加载器机制,提供预先检查依赖能力 ![image.png](https://raw.gitcode.com/user-images/assets/8444818/a596143e-9d8c-46be-b862-5cbe51874897/image.png 'image.png') - Please clarify what changes you are proposing. The purpose of this section is to outline the changes and how this PR fixes the issue. If possible, please consider writing useful notes for better and faster reviews in your PR. - Please clarify why the changes are needed. For instance, the use case and bug description. - Related issue number (if any) ## 面向用户的变更 (Does this PR introduce _any_ user-facing change)? - 请注意,这里指的是**任何**面向用户的变更,包括但不限于API、用户界面或其他使用方式上的变更。 - Note that it means *any* user-facing change including all aspects such as API, interface or other behavior changes. ## 功能验证 (How was this patch tested?) 请确认CI已通过增量及存量的单元测试用例。 如果本次测试方式与常规单元测试不同,请详细说明您的测试步骤(最好提供完整的可复现的操作路径及关键截图),以便Committer能够快速复现验证,也便于后续的维护。 如果未添加测试,请说明未添加的原因,以及为何难添加测试。 - [_] 功能自验 - [_] 本地自验截图(涉及个人标识符等敏感信息请注意脱敏) - [_] 新增/变更内容是否已新增/适配UT测试用例看护 CI passed with new added/existing test. If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future. If tests were not added, please describe why they were not added and/or why it was difficult to add. - [_] Self-verification of the feature. - [_] Screenshot of local self-verification (please anonymize any sensitive information such as personal identifiers) - [_] Have new or modified unit test (UT) cases been added or adapted to cover the newly added or changed content? See merge request: Ascend/msmodelslim!41415 天前
【msmodelslim】刷新文件头部声明和版权 Co-authored-by: caishengcheng<caishengcheng@huawei.com> # message auto-generated for no-merge-commit merge: !28 merge license into master 【msmodelslim】刷新文件头部声明和版权 Created-by: caishengcheng Commit-by: caishengcheng Merged-by: ascend-robot Description: 【msmodelslim】刷新文件头部声明和版权 See merge request: Ascend/msmodelslim!284 个月前