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

Removes diffusivity calculation from DiffusivityFields() for Smagorinsky closure #2908

Merged
merged 2 commits into from
Feb 7, 2023

Conversation

tomchor
Copy link
Collaborator

@tomchor tomchor commented Feb 6, 2023

This PR removes the calculation of the diffusivities in DiffusivityFields() for the SmagorinskyLilly so that binary operations are avoided.

Closes #2869

@glwagner
Copy link
Member

glwagner commented Feb 6, 2023

Perfect, does this also solve the issue?

@tomchor
Copy link
Collaborator Author

tomchor commented Feb 6, 2023

Perfect, does this also solve the issue?

Yes! I tested it with up to 10 tracers:

┌ Info: NonhydrostaticModel{GPU, RectilinearGrid}(time = 0 seconds, iteration = 0)
│ ├── grid: 8×8×6 RectilinearGrid{Float64, Periodic, Periodic, Bounded} on GPU with 3×3×3 halo
│ ├── timestepper: QuasiAdamsBashforth2TimeStepper
│ ├── tracers: (b, τ1, τ2, t3, t4, t5, t6, t8, t9, t10)
│ ├── closure: SmagorinskyLilly: C=0.1, Cb=1.0, Pr=(b = 1.0, τ1 = 1.0, τ2 = 1.0, t3 = 1.0, t4 = 1.0, t5 = 1.0, t6 = 1.0, t8 = 1.0, t9 = 1.0, t10 = 1.0)
│ ├── buoyancy: Nothing
└ └── coriolis: Nothing
[ Info: Initializing simulation...
[ Info:     ... simulation initialization complete (79.486 ms)
[ Info: Executing initial time step...
[ Info:     ... initial time step complete (4.737 minutes).
[ Info: Simulation is stopping after running for 4.739 minutes.
[ Info: Model iteration 10 equals or exceeds stop iteration 10.

@tomchor tomchor merged commit 6f929c4 into main Feb 7, 2023
@tomchor tomchor deleted the tc/smag-binary-op2 branch February 7, 2023 05:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

device kernel image is invalid error when running relatively complex simulation on GPUs
2 participants