Add transformers v5.10 support - #1863
Open
echarlaix wants to merge 10 commits into
Open
Conversation
|
The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update. |
echarlaix
marked this pull request as draft
July 13, 2026 16:43
echarlaix
marked this pull request as draft
July 13, 2026 16:43
rkazants
reviewed
Jul 13, 2026
echarlaix
commented
Jul 16, 2026
echarlaix
force-pushed
the
transformers-v5.10-support
branch
from
July 16, 2026 16:36
ac9a688 to
052e1a9
Compare
echarlaix
marked this pull request as ready for review
July 17, 2026 12:49
echarlaix
marked this pull request as ready for review
July 17, 2026 12:49
echarlaix
marked this pull request as draft
July 17, 2026 16:06
echarlaix
commented
Jul 20, 2026
| max_grid_size = grid_thw[:, 1:].max() | ||
| rotary_pos_emb_full = self._rotary_pos_emb(max_grid_size) | ||
| rotary_pos_emb = rotary_pos_emb_full[pos_ids].flatten(1) | ||
| if is_transformers_version(">=", "5.9"): |
Collaborator
Author
There was a problem hiding this comment.
echarlaix
marked this pull request as ready for review
July 20, 2026 14:55
echarlaix
marked this pull request as ready for review
July 20, 2026 14:55
echarlaix
requested review from
IlyasMoutawwakil,
popovaan,
regisss and
rkazants
July 20, 2026 15:19
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.
Add support for transformers v5.10:
CLIPTextTransformerwas removed in Refactor CLIP-like models聽transformers#44431, sotext_encoder.text_modelno longer exists since transformers v5.6gemma4_text_attention_forward: transformers v5.6 (First model聽transformers#45788) replacedpast_key_values.shared_layers/self.kv_shared_layer_indexwith ashared_kv_statesdict passed throughkwargsrot_pos_emb()in_OVQwen2VLForCausalLMand_OVQwen3OmniMoeForCausalLMnow callsself._rotary_pos_emb(pos_ids)directly whenis_transformers_version(">=", "5.9"), since the upstream signature changed from takingmax_grid_sizeto takingpos_idsdirectly