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

NetCDF output with BFloat16 #407

Merged
merged 4 commits into from
Nov 7, 2023
Merged

NetCDF output with BFloat16 #407

merged 4 commits into from
Nov 7, 2023

Conversation

milankl
Copy link
Member

@milankl milankl commented Nov 6, 2023

fixes #406, T21 simulation with BFloat16!

out.mp4

There remains an issue with the restart files

ERROR: MethodError: no method matching round!(::LowerTriangularMatrix{Complex{BFloat16}}, ::Int64)

Closest candidates are:
  round!(::AbstractArray{T}, ::Integer) where T<:Union{Float16, Float32, Float64, ComplexF64, ComplexF16, ComplexF32}
   @ BitInformation ~/.julia/packages/BitInformation/CkrSa/src/round_nearest.jl:90

which however should probably be fixed in BitInformation.jl (at the moment it just doesn't create a restart file, but netcdf is fine (see video)

@madnanabid

@milankl milankl added low precision 🚂 Low precision arithmetics, rounding, 32 or 16-bit. output 📤 NetCDF or JLD2 output, their writers, formats, etc labels Nov 6, 2023
@milankl
Copy link
Member Author

milankl commented Nov 7, 2023

@croci some vorticity advection with a pseudo-spectral solver in BFloat16! At the moment going to higher resolution fails though, probably something wrong with the spectral transform!? Could be interesting to test out BFloat16sr in comparison!

@milankl milankl mentioned this pull request Nov 7, 2023
@milankl milankl merged commit b3517f4 into main Nov 7, 2023
4 checks passed
@milankl milankl deleted the mk/ncoutput branch November 29, 2023 19:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
low precision 🚂 Low precision arithmetics, rounding, 32 or 16-bit. output 📤 NetCDF or JLD2 output, their writers, formats, etc
Projects
None yet
Development

Successfully merging this pull request may close these issues.

run BarotropicModel T21 with BFloat16 and output
1 participant