From cc871c5d8a67e0d556d6b13139cace3d5b3e73f8 Mon Sep 17 00:00:00 2001 From: Mark Saroufim Date: Mon, 15 Jul 2024 20:31:31 -0700 Subject: [PATCH] pin nightly to 2.5.0.dev20240709+cu121 (#505) * pin nightly to 2.5.0.dev20240711+cu121 * push * Update regression_test.yml * Update regression_test.yml --- .github/workflows/regression_test.yml | 4 ++-- test/dtypes/test_uint4.py | 8 +------- 2 files changed, 3 insertions(+), 9 deletions(-) diff --git a/.github/workflows/regression_test.yml b/.github/workflows/regression_test.yml index 191fb6fe6..aedcb3824 100644 --- a/.github/workflows/regression_test.yml +++ b/.github/workflows/regression_test.yml @@ -33,7 +33,7 @@ jobs: gpu-arch-version: "12.1" - name: CUDA Nightly runs-on: linux.g5.12xlarge.nvidia.gpu - torch-spec: '--pre torch --index-url https://download.pytorch.org/whl/nightly/cu121' + torch-spec: '--pre torch==2.5.0.dev20240709+cu121 --index-url https://download.pytorch.org/whl/nightly/cu121' gpu-arch-type: "cuda" gpu-arch-version: "12.1" - name: CPU 2.2.2 @@ -48,7 +48,7 @@ jobs: gpu-arch-version: "" - name: CPU Nightly runs-on: linux.4xlarge - torch-spec: '--pre torch --index-url https://download.pytorch.org/whl/nightly/cpu' + torch-spec: '--pre torch==2.5.0.dev20240709+cpu --index-url https://download.pytorch.org/whl/nightly/cpu' gpu-arch-type: "cpu" gpu-arch-version: "" diff --git a/test/dtypes/test_uint4.py b/test/dtypes/test_uint4.py index d4fbdd6b1..aa9415e51 100644 --- a/test/dtypes/test_uint4.py +++ b/test/dtypes/test_uint4.py @@ -4,19 +4,14 @@ PerChannelSymmetricWeightUInt4Tensor, ) import unittest -from unittest import TestCase, main from torch.ao.quantization.quantize_pt2e import prepare_pt2e, convert_pt2e from torch.ao.quantization.quantizer import QuantizationSpec, Quantizer from torch._export import capture_pre_autograd_graph -from torch._export import dynamic_dim from torch.testing._internal.common_quantization import ( NodeSpec as ns, QuantizationTestCase, ) -from torchao.quantization.utils import ( - compute_error, -) from torchao.quantization.quant_api import ( _replace_with_custom_fn_if_matches_filter, ) @@ -30,7 +25,6 @@ QuantizationAnnotation, ) import copy -from packaging import version def _apply_weight_only_uint4_quant(model): @@ -229,4 +223,4 @@ def forward(self, x): ) if __name__ == "__main__": - main() + unittest.main()