Skip to content

Bump torch to 2.11.0#3996

Draft
AlexanderDokuchaev wants to merge 25 commits into
openvinotoolkit:developfrom
AlexanderDokuchaev:ad/pt2110
Draft

Bump torch to 2.11.0#3996
AlexanderDokuchaev wants to merge 25 commits into
openvinotoolkit:developfrom
AlexanderDokuchaev:ad/pt2110

Conversation

@AlexanderDokuchaev
Copy link
Copy Markdown
Collaborator

@AlexanderDokuchaev AlexanderDokuchaev commented Mar 24, 2026

Changes

  • torch==2.11
  • onnx-ir==0.2.1
  • onnxscript==0.7.0
  • Update cuda to 13
  • Use torch.export.export instead of removed torch.export.export_for_training
  • Temporary disables some testcase for linalg.cholesky_inverse (it falls only on t4)
  • Disable test of gptqmodel example
  • -removed disable_tf32_precision

Reason for changes

Related tickets

Tests

Test examples - success
Weight compression - success
PTQ-850

@github-actions github-actions Bot added documentation Improvements or additions to documentation NNCF PT Pull requests that updates NNCF PyTorch NNCF OpenVINO Pull requests that updates NNCF OpenVINO NNCF ONNX Pull requests that updates NNCF ONNX labels Mar 24, 2026
@github-actions github-actions Bot added the NNCF PTQ Pull requests that updates NNCF PTQ label Mar 24, 2026
@AlexanderDokuchaev AlexanderDokuchaev marked this pull request as ready for review April 24, 2026 11:50
@AlexanderDokuchaev AlexanderDokuchaev requested a review from a team as a code owner April 24, 2026 11:50
Copilot AI review requested due to automatic review settings April 24, 2026 11:50
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates NNCF’s dependency stack and test/export utilities to be compatible with PyTorch 2.11 (and associated ONNX tooling), including CI updates for CUDA 13.

Changes:

  • Bump PyTorch/TorchVision and ONNX-related pinned versions across constraints and example requirements.
  • Replace torch.export.export_for_training usages with torch.export.export across tests/examples.
  • Update CI workflows to install CUDA 13.2.1 and adjust/disable specific tests/examples impacted by the upgrade.

Reviewed changes

Copilot reviewed 37 out of 37 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
tests/torch/test_tensor.py Overrides CUDA cholesky_inverse test cases and adds a TODO note for T4-related failures.
tests/torch/fx/test_model_transformer.py Updates export API usage and adjusts a comment near SWIN capture reproduction.
tests/torch/fx/helpers.py Switches FX capture helper from export_for_training to export.
tests/torch/function_hook/test_wrapper.py Adds explicit ids for dynamo/no-dynamo parametrization.
tests/torch/conftest.py Updates global fp32 precision backend settings for tests.
tests/post_training/pipelines/image_classification_torchvision.py Switches torchvision pipeline export function to torch.export.export.
tests/post_training/pipelines/fx_modelling.py Switches HuggingFace export path to torch.export.export.
tests/cross_fw/examples/example_scope.json Removes GPTQModel converter example entry (disables that example test).
src/nncf/torch/function_hook/handle_inner_functions.py Updates internal MHA forward handling to match newer torch internals and replaces assert statements.
examples/quantization_aware_training/torch/resnet18/requirements.txt Bumps torch/torchvision pins to 2.11.0/0.26.0.
examples/quantization_aware_training/torch/anomalib/requirements.txt Bumps torch pin to 2.11.0.
examples/pruning/torch/resnet18/requirements.txt Bumps torch/torchvision pins to 2.11.0/0.26.0.
examples/post_training_quantization/torch_fx/resnet18/requirements.txt Bumps torch/torchvision pins to 2.11.0/0.26.0.
examples/post_training_quantization/torch/ssd300_vgg16/requirements.txt Bumps torch/torchvision pins to 2.11.0/0.26.0.
examples/post_training_quantization/torch/mobilenet_v2/requirements.txt Bumps torch/torchvision pins to 2.11.0/0.26.0.
examples/post_training_quantization/openvino/yolov8_quantize_with_accuracy_control/requirements.txt Bumps torch pin to 2.11.0.
examples/post_training_quantization/openvino/yolo26/requirements.txt Bumps torch pin to 2.11.0.
examples/post_training_quantization/onnx/yolov8_quantize_with_accuracy_control/requirements.txt Bumps torch pin to 2.11.0.
examples/post_training_quantization/onnx/mobilenet_v2/requirements.txt Bumps torch/torchvision pins to 2.11.0/0.26.0.
examples/llm_compression/torch_fx/tiny_llama/requirements.txt Bumps torch/torchvision pins to 2.11.0/0.26.0.
examples/llm_compression/torch_fx/tiny_llama/modelling.py Switches export path to torch.export.export.
examples/llm_compression/torch/downstream_qat_with_nls/requirements.txt Bumps torch pin to 2.11.0.
examples/llm_compression/torch/distillation_qat_with_lora/requirements.txt Bumps torch pin to 2.11.0.
examples/llm_compression/openvino/tiny_llama_synthetic_data/requirements.txt Bumps torch pin to 2.11.0.
examples/llm_compression/openvino/tiny_llama_find_hyperparams/requirements.txt Bumps torch pin to 2.11.0.
examples/llm_compression/openvino/tiny_llama/requirements.txt Bumps torch pin to 2.11.0.
examples/llm_compression/openvino/smollm2_360m_fp8/requirements.txt Bumps torch pin to 2.11.0.
examples/llm_compression/openvino/smollm2_360m_codebook/requirements.txt Bumps torch/torchvision pins to 2.11.0/0.26.0.
examples/llm_compression/openvino/smollm2_360m_adaptive_codebook/requirements.txt Bumps torch/torchvision pins to 2.11.0/0.26.0.
examples/llm_compression/onnx/tiny_llama_scale_estimation/requirements.txt Bumps torch pin to 2.11.0.
examples/llm_compression/onnx/tiny_llama/requirements.txt Bumps torch pin to 2.11.0.
docs/Installation.md Updates documented PyTorch/CUDA versions for develop.
constraints.txt Updates pinned torch/torchvision/onnx-ir/onnxscript versions.
README.md Updates TorchFX export snippet to use torch.export.export.
.github/workflows/install.yml Updates CI CUDA installer from 12.6.3 to 13.2.1.
.github/workflows/examples.yml Updates examples CI CUDA installer from 12.6.3 to 13.2.1.
.github/workflows/call_precommit.yml Updates pre-commit CI CUDA installer from 12.6.3 to 13.2.1.
Comments suppressed due to low confidence (1)

tests/post_training/pipelines/image_classification_torchvision.py:33

  • There are two identical _torch_export function definitions back-to-back. This duplication is easy to miss and makes future edits error-prone; please remove one definition (and ensure only one canonical export helper is used in this module).

Comment thread tests/torch/fx/test_model_transformer.py Outdated
Comment thread README.md Outdated
Comment thread src/nncf/torch/function_hook/handle_inner_functions.py
Comment thread tests/torch/test_tensor.py
Comment thread tests/torch/conftest.py Outdated
@AlexanderDokuchaev AlexanderDokuchaev marked this pull request as draft May 19, 2026 13:42
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 NNCF ONNX Pull requests that updates NNCF ONNX NNCF OpenVINO Pull requests that updates NNCF OpenVINO NNCF PT Pull requests that updates NNCF PyTorch NNCF PTQ Pull requests that updates NNCF PTQ

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants