Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: reenable py313 #3455

Draft
wants to merge 20 commits into
base: main
Choose a base branch
from
Draft

chore: reenable py313 #3455

wants to merge 20 commits into from

Conversation

zewenli98
Copy link
Collaborator

Description

Reenabled Python 3.13 builds since TensorRT has 3.13 wheels available now for TensorRT 10.9.

Type of change

  • New feature (non-breaking change which adds functionality)

Checklist:

  • My code follows the style guidelines of this project (You can use the linters)
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas and hacks
  • I have made corresponding changes to the documentation
  • I have added tests to verify my fix or my feature
  • New and existing unit tests pass locally with my changes
  • I have added the relevant labels to my PR in so that relevant reviewers are notified

@zewenli98 zewenli98 requested a review from lanluo-nvidia March 31, 2025 20:20
@zewenli98 zewenli98 self-assigned this Mar 31, 2025
@zewenli98 zewenli98 marked this pull request as draft March 31, 2025 20:20
@zewenli98 zewenli98 requested a review from narendasan March 31, 2025 21:24
@narendasan narendasan added the ciflow/binaries/all Build for all Python Versions label Mar 31, 2025
Copy link

pytorch-bot bot commented Mar 31, 2025

No ciflow labels are configured for this repo.
For information on how to enable CIFlow bot see this wiki

@narendasan narendasan linked an issue Mar 31, 2025 that may be closed by this pull request
@github-actions github-actions bot added the component: tests Issues re: Tests label Apr 1, 2025
- name: Install Rust
run: |
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
source $HOME/.cargo/env
Copy link
Contributor

Choose a reason for hiding this comment

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

I think you don't need to install rust. Instead, you should try to bump the version of transformers in tests/py/requirements.txt. transformers 4.40.2 depended on tokenizers 0.19.x, but tokenizers 0.19.x didn't have wheels for cp313. That's why pip downloaded the source archive of tokenizers and then compiled unsuccessfully.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

The updated transformers doesn't match the results of BERT, compared with old transformers and TRT, so we fixed the version here. Any idea?

Copy link
Contributor

Choose a reason for hiding this comment

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

The test_bert_base_uncased in test_models and test_models_export was flawed. The inputs were defined as torch.randint(0, 1, ...), which returned a meaningless tensor filled with all zeros because the value of the second arg high is exclusive. To get a useful tensor the high arg should be at least 2, like https://pytorch.org/TensorRT/tutorials/_rendered_examples/dynamo/torch_compile_transformers_example.html.

@zewenli98 zewenli98 force-pushed the reenable_py313 branch 2 times, most recently from 323e177 to 404365a Compare April 1, 2025 19:54
@github-actions github-actions bot added component: conversion Issues re: Conversion stage component: api [Python] Issues re: Python API component: dynamo Issues relating to the `torch.compile` or `torch._dynamo.export` paths labels Apr 3, 2025
@github-actions github-actions bot removed the component: conversion Issues re: Conversion stage label Apr 3, 2025
@github-actions github-actions bot removed component: api [Python] Issues re: Python API component: dynamo Issues relating to the `torch.compile` or `torch._dynamo.export` paths labels Apr 3, 2025
@github-actions github-actions bot added component: conversion Issues re: Conversion stage component: api [Python] Issues re: Python API component: dynamo Issues relating to the `torch.compile` or `torch._dynamo.export` paths labels Apr 3, 2025
@github-actions github-actions bot removed component: conversion Issues re: Conversion stage component: api [Python] Issues re: Python API component: dynamo Issues relating to the `torch.compile` or `torch._dynamo.export` paths labels Apr 3, 2025
@narendasan narendasan added cherry-pick To cherry-pick to a release branch needs-release-cherrypick labels Apr 4, 2025
@github-actions github-actions bot requested a review from narendasan April 4, 2025 00:35
@narendasan narendasan removed the cherry-pick To cherry-pick to a release branch label Apr 4, 2025
@github-actions github-actions bot added the component: build system Issues re: Build system label Apr 9, 2025
@github-actions github-actions bot added component: conversion Issues re: Conversion stage component: api [Python] Issues re: Python API component: dynamo Issues relating to the `torch.compile` or `torch._dynamo.export` paths labels Apr 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ciflow/binaries/all Build for all Python Versions cla signed component: api [Python] Issues re: Python API component: build system Issues re: Build system component: conversion Issues re: Conversion stage component: dynamo Issues relating to the `torch.compile` or `torch._dynamo.export` paths component: tests Issues re: Tests needs-release-cherrypick
Projects
None yet
Development

Successfully merging this pull request may close these issues.

✨[Feature] py3.13 wheels
4 participants