lightning/.github/workflows/events-nightly.yml

272 lines
10 KiB
YAML
Raw Normal View History

name: Nightly
# https://jasonet.co/posts/scheduled-actions/
# https://github.community/t/distinct-job-for-each-schedule/17811/2
on:
schedule:
# At the end of every day
- cron: "0 0 * * *"
env:
PUSH_TO_HUB: true
# based on https://github.com/pypa/gh-action-pypi-publish
jobs:
pypi-release:
if: ${{ github.repository_owner == 'PyTorchLightning' }}
runs-on: ubuntu-20.04
steps:
# does nightly releases from feature branch
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
2021-10-26 11:58:20 +00:00
python-version: 3.9
- name: Install dependencies
run: >-
python -m pip install --user --upgrade setuptools wheel
- name: Build packages
run: |
pip install -q fire
python .actions/assistant.py prepare-nightly-version
python setup.py sdist bdist_wheel
ls -lh dist/
- name: Delay releasing
uses: juliangruber/sleep-action@v1
with:
time: 5m
# We do this, since failures on test.pypi aren't that bad
- name: Publish to Test PyPI
uses: pypa/gh-action-pypi-publish@v1.4.1
with:
user: __token__
password: ${{ secrets.test_pypi_password }}
repository_url: https://test.pypi.org/legacy/
verbose: true
# report failure to Slack
- name: Slack notification
if: failure() && github.event_name == 'schedule'
uses: ravsamhq/notify-slack-action@v1
with:
status: ${{ job.status }}
token: ${{ secrets.GITHUB_TOKEN }}
notification_title: 'Publish nightly package to test.pypi.org'
message_format: '{emoji} *{workflow}* {status_message}, see <{run_url}|detail>, cc: <@UR9FXE6QG>' #Borda
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
docker-XLA:
if: ${{ github.repository_owner == 'PyTorchLightning' }}
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
# the config used in '.circleci/config.yml`'
python_version: ["3.7"]
xla_version: ["1.8"]
steps:
- name: Checkout
uses: actions/checkout@v2
# https://github.com/docker/setup-buildx-action
# Set up Docker Buildx - to use cache-from and cache-to argument of buildx command
- uses: docker/setup-buildx-action@v1
- name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Publish XLA to Docker Hub
# publish master/release
uses: docker/build-push-action@v2
with:
build-args: |
PYTHON_VERSION=${{ matrix.python_version }}
XLA_VERSION=${{ matrix.xla_version }}
file: dockers/base-xla/Dockerfile
push: ${{ env.PUSH_TO_HUB }}
tags: pytorchlightning/pytorch_lightning:base-xla-py${{ matrix.python_version }}-torch${{ matrix.xla_version }}
timeout-minutes: 55
# report failure to Slack
- name: Slack notification
if: failure() && github.event_name == 'schedule'
uses: ravsamhq/notify-slack-action@v1
with:
status: ${{ job.status }}
token: ${{ secrets.GITHUB_TOKEN }}
notification_title: ${{ format('XLA; {0} py{1} for *{2}*', runner.os, matrix.python_version, matrix.xla_version) }}
message_format: '{emoji} *{workflow}* {status_message}, see <{run_url}|detail>, cc: <@U01GD29QCAV>' #kaushikb11
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
docker-CUDA:
if: ${{ github.repository_owner == 'PyTorchLightning' }}
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
include:
# the config used in '.azure-pipelines/gpu-tests.yml'
- {python_version: "3.7", pytorch_version: "1.8", cuda_version: "10.2", ubuntu_version: "18.04"}
- {python_version: "3.7", pytorch_version: "1.10", cuda_version: "11.1", ubuntu_version: "20.04"}
- {python_version: "3.7", pytorch_version: "1.11", cuda_version: "11.3.1", ubuntu_version: "20.04"}
# latest (used in Tutorials)
- {python_version: "3.8", pytorch_version: "1.8", cuda_version: "11.1", ubuntu_version: "20.04"}
- {python_version: "3.8", pytorch_version: "1.9", cuda_version: "11.1", ubuntu_version: "20.04"}
- {python_version: "3.9", pytorch_version: "1.10", cuda_version: "11.1", ubuntu_version: "20.04"}
- {python_version: "3.9", pytorch_version: "1.11", cuda_version: "11.3.1", ubuntu_version: "20.04"}
steps:
- name: Checkout
uses: actions/checkout@v2
- uses: docker/setup-buildx-action@v1
- name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Publish CUDA to Docker Hub
# publish master/release
uses: docker/build-push-action@v2
with:
build-args: |
PYTHON_VERSION=${{ matrix.python_version }}
PYTORCH_VERSION=${{ matrix.pytorch_version }}
CUDA_VERSION=${{ matrix.cuda_version }}
UBUNTU_VERSION=${{ matrix.ubuntu_version }}
file: dockers/base-cuda/Dockerfile
push: ${{ env.PUSH_TO_HUB }}
tags: pytorchlightning/pytorch_lightning:base-cuda-py${{ matrix.python_version }}-torch${{ matrix.pytorch_version }}
2021-10-25 20:56:47 +00:00
timeout-minutes: 85
# report failure to Slack
- name: Slack notification
if: failure() && github.event_name == 'schedule'
uses: ravsamhq/notify-slack-action@v1
with:
status: ${{ job.status }}
token: ${{ secrets.GITHUB_TOKEN }}
notification_title: ${{ format('CUDA; {0} py{1} for *{2}*', runner.os, matrix.python_version, matrix.pytorch_version) }}
message_format: '{emoji} *{workflow}* {status_message}, see <{run_url}|detail>, cc: <@U01A5T7EY9M>' #akihironitta
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
docker-Conda:
if: ${{ github.repository_owner == 'PyTorchLightning' }}
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
include:
# see: https://pytorch.org/get-started/previous-versions/
- {python_version: "3.8", pytorch_version: "1.8", cuda_version: "11.1"}
- {python_version: "3.8", pytorch_version: "1.9", cuda_version: "11.1"}
- {python_version: "3.8", pytorch_version: "1.10", cuda_version: "11.1"}
- {python_version: "3.9", pytorch_version: "1.11", cuda_version: "11.3.1"}
# nightly: add when there's a release candidate
# - {python_version: "3.9", pytorch_version: "1.12"}
steps:
- name: Checkout
uses: actions/checkout@v2
- uses: docker/setup-buildx-action@v1
- name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Publish Conda to Docker Hub
# publish master/release
uses: docker/build-push-action@v2
with:
build-args: |
PYTHON_VERSION=${{ matrix.python_version }}
PYTORCH_VERSION=${{ matrix.pytorch_version }}
CUDA_VERSION=${{ matrix.cuda_version }}
file: dockers/base-conda/Dockerfile
push: ${{ env.PUSH_TO_HUB }}
tags: pytorchlightning/pytorch_lightning:base-conda-py${{ matrix.python_version }}-torch${{ matrix.pytorch_version }}
2021-10-25 20:56:47 +00:00
timeout-minutes: 85
# report failure to Slack
- name: Slack notification
if: failure() && github.event_name == 'schedule'
uses: ravsamhq/notify-slack-action@v1
with:
status: ${{ job.status }}
token: ${{ secrets.GITHUB_TOKEN }}
notification_title: ${{ format('Conda; {0} py{1} for *{2}*', runner.os, matrix.python_version, matrix.pytorch_version) }}
message_format: '{emoji} *{workflow}* {status_message}, see <{run_url}|detail>, cc: <@U01A5T7EY9M>' #akihironitta
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
docker-IPU:
if: ${{ github.repository_owner == 'PyTorchLightning' }}
2021-05-07 12:07:29 +00:00
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
# the config used in 'dockers/ipu-ci-runner/Dockerfile'
2021-05-07 12:07:29 +00:00
include:
- {python_version: "3.9", pytorch_version: "1.9"}
2021-05-07 12:07:29 +00:00
steps:
- name: Checkout
uses: actions/checkout@v2
# https://github.com/docker/setup-buildx-action
# Set up Docker Buildx - to use cache-from and cache-to argument of buildx command
- uses: docker/setup-buildx-action@v1
- name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Publish IPU base to Docker Hub
# publish master/release
uses: docker/build-push-action@v2
with:
build-args: |
PYTHON_VERSION=${{ matrix.python_version }}
PYTORCH_VERSION=${{ matrix.pytorch_version }}
file: dockers/base-ipu/Dockerfile
push: ${{ env.PUSH_TO_HUB }}
2021-05-07 12:07:29 +00:00
tags: pytorchlightning/pytorch_lightning:base-ipu-py${{ matrix.python_version }}-torch${{ matrix.pytorch_version }}
timeout-minutes: 55
- name: Publish IPU CI runner to Docker Hub
# publish master/release
uses: docker/build-push-action@v2
with:
build-args: |
PYTHON_VERSION=${{ matrix.python_version }}
PYTORCH_VERSION=${{ matrix.pytorch_version }}
file: dockers/ipu-ci-runner/Dockerfile
push: ${{ env.PUSH_TO_HUB }}
2021-05-07 12:07:29 +00:00
tags: pytorchlightning/pytorch_lightning:ipu-ci-runner-py${{ matrix.python_version }}
timeout-minutes: 55
# report failure to Slack
- name: Slack notification
if: failure() && github.event_name == 'schedule'
uses: ravsamhq/notify-slack-action@v1
with:
status: ${{ job.status }}
token: ${{ secrets.GITHUB_TOKEN }}
notification_title: ${{ format('IPU; {0} py{1} for *{2}*', runner.os, matrix.python_version, matrix.pytorch_version) }}
message_format: '{emoji} *{workflow}* {status_message}, see <{run_url}|detail>, cc: <@U01BULUS2BG>' #SeanNaren
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}