Skip to content

Commit

Permalink
Enable workflow dispatch on Torch 1.10 CI tests (#4361)
Browse files Browse the repository at this point in the history
  • Loading branch information
loadams authored Sep 19, 2023
1 parent dcf649c commit dcd3ae1
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions .github/workflows/nv-torch110-p40.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ name: nv-torch110-p40
on:
schedule:
- cron: "0 0 * * *"
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/nv-torch110-v100.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ name: nv-torch110-v100
on:
schedule:
- cron: "0 0 * * *"
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
Expand Down
5 changes: 2 additions & 3 deletions tests/unit/inference/quantization/test_int4_quantization.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,16 @@
from deepspeed.inference.quantization.quantization import _init_group_wise_weight_quantization
from deepspeed.inference.quantization.utils import Quantizer, DeQuantizer
from deepspeed.inference.quantization.layers import QuantizedLinear
from deepspeed.runtime.utils import required_torch_version
from transformers.models.opt.modeling_opt import OPTDecoderLayer
from transformers import AutoConfig, OPTConfig, AutoModel
import pytest
from collections import OrderedDict
from typing import Dict

TORCH_MAJOR = int(torch.__version__.split('.')[0])
TORCH_MINOR = int(torch.__version__.split('.')[1])
device = get_accelerator().device_name() if get_accelerator().is_available() else 'cpu'

if (TORCH_MAJOR < 1 or (TORCH_MAJOR == 1 and TORCH_MINOR < 10)):
if not required_torch_version(min_version=1.10):
pytest.skip("torch.Tensor.bitwise_left_shift in INT4 quantizer needs torch 1.10 or above.",
allow_module_level=True)

Expand Down

0 comments on commit dcd3ae1

Please sign in to comment.