File tree 1 file changed +9
-5
lines changed
1 file changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -24,24 +24,28 @@ runs:
24
24
cache-dependency-path : |
25
25
pyproject.toml
26
26
27
+ - name : Pre-install NumPy<2 if necessary
28
+ run : |
29
+ [[ ${{ inputs.torch-version }} =~ ^2\.[0-2] ]] && pip install 'numpy<2' || echo "Skipping NumPy<2 installation"
30
+ shell : bash
31
+
27
32
- name : Install PyTorch ${{ inputs.torch-version }}+${{ inputs.cuda-version }}
28
33
if : ${{ inputs.torch-version != 'nightly' }}
29
34
run : |
30
35
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
36
shell : bash
34
37
35
38
- name : Install PyTorch ${{ inputs.torch-version }}+${{ inputs.cuda-version }}
36
39
if : ${{ inputs.torch-version == 'nightly' }}
37
40
run : |
38
41
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)"
41
42
shell : bash
42
43
43
44
- name : List installed packages
44
- run : pip list
45
+ run : |
46
+ pip list
47
+ python -c "import torch; print('PyTorch:', torch.__version__)"
48
+ python -c "import torch; print('CUDA:', torch.version.cuda)"
45
49
shell : bash
46
50
47
51
# TODO: Include catboost in Python 3.13 CI when catboost supports it:
You can’t perform that action at this time.
0 commit comments