Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions .buildkite/cuda_tutorials.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
steps:
- group: ":open_book: Build & Deploy Documentation"
if: build.message !~ /\[skip docs\]/
steps:
- label: "Tutorial Build [%N/%t] CUDA Runners"
key: "tutorial-build-cuda"
parallelism: 4
plugins:
- JuliaCI/julia#v1:
version: "1.11"
command: julia --code-coverage=user --color=yes --project=docs --threads=auto docs/tutorials.jl
env:
TUTORIAL_BACKEND_GROUP: "CUDA"
agents:
queue: "juliagpu"
cuda: "*"
artifact_paths:
- "docs/src/tutorials/beginner/**/*"
- "docs/src/tutorials/intermediate/**/*"
- "docs/src/tutorials/advanced/**/*"
- "tutorial_deps/*"
- "**/*.cov"
- "docs/src/public/examples/**/*"
timeout_in_minutes: 120

env:
DATADEPS_ALWAYS_ACCEPT: true
GKSwstype: "100" # https://discourse.julialang.org/t/generation-of-documentation-fails-qt-qpa-xcb-could-not-connect-to-display/60988
92 changes: 0 additions & 92 deletions .buildkite/documentation.yml

This file was deleted.

37 changes: 7 additions & 30 deletions .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ steps:
- "ext/"
- "test/"
- "Project.toml"
- ".buildkite/"
- ".buildkite/testing.yml"
- "lib/"
config:
command: "buildkite-agent pipeline upload .buildkite/testing.yml"
Expand All @@ -24,7 +24,7 @@ steps:
- label: "LuxCUDA"
path:
- "lib/LuxCUDA/"
- ".buildkite/"
- ".buildkite/testing_luxcuda.yml"
config:
command: "buildkite-agent pipeline upload .buildkite/testing_luxcuda.yml"
agents:
Expand All @@ -33,7 +33,7 @@ steps:
- label: "WeightInitializers"
path:
- "lib/WeightInitializers/"
- ".buildkite/"
- ".buildkite/testing_weightinitializers.yml"
config:
command: "buildkite-agent pipeline upload .buildkite/testing_weightinitializers.yml"
agents:
Expand All @@ -42,7 +42,7 @@ steps:
- label: "MLDataDevices"
path:
- "lib/MLDataDevices/"
- ".buildkite/"
- ".buildkite/testing_mldatadevices.yml"
config:
command: "buildkite-agent pipeline upload .buildkite/testing_mldatadevices.yml"
agents:
Expand All @@ -51,7 +51,7 @@ steps:
- label: "LuxLib"
path:
- "lib/LuxLib/"
- ".buildkite/"
- ".buildkite/testing_luxlib.yml"
- "lib/LuxTestUtils/"
- "lib/LuxCore/"
- "lib/MLDataDevices/"
Expand All @@ -63,7 +63,7 @@ steps:
- label: "LuxTestUtils"
path:
- "lib/LuxTestUtils/"
- ".buildkite/"
- ".buildkite/testing_luxtestutils.yml"
config:
command: "buildkite-agent pipeline upload .buildkite/testing_luxtestutils.yml"
agents:
Expand All @@ -83,28 +83,13 @@ steps:
# agents:
# queue: "juliagpu"

- label: "Documentation"
path:
- "src/"
- "ext/"
- "test/"
- "Project.toml"
- "docs/"
- "examples/"
- ".buildkite/"
- "lib"
config:
command: "buildkite-agent pipeline upload .buildkite/documentation.yml"
agents:
queue: "juliagpu"

- label: "Downstream"
path:
- "src/"
- "ext/"
- "lib/"
- "Project.toml"
- ".buildkite/"
- ".buildkite/downstream.yml"
if: build.pull_request.labels includes "run downstream test"
config:
command: "buildkite-agent pipeline upload .buildkite/downstream.yml"
Expand All @@ -129,11 +114,3 @@ steps:
# Disable benchmarks for now
# # Benchmarks
# buildkite-agent pipeline upload .buildkite/benchmarks.yml

- label: "Triggering Documentation Pipeline (Main Branch / Tag)"
if: build.tag != null || build.branch == "main"
agents:
queue: "juliagpu"
command: |
# Documentation
buildkite-agent pipeline upload .buildkite/documentation.yml
156 changes: 156 additions & 0 deletions .github/workflows/Documentation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,156 @@
name: Documentation

permissions:
contents: write # contents permission to update benchmark contents in gh-pages branch
statuses: read
deployments: write # deployments permission to deploy GitHub pages website
pages: write
id-token: write
pull-requests: write

on:
pull_request:
branches:
- main
paths:
- "src/**/*"
- "ext/**/*"
- "test/**/*"
- "Project.toml"
- "docs/**/*"
- "examples/**/*"
- ".buildkite/**/*"
- ".github/workflows/Documentation.yml"
- "lib/**/*"
push:
branches:
- main
tags:
- "*"

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}

jobs:
tutorial-cuda:
if: ${{ !contains(github.event.head_commit.message, '[skip docs]') }}
runs-on: ubuntu-latest
steps:
- name: Trigger CUDA Tutorial Build
id: buildkite-build
uses: buildkite/trigger-pipeline-action@v2.4.1
with:
buildkite_api_access_token: ${{ secrets.BUILDKITE_TOKEN }}
pipeline: "julialang/lux-dot-jl"
commit: ${{ github.event.pull_request.head.sha }}
branch: ${{ github.event.pull_request.head.ref }}
message: |
Triggered from PR #${{ github.event.pull_request.number }}: ${{ github.event.pull_request.title }}
send_pull_request: true
pull_request_base_branch: ${{ github.event.pull_request.base.ref }}
build_env_vars: >-
{
"LUX_CUDA_TUTORIALS": "1",
"GITHUB_PR_NUMBER": "${{ github.event.pull_request.number }}"
}

- name: Download CUDA Tutorial Artifacts
uses: EnricoMi/download-buildkite-artifact-action@v1
with:
buildkite_token: ${{ secrets.BUILDKITE_TOKEN }}
buildkite_build_url: ${{ steps.buildkite-build.outputs.url }}
ignore_build_states: blocked,canceled,skipped,not_run
ignore_job_states: timed_out,failed
output_path: artifacts
poll_interval: 30

- name: Upload Tutorial Artifacts
uses: actions/upload-artifact@v5
with:
name: "tutorial-cuda"
path: artifacts/**/*
retention-days: 90
if-no-files-found: error

tutorial-cpu:
if: ${{ !contains(github.event.head_commit.message, '[skip docs]') }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
group: [0, 1, 2, 3]
steps:
- uses: actions/checkout@v6
- name: Collect Workflow Telemetry
uses: catchpoint/workflow-telemetry-action@v2
with:
comment_on_pr: false
job_summary: true
- uses: julia-actions/setup-julia@v2
with:
version: "1.11"
- uses: julia-actions/cache@v2
with:
cache-name: julia-cache;workflow=tutorial-cpu-${{ matrix.group }}-${{ github.event_name }}-${{ github.event.repository.default_branch }}-${{ github.sha }}
- name: Run Tutorials
run: julia --color=yes --project=docs --threads=auto docs/tutorials.jl
env:
TUTORIAL_BACKEND_GROUP: "CPU"
BUILDKITE_PARALLEL_JOB_COUNT: 4
BUILDKITE_PARALLEL_JOB: ${{ matrix.group }}
LD_LIBRARY_PATH: ""
- name: Upload Tutorial Artifacts
uses: actions/upload-artifact@v5
with:
name: "tutorial-cpu-${{ matrix.group }}"
path: |
docs/src/tutorials/beginner/**/*
docs/src/tutorials/intermediate/**/*
docs/src/tutorials/advanced/**/*
tutorial_deps/*
**/*.cov
docs/src/public/examples/**/*
retention-days: 90
if-no-files-found: error

documentation:
if: ${{ !contains(github.event.head_commit.message, '[skip docs]') }}
runs-on: ubuntu-latest
needs: [tutorial-cpu, tutorial-cuda]
steps:
- uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Collect Workflow Telemetry
uses: catchpoint/workflow-telemetry-action@v2
with:
comment_on_pr: false
job_summary: true
- uses: julia-actions/setup-julia@v2
with:
version: "1.11"
- uses: julia-actions/cache@v2
with:
cache-name: julia-cache;workflow=documentation-${{ github.event_name }}-${{ github.event.repository.default_branch }}-${{ github.sha }}

# Download the artifacts from the tutorials
- name: Download Tutorial Artifacts
uses: actions/download-artifact@v5
with:
pattern: "tutorial-*"
path: tutorial_artifacts
merge-multiple: true

- name: Move Documentation Artifacts
run: cp -r tutorial_artifacts/* ./

- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-docdeploy@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

env:
JULIA_DEBUG: "Documenter,Reactant,Reactant_jll,Lux"
DATADEPS_ALWAYS_ACCEPT: true
GKSwstype: "100" # https://discourse.julialang.org/t/generation-of-documentation-fails-qt-qpa-xcb-could-not-connect-to-display/60988
10 changes: 0 additions & 10 deletions docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,6 @@ if DRAFT_MODE
end
end

deploy_config = Documenter.auto_detect_deploy_system()
deploy_decision = Documenter.deploy_folder(
deploy_config;
repo="github.com/LuxDL/Lux.jl",
devbranch="main",
devurl="dev",
push_preview=true,
)

warnonly = [:linkcheck]
if DRAFT_MODE
push!(warnonly, :cross_references)
Expand All @@ -41,7 +32,6 @@ makedocs(;
devbranch="main",
devurl="dev",
deploy_url="https://lux.csail.mit.edu",
deploy_decision,
),
plugins=[CitationBibliography(joinpath(@__DIR__, "references.bib"))],
draft=DRAFT_MODE,
Expand Down
Loading
Loading