diff --git a/.buildkite/Project.toml b/.buildkite/Project.toml index c93373cbda..747c76b169 100644 --- a/.buildkite/Project.toml +++ b/.buildkite/Project.toml @@ -14,7 +14,6 @@ ClimaCoreTempestRemap = "d934ef94-cdd4-4710-83d6-720549644b70" ClimaCoreVTK = "c8b6d40d-e815-466f-95ae-c48aefa668fa" ClimaTimeSteppers = "595c0a79-7f3d-439a-bc5a-b232dc3bde79" Colors = "5ae59095-9a9b-59fe-a467-6f913c188581" -Combinatorics = "861a8166-3701-5b0c-9a16-15d98fcdc6aa" CountFlops = "1db9610d-79e1-487a-8d40-77f3295c7593" CubedSphere = "7445602f-e544-4518-8976-18f8e8ae6cdb" DiffEqCallbacks = "459566f4-90b8-5000-8ac3-15dfb0a30def" @@ -33,7 +32,6 @@ Logging = "56ddb016-857b-54e1-b83d-db4d58db5568" MPI = "da04e1cc-30fd-572f-bb4f-1f8673147195" NCDatasets = "85f8d34a-cbdd-5861-8df4-14fed0d494ab" NVTX = "5da4648a-3479-48b8-97b9-01cb529c0a1f" -OrderedCollections = "bac558e1-5e72-5ebc-8fee-abe8a469f55d" OrdinaryDiffEqSSPRK = "669c94d9-1f4b-4b64-b377-1aa079aa2388" OrdinaryDiffEqTsit5 = "b1df2697-797e-41e3-8120-5422d3b24e4a" PProf = "e4faabce-9ead-11e9-39d9-4379958e3056" diff --git a/.github/workflows/downgrade.yml b/.github/workflows/downgrade.yml new file mode 100644 index 0000000000..44363fb70b --- /dev/null +++ b/.github/workflows/downgrade.yml @@ -0,0 +1,34 @@ +name: Downgrade +on: + pull_request: + push: + branches: + - main + tags: '*' + +# Needed to allow julia-actions/cache to delete old caches that it has created +permissions: + actions: write + contents: read + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + test: + runs-on: ubuntu-latest + strategy: + matrix: + version: ['1.9', '1.10', '1.11'] + steps: + - uses: actions/checkout@v4 + - uses: julia-actions/setup-julia@latest + with: + version: ${{ matrix.version }} + - uses: julia-actions/cache@v2 + - uses: julia-actions/julia-downgrade-compat@v1 + with: + skip: Dates, InteractiveUtils, LinearAlgebra, Logging, Random, Test, SparseArrays, Statistics + - uses: julia-actions/julia-buildpkg@latest + - uses: julia-actions/julia-runtest@latest diff --git a/Project.toml b/Project.toml index d1cb55b330..82a1654c22 100644 --- a/Project.toml +++ b/Project.toml @@ -10,7 +10,6 @@ BlockArrays = "8e7c35d0-a365-5155-bbbb-fb81a777f24e" ClimaComms = "3a4d1b5c-c61d-41fd-a00a-5873ba7a1b0d" CubedSphere = "7445602f-e544-4518-8976-18f8e8ae6cdb" DataStructures = "864edb3b-99cc-5e75-8d2d-829cb0a9cfe8" -DocStringExtensions = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae" ForwardDiff = "f6369f11-7733-5829-9624-2563aa707210" GaussQuadrature = "d54b0c1a-921d-58e0-8e36-89d8069c0969" GilbertCurves = "88fa7841-ef32-4516-bb70-c6ec135699d9" @@ -42,47 +41,43 @@ Adapt = "3, 4" Aqua = "0.8" ArgParse = "1" AssociatedLegendrePolynomials = "1" -BandedMatrices = "0.17, 1" +BandedMatrices = "1" BenchmarkTools = "1" -BlockArrays = "0.16, 1" +BlockArrays = "1" ClimaComms = "0.6" -Combinatorics = "1" CountFlops = "0.1" CubedSphere = "0.2, 0.3" -CUDA = "5" +CUDA = "5.5" Dates = "1" -DataStructures = "0.18" -DocStringExtensions = "0.8, 0.9" -FastBroadcast = "0.3" -ForwardDiff = "0.10" -GaussQuadrature = "0.5" +DataStructures = "0.18.13" +FastBroadcast = "0.3.1" +ForwardDiff = "0.10.15" +GaussQuadrature = "0.5.5" GilbertCurves = "0.1" -HDF5 = "0.16, 0.17" +HDF5 = "0.16.10, 0.17" InteractiveUtils = "1" IntervalSets = "0.5, 0.6, 0.7" -JET = "0.9" +JET = "0.8.28, 0.9" Krylov = "0.9" KrylovKit = "0.6, 0.7, 0.8" LinearAlgebra = "1" -LazyBroadcast = "0.1" +LazyBroadcast = "0.1.4" Logging = "1" -MPI = "0.20" -MultiBroadcastFusion = "0.3, 0.4" +MultiBroadcastFusion = "0.3.1, 0.4" NVTX = "0.3" -OrderedCollections = "1" PkgVersion = "0.1, 0.2, 0.3" PrettyTables = "2" Random = "1" -RecursiveArrayTools = "2, 3" +RecursiveArrayTools = "3.1" RootSolvers = "0.3, 0.4" SafeTestsets = "0.1" SparseArrays = "1" -StaticArrays = "1" +StaticArrays = "1.6" Statistics = "1" StatsBase = "0.34" TerminalLoggers = "0.1" Test = "1" -Unrolled = "0.1" +Unrolled = "0.1.2" julia = "1.9" [extras] @@ -90,16 +85,13 @@ Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595" ArgParse = "c7e460c6-2fb9-53a9-8c5b-16f535851c63" AssociatedLegendrePolynomials = "2119f1ac-fb78-50f5-8cc0-dda848ebdb19" BenchmarkTools = "6e4b80f9-dd63-53aa-95a3-0cdb28fa8baf" -Combinatorics = "861a8166-3701-5b0c-9a16-15d98fcdc6aa" CountFlops = "1db9610d-79e1-487a-8d40-77f3295c7593" Dates = "ade2ca70-3891-5945-98fb-dc099432e06a" FastBroadcast = "7034ab61-46d4-4ed7-9d0f-46aef9175898" -Krylov = "ba0b0d4f-ebba-5204-a429-3ac8c609bfb7" JET = "c3a54625-cd67-489e-a8e7-0a5a0ff4e31b" +Krylov = "ba0b0d4f-ebba-5204-a429-3ac8c609bfb7" LazyBroadcast = "9dccce8e-a116-406d-9fcc-a88ed4f510c8" Logging = "56ddb016-857b-54e1-b83d-db4d58db5568" -MPI = "da04e1cc-30fd-572f-bb4f-1f8673147195" -OrderedCollections = "bac558e1-5e72-5ebc-8fee-abe8a469f55d" PrettyTables = "08abe8d2-0d0c-5749-adfa-8a2ac140af0d" Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c" SafeTestsets = "1bc83da4-3b8d-516f-aca4-4fe02f6d838f" @@ -108,5 +100,4 @@ TerminalLoggers = "5d786b92-1e48-4d6f-9151-6b4477ca9bed" Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" [targets] -test = ["Aqua", "ArgParse", "AssociatedLegendrePolynomials", "BenchmarkTools", "Combinatorics", "CountFlops", "Dates", "FastBroadcast", "Krylov", "JET", "LazyBroadcast", "Logging", "MPI", "OrderedCollections", "PrettyTables", "Random", "SafeTestsets", "StatsBase", "TerminalLoggers", "Test"] - +test = ["Aqua", "ArgParse", "AssociatedLegendrePolynomials", "BenchmarkTools", "CountFlops", "Dates", "FastBroadcast", "Krylov", "JET", "LazyBroadcast", "Logging", "PrettyTables", "Random", "SafeTestsets", "StatsBase", "TerminalLoggers", "Test"] diff --git a/src/Domains/Domains.jl b/src/Domains/Domains.jl index 5336f30a2c..4bd1c5e972 100644 --- a/src/Domains/Domains.jl +++ b/src/Domains/Domains.jl @@ -1,7 +1,7 @@ module Domains import ..Geometry: Geometry, float_type -using IntervalSets +import IntervalSets export RectangleDomain """ @@ -62,7 +62,7 @@ function IntervalDomain( end IntervalDomain(promote(coord_min, coord_max)..., boundary_names) end -IntervalDomain(coords::ClosedInterval; kwargs...) = +IntervalDomain(coords::IntervalSets.ClosedInterval; kwargs...) = IntervalDomain(coords.left, coords.right; kwargs...) """ @@ -130,8 +130,8 @@ Construct a `RectangularDomain` in the horizontal. If a given x1 or x2 boundary is not periodic, then `x1boundary` or `x2boundary` boundary name keyword arguments must be supplied. """ function RectangleDomain( - x1::ClosedInterval{X1CT}, - x2::ClosedInterval{X2CT}; + x1::IntervalSets.ClosedInterval{X1CT}, + x2::IntervalSets.ClosedInterval{X2CT}; x1periodic = false, x2periodic = false, x1boundary::BCTagType = nothing, diff --git a/src/Meshes/Meshes.jl b/src/Meshes/Meshes.jl index 4d35a05327..a42585742d 100644 --- a/src/Meshes/Meshes.jl +++ b/src/Meshes/Meshes.jl @@ -1,7 +1,6 @@ module Meshes import RootSolvers -using DocStringExtensions export RectilinearMesh, EquiangularCubedSphere, diff --git a/src/Topologies/Topologies.jl b/src/Topologies/Topologies.jl index 77dd9b20d6..06c12d4053 100644 --- a/src/Topologies/Topologies.jl +++ b/src/Topologies/Topologies.jl @@ -1,7 +1,5 @@ module Topologies -using DocStringExtensions - import ClimaComms, Adapt import ..ClimaCore diff --git a/src/Topologies/dss.jl b/src/Topologies/dss.jl index a78b7090be..75afab7fec 100644 --- a/src/Topologies/dss.jl +++ b/src/Topologies/dss.jl @@ -1,4 +1,3 @@ -using DocStringExtensions using .DataLayouts: CartesianFieldIndex const DSSTypesAll = Union{ @@ -24,7 +23,18 @@ const DSSWeightTypes = Union{DataLayouts.IJFH, DataLayouts.IJHF} DSSBuffer{G, D, A, B} # Fields -$(DocStringExtensions.FIELDS) + +- `graph_context`: ClimaComms graph context for communication +- `perimeter_data`: Perimeter `DataLayout` object: typically a + `VIFH{TT,Nv,Np,Nh}` or `VIHF{TT,Nv,Np,Nh}`, where `TT` is the transformed + type, `Nv` is the number of vertical levels, and `Np` is the length of the + perimeter +- `send_date`: send buffer `AbstractVector{FT}` +- `recv_data`: recv buffer `AbstractVector{FT}` +- `send_buf_idx`: indexing array for loading send buffer from `perimeter_data` +- `recv_buf_idx`: indexing array for loading (and summing) data from recv buffer to +- `internal_elems`: internal local elements (lidx) +- `perimeter_elems`: local elements (lidx) located on process boundary """ struct DSSBuffer{S, G, D, A, B, VI} "ClimaComms graph context for communication" diff --git a/src/Topologies/topology2d.jl b/src/Topologies/topology2d.jl index 7ae2402230..607a4e40d1 100644 --- a/src/Topologies/topology2d.jl +++ b/src/Topologies/topology2d.jl @@ -454,7 +454,7 @@ function _Topology2D( end end end - # 6). + # 6). comm_vertex_lengths = zeros(Int, length(send_elem_pids)) ghost_vertex_neighbor_loc = Int[] ghost_vertex_comm_idx_offset = ones(Int, length(ghost_vertex_offset)) @@ -492,7 +492,7 @@ function _Topology2D( end unique!(perimeter_elems) internal_elems = setdiff(1:length(local_elem_gidx), perimeter_elems) - # 7). + # 7). comm_face_lengths = zeros(Int, length(send_elem_pids)) ghost_face_neighbor_loc = Vector{Int}(undef, length(ghost_faces)) ghost_face_gcidx = zeros(Int, length(ghost_faces)) diff --git a/test/Fields/convergence_field_integrals.jl b/test/Fields/convergence_field_integrals.jl index 4dcf0c1842..17ed08fdf3 100644 --- a/test/Fields/convergence_field_integrals.jl +++ b/test/Fields/convergence_field_integrals.jl @@ -8,7 +8,7 @@ using JET using ClimaComms ClimaComms.@import_required_backends -using OrderedCollections +import DataStructures using StaticArrays, IntervalSets import ClimaCore import ClimaCore.Utilities: PlusHalf @@ -51,7 +51,7 @@ convergence_rate(err, Δh) = @testset "Definite column integrals bycolumn" begin FT = Float64 - results = OrderedCollections.OrderedDict() + results = DataStructures.OrderedDict() ∫y_analytic = 1 - cos(1) - (0 - cos(0)) function col_field_copy(y) col_copy = similar(y[Fields.ColumnIndex((1, 1), 1)]) diff --git a/test/Fields/unit_field.jl b/test/Fields/unit_field.jl index 805b4ef8cd..d2f779289b 100644 --- a/test/Fields/unit_field.jl +++ b/test/Fields/unit_field.jl @@ -8,7 +8,6 @@ using JET using ClimaComms ClimaComms.@import_required_backends -using OrderedCollections using StaticArrays, IntervalSets import ClimaCore import ClimaCore.InputOutput diff --git a/test/Fields/utils_field_multi_broadcast_fusion.jl b/test/Fields/utils_field_multi_broadcast_fusion.jl index 35abea33be..1557f94944 100644 --- a/test/Fields/utils_field_multi_broadcast_fusion.jl +++ b/test/Fields/utils_field_multi_broadcast_fusion.jl @@ -10,7 +10,6 @@ using BenchmarkTools using ClimaComms ClimaComms.@import_required_backends -using OrderedCollections using StaticArrays, IntervalSets import ClimaCore import ClimaCore.Utilities: PlusHalf diff --git a/test/Geometry/axistensor_conversion_benchmarks.jl b/test/Geometry/axistensor_conversion_benchmarks.jl index 9188561363..5e7af551cf 100644 --- a/test/Geometry/axistensor_conversion_benchmarks.jl +++ b/test/Geometry/axistensor_conversion_benchmarks.jl @@ -1,7 +1,7 @@ using Test, StaticArrays #! format: off import Random, BenchmarkTools, StatsBase, - OrderedCollections, LinearAlgebra, Combinatorics, CountFlops + DataStructures, LinearAlgebra, CountFlops using ClimaCore.Geometry:Geometry, AbstractAxis, CovariantAxis, AxisVector, ContravariantAxis, LocalAxis, CartesianAxis, AxisTensor, Covariant1Vector, Covariant13Vector, UVVector, UWVector, UVector, @@ -150,7 +150,7 @@ compare(x::T, y::T) where {T <: AxisTensor} = compare(components(x), components( function test_optimized_functions(::Type{FT}; print_method_info=false) where {FT} @info "Testing optimized functions with $FT" - benchmarks = OrderedCollections.OrderedDict() + benchmarks = DataStructures.OrderedDict() for f in ( Geometry.project, Geometry.transform, diff --git a/test/Operators/finitedifference/benchmark_stencils_utils.jl b/test/Operators/finitedifference/benchmark_stencils_utils.jl old mode 100644 new mode 100755 index ad9395b731..b5aedab5b8 --- a/test/Operators/finitedifference/benchmark_stencils_utils.jl +++ b/test/Operators/finitedifference/benchmark_stencils_utils.jl @@ -5,7 +5,7 @@ ClimaComms.@import_required_backends using StaticArrays, IntervalSets, LinearAlgebra import BenchmarkTools import StatsBase -import OrderedCollections +import DataStructures using ClimaCore.Geometry: ⊗ import ClimaCore.DataLayouts @@ -348,8 +348,8 @@ function benchmark_operators_column(bm; z_elems, helem, Nq, compile::Bool = fals FT = bm.float_type device = ClimaComms.device() @show device - trials = OrderedCollections.OrderedDict() - t_min = OrderedCollections.OrderedDict() + trials = DataStructures.OrderedDict() + t_min = DataStructures.OrderedDict() cspace = TU.ColumnCenterFiniteDifferenceSpace(FT; zelem=z_elems) fspace = Spaces.FaceFiniteDifferenceSpace(cspace) @@ -367,8 +367,8 @@ function benchmark_operators_sphere(bm; z_elems, helem, Nq, compile::Bool = fals FT = bm.float_type device = ClimaComms.device() @show device - trials = OrderedCollections.OrderedDict() - t_min = OrderedCollections.OrderedDict() + trials = DataStructures.OrderedDict() + t_min = DataStructures.OrderedDict() cspace = TU.CenterExtrudedFiniteDifferenceSpace(FT; zelem=z_elems, helem, Nq, horizontal_layout_type) fspace = Spaces.FaceExtrudedFiniteDifferenceSpace(cspace) diff --git a/test/Operators/spectralelement/benchmark_ops.jl b/test/Operators/spectralelement/benchmark_ops.jl index a7d81fb6bf..cd1b47c275 100644 --- a/test/Operators/spectralelement/benchmark_ops.jl +++ b/test/Operators/spectralelement/benchmark_ops.jl @@ -87,7 +87,7 @@ function benchmark_all(kernel_args = setup_kernel_args(ARGS)) #! format: on silent = true # see BenchmarkTools.@benchmark output with `silent = false` - bm = OrderedCollections.OrderedDict() + bm = DataStructures.OrderedDict() for (k, ka) in kernels # key = (Symbol(k), Symbol(ka)) key = Symbol(k) diff --git a/test/Operators/spectralelement/benchmark_times.jl b/test/Operators/spectralelement/benchmark_times.jl index b4288f208a..b252e02db6 100644 --- a/test/Operators/spectralelement/benchmark_times.jl +++ b/test/Operators/spectralelement/benchmark_times.jl @@ -9,7 +9,7 @@ function get_best_times((; device, float_type)) end function get_best_times_cpu_float64() - best_times = OrderedCollections.OrderedDict() + best_times = DataStructures.OrderedDict() best_times[:kernel_spectral_wdiv!] = 87042.2667 best_times[:kernel_spectral_grad!] = 77839.3543 best_times[:kernel_spectral_grad_norm!] = 105859.9405 @@ -22,7 +22,7 @@ function get_best_times_cpu_float64() return best_times end function get_best_times_cpu_float32() - best_times = OrderedCollections.OrderedDict() + best_times = DataStructures.OrderedDict() best_times[:kernel_spectral_wdiv!] = 79922.8909 best_times[:kernel_spectral_grad!] = 74736.2011 best_times[:kernel_spectral_grad_norm!] = 101959.6227 @@ -35,7 +35,7 @@ function get_best_times_cpu_float32() return best_times end function get_best_times_gpu_float64() - best_times = OrderedCollections.OrderedDict() + best_times = DataStructures.OrderedDict() best_times[:kernel_spectral_wdiv!] = 21750.2493 best_times[:kernel_spectral_grad!] = 21046.113 best_times[:kernel_spectral_grad_norm!] = 53723.9003 @@ -48,7 +48,7 @@ function get_best_times_gpu_float64() return best_times end function get_best_times_gpu_float32() - best_times = OrderedCollections.OrderedDict() + best_times = DataStructures.OrderedDict() best_times[:kernel_spectral_wdiv!] = 26606.9483 best_times[:kernel_spectral_grad!] = 20715.8317 best_times[:kernel_spectral_grad_norm!] = 52673.6528 diff --git a/test/Operators/spectralelement/benchmark_utils.jl b/test/Operators/spectralelement/benchmark_utils.jl index fb82644196..41541248a0 100644 --- a/test/Operators/spectralelement/benchmark_utils.jl +++ b/test/Operators/spectralelement/benchmark_utils.jl @@ -5,7 +5,6 @@ using LinearAlgebra: × import PrettyTables import LinearAlgebra as LA -import OrderedCollections import ClimaCore.DataLayouts import ClimaCore.Operators as Operators import ClimaCore.Domains as Domains