Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run CI on pre #739

Merged
merged 1 commit into from
Jun 28, 2024
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
2 changes: 2 additions & 0 deletions .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ steps:
- "ext/"
- "test/"
- "Project.toml"
- ".buildkite/"
config:
command: "buildkite-agent pipeline upload .buildkite/testing.yml"
agents:
Expand All @@ -24,6 +25,7 @@ steps:
- "Project.toml"
- "docs/"
- "examples/"
- ".buildkite/"
config:
command: "buildkite-agent pipeline upload .buildkite/documentation.yml"
agents:
Expand Down
7 changes: 7 additions & 0 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ on:
- "ext/**"
- "test/**"
- "Project.toml"
- ".github/workflows/CI.yml"
push:
branches:
- main
Expand All @@ -28,6 +29,7 @@ jobs:
matrix:
version:
- "1"
- "pre"
os:
- ubuntu-latest
- macos-latest
Expand All @@ -41,6 +43,11 @@ jobs:
- "others"
- "autodiff"
- "recurrent_layers"
exclude:
- version: pre
os: windows-latest
- version: pre
os: macos-latest
steps:
- uses: actions/checkout@v4
- uses: julia-actions/setup-julia@v2
Expand Down
75 changes: 75 additions & 0 deletions .github/workflows/CIPreRelease.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
name: CIPreRelease
on:
pull_request:
branches:
- main
paths:
- "src/**"
- "ext/**"
- "test/**"
- "Project.toml"
- ".github/workflows/CI.yml"
push:
branches:
- main

concurrency:
# Skip intermediate builds: always.
# Cancel intermediate builds: only if it is a pull request build.
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}

jobs:
ci:
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.test_group }}
if: ${{ !contains(github.event.head_commit.message, '[skip tests]') }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
version:
- "pre"
os:
- ubuntu-latest
test_group:
- "core_layers"
- "contrib"
- "helpers"
- "distributed"
- "normalize_layers"
- "others"
- "autodiff"
- "recurrent_layers"
steps:
- uses: actions/checkout@v4
- uses: julia-actions/setup-julia@v2
with:
version: ${{ matrix.version }}
- uses: actions/cache@v4
env:
cache-name: cache-artifacts
with:
path: ~/.julia/artifacts
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
restore-keys: |
${{ runner.os }}-test-${{ env.cache-name }}-
${{ runner.os }}-test-
${{ runner.os }}-
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-runtest@v1
env:
LUX_TEST_GROUP: ${{ matrix.test_group }}
- uses: julia-actions/julia-processcoverage@v1
with:
directories: src,ext
- uses: codecov/codecov-action@v4
with:
files: lcov.info
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true
fail_ci_if_error: true

env:
BACKEND_GROUP: "CPU"
RETESTITEMS_NWORKERS: 4
RETESTITEMS_NWORKER_THREADS: 2
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@
[![Stable Docs](https://img.shields.io/badge/docs-stable-blue.svg)](http://lux.csail.mit.edu/stable/)

[![CI](https://github.com/LuxDL/Lux.jl/actions/workflows/CI.yml/badge.svg?branch=main)](https://github.com/LuxDL/Lux.jl/actions/workflows/CI.yml)
[![CI (pre-release)](https://github.com/LuxDL/Lux.jl/actions/workflows/CIPreRelease.yml/badge.svg?branch=main)](https://github.com/LuxDL/Lux.jl/actions/workflows/CIPreRelease.yml)
[![Build status](https://img.shields.io/buildkite/ba1f9622add5978c2d7b194563fd9327113c9c21e5734be20e/main.svg?label=gpu&branch=main)](https://buildkite.com/julialang/lux-dot-jl)
[![codecov](https://codecov.io/gh/LuxDL/Lux.jl/branch/main/graph/badge.svg?token=IMqBM1e3hz)](https://codecov.io/gh/LuxDL/Lux.jl)
[![Benchmarks](https://github.com/LuxDL/Lux.jl/actions/workflows/Benchmark.yml/badge.svg?branch=main)](https://lux.csail.mit.edu/benchmarks/)

[![Downloads](https://img.shields.io/badge/dynamic/json?url=http%3A%2F%2Fjuliapkgstats.com%2Fapi%2Fv1%2Fmonthly_downloads%2FLux&query=total_requests&suffix=%2Fmonth&label=Downloads)](https://juliapkgstats.com/pkg/Lux)
[![Downloads](https://img.shields.io/badge/dynamic/json?url=http%3A%2F%2Fjuliapkgstats.com%2Fapi%2Fv1%2Ftotal_downloads%2FLux&query=total_requests&&label=Total%20Downloads)](https://juliapkgstats.com/pkg/Lux)


[![Aqua QA](https://raw.githubusercontent.com/JuliaTesting/Aqua.jl/master/badge.svg)](https://github.com/JuliaTesting/Aqua.jl)
[![ColPrac: Contributor's Guide on Collaborative Practices for Community Packages](https://img.shields.io/badge/ColPrac-Contributor's%20Guide-blueviolet)](https://github.com/SciML/ColPrac)
[![SciML Code Style](https://img.shields.io/static/v1?label=code%20style&message=SciML&color=9558b2&labelColor=389826)](https://github.com/SciML/SciMLStyle)
Expand Down
17 changes: 4 additions & 13 deletions src/Lux.jl
Original file line number Diff line number Diff line change
Expand Up @@ -7,36 +7,27 @@ using ArgCheck: @argcheck
using ArrayInterface: ArrayInterface, fast_scalar_indexing
using ChainRulesCore: ChainRulesCore, AbstractZero, HasReverseMode, NoTangent, ProjectTo,
RuleConfig, ZeroTangent, @thunk
using Compat: @compat
using ConcreteStructs: @concrete
using ConstructionBase: ConstructionBase
using EnzymeCore: EnzymeCore, EnzymeRules
using FastClosures: @closure
using Functors: Functors, fmap
using GPUArraysCore: GPUArraysCore
using LossFunctions: LossFunctions
using MacroTools: MacroTools, block, combinedef, splitdef
using Markdown: @doc_str
using Preferences: @load_preference
using Random: Random, AbstractRNG
using Reexport: @reexport
using Statistics: mean
using UnrolledUtilities: unrolled_map, unrolled_mapreduce

using LuxCore, LuxLib, LuxDeviceUtils, WeightInitializers
@reexport using LuxCore, LuxLib, LuxDeviceUtils, WeightInitializers
using LuxLib: __apply_bias_activation
import LuxCore: AbstractExplicitLayer, AbstractExplicitContainerLayer, initialparameters,
initialstates, parameterlength, statelength, inputsize, outputsize,
update_state, trainmode, testmode, setup, apply, display_name, replicate
using LuxDeviceUtils: get_device

# @compact specific
using MacroTools: MacroTools, block, combinedef, splitdef

# @compact and stateful layers
using ConstructionBase: ConstructionBase

# For public keyword
using Compat: @compat

@reexport using LuxCore, LuxLib, LuxDeviceUtils, WeightInitializers

const CRC = ChainRulesCore

Expand Down
Loading