Skip to content

Import backend modules in nncf/__init__.py #3451

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

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from

Conversation

AlexanderDokuchaev
Copy link
Collaborator

@AlexanderDokuchaev AlexanderDokuchaev commented Apr 22, 2025

Changes

Import backend modules in nncf/init.py

import nncf
nncf.torch.load_from_config(...)

Related tickets

164656

Tests

https://github.com/openvinotoolkit/nncf/actions/runs/14603877559

@github-actions github-actions bot added documentation Improvements or additions to documentation NNCF PT Pull requests that updates NNCF PyTorch experimental labels Apr 22, 2025
@@ -90,3 +90,15 @@
"Please install one of the supported frameworks above in order to use NNCF on top of it.\n"
"See the installation guide at https://github.com/openvinotoolkit/nncf#installation-guide for help."
)

if _AVAILABLE_FRAMEWORKS["torch"]:
from nncf import torch as torch
Copy link
Contributor

Choose a reason for hiding this comment

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

Do PyTorch extensions compile during this call?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

No, extensions compiles on first using

@AlexanderDokuchaev AlexanderDokuchaev marked this pull request as ready for review April 23, 2025 08:05
@AlexanderDokuchaev AlexanderDokuchaev requested a review from a team as a code owner April 23, 2025 08:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation experimental NNCF PT Pull requests that updates NNCF PyTorch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants