Repository navigation
Fix issue for changing transformer version - #24828
Merged
Merged
Conversation
test-model-metal-e2e installed the optimum-executorch pin, which needs transformers 5.0.0rc1, before install_executorch.sh. Since requirements-examples.txt moved to transformers 5.11.0, install_executorch.sh upgrades transformers afterwards, and the optimum-cli exports of Whisper and Voxtral fail: StaticLayer now mutates cumulative_length during export, and Voxtral's get_audio_features returns a BaseModelOutputWithPooling instead of a tensor. Signed-off-by: Jiseong Oh <jiseong.oh@samsung.com>
With transformers 5.11.0, StaticLayer.update ignores cache_position and writes K/V at arange(n) + cumulative_length, then advances cumulative_length in place. Register cumulative_length as a non-persistent buffer of each wrapper and set it from cache_position at the start of forward, so the cache row follows the cache_position input again. With this change both exported decoders match eager on transformers 5.11.0. Signed-off-by: Jiseong Oh <jiseong.oh@samsung.com>
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/24828
Note: Links to docs will display an error until the docs builds have been completed. ✅ No FailuresAs of commit a657dde with merge base e34f8cf ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
This PR needs a
|
metascroy
approved these changes
Nov 10, 2026
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
whisper: RuntimeError: Constant L__self___cache_self_attention_cache_layers_0_cumulative_length is mutated in the forward method.
the metal job installs the optimum-executorch pin first (transformers 5.0.0rc1), then install_executorch.sh pulls requirements-examples.txt, which now upgrades transformers to 5.11.0. cuda e2e installs them in the other order, so it still ends on 5.0.0rc1 and stays green. likely fix: in metal.yml install optimum-executorch after install_executorch.sh like cuda.yml does, or bump the optimum-executorch pin to one that works with 5.11