You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -669,8 +669,8 @@ function grid_attributes(ibg::ImmersedBoundaryGrid)
669
669
return attrs, dims
670
670
end
671
671
672
-
# Using OrderedDict to preserve order of keys. Important for positional arguments.
673
-
convert_for_netcdf(dict::AbstractDict) =OrderedDict{Symbol, Any}(key =>convert_for_netcdf(value) for (key, value) in dict)
672
+
# Using OrderedDict to preserve order of keys (important when saving positional arguments), and string(key) because that's what NetCDF supports as global_attributes.
673
+
convert_for_netcdf(dict::AbstractDict) =OrderedDict(string(key)=>convert_for_netcdf(value) for (key, value) in dict)
674
674
convert_for_netcdf(x::Number) = x
675
675
convert_for_netcdf(x::Bool) =string(x)
676
676
convert_for_netcdf(x::NTuple{N, Number}) where N =collect(x)
@@ -699,7 +699,7 @@ function write_grid_reconstruction_data!(ds, grid; array_type=Array{eltype(grid)
0 commit comments