Skip to content

Commit

Permalink
Merge pull request #27 from CliMA/ncc/drop-cuda
Browse files Browse the repository at this point in the history
Drops CUDA dependency
  • Loading branch information
navidcy authored Aug 19, 2024
2 parents a9dad47 + 83a9fd5 commit b5dc705
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 8 deletions.
4 changes: 1 addition & 3 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
name = "OrthogonalSphericalShellGrids"
uuid = "c2be9673-fb75-4747-82dc-aa2bb9f4aed0"
authors = ["Climate Modeling Alliance and contributors"]
version = "0.1.2"
version = "0.1.3"

[deps]
Adapt = "79e6a3ab-5dfb-504d-930d-738a2a938a0e"
CUDA = "052768ef-5323-5732-b1bb-66c8b64840ba"
JLD2 = "033835bb-8acc-5ee8-8aae-3f567f8a3819"
KernelAbstractions = "63c18a36-062a-441e-b654-da1e3ab1ce7c"
MPI = "da04e1cc-30fd-572f-bb4f-1f8673147195"
Expand All @@ -14,7 +13,6 @@ OffsetArrays = "6fe1bfb0-de20-5000-8ca7-80f57d26f881"

[compat]
Adapt = "4"
CUDA = "5"
JLD2 = "0.4"
KernelAbstractions = "0.9"
MPI = "0.20"
Expand Down
6 changes: 1 addition & 5 deletions src/grid_extensions.jl
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,9 @@ import Oceananigans.Grids: x_domain, y_domain
import Oceananigans.Fields: Field
import Oceananigans.Fields: tupled_fill_halo_regions!

# Horrible, just for this allowscalar!
# we should remove this dependency
using CUDA: @allowscalar

# A tripolar grid is always between 0 and 360 in longitude!
x_domain(grid::TRG) = 0, 360
y_domain(grid::TRG) = @allowscalar minimum(grid.φᶠᶠᵃ), 90
y_domain(grid::TRG) = minimum(parent(grid.φᶠᶠᵃ)), 90

# a `TripolarGrid` needs a `ZipperBoundaryCondition` for the north boundary
# The `sign` 1 for regular tracers and -1 for velocities and signed vectors
Expand Down
1 change: 1 addition & 0 deletions test/runtests.jl
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using OrthogonalSphericalShellGrids
using OrthogonalSphericalShellGrids.Oceananigans
using Oceananigans: GPU, CPU
using Oceananigans.CUDA
using Test

Expand Down

0 comments on commit b5dc705

Please sign in to comment.