Skip to content

[Test][Kosmos2.5] Add XPU expectations for integration tests#46135

Merged
IlyasMoutawwakil merged 3 commits into
huggingface:mainfrom
YangKai0616:fix-kosmos
May 28, 2026
Merged

[Test][Kosmos2.5] Add XPU expectations for integration tests#46135
IlyasMoutawwakil merged 3 commits into
huggingface:mainfrom
YangKai0616:fix-kosmos

Conversation

@YangKai0616
Copy link
Copy Markdown
Contributor

What does this PR do?

This PR:

  1. Updates the Kosmos2.5 integration tests to use the shared Expectations helper for device-specific generated outputs, matching the style used in other transformers tests.
  2. Adds XPU ground truth for the eager and sdpa generation paths.

@ydshieh , pls help review, thx!

@YangKai0616
Copy link
Copy Markdown
Contributor Author

Friendly ping @IlyasMoutawwakil .

Copy link
Copy Markdown
Member

@IlyasMoutawwakil IlyasMoutawwakil left a comment

Choose a reason for hiding this comment

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

lgtm, just a style nit, but better resolve the expectation directly so that expected_text is a text

"<bbox><x_53><y_573><x_69><y_606></bbox>1\n<bbox><x_79><y_573><x_464><y_611></bbox>[REG] BLACK SAKURA\n<bbox><x_690><y_569><x_810><y_606></bbox>45,455\n<bbox><x_53><y_614><x_69><y_648></bbox>1\n<bbox><x_79><y_614><x_468><y_650></bbox>COOKIE DOH SAUCES\n<bbox><x_788><y_609><x_812><y_644></bbox>0\n<bbox><x_50><y_658><x_69><y_693></bbox>1\n<bbox><x_79><y_658><x_358><y_693></bbox>NATA DE COCO\n<bbox><x_790><y_652><x_814><y_687></bbox>0\n<bbox><x_31><y_742><x_820><y_781></bbox>Sub Total 45,455\n<bbox><x_27><y_781><x_822><y_827></bbox>PB1 (10%) 4,545\n<bbox><x_27><y_826><x_824><y_872></bbox>Rounding 0\n<bbox><x_24><y_872><x_827><y_921></bbox>Total 50,000\n<bbox><x_17><y_1056><x_836><y_1108></bbox>Card Payment 50,000\n"
],
}
)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

its better to resolve the expectation here (same for others)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Done!

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@github-actions
Copy link
Copy Markdown
Contributor

[For maintainers] Suggested jobs to run (before merge)

run-slow: kosmos2_5

@HuggingFaceDocBuilderDev
Copy link
Copy Markdown

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.

@IlyasMoutawwakil IlyasMoutawwakil added this pull request to the merge queue May 28, 2026
Merged via the queue into huggingface:main with commit 88070ef May 28, 2026
23 checks passed
yuchenxie4645 pushed a commit to yuchenxie4645/transformers that referenced this pull request May 28, 2026
…face#46135)

* [Kosmos2.5][Test] Add XPU expectations for integration tests

* Update according to the comments
kashif pushed a commit to kashif/transformers that referenced this pull request Jun 1, 2026
…face#46135)

* [Kosmos2.5][Test] Add XPU expectations for integration tests

* Update according to the comments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants