eaceb243df
[BE] Update the XPU support package to 2025.1.3 ( #154346 )
...
Fixes #153632
Pull Request resolved: https://github.com/pytorch/pytorch/pull/154346
Approved by: https://github.com/EikanWang , https://github.com/atalman
2025-06-11 09:46:18 +00:00
7a03b0d2ca
[BE] Remove CUDA 11 artifacts. Fix Check Binary workflow ( #155555 )
...
Please see: https://github.com/pytorch/pytorch/issues/147383
1. Remove CUDA 11 build and test artifacts. One place CUDA 12.4
2. Fix Check Binary Workflow to use Stable Cuda version variable rather then hardcoded one
Pull Request resolved: https://github.com/pytorch/pytorch/pull/155555
Approved by: https://github.com/malfet , https://github.com/Skylion007
2025-06-10 21:32:08 +00:00
0319044e92
[Easy] update pip sources for ROCm in nightly pull tool ( #145685 )
...
Pull Request resolved: https://github.com/pytorch/pytorch/pull/145685
Approved by: https://github.com/ezyang
2025-06-10 08:07:30 +00:00
8153340d10
[CI/CD] Remove CUDA 11.8 builds ( #155509 )
...
This removes CUDA 11.8 from CI/CD
Please see: https://github.com/pytorch/pytorch/issues/147383
TODO: Will followup of cleaning CUDA 11.8 config from scripts
Pull Request resolved: https://github.com/pytorch/pytorch/pull/155509
Approved by: https://github.com/cyyever , https://github.com/huydhn , https://github.com/malfet
2025-06-10 05:16:41 +00:00
3863bbb55b
[BE]: Update cusparselt to 0.7.1 ( #155232 )
...
Needed to support sparse operations on Blackwell, and implements new features for the library. Also optimizes library sizes vs 0.7
Pull Request resolved: https://github.com/pytorch/pytorch/pull/155232
Approved by: https://github.com/nWEIdia , https://github.com/malfet
2025-06-09 18:01:23 +00:00
9656251bb1
Revert "[BE] Update cudnn to 9.10.1.4 ( #155122 )"
...
This reverts commit a14f427db68e54500ef4cd9ed34cb9537263bb74.
Reverted https://github.com/pytorch/pytorch/pull/155122 on behalf of https://github.com/malfet due to Looks like it breaks a bunch of tests, see 36a722e20d/1 ([comment](https://github.com/pytorch/pytorch/pull/155122#issuecomment-2949209801 ))
2025-06-06 13:03:49 +00:00
a14f427db6
[BE] Update cudnn to 9.10.1.4 ( #155122 )
...
Follow up to #152782
Pull Request resolved: https://github.com/pytorch/pytorch/pull/155122
Approved by: https://github.com/malfet , https://github.com/atalman
2025-06-05 16:07:25 +00:00
34c6371d24
Add NVSHMEM to PYTORCH_EXTRA_INSTALL_REQUIREMENTS ( #154568 )
...
NVSHMEM 3.2.5 (released Mar 2025) have both cu11 and cu12 builds.
See:
https://pypi.nvidia.com/nvidia-nvshmem-cu12/
https://pypi.nvidia.com/nvidia-nvshmem-cu11/
Pull Request resolved: https://github.com/pytorch/pytorch/pull/154568
Approved by: https://github.com/atalman
ghstack dependencies: #154538
2025-06-04 17:43:24 +00:00
bab59d3c28
Upgrade to CUDA 12.8.1 for nightly binaries ( #152923 )
...
Upgrade current CUDA 12.8 builds to 12.8.1
Pull Request resolved: https://github.com/pytorch/pytorch/pull/152923
Approved by: https://github.com/atalman
2025-05-23 22:37:05 +00:00
c92ea3bc98
[BE] Upgrade XPU support package to 2025.1 in CICD ( #151899 )
...
Address #151097 . Including below changes,
- Add XPU support package 2025.1 build and test in CI for both Linux and Windows
- Keep XPU support package 2025.0 build in CI to ensure no break issue until PyTorch 2.8 release
- Upgrade XPU support package from 2025.0 to 2025.1 in CD for both Linux and Windows
- Enable XCCL in Linux CD wheel and oneMKL integration in both both Linux and Windows
- Update XPU runtime pypi packages of CD wheels
- Remove deprecated support package version docker image build
Pull Request resolved: https://github.com/pytorch/pytorch/pull/151899
Approved by: https://github.com/EikanWang , https://github.com/atalman
2025-05-14 20:21:09 +00:00
7f79222992
Upgrade to NCCL 2.26.5 for CUDA 12 ( #152810 )
...
Upgrade NCCL to latest 2.26.5
Pull Request resolved: https://github.com/pytorch/pytorch/pull/152810
Approved by: https://github.com/eqy , https://github.com/albanD , https://github.com/nWEIdia , https://github.com/atalman , https://github.com/cyyever
2025-05-14 00:52:50 +00:00
c869862875
Remove cuda dependencies from non cuda buids ( #152333 )
...
These dependancies added to fix poetry issue on pypi. However inclusion of these dependencies creates issue with poetry on download.pytorch.org due to poetry reading first available wheel on index for METADATA requirements. Hence all metadata requirements for CPU wheels can't list any cuda dependencies.
Injecting these dependencies via prep for pypi will need to be done via:
https://github.com/pytorch/test-infra/blob/main/release/pypi/prep_binary_for_pypi.sh
Ref: https://github.com/pytorch/pytorch/issues/152121
Pull Request resolved: https://github.com/pytorch/pytorch/pull/152333
Approved by: https://github.com/jeanschmidt , https://github.com/malfet
2025-04-28 16:46:44 +00:00
e05ac9b794
Use folder tagged docker images for binary builds ( #151706 )
...
Should be the last part of https://github.com/pytorch/pytorch/pull/150558 , except for maybe s390x stuff, which I'm still not sure what's going on there
For binary builds, do the thing like we do in CI where we tag each image with a hash of the .ci/docker folder to ensure a docker image built from that commit gets used. Previously it would use imagename:arch-main, which could be a version of the image based on an older commit
After this, changing a docker image and then tagging with ciflow/binaries on the same PR should use the new docker images
Release and main builds should still pull from docker io
Cons:
* if someone rebuilds the image from main or a PR where the hash is the same (ex folder is unchanged, but retrigger docker build for some reason), the release would use that image instead of one built on the release branch
* spin wait for docker build to finish
Pull Request resolved: https://github.com/pytorch/pytorch/pull/151706
Approved by: https://github.com/atalman
2025-04-22 21:50:10 +00:00
b4550541ea
[ROCm] upgrade nightly wheels to rocm6.4 ( #151355 )
...
Pull Request resolved: https://github.com/pytorch/pytorch/pull/151355
Approved by: https://github.com/jeffdaily
Co-authored-by: Jeff Daily <jeff.daily@amd.com >
2025-04-17 17:29:07 +00:00
bb11122e12
Update docker image names for s390x ( #151426 )
...
Disable switching tag for s390x docker images
Keep it that way unless they are published.
There's no way to determine in advance
which docker image names are needed
for building s390x binaries otherwise.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/151426
Approved by: https://github.com/malfet , https://github.com/seemethere
2025-04-17 12:47:23 +00:00
b238e36fd9
Revert "[BE][Ez]: Update CU126 to CUDNN 12.8 too ( #149254 )"
...
This reverts commit b0a5d55c584792a504ec18600180e3d1200dfea6.
Reverted https://github.com/pytorch/pytorch/pull/149254 on behalf of https://github.com/izaitsevfb due to seems to be causing multiple test failures ([comment](https://github.com/pytorch/pytorch/pull/149254#issuecomment-2744686862 ))
2025-03-21 23:44:09 +00:00
b0a5d55c58
[BE][Ez]: Update CU126 to CUDNN 12.8 too ( #149254 )
...
Have CUDNN have the same version for 12.6 and 12.8 for better performance and consistency. We can't do CU12.1 because it's not supported and CU12.4 isn't updated due to manywheel Linux compatibility reasons and dropping support for it.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/149254
Approved by: https://github.com/jansel , https://github.com/atalman , https://github.com/tinglvv
2025-03-21 18:20:44 +00:00
1d9401befc
ci: Remove mentions and usages of DESIRED_DEVTOOLSET and cxx11 ( #149443 )
...
This is a remnant of our migration to manylinux2_28 we should remove
these since all of our binary builds are now built with cxx11_abi
Signed-off-by: Eli Uriegas <eliuriegas@meta.com >
Pull Request resolved: https://github.com/pytorch/pytorch/pull/149443
Approved by: https://github.com/izaitsevfb , https://github.com/atalman
2025-03-20 16:49:46 +00:00
2be97c7257
Update nightly s390x builds ( #149337 )
...
This change should fix new nightly build failures for s390x.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/149337
Approved by: https://github.com/malfet
2025-03-19 23:27:14 +00:00
dea7157160
nccl: upgrade to 2.26.2 to avoid hang on ncclCommAbort ( #149351 )
...
Fixes #149153
Yaml generated from:
```
python .github/scripts/generate_ci_workflows.py
```
Test plan:
Repro in https://gist.github.com/d4l3k/16a19b475952bc40ddd7f2febcc297b7
```
rm -rf third_party/nccl
python setup.py develop
```
Pull Request resolved: https://github.com/pytorch/pytorch/pull/149351
Approved by: https://github.com/kwen2501 , https://github.com/atalman , https://github.com/malfet
2025-03-18 05:23:18 +00:00
6856d81c60
[BE]: Update CU128 cudnn to 9.8.0.87 ( #148963 )
...
Also cu12.6 is an on old CUDNN version, we may want to upgrade it for all the performance reasons as I don't see a manywheel linux reason to stay back on the old 9.5 release. I might split that into it's own PR. This one just updates CU126 to the latest and greatest.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/148963
Approved by: https://github.com/jansel , https://github.com/eqy , https://github.com/nWEIdia , https://github.com/tinglvv , https://github.com/atalman
2025-03-13 16:59:12 +00:00
29fd875bc1
Automate stable CUDA update and linter using min Python verison ( #148912 )
...
1. Fixes: https://github.com/pytorch/pytorch/issues/145571 . Cuda Stable is the same cuda version that is published to pypi, also used to set Metadata section in the rest of whl scripts and tag the docker releases with latest tag.
2. Updates min python version used in linter
Pull Request resolved: https://github.com/pytorch/pytorch/pull/148912
Approved by: https://github.com/Skylion007 , https://github.com/malfet
2025-03-12 18:12:34 +00:00
2a1eeaeed8
Remove 12.4 x86 builds and 12.6 sbsa builds from nightly ( #148895 )
...
https://github.com/pytorch/pytorch/issues/145570
redo https://github.com/pytorch/pytorch/pull/148625
Pull Request resolved: https://github.com/pytorch/pytorch/pull/148895
Approved by: https://github.com/atalman
2025-03-10 20:55:09 +00:00
a81751d8b7
[CD] Annotate linux/arm64 cuda wheels with consistent nvidia dependencies ( #145021 )
...
This resolves issues installing torch nightly wheels into a `uv sync`-generated `.venv`
The root cause is that the x64 and arm64 cuda nightly wheels have inconsistent metadata. This can be seen comparing `generated-linux-aarch64-binary-manywheel-nightly.yml` and `generated-linux-binary-manywheel-nightly.yml`
`uv` expects consistency:
https://github.com/astral-sh/uv/issues/10693
>Frankly, it's really not ideal that they change their dependencies from wheel to wheel.
>They could still put the dependencies there with the same platform markers they're using in the other wheel though... 🤷 ♀
https://github.com/astral-sh/uv/issues/10119#issuecomment-2559898792
>I think this is something that basically has to be solved by PyTorch. The issue is that the wheels for `2.6.0.dev20241222+cu126` don't have consistent metadata, and it's a fundamental assumption of uv that the metadata for a given version _is_ consistent.
To resolve this, I modified the arm64 nightly build workflow to add two new `PYTORCH_EXTRA_INSTALL_REQUIREMENTS` entries, under `manywheel-py3_11-cuda-aarch64-build` and `manywheel-py3_12-cuda-aarch64-build`. These are based on their equivalents in the x64 workflow for the corresponding python versions.
I used the cuda 12.6 dependencies versions for the nvidia packages, to match the `DOCKER_IMAGE: pytorch/manylinuxaarch64-builder:cuda12.6-main` being used by these jobs.
(The arm64 workflow file already had several `PYTORCH_EXTRA_INSTALL_REQUIREMENTS` entries, under various cpu wheels. I'm not sure why these are there, but I left them as-is.)
Pull Request resolved: https://github.com/pytorch/pytorch/pull/145021
Approved by: https://github.com/seemethere , https://github.com/atalman
Co-authored-by: Eli Uriegas <eliuriegas@meta.com >
Co-authored-by: Andrey Talman <atalman@fb.com >
2025-03-10 14:39:39 +00:00
99da439d10
Revert "Remove Cuda 12.4 from nightly Binaries ( #148625 )"
...
This reverts commit 1239176fe717839ca5612ac03a4806051225f381.
Reverted https://github.com/pytorch/pytorch/pull/148625 on behalf of https://github.com/malfet due to Broke lint ([comment](https://github.com/pytorch/pytorch/pull/148625#issuecomment-2707415005 ))
2025-03-07 20:47:45 +00:00
1239176fe7
Remove Cuda 12.4 from nightly Binaries ( #148625 )
...
https://github.com/pytorch/pytorch/issues/145570
removes cuda 12.4 nightly builds
Pull Request resolved: https://github.com/pytorch/pytorch/pull/148625
Approved by: https://github.com/atalman
2025-03-07 18:56:04 +00:00
61c4074df7
Add Windows Arm64 Nightly Builds ( #139760 )
...
This PR creates 3 new worklflows for Windows Arm64 target. The workflows and outputs can be reviewed at the following links:
https://github.com/pytorch/pytorch/actions/workflows/generated-windows-arm64-binary-libtorch-release-nightly.yml
https://github.com/pytorch/pytorch/actions/workflows/generated-windows-arm64-binary-libtorch-debug-nightly.yml
https://github.com/pytorch/pytorch/actions/workflows/generated-windows-arm64-binary-wheel-nightly.yml
Pull Request resolved: https://github.com/pytorch/pytorch/pull/139760
Approved by: https://github.com/malfet
Co-authored-by: Ozan Aydin <148207261+ozanMSFT@users.noreply.github.com >
Co-authored-by: Huy Do <huydhn@gmail.com >
2025-03-07 18:53:56 +00:00
3f4311d589
[CD] Upgrade xpu runtime pypi packages version and enable windows kineto again ( #148319 )
...
Fixes https://github.com/pytorch/pytorch/issues/145155
Pull Request resolved: https://github.com/pytorch/pytorch/pull/148319
Approved by: https://github.com/xuhancn , https://github.com/atalman
2025-03-05 18:39:55 +00:00
fe100c3c5b
Add libtorch nightly build for CUDA 12.8 ( #146265 )
...
Try removing sm50 and sm60 to shrink binary size, and resolve the ld --relink error
"Architecture support for Maxwell, Pascal, and Volta is considered feature-complete and will be frozen in an upcoming release." from 12.8 release note.
Also updating the runner for cuda 12.8 test to g4dn (T4, sm75) due to the drop in sm50/60 support.
https://github.com/pytorch/pytorch/issues/145570
Pull Request resolved: https://github.com/pytorch/pytorch/pull/146265
Approved by: https://github.com/atalman
2025-02-21 03:04:06 +00:00
e6c86952c6
Add CUDA 12.8 windows nightly build ( #147037 )
...
https://github.com/pytorch/pytorch/issues/145570
windows AMI is deployed to prod today, prepping the windows cuda 12.8 build
Pull Request resolved: https://github.com/pytorch/pytorch/pull/147037
Approved by: https://github.com/atalman
2025-02-19 16:59:32 +00:00
4ece056791
Nccl update to 2.25.1 for cuda 12.4-12.8 ( #146073 )
...
Should resolve: https://github.com/pytorch/pytorch/issues/144768
We use one common nccl version for cuda builds 12.4-12.8 : ``NCCL_VERSION=v2.25.1-1``
For CUDA 11.8 we use legacy ``NCCL_VERSION=v2.21.1-1``
We use pinned version of NCCL rather then submodule.
Move nccl location from ``third_party/nccl/nccl`` to ``third_party/nccl``
Pull Request resolved: https://github.com/pytorch/pytorch/pull/146073
Approved by: https://github.com/Skylion007 , https://github.com/malfet , https://github.com/kwen2501 , https://github.com/fduwjj
2025-02-19 03:52:26 +00:00
7622e29a37
Revert "Nccl update to 2.25.1 for cuda 12.4-12.8 ( #146073 )"
...
This reverts commit eecee5863e698d19458b33df7bfecbda0a04557a.
Reverted https://github.com/pytorch/pytorch/pull/146073 on behalf of https://github.com/atalman due to breaks Locally building benchmarks ([comment](https://github.com/pytorch/pytorch/pull/146073#issuecomment-2667054179 ))
2025-02-18 22:23:35 +00:00
eecee5863e
Nccl update to 2.25.1 for cuda 12.4-12.8 ( #146073 )
...
Should resolve: https://github.com/pytorch/pytorch/issues/144768
We use one common nccl version for cuda builds 12.4-12.8 : ``NCCL_VERSION=v2.25.1-1``
For CUDA 11.8 we use legacy ``NCCL_VERSION=v2.21.1-1``
We use pinned version of NCCL rather then submodule.
Move nccl location from ``third_party/nccl/nccl`` to ``third_party/nccl``
Pull Request resolved: https://github.com/pytorch/pytorch/pull/146073
Approved by: https://github.com/Skylion007 , https://github.com/malfet , https://github.com/kwen2501 , https://github.com/fduwjj
2025-02-14 21:23:19 +00:00
e06ee4aa9f
Revert "Nccl update to 2.25.1 for cuda 12.4-12.8 ( #146073 )"
...
This reverts commit 06f4a5c0e578d7da10ebdf14edcd24e5dcef78d6.
Reverted https://github.com/pytorch/pytorch/pull/146073 on behalf of https://github.com/atalman due to breaks macos builds: ModuleNotFoundError: No module named 'torch._C._distributed_c10d'; 'torch._C' is not a package ([comment](https://github.com/pytorch/pytorch/pull/146073#issuecomment-2659802389 ))
2025-02-14 16:44:46 +00:00
06f4a5c0e5
Nccl update to 2.25.1 for cuda 12.4-12.8 ( #146073 )
...
Should resolve: https://github.com/pytorch/pytorch/issues/144768
We use one common nccl version for cuda builds 12.4-12.8 : ``NCCL_VERSION=v2.25.1-1``
For CUDA 11.8 we use legacy ``NCCL_VERSION=v2.21.1-1``
We use pinned version of NCCL rather then submodule.
Move nccl location from ``third_party/nccl/nccl`` to ``third_party/nccl``
Pull Request resolved: https://github.com/pytorch/pytorch/pull/146073
Approved by: https://github.com/Skylion007 , https://github.com/malfet , https://github.com/kwen2501 , https://github.com/fduwjj
2025-02-14 15:29:59 +00:00
0344bf8a5a
[cuDNN] cuDNN to 9.7.1.26 for CUDA 12.8 ( #146957 )
...
rebasing for https://github.com/pytorch/pytorch/pull/146717
Pull Request resolved: https://github.com/pytorch/pytorch/pull/146957
Approved by: https://github.com/Skylion007 , https://github.com/eqy , https://github.com/nWEIdia , https://github.com/atalman
Co-authored-by: Aaron Gokaslan <aaronGokaslan@gmail.com >
2025-02-12 23:43:34 +00:00
8c80c13b34
[CD] Add python 3.13t build for xpu ( #146614 )
...
Fixes #146451
Pull Request resolved: https://github.com/pytorch/pytorch/pull/146614
Approved by: https://github.com/atalman
2025-02-12 07:01:36 +00:00
861bf892fb
Set USE_CUFILE=1 by default and add pypi package to binary build matrix ( #145748 )
...
Pull Request resolved: https://github.com/pytorch/pytorch/pull/145748
Approved by: https://github.com/atalman
2025-02-11 15:49:01 +00:00
9e45bc82e9
[aarch64] CUDA 12.8 aarch64 builds to nightly binaries ( #146378 )
...
https://github.com/pytorch/pytorch/issues/145570
Adding Cuda 12.8 and keeping 12.6 for the sbsa build, supported CUDA_ARCH: 9.0, 10.0, 12.0
Refactor the binaries matrix for cuda sbsa build. Previously cuda-aarch64 was hardcoded to cuda 12.6. Now reads 12.6 and 12.8, new build naming example [manywheel-py3_9-cuda-aarch64-12_8-build](https://github.com/pytorch/pytorch/actions/runs/13132625006/job/36640885079?pr=146378#logs )
TODO: once 12.8 is stable, remove 12.6 in sbsa
Pull Request resolved: https://github.com/pytorch/pytorch/pull/146378
Approved by: https://github.com/atalman
2025-02-05 02:55:21 +00:00
a7cc6d3e84
Manylinux 2.28 migration - remove pre-cxx11 abi libtorch builds ( #146200 )
...
Related to: https://github.com/pytorch/pytorch/issues/123649
Removing pre-cxx11 abi builds.
As per announcement : https://dev-discuss.pytorch.org/t/pytorch-linux-wheels-switching-to-new-wheel-build-platform-manylinux-2-28-on-november-12-2024/2581
Pull Request resolved: https://github.com/pytorch/pytorch/pull/146200
Approved by: https://github.com/kit1980 , https://github.com/huydhn
2025-01-31 21:43:12 +00:00
9232355bb0
Add CUDA 12.8 manywheel x86 Builds to Binaries Matrix ( #145792 )
...
https://github.com/pytorch/pytorch/issues/145570
Adding cuda 12.8.0 x86 builds first
Pull Request resolved: https://github.com/pytorch/pytorch/pull/145792
Approved by: https://github.com/nWEIdia , https://github.com/malfet , https://github.com/atalman
2025-01-31 16:12:02 +00:00
60f98262f1
PEP585: .github ( #145707 )
...
Pull Request resolved: https://github.com/pytorch/pytorch/pull/145707
Approved by: https://github.com/huydhn
2025-01-27 21:21:01 +00:00
2cffbff7da
Add 3.13t Windows and MacOS binary builds ( #141806 )
...
Related to: https://github.com/pytorch/pytorch/issues/130249
For conda uses approach described here:
https://conda-forge.org/blog/2024/09/26/python-313/
Create Python 3.13t conda env like so:
```
conda create -n py313 python=3.13 python-freethreading -c conda-forge
```
For windows executable installation we need to pass additional parameter to enable 3.13t:
```
Include_freethreaded=1
```
Pull Request resolved: https://github.com/pytorch/pytorch/pull/141806
Approved by: https://github.com/albanD
2025-01-21 17:16:19 +00:00
b4b4e57469
[CD] Enable profiling for XPU Windows nightly wheels ( #144316 )
...
PR https://github.com/pytorch/pytorch/pull/144034 added profiling support for torch XPU Windows binary, enable it in PyTorch XPU Windows CD
Works for https://github.com/pytorch/pytorch/issues/114850
Pull Request resolved: https://github.com/pytorch/pytorch/pull/144316
Approved by: https://github.com/xuhancn , https://github.com/atalman
2025-01-14 19:01:27 +00:00
6053242890
[CD] Enable python3.13t builds for aarch64 ( #144698 )
...
But make sure that right numpy version is picked (2.0.2 does not support 3.13)
Pull Request resolved: https://github.com/pytorch/pytorch/pull/144698
Approved by: https://github.com/atalman
ghstack dependencies: #144696 , #144697 , #144716
2025-01-14 02:29:01 +00:00
d44c3906b8
[EZ] [CD] Add 3.13 to FULL_PYTHON_VERSIONS ( #144697 )
...
Separation was necessary for Conda codegen, but now it's gone
Pull Request resolved: https://github.com/pytorch/pytorch/pull/144697
Approved by: https://github.com/atalman , https://github.com/izaitsevfb
ghstack dependencies: #144696
2025-01-13 19:12:12 +00:00
d2f905760d
[EZ] [CD] Eliminate stale TODO ( #144696 )
...
As 3.13 has been enabled across the board, which one can verify by running `./github/regenerate.sh` and observe that non of the configs have changed
Pull Request resolved: https://github.com/pytorch/pytorch/pull/144696
Approved by: https://github.com/izaitsevfb , https://github.com/atalman
2025-01-13 19:12:12 +00:00
b6bdb67f82
[BE][Easy] use pathlib.Path instead of dirname / ".." / pardir ( #129374 )
...
Changes by apply order:
1. Replace all `".."` and `os.pardir` usage with `os.path.dirname(...)`.
2. Replace nested `os.path.dirname(os.path.dirname(...))` call with `str(Path(...).parent.parent)`.
3. Reorder `.absolute()` ~/ `.resolve()`~ and `.parent`: always resolve the path first.
`.parent{...}.absolute()` -> `.absolute().parent{...}`
4. Replace chained `.parent x N` with `.parents[${N - 1}]`: the code is easier to read (see 5.)
`.parent.parent.parent.parent` -> `.parents[3]`
5. ~Replace `.parents[${N - 1}]` with `.parents[${N} - 1]`: the code is easier to read and does not introduce any runtime overhead.~
~`.parents[3]` -> `.parents[4 - 1]`~
6. ~Replace `.parents[2 - 1]` with `.parent.parent`: because the code is shorter and easier to read.~
Pull Request resolved: https://github.com/pytorch/pytorch/pull/129374
Approved by: https://github.com/justinchuby , https://github.com/malfet
2024-12-29 17:23:13 +00:00
c4bff71854
[Easy] Add ROCm support to nightly pull tool ( #141282 )
...
Pull Request resolved: https://github.com/pytorch/pytorch/pull/141282
Approved by: https://github.com/malfet
ghstack dependencies: #143263
2024-12-27 00:07:38 +00:00
475656fd9c
Revert "[BE][Easy] use pathlib.Path instead of dirname / ".." / pardir ( #129374 )"
...
This reverts commit 2293fe1024812d6349f6e2b3b7de82c6b73f11e4.
Reverted https://github.com/pytorch/pytorch/pull/129374 on behalf of https://github.com/malfet due to failing internal ROCM builds with error: ModuleNotFoundError: No module named hipify ([comment](https://github.com/pytorch/pytorch/pull/129374#issuecomment-2562973920 ))
2024-12-26 17:32:23 +00:00