Commit Graph

188 Commits

Author SHA1 Message Date
Huy Do
b4160fd9c7 Clean up macOS x86 binaries build jobs (#116726)
This will stop building binaries for MacOS x86 on PyTorch including nightly and all future releases.  If we want this for 2.2, this can be cherry-picked there.

* [x] https://github.com/pytorch/pytorch/pull/116725
* [ ] https://github.com/pytorch/pytorch/pull/116726

Fixes https://github.com/pytorch/pytorch/issues/114602

Pull Request resolved: https://github.com/pytorch/pytorch/pull/116726
Approved by: https://github.com/atalman
2024-03-11 19:09:39 +00:00
Nikita Shulga
98a044d33e [CI] Build M1 conda binaries on M1 runners (#117801)
As usual, almost no work on PyTorch side, all changes are on the builder end, namely:
- 8b67d32929 - depend on `blas * mkl` only on x86 machines
- eb78393f1e - install arm64 conda when running on Apple Silicon
- 0d3aea4ee0 - constrain llvmdev-9 to x86 machines only
- 6c6a33b271 - set correct DEVELOPER_DIR path

TODO:
 - We should auto-detect this `DEVELOPER_DIR` via `xcode-select`
Pull Request resolved: https://github.com/pytorch/pytorch/pull/117801
Approved by: https://github.com/atalman
2024-01-19 14:31:12 +00:00
atalman
995fae6060 Move small pypi build as default for linux cuda 12.1 (#114281)
This is first PR to resolve: https://github.com/pytorch/pytorch/issues/113972
Move our small wheel build as default
Test:
```
pip3 install --no-cache-dir --pre torch-2.2.0.dev20231121%2Bcu121-cp310-cp310-linux_x86_64.whl  --index-url https://download.pytorch.org/whl/nightly/cu121
Looking in indexes: https://download.pytorch.org/whl/nightly/cu121
Processing ./torch-2.2.0.dev20231121%2Bcu121-cp310-cp310-linux_x86_64.whl
Collecting filelock (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/filelock-3.9.0-py3-none-any.whl (9.7 kB)
Collecting typing-extensions>=4.8.0 (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/typing_extensions-4.8.0-py3-none-any.whl (31 kB)
Collecting sympy (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/sympy-1.11.1-py3-none-any.whl (6.5 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 6.5/6.5 MB 253.4 MB/s eta 0:00:00
Collecting networkx (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/networkx-3.0rc1-py3-none-any.whl (2.0 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 2.0/2.0 MB 387.1 MB/s eta 0:00:00
Collecting jinja2 (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/Jinja2-3.1.2-py3-none-any.whl (133 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 133.1/133.1 kB 365.3 MB/s eta 0:00:00
Collecting fsspec (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/fsspec-2023.4.0-py3-none-any.whl (153 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 154.0/154.0 kB 370.6 MB/s eta 0:00:00
Collecting pytorch-triton==2.1.0+6e4932cda8 (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/pytorch_triton-2.1.0%2B6e4932cda8-cp310-cp310-linux_x86_64.whl (125.4 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 125.4/125.4 MB 384.1 MB/s eta 0:00:00
Collecting nvidia-cuda-nvrtc-cu12==12.1.105 (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/cu121/nvidia_cuda_nvrtc_cu12-12.1.105-py3-none-manylinux1_x86_64.whl (23.7 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 23.7/23.7 MB 404.9 MB/s eta 0:00:00
Collecting nvidia-cuda-runtime-cu12==12.1.105 (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/cu121/nvidia_cuda_runtime_cu12-12.1.105-py3-none-manylinux1_x86_64.whl (823 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 823.6/823.6 kB 402.5 MB/s eta 0:00:00
Collecting nvidia-cuda-cupti-cu12==12.1.105 (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/cu121/nvidia_cuda_cupti_cu12-12.1.105-py3-none-manylinux1_x86_64.whl (14.1 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 14.1/14.1 MB 383.9 MB/s eta 0:00:00
Collecting nvidia-cudnn-cu12==8.9.2.26 (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/cu121/nvidia_cudnn_cu12-8.9.2.26-py3-none-manylinux1_x86_64.whl (731.7 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 731.7/731.7 MB 406.9 MB/s eta 0:00:00
Collecting nvidia-cublas-cu12==12.1.3.1 (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/cu121/nvidia_cublas_cu12-12.1.3.1-py3-none-manylinux1_x86_64.whl (410.6 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 410.6/410.6 MB 388.2 MB/s eta 0:00:00
Collecting nvidia-cufft-cu12==11.0.2.54 (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/cu121/nvidia_cufft_cu12-11.0.2.54-py3-none-manylinux1_x86_64.whl (121.6 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 121.6/121.6 MB 410.5 MB/s eta 0:00:00
Collecting nvidia-curand-cu12==10.3.2.106 (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/cu121/nvidia_curand_cu12-10.3.2.106-py3-none-manylinux1_x86_64.whl (56.5 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 56.5/56.5 MB 272.9 MB/s eta 0:00:00
Collecting nvidia-cusolver-cu12==11.4.5.107 (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/cu121/nvidia_cusolver_cu12-11.4.5.107-py3-none-manylinux1_x86_64.whl (124.2 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 124.2/124.2 MB 381.5 MB/s eta 0:00:00
Collecting nvidia-cusparse-cu12==12.1.0.106 (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/cu121/nvidia_cusparse_cu12-12.1.0.106-py3-none-manylinux1_x86_64.whl (196.0 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 196.0/196.0 MB 394.6 MB/s eta 0:00:00
Collecting nvidia-nccl-cu12==2.19.3 (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/cu121/nvidia_nccl_cu12-2.19.3-py3-none-manylinux1_x86_64.whl (166.0 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 166.0/166.0 MB 384.7 MB/s eta 0:00:00
Collecting nvidia-nvtx-cu12==12.1.105 (from torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/cu121/nvidia_nvtx_cu12-12.1.105-py3-none-manylinux1_x86_64.whl (99 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 99.1/99.1 kB 281.8 MB/s eta 0:00:00
Collecting nvidia-nvjitlink-cu12 (from nvidia-cusolver-cu12==11.4.5.107->torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/cu121/nvidia_nvjitlink_cu12-12.1.105-py3-none-manylinux1_x86_64.whl (19.8 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 19.8/19.8 MB 367.3 MB/s eta 0:00:00
Collecting MarkupSafe>=2.0 (from jinja2->torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/MarkupSafe-2.1.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (25 kB)
Collecting mpmath>=0.19 (from sympy->torch==2.2.0.dev20231121+cu121)
  Downloading https://download.pytorch.org/whl/nightly/mpmath-1.2.1-py3-none-any.whl (532 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 532.6/532.6 kB 391.3 MB/s eta 0:00:00
Installing collected packages: mpmath, typing-extensions, sympy, nvidia-nvtx-cu12, nvidia-nvjitlink-cu12, nvidia-nccl-cu12, nvidia-curand-cu12, nvidia-cufft-cu12, nvidia-cuda-runtime-cu12, nvidia-cuda-nvrtc-cu12, nvidia-cuda-cupti-cu12, nvidia-cublas-cu12, networkx, MarkupSafe, fsspec, filelock, pytorch-triton, nvidia-cusparse-cu12, nvidia-cudnn-cu12, jinja2, nvidia-cusolver-cu12, torch
```
Pull Request resolved: https://github.com/pytorch/pytorch/pull/114281
Approved by: https://github.com/malfet, https://github.com/huydhn
2023-11-22 00:10:03 +00:00
Nikita Shulga
1b86d5ef2f [Ci] Add arm64 libtorch CI config (#112474)
Pull Request resolved: https://github.com/pytorch/pytorch/pull/112474
Approved by: https://github.com/ZainRizvi, https://github.com/seemethere
ghstack dependencies: #112451, #112452
2023-11-01 19:09:34 +00:00
Nikita Shulga
8d6b4322d0 [CI] Limit libtorch builds to shared-with-deps (#112452)
As that is the only variant that is being mentioned on  https://pytorch.org/get-started/locally/

And for MacOS those three flavors were just building and uploading the
same thing 3 times over, see [this](https://github.com/pytorch/pytorch/actions/runs/6689661275/job/18176516410) for example:
```
upload: ../../_temp/artifacts/libtorch-macos-2.2.0.dev20231030.zip to s3://pytorch/libtorch/nightly/cpu/libtorch-macos-2.2.0.dev20231030.zip
```

Pull Request resolved: https://github.com/pytorch/pytorch/pull/112452
Approved by: https://github.com/huydhn
ghstack dependencies: #112451
2023-10-31 08:40:06 +00:00
Nikita Shulga
cd0e7d133b Migrate MacOs wheel binary builds to ephemeral M1 runners (#110432)
Surprisingly there are no speed difference between running the cross-compilation on `macos12-xl` (x86_64 12 core machine) and `macos-13-xlarge` (m1 6 core machine)

Most of the changes are on the https://github.com/pytorch/builder side:
- 50a6e91f97 skips installing mkl on M1 machines
- bbb29b0467 same for llvm-9
- 8bcc83dbb1 bumps minimal numpy version to 1.19 (as 1.17 is not available for m1)
- cc4f1f9055 skips building tests/distributed for M1
Pull Request resolved: https://github.com/pytorch/pytorch/pull/110432
Approved by: https://github.com/kit1980
2023-10-03 17:31:28 +00:00
Mike Schneider
ec85ab6157 Adding aarch64 wheel CI workflows (#104109)
Adding Workflows for building aarch64 Linux PyTorch PIP wheels

Updates:
* Created aarch64 template for generated workflows
* Updated generate_ci_workflows.py to include aarch64
* Generated the aarch64 wheel workflow
* added _binary-build-aarch64.yml for building aarch64 wheel
* added _binary-test-aarch64.yml for sanity check of aarch64 wheel
* Updated binary_linux_test.sh to use --extra-index-url for aarch64 till needed aarch64 dependencies are available at https://download.pytorch.org/whl/nightly/cpu

NOTES:
* The build and test workflows are using arm64v8/alpine and quay.io/pypa/manylinux2014_aarch64:latest docker images at this time.
* Conda generated workflow not included at this time and being worked on.

Workflows were successfully tested at https://github.com/xncqr/pytorch/actions/runs/5351891068
Pull Request resolved: https://github.com/pytorch/pytorch/pull/104109
Approved by: https://github.com/malfet, https://github.com/atalman
2023-06-29 18:58:43 +00:00
Huy Do
1d5577b601 No need to run Windows binary build for every PR (#100638)
Per the discussion with @malfet , there is no need to run Windows binary build for every PR. We will keep it running in trunk (on push) though just in case.

This also moves the workflow back from unstable after the symlink copy fix in 860d444515

Another data point to back this up is the high correlation between Windows binaries debug and release build v.s. Windows CPU CI job.  The numbers are:

* `libtorch-cpu-shared-with-deps-debug` and `win-vs2019-cpu-py3` has 0.95 correlation
* `libtorch-cpu-shared-with-deps-release` and `win-vs2019-cpu-py3` has the same 0.95 correlation

The rest is noise, eh?
Pull Request resolved: https://github.com/pytorch/pytorch/pull/100638
Approved by: https://github.com/atalman
2023-05-04 21:57:39 +00:00
Huy Do
478a5ddd8a Mark Windows CPU jobs as unstable (#100581)
Caused by https://github.com/pytorch/pytorch/pull/100377, something removes VS2019 installation on the non-ephemeral runner.  I think moving this to unstable is nicer to gather signals in trunk without completely disable the job or revert https://github.com/pytorch/pytorch/pull/100377 (for the Nth times)

Pull Request resolved: https://github.com/pytorch/pytorch/pull/100581
Approved by: https://github.com/clee2000, https://github.com/malfet
2023-05-03 21:43:43 +00:00
pbialecki
73645a8412 Add CUDA 12.1 CI workflows (#98832)
Adds CUDA 12.1 CI workflows, removes CUDA 11.7.
CC @malfet

Pull Request resolved: https://github.com/pytorch/pytorch/pull/98832
Approved by: https://github.com/atalman
2023-05-01 16:25:53 +00:00
Nikita Shulga
3fef633333 Add CUDA-12.1 manywheel build to trunk (#99458)
As CUDA-11.7 is getting deprecated anyway.

Also, fix the problem when script actually generated the same workflow twice, overriding 11.8 ones with 11.7+11.7-with-pypi

<!--
copilot:poem
-->
### <samp>🤖 Generated by Copilot at 0c6c182</samp>

> _Oh we are the PyTorch crew and we have a job to do_
> _We build and test the manywheel package with CUDA 11.8_
> _So heave away, me hearties, heave away with all your might_
> _We'll smoke the Linux binary and make sure it runs all right_

Pull Request resolved: https://github.com/pytorch/pytorch/pull/99458
Approved by: https://github.com/dagitses, https://github.com/atalman
2023-04-19 00:13:32 +00:00
Nikita Shulga
2418b94576
Rename default branch to main (#99210)
Mostly `s/@master/@main` in numerous `.yml` files.

Keep `master` in `weekly.yml` as it refers to `xla` repo and in `test_trymerge.py` as it refers to a branch PR originates from.
2023-04-16 18:48:14 -07:00
Huy Do
4c0dce50fd [BE] Apply ufmt to run_test and GitHub Python util scripts (#97588)
This has been bugging me for a while as I'm working on these Python scripts and they are not tracked by ufmt linter.  So I add these script into that linter.

```
[[linter]]
code = 'UFMT'
include_patterns = [
    '.github/**/*.py',
    'test/run_test.py',
```

This change should just work and not break anything as ufmt (black + usort) linter is very safe to use for standalone util scripts.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/97588
Approved by: https://github.com/kit1980
2023-03-26 04:52:55 +00:00
Nikita Shulga
9c5a24b9df [BE] Delete `pre-cxx-11-abi MacOS libtorch builds (#96301)
Those ABI flags makes sense only for Linux, libc++ binaries shipped with MacOS has only one ABI flavor.

Moreover, those binaries were uploaded to the same location anyway, see
[upload job for pre-cxx-11 abi](https://github.com/pytorch/pytorch/actions/runs/4362299843/jobs/7628815268#step:7:97) and [upload job for cxx-11 abi](https://github.com/pytorch/pytorch/actions/runs/4362299812/jobs/7628879450#step:7:97)

Pull Request resolved: https://github.com/pytorch/pytorch/pull/96301
Approved by: https://github.com/atalman
2023-03-08 17:25:19 +00:00
Xuehai Pan
69e0bda999 [BE] Import Literal, Protocol, and Final from standard library typing as of Python 3.8+ (#94490)
Changes:

1. `typing_extensions -> typing-extentions` in dependency. Use dash rather than underline to fit the [PEP 503: Normalized Names](https://peps.python.org/pep-0503/#normalized-names) convention.

```python
import re

def normalize(name):
    return re.sub(r"[-_.]+", "-", name).lower()
```

2. Import `Literal`, `Protocal`, and `Final` from standard library as of Python 3.8+
3. Replace `Union[Literal[XXX], Literal[YYY]]` to `Literal[XXX, YYY]`.

Pull Request resolved: https://github.com/pytorch/pytorch/pull/94490
Approved by: https://github.com/ezyang, https://github.com/albanD
2023-02-09 19:17:49 +00:00
atalman
2910695942 Remove cuda 11.6 from nightly (#93979)
Remove cuda 11.6 from CI replace with 11.7
Following the Release readme here: https://github.com/pytorch/pytorch/blob/master/RELEASE.md#release-compatibility-matrix
Pull Request resolved: https://github.com/pytorch/pytorch/pull/93979
Approved by: https://github.com/Skylion007, https://github.com/clee2000, https://github.com/malfet
2023-02-02 20:27:19 +00:00
PyTorch MergeBot
f5e9c8ce54 Revert "Remove CUDA 11.6 from nightly builds (#93404)"
This reverts commit c76ac8eef2.

Reverted https://github.com/pytorch/pytorch/pull/93404 on behalf of https://github.com/clee2000 due to breaking lint
2023-02-02 17:10:01 +00:00
atalman
c76ac8eef2 Remove CUDA 11.6 from nightly builds (#93404)
Remove CUDA 11.6 from nightly builds.
Following the Release readme here: https://github.com/pytorch/pytorch/blob/master/RELEASE.md#release-compatibility-matrix
Pull Request resolved: https://github.com/pytorch/pytorch/pull/93404
Approved by: https://github.com/malfet
2023-02-02 14:26:52 +00:00
Nikita Shulga
5976f0bdfe Set min supported Python version to 3.8 (#93155)
Also, grep for `if sys.version_info .cond. (3, 8)` and replaces them with appropriate action.

This is a last in a series of PRs that moved CI/CD away from testing PyTorch behavior against Python-3.7.

Fixes https://github.com/pytorch/pytorch/issues/80513

Pull Request resolved: https://github.com/pytorch/pytorch/pull/93155
Approved by: https://github.com/huydhn
2023-01-29 18:28:46 +00:00
pbialecki
9bfd1357d5 Add CUDA 11.8 CI workflows (#92137)
Fixes #92090
CC @atalman
Pull Request resolved: https://github.com/pytorch/pytorch/pull/92137
Approved by: https://github.com/atalman
2023-01-23 21:03:53 +00:00
atalman
0c835e25bb Fix nightly build binary errors (#89153)
This is pretty much self explanatory issues
Two typo's in generate generate binary script caused workflows to be generated with invalid parameters:

1 .generated-linux-binary-libtorch-pre-cxx11-master.yml
2 .generated-macos-arm64-binary-wheel-nightly.yml
Pull Request resolved: https://github.com/pytorch/pytorch/pull/89153
Approved by: https://github.com/malfet
2022-11-17 00:30:12 +00:00
atalman
a807f1987a Stop cuda-10.2 binary builds (#85873)
Deprecate cuda 10.2 nightly

Pull Request resolved: https://github.com/pytorch/pytorch/pull/85873
Approved by: https://github.com/malfet
2022-09-29 15:04:24 +00:00
atalman
5014282792 Removing cuda 11.3 nightly builds (#84866)
Removing cuda 11.3 nightly builds

Pull Request resolved: https://github.com/pytorch/pytorch/pull/84866
Approved by: https://github.com/weiwangmeta, https://github.com/malfet
2022-09-15 15:47:36 +00:00
Michael Suo
d98a8148b6 [ci] remove ciflow/all (#78317)
The counterpart to https://github.com/pytorch/test-infra/pull/353, see
that PR for more context.

[skip ci]

Pull Request resolved: https://github.com/pytorch/pytorch/pull/78317
Approved by: https://github.com/janeyx99
2022-05-26 16:25:25 +00:00
Catherine Lee
1bb6b3bd96 remove from generate_ci_workflows.py, add tags back in .github/templates
- get rid of a lot of stuff in generate_ci_workflows.py b/c its only used for binaries now
- get rid of generated-ciflow-ruleset.json b/c its super outdated
- add if statement for tags: in templates b/c it used to cause the tags to be put under branches

helps w/ #74478
Pull Request resolved: https://github.com/pytorch/pytorch/pull/75372
Approved by: https://github.com/seemethere
2022-04-08 15:48:18 +00:00
pbialecki
14baca38c5 [WIP] enable cu116 builds
Enable and test CUDA11.6 builds

Pull Request resolved: https://github.com/pytorch/pytorch/pull/75092
Approved by: https://github.com/atalman
2022-04-06 17:23:09 +00:00
Jeff Daily
eb43e60a92 [ROCm] upgrade CI distributed test to ROCm 5.0
This change was missed by earlier CI upgrade #73105.

Pull Request resolved: https://github.com/pytorch/pytorch/pull/74959
Approved by: https://github.com/suo, https://github.com/malfet
2022-04-06 17:19:39 +00:00
Jithun Nair
dfe6e88adc Upgrade CI to ROCm5.0
cc @jaglinux @pruthvistony @arindamroy-eng @kyleczh

Depends on https://github.com/pytorch/pytorch/pull/73906

Fixes https://github.com/pytorch/pytorch/issues/65884 as well
Pull Request resolved: https://github.com/pytorch/pytorch/pull/73105
Approved by: https://github.com/osalpekar, https://github.com/malfet
2022-03-30 02:58:23 +00:00
David Berard
15c98700ed Add CPU slow test job (#73748)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/73748

This adds CPU-only slow test jobs, which previously would never run.

Includes fixes/skips for slow tests which fail (they need to be skipped now because they used to never run)

Test Plan: Imported from OSS

Reviewed By: malfet

Differential Revision: D34628803

Pulled By: davidberard98

fbshipit-source-id: c090ab7bf7bda9e24ec5cdefa6fd35c6310dbac0
(cherry picked from commit 06f7a94a57cc7023e9c5442be8298d20cd011144)
2022-03-23 21:17:27 +00:00
Nikita Shulga
c7e5fb78ca [GHA] Use GITHUB_DIR in path generate_ci_workflow.py
This makes script invocable regardless of current dir

Fixes #ISSUE_NUMBER

Pull Request resolved: https://github.com/pytorch/pytorch/pull/74496
Approved by: https://github.com/atalman, https://github.com/seemethere
2022-03-21 21:43:13 +00:00
Michael Suo
4ca56b7c2c Workflow consolidation for GitHub actions
This PR implements the proposal in https://fb.quip.com/RcLZAOb9k0qI,
which calls for using GitHub's "normal" means of composition (composite
actions, reusable workflows) instead of codegen.

Pull Request resolved: https://github.com/pytorch/pytorch/pull/74306

Approved by: https://github.com/janeyx99
2022-03-21 14:15:03 +00:00
Nikita Shulga
80e0d8a8fb Move AndroidNightly to GHA
And revert "[CircleCI] Re-enable nightly android builds"

Pull Request resolved: https://github.com/pytorch/pytorch/pull/74243
Approved by: https://github.com/seemethere
2022-03-17 14:32:39 +00:00
Sahan Paliskara
0bfa2f8255 Move torch::deploy tests to their own workflow job (#73676)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/73676

For some reason https://github.com/pytorch/pytorch/pull/72637 ended up in getting messed up during rebasing so please refer to that pr for review history.

This PR creates a new workflow called ` deploy-linux-xenial-cuda11.3-py3.7-gcc7` for torch::deploy tests.

For testing go to https://www.torch-ci.com/pytorch/pytorch/pull/73676 and check if a build and test job occur with ` deploy-linux-xenial-cuda11.3-py3.7-gcc7`

Test Plan: Imported from OSS

Reviewed By: soulitzer

Differential Revision: D34586702

Pulled By: PaliC

fbshipit-source-id: 5627cf4ff411a4a04030f8b7726f84af979da213
(cherry picked from commit df6dddebb9fe078a6053a31033b5a40cc742fcf3)
2022-03-17 12:19:48 +00:00
Michael Suo
62e032e328 [ci] move rocm distributed jobs to master-only
To help reduce queueing times on rocm jobs (see https://github.com/pytorch/pytorch/issues/73039), this PR moves the distributed tests to run only on master.

Pull Request resolved: https://github.com/pytorch/pytorch/pull/74057
Approved by: https://github.com/malfet
2022-03-10 20:53:34 +00:00
Eli Uriegas
11231b0f93 ci: Migrate windows conda to GHA
Signed-off-by: Eli Uriegas <eliuriegasfb.com>

Pull Request resolved: https://github.com/pytorch/pytorch/pull/73262

Signed-off-by: Eli Uriegas <eliuriegas@fb.com>

Approved by: https://github.com/malfet, https://github.com/atalman
2022-03-08 19:55:37 +00:00
PyTorch MergeBot
be4bcf8fdf Revert "ci: Migrate windows conda to GHA"
This reverts commit 2acf9c74f3.

Reverted https://github.com/pytorch/pytorch/pull/73262 on behalf of https://github.com/malfet
2022-03-08 01:30:37 +00:00
Eli Uriegas
2acf9c74f3 ci: Migrate windows conda to GHA
Signed-off-by: Eli Uriegas <eliuriegasfb.com>

Pull Request resolved: https://github.com/pytorch/pytorch/pull/73262

Signed-off-by: Eli Uriegas <eliuriegas@fb.com>

Approved by: https://github.com/malfet
2022-03-07 19:39:50 +00:00
Nikita Shulga
9929a9fc8f [GHA] Migrate win/linux binary-smoke workflows from CircleCI
Partially fixes https://github.com/pytorch/pytorch/issues/72956
Pull Request resolved: https://github.com/pytorch/pytorch/pull/73788
Approved by: https://github.com/seemethere
2022-03-07 15:22:23 +00:00
PyTorch MergeBot
ea698c148a Revert "[GHA] Migrate win/linux binary-smoke workflows from CircleCI"
This reverts commit 486bd9f306.

Reverted https://github.com/pytorch/pytorch/pull/73788 on behalf of https://github.com/malfet
2022-03-06 19:07:04 +00:00
Nikita Shulga
486bd9f306 [GHA] Migrate win/linux binary-smoke workflows from CircleCI
Partially fixes https://github.com/pytorch/pytorch/issues/72956
Pull Request resolved: https://github.com/pytorch/pytorch/pull/73788
Approved by: https://github.com/seemethere
2022-03-06 17:08:08 +00:00
Nikita Shulga
bebfdca093 Re-enable Windows debug libtorch
Get rid of `BUILD_FOR_SYSTEM` environment variable
Pass `libtorch_config` environment variable for Windows builds

Fixes https://github.com/pytorch/pytorch/issues/73068

Pull Request resolved: https://github.com/pytorch/pytorch/pull/73805
Approved by: https://github.com/seemethere
2022-03-04 23:49:07 +00:00
Nikita Shulga
71ed388905
[GHA] Increase ASAN test timeout to 5h (#73740)
Also, dynamically set test workflow timeout to test step timeout + 30
2022-03-03 07:05:51 -08:00
Nikita Shulga
bbf4bc9f8e [GHA][BE] Delete unused only_on_pr attribute
Pull Request resolved: https://github.com/pytorch/pytorch/pull/73618
2022-03-02 14:48:33 +00:00
Nikita Shulga
5eb3664c66 [GHA] Enable XLA tests on PR
This fixes accidental regression introduced by https://github.com/pytorch/pytorch/pull/72496

Add `on_pull_request` template parameter and set it to true during
workflow generation

Pull Request resolved: https://github.com/pytorch/pytorch/pull/73621
2022-03-02 14:43:19 +00:00
Mengwei Liu
9ce9803abe [PyTorch] Add codegen unboxing ability (#69881)
Summary:
RFC: https://github.com/pytorch/rfcs/pull/40

This PR (re)introduces python codegen for unboxing wrappers. Given an entry of `native_functions.yaml` the codegen should be able to generate the corresponding C++ code to convert ivalues from the stack to their proper types. To trigger the codegen, run
```
tools/jit/gen_unboxing.py -d cg/torch/share/ATen
```

Merged changes on CI test. In https://github.com/pytorch/pytorch/issues/71782 I added an e2e test for static dispatch + codegen unboxing. The test exports a mobile model of mobilenetv2, load and run it on a new binary for lite interpreter: `test/mobile/custom_build/lite_predictor.cpp`.

## Lite predictor build specifics

1. Codegen: `gen.py` generates `RegisterCPU.cpp` and `RegisterSchema.cpp`. Now with this PR, once `static_dispatch` mode is enabled, `gen.py` will not generate `TORCH_LIBRARY` API calls in those cpp files, hence avoids interaction with the dispatcher. Once `USE_LIGHTWEIGHT_DISPATCH` is turned on, `cmake/Codegen.cmake` calls `gen_unboxing.py` which generates `UnboxingFunctions.h`, `UnboxingFunctions_[0-4].cpp` and `RegisterCodegenUnboxedKernels_[0-4].cpp`.
2. Build: `USE_LIGHTWEIGHT_DISPATCH` adds generated sources into `all_cpu_cpp` in `aten/src/ATen/CMakeLists.txt`. All other files remain unchanged. In reality all the `Operators_[0-4].cpp` are not necessary but we can rely on linker to strip them off.

## Current CI job test coverage update

Created a new CI job `linux-xenial-py3-clang5-mobile-lightweight-dispatch-build` that enables the following build options:
* `USE_LIGHTWEIGHT_DISPATCH=1`
* `BUILD_LITE_INTERPRETER=1`
* `STATIC_DISPATCH_BACKEND=CPU`

This job triggers `test/mobile/lightweight_dispatch/build.sh` and builds `libtorch`. Then the script runs C++ tests written in `test_lightweight_dispatch.cpp` and `test_codegen_unboxing.cpp`. Recent commits added tests to cover as many C++ argument type as possible: in `build.sh` we installed PyTorch Python API so that we can export test models in `tests_setup.py`. Then we run C++ test binary to run these models on lightweight dispatch enabled runtime.

Pull Request resolved: https://github.com/pytorch/pytorch/pull/69881

Reviewed By: iseeyuan

Differential Revision: D33692299

Pulled By: larryliu0820

fbshipit-source-id: 211e59f2364100703359b4a3d2ab48ca5155a023
(cherry picked from commit 58e1c9a25e3d1b5b656282cf3ac2f548d98d530b)
2022-03-01 23:28:13 +00:00
Nikita Shulga
a1d5b5d2b3 [BE][GHA] Use timeout_after for win templates
Rather than hardcode the value to 240 min, use `timeout_after` argument
to specify different limits depending on config
Pull Request resolved: https://github.com/pytorch/pytorch/pull/73508
2022-02-28 17:12:41 +00:00
Eli Uriegas
9a8000fbf1 ci: Bump CUDA 11.1 -> 11.3
We're deprecating support for CUDA 11.1 so moving all of our CUDA 11.1
workflows to CUDA 11.3

Signed-off-by: Eli Uriegas <eliuriegasfb.com>

Pull Request resolved: https://github.com/pytorch/pytorch/pull/73449

Signed-off-by: Eli Uriegas <eliuriegas@fb.com>
2022-02-25 22:52:36 +00:00
Michael Suo
51b04f27c7 [ci] do not run distributed jobs for windows (#73064)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/73064

These accidentally got turned on by https://github.com/pytorch/pytorch/pull/73001. Turn them off.

Test Plan: Imported from OSS

Reviewed By: shannonzhu

Differential Revision: D34332530

Pulled By: suo

fbshipit-source-id: a6493b7d94465fa9141f1527648dbbec09c5706d
(cherry picked from commit b18c95e4a6)
2022-02-18 05:20:30 +00:00
Jane Xu
bac7feb76e Remove smoke test functionality to simplify infra
Follow up to https://github.com/pytorch/pytorch/issues/73030

Pull Request resolved: https://github.com/pytorch/pytorch/pull/73042
2022-02-17 23:28:13 +00:00
Michael Suo
2cd0667928 [ci] delete generate-test-matrix
Today, we have two pieces that conspire to determine what workflows we run:
- `generate_ci_workflows.py`, which takes a declarative description of what we want the workflow to do and uses jinja to generate a workflow yaml file
- `generate-test-matrix`, which runs at CI time to dynamically generate test jobs.

This is bad:
- Having one layer of code generation is unfortunate, having two is confusing.
- You cannot tell from a workflow yaml file what test jobs will be run.
- We have to do this careful dance of plumbing the args to `generate-test-matrix` through setting env vars and other such ugliness.
- In cases where the build job fails and prevents `generate-test-matrix` from running, a ghost `test` job that doesn't actually exist noises up the HUD and our stats.
- A bunch of useless `generate-test-matrix` jobs (8 on PRs) noise up our signal.

As far as I can tell, this complexity is unnecessary--we have all the information we need to generate the build matrix statically. There does not appear to be an advantage in retaining generate-build-matrix, so I am removing `generate-test-matrix` to simplify the CI.

The *only* place where we were actually doing something dynamic is in our windows gpu workflow, where we would check at runtime whether the workflow was triggered from a PR or master and behave accordingly. This is more simply done by just having two separate workflows with different trigger conditions, which avoids the madness of needing to parse labels and forking the behavior dynamically, which has been a source of confusion in the past.

Pull Request resolved: https://github.com/pytorch/pytorch/pull/73001
2022-02-17 21:34:18 +00:00