File tree 1 file changed +10
-5
lines changed
1 file changed +10
-5
lines changed Original file line number Diff line number Diff line change @@ -28,20 +28,25 @@ runs:
28
28
if : ${{ inputs.torch-version != 'nightly' }}
29
29
run : |
30
30
pip install torch==${{ inputs.torch-version }}.* --extra-index-url https://download.pytorch.org/whl/${{ inputs.cuda-version }}
31
- python -c "import torch; print('PyTorch:', torch.__version__)"
32
- python -c "import torch; print('CUDA:', torch.version.cuda)"
33
31
shell : bash
34
32
35
33
- name : Install PyTorch ${{ inputs.torch-version }}+${{ inputs.cuda-version }}
36
34
if : ${{ inputs.torch-version == 'nightly' }}
37
35
run : |
38
36
pip install --pre torch --extra-index-url https://download.pytorch.org/whl/nightly/${{ inputs.cuda-version }}
39
- python -c "import torch; print('PyTorch:', torch.__version__)"
40
- python -c "import torch; print('CUDA:', torch.version.cuda)"
37
+ shell : bash
38
+
39
+ - name : Downgrade NumPy if necessary
40
+ run : |
41
+ torch_version=$(python -c "import torch; print(torch.__version__)")
42
+ [[ $torch_version =~ ^2\.[0-2] ]] && pip install 'numpy<2'
41
43
shell : bash
42
44
43
45
- name : List installed packages
44
- run : pip list
46
+ run : |
47
+ pip list
48
+ python -c "import torch; print('PyTorch:', torch.__version__)"
49
+ python -c "import torch; print('CUDA:', torch.version.cuda)"
45
50
shell : bash
46
51
47
52
# TODO: Include catboost in Python 3.13 CI when catboost supports it:
You can’t perform that action at this time.
0 commit comments