Skip to content

Commit

Permalink
chore: use sources in Projects
Browse files Browse the repository at this point in the history
  • Loading branch information
avik-pal committed Nov 17, 2024
1 parent cf8fd61 commit e13598a
Show file tree
Hide file tree
Showing 15 changed files with 91 additions and 128 deletions.
26 changes: 8 additions & 18 deletions .buildkite/testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,6 @@ steps:
command: |
julia --color=yes --code-coverage=user --depwarn=yes --project=. -e '
import Pkg;
dev_pkgs = Pkg.PackageSpec[];
for pkg in ("lib/LuxCore", "lib/MLDataDevices", "lib/WeightInitializers", "lib/LuxLib",)
push!(dev_pkgs, Pkg.PackageSpec(path=pkg));
end
Pkg.develop(dev_pkgs);
Pkg.Registry.update();
Pkg.instantiate();
Pkg.activate("test");
Expand All @@ -39,10 +34,10 @@ steps:
end
Pkg.develop(dev_pkgs);
Pkg.instantiate();'
julia --color=yes --code-coverage=user --depwarn=yes --project=test -e '
import Pkg, Lux;
dir = dirname(pathof(Lux));
include(joinpath(dir, "../test/runtests.jl"))'
julia --color=yes --code-coverage=user --depwarn=yes --project=test -e '
import Pkg, Lux;
dir = dirname(pathof(Lux));
include(joinpath(dir, "../test/runtests.jl"))'
env:
BACKEND_GROUP: "CUDA"
LUX_TEST_GROUP: "{{matrix.group}}"
Expand Down Expand Up @@ -79,11 +74,6 @@ steps:
command: |
julia --color=yes --code-coverage=user --depwarn=yes --project=. -e '
import Pkg;
dev_pkgs = Pkg.PackageSpec[];
for pkg in ("lib/LuxCore", "lib/MLDataDevices", "lib/WeightInitializers", "lib/LuxLib",)
push!(dev_pkgs, Pkg.PackageSpec(path=pkg));
end
Pkg.develop(dev_pkgs);
Pkg.Registry.update();
Pkg.instantiate();
Pkg.activate("test");
Expand All @@ -93,10 +83,10 @@ steps:
end
Pkg.develop(dev_pkgs);
Pkg.instantiate();'
julia --color=yes --code-coverage=user --depwarn=yes --project=test -e '
import Pkg, Lux;
dir = dirname(pathof(Lux));
include(joinpath(dir, "../test/runtests.jl"))'
julia --color=yes --code-coverage=user --depwarn=yes --project=test -e '
import Pkg, Lux;
dir = dirname(pathof(Lux));
include(joinpath(dir, "../test/runtests.jl"))'
env:
BACKEND_GROUP: "AMDGPU"
agents:
Expand Down
10 changes: 0 additions & 10 deletions .buildkite/testing_luxlib.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,6 @@ steps:
julia --color=yes --code-coverage=user --depwarn=yes --project=lib/LuxLib -e '
import Pkg;
Pkg.Registry.update();
dev_pkgs = Pkg.PackageSpec[];
for pkg in ("lib/LuxCore", "lib/MLDataDevices")
push!(dev_pkgs, Pkg.PackageSpec(path=pkg));
end;
Pkg.develop(dev_pkgs);
Pkg.instantiate();
Pkg.activate("lib/LuxLib/test");
dev_pkgs = Pkg.PackageSpec[];
Expand Down Expand Up @@ -67,11 +62,6 @@ steps:
julia --color=yes --code-coverage=user --depwarn=yes --project=lib/LuxLib -e '
import Pkg;
Pkg.Registry.update();
dev_pkgs = Pkg.PackageSpec[];
for pkg in ("lib/LuxCore", "lib/MLDataDevices")
push!(dev_pkgs, Pkg.PackageSpec(path=pkg));
end;
Pkg.develop(dev_pkgs);
Pkg.instantiate();
Pkg.activate("lib/LuxLib/test");
dev_pkgs = Pkg.PackageSpec[];
Expand Down
5 changes: 0 additions & 5 deletions .buildkite/testing_luxtestutils.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,6 @@ steps:
julia --color=yes --code-coverage=user --depwarn=yes --project=lib/LuxTestUtils -e '
import Pkg;
Pkg.Registry.update();
dev_pkgs = Pkg.PackageSpec[];
for pkg in ("lib/MLDataDevices",)
push!(dev_pkgs, Pkg.PackageSpec(path=pkg));
end;
Pkg.develop(dev_pkgs);
Pkg.instantiate();
Pkg.test(; coverage="user")'
agents:
Expand Down
32 changes: 10 additions & 22 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,10 @@ jobs:
- "misc"
- "reactant"
include:
- version: "1.10"
- version: "1"
os: "macos-latest"
test_group: "all"
- version: "1.10"
- version: "1"
os: "windows-latest"
test_group: "all"
steps:
Expand All @@ -65,24 +65,18 @@ jobs:
${{ runner.os }}-test-${{ env.cache-name }}-
${{ runner.os }}-test-
${{ runner.os }}-
- name: "Install Dependencies"
- uses: julia-actions/julia-buildpkg@v1
- name: "Dev Test Dependencies"
run: |
import Pkg
dev_pkgs = Pkg.PackageSpec[]
for pkg in ("lib/LuxCore", "lib/MLDataDevices", "lib/WeightInitializers", "lib/LuxLib",)
push!(dev_pkgs, Pkg.PackageSpec(path=pkg))
end
Pkg.develop(dev_pkgs)
Pkg.Registry.update()
Pkg.instantiate()
Pkg.activate("test")
dev_pkgs = Pkg.PackageSpec[]
for pkg in ("lib/LuxTestUtils", "lib/LuxLib", "lib/MLDataDevices", "lib/LuxCore", ".")
push!(dev_pkgs, Pkg.PackageSpec(path=pkg))
end
Pkg.develop(dev_pkgs)
Pkg.instantiate()
shell: julia --color=yes --code-coverage=user --depwarn=yes --project=. {0}
shell: julia --color=yes --code-coverage=user --depwarn=yes --project=test {0}
- name: "Run Tests"
run: |
import Pkg, Lux
Expand All @@ -99,7 +93,7 @@ jobs:
files: lcov.info
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true
fail_ci_if_error: true
fail_ci_if_error: false

downgrade:
if: ${{ !contains(github.event.head_commit.message, '[skip tests]') && github.base_ref == github.event.repository.default_branch }}
Expand All @@ -112,24 +106,18 @@ jobs:
- uses: julia-actions/julia-downgrade-compat@v1
with:
skip: "LuxCore,MLDataDevices,WeightInitializers,LuxLib"
- name: "Install Dependencies"
- uses: julia-actions/julia-buildpkg@v1
- name: "Dev Test Dependencies"
run: |
import Pkg
dev_pkgs = Pkg.PackageSpec[]
for pkg in ("lib/LuxCore", "lib/MLDataDevices", "lib/WeightInitializers", "lib/LuxLib",)
push!(dev_pkgs, Pkg.PackageSpec(path=pkg))
end
Pkg.develop(dev_pkgs)
Pkg.Registry.update()
Pkg.instantiate()
Pkg.activate("test")
dev_pkgs = Pkg.PackageSpec[]
for pkg in ("lib/LuxTestUtils", "lib/LuxLib", "lib/MLDataDevices", "lib/LuxCore", ".")
push!(dev_pkgs, Pkg.PackageSpec(path=pkg))
end
Pkg.develop(dev_pkgs)
Pkg.instantiate()
shell: julia --color=yes --code-coverage=user --depwarn=yes --project=. {0}
shell: julia --color=yes --code-coverage=user --depwarn=yes --project=test {0}
- name: "Run Tests"
run: |
import Pkg, Lux
Expand All @@ -144,7 +132,7 @@ jobs:
files: lcov.info
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true
fail_ci_if_error: true
fail_ci_if_error: false

env:
BACKEND_GROUP: "CPU"
2 changes: 1 addition & 1 deletion .github/workflows/CIPreRelease.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,4 +92,4 @@ jobs:
files: lcov.info
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true
fail_ci_if_error: true
fail_ci_if_error: false
18 changes: 10 additions & 8 deletions .github/workflows/CI_LuxCUDA.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,12 @@ jobs:
${{ runner.os }}-test-${{ env.cache-name }}-
${{ runner.os }}-test-
${{ runner.os }}-
- name: "Install Dependencies and Run Tests"
- uses: julia-actions/julia-buildpkg@v1
with:
project: "lib/LuxCUDA"
- name: "Run Tests"
run: |
import Pkg
Pkg.Registry.update()
Pkg.instantiate()
Pkg.test(; coverage="user")
shell: julia --color=yes --code-coverage=user --depwarn=yes --project=lib/LuxCUDA {0}
- uses: julia-actions/julia-processcoverage@v1
Expand All @@ -54,7 +55,7 @@ jobs:
files: lcov.info
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true
fail_ci_if_error: true
fail_ci_if_error: false

downgrade:
if: ${{ !contains(github.event.head_commit.message, '[skip tests]') && github.base_ref == github.event.repository.default_branch }}
Expand All @@ -65,11 +66,12 @@ jobs:
with:
version: "1.10"
- uses: julia-actions/julia-downgrade-compat@v1
- name: "Install Dependencies and Run Tests"
- uses: julia-actions/julia-buildpkg@v1
with:
project: "lib/LuxCUDA"
- name: "Run Tests"
run: |
import Pkg
Pkg.Registry.update()
Pkg.instantiate()
Pkg.test(; coverage="user")
shell: julia --color=yes --code-coverage=user --depwarn=yes --project=lib/LuxCUDA {0}
- uses: julia-actions/julia-processcoverage@v1
Expand All @@ -80,7 +82,7 @@ jobs:
files: lcov.info
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true
fail_ci_if_error: true
fail_ci_if_error: false

env:
BACKEND_GROUP: "CPU"
4 changes: 2 additions & 2 deletions .github/workflows/CI_LuxCore.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ jobs:
files: lcov.info
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true
fail_ci_if_error: true
fail_ci_if_error: false

downgrade:
if: ${{ !contains(github.event.head_commit.message, '[skip tests]') && github.base_ref == github.event.repository.default_branch }}
Expand Down Expand Up @@ -110,7 +110,7 @@ jobs:
files: lcov.info
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true
fail_ci_if_error: true
fail_ci_if_error: false

env:
BACKEND_GROUP: "CPU"
43 changes: 16 additions & 27 deletions .github/workflows/CI_LuxLib.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ jobs:
fail-fast: false
matrix:
version:
- "1.10"
- "1"
os:
- ubuntu-latest
Expand All @@ -41,22 +40,22 @@ jobs:
loopvec:
- "true"
include:
- version: "1.10"
- version: "1"
os: ubuntu-latest
test_group: "dense"
blas_backend: "default"
loopvec: "false"
- version: "1.10"
- version: "1"
os: ubuntu-latest
test_group: "misc"
blas_backend: "default"
loopvec: "false"
- version: "1.10"
- version: "1"
os: macos-latest
test_group: "all"
blas_backend: "default"
loopvec: "true"
- version: "1.10"
- version: "1"
os: windows-latest
test_group: "all"
blas_backend: "default"
Expand All @@ -76,23 +75,18 @@ jobs:
${{ runner.os }}-test-${{ env.cache-name }}-
${{ runner.os }}-test-
${{ runner.os }}-
- name: "Install Dependencies"
- uses: julia-actions/julia-buildpkg@v1
with:
project: "lib/LuxLib"
- name: "Dev Test Dependencies"
run: |
import Pkg
dev_pkgs = Pkg.PackageSpec[]
for pkg in ("lib/LuxCore", "lib/MLDataDevices")
push!(dev_pkgs, Pkg.PackageSpec(path=pkg))
end
Pkg.develop(dev_pkgs)
Pkg.Registry.update()
Pkg.instantiate()
Pkg.activate("lib/LuxLib/test")
dev_pkgs = Pkg.PackageSpec[]
for pkg in ("lib/LuxTestUtils", "lib/LuxLib", "lib/MLDataDevices")
push!(dev_pkgs, Pkg.PackageSpec(path=pkg))
end
Pkg.develop(dev_pkgs)
shell: julia --color=yes --code-coverage=user --depwarn=yes --project=lib/LuxLib {0}
shell: julia --color=yes --code-coverage=user --depwarn=yes --project=lib/LuxLib/test {0}
- name: "Run Tests"
run: |
import Pkg, LuxLib
Expand All @@ -111,7 +105,7 @@ jobs:
files: lcov.info
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true
fail_ci_if_error: true
fail_ci_if_error: false

downgrade:
if: ${{ !contains(github.event.head_commit.message, '[skip tests]') && github.base_ref == github.event.repository.default_branch }}
Expand All @@ -126,23 +120,18 @@ jobs:
- uses: julia-actions/julia-downgrade-compat@v1
with:
skip: "LuxCore,MLDataDevices"
- name: "Install Dependencies"
- uses: julia-actions/julia-buildpkg@v1
with:
project: "lib/LuxLib"
- name: "Dev Test Dependencies"
run: |
import Pkg
dev_pkgs = Pkg.PackageSpec[]
for pkg in ("lib/LuxCore", "lib/MLDataDevices")
push!(dev_pkgs, Pkg.PackageSpec(path=pkg))
end
Pkg.develop(dev_pkgs)
Pkg.Registry.update()
Pkg.instantiate()
Pkg.activate("lib/LuxLib/test")
dev_pkgs = Pkg.PackageSpec[]
for pkg in ("lib/LuxTestUtils", "lib/LuxLib", "lib/MLDataDevices")
push!(dev_pkgs, Pkg.PackageSpec(path=pkg))
end
Pkg.develop(dev_pkgs)
shell: julia --color=yes --code-coverage=user --depwarn=yes --project=lib/LuxLib {0}
shell: julia --color=yes --code-coverage=user --depwarn=yes --project=lib/LuxLib/test {0}
- name: "Run Tests"
run: |
import Pkg, LuxLib
Expand All @@ -161,7 +150,7 @@ jobs:
files: lcov.info
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true
fail_ci_if_error: true
fail_ci_if_error: false

env:
BACKEND_GROUP: "CPU"
Loading

0 comments on commit e13598a

Please sign in to comment.