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

Remove imports and use forward references in ONNX feature #17926

Merged
merged 1 commit into from
Jun 29, 2022
Merged

Conversation

sgugger
Copy link
Collaborator

@sgugger sgugger commented Jun 28, 2022

What does this PR do?

Type annotations should not be responsible for imports, so moving the pretrained models import in the onnx feature file inside a TYPE_CHECKING block and using fast-forward references instead.

@sgugger sgugger requested a review from lewtun June 28, 2022 19:41
@HuggingFaceDocBuilderDev
Copy link

HuggingFaceDocBuilderDev commented Jun 28, 2022

The documentation is not available anymore as the PR was closed or merged.

Copy link
Member

@lewtun lewtun left a comment

Choose a reason for hiding this comment

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

Thanks a lot for fixing this!

Sorry I missed it in the last refactor 🙈

The changes LGTM :)

@sgugger sgugger merged commit 47b9165 into main Jun 29, 2022
@sgugger sgugger deleted the onnx_again branch June 29, 2022 13:02
viclzhu pushed a commit to viclzhu/transformers that referenced this pull request Jul 18, 2022
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