MITgcmTools.jl
Set of tools for the analysis, manipulation, etc of MITgcm input and output files.
MITgcmTools.MatrixInterp
MITgcmTools.MetaFileRead
MITgcmTools.convert2array
MITgcmTools.convert2gcmfaces
MITgcmTools.findtiles
MITgcmTools.parsemeta
MITgcmTools.prep_MTRX
MITgcmTools.qwckplot
MITgcmTools.qwckplot
MITgcmTools.qwckplot
MITgcmTools.readAvailDiagnosticsLog
MITgcmTools.read_SPM
MITgcmTools.read_bin
MITgcmTools.read_nctiles
MITgcmTools.MatrixInterp
— MethodMatrixInterp(in::Array{T,N},MTRX,siz) where {T,N}
Interpolate in
using MTRX
to grid of size siz
.
MITgcmTools.MetaFileRead
— MethodMetaFileRead(filIn::String)
Reads a meta file generated by MITgcm
MITgcmTools.convert2array
— Methodconvert2array(fld::MeshArray)
Convert MeshArray to Array (or vice versa otherwise)
MITgcmTools.convert2gcmfaces
— Methodconvert2gcmfaces(fld::MeshArray)
Convert mitgcm output to MeshArray (or vice versa otherwise)
MITgcmTools.findtiles
— Methodfindtiles(ni::Int,nj::Int,mygrid::gcmgrid)
findtiles(ni::Int,nj::Int,grid::String="LatLonCap",GridParentDir="../inputs/GRID_LLC90/")
Return a MeshArray
map of tile indices, mytiles["tileNo"]
, for tile size ni,nj
and extract grid variables accordingly.
MITgcmTools.parsemeta
— Methodparsemeta(metafile)
Parse out an MITgcm
metadata file and return a Dict
of fields in the file.
MITgcmTools.prep_MTRX
— Methodprep_MTRX()
Repackage interpolation matrix, mask, etc to .jld
file.
MITgcmTools.qwckplot
— Methodqwckplot(fld::MeshArray,ttl::String)
Plot input using convert2array and heatmap + add title
MITgcmTools.qwckplot
— Methodqwckplot(fld::MeshArray,clims::NTuple{2, Number})
Plot input using convert2array and heatmap w. chosen clims
MITgcmTools.qwckplot
— Methodqwckplot(fld::MeshArray)
Call qwckplot(fld::MeshArray) with date as title. Example:
!isdir("GRID_LLC90") ? error("missing files") : nothing
GridVariables=GridLoad(GridSpec("LLC90"))
qwckplot(GridVariables["Depth"])
MITgcmTools.readAvailDiagnosticsLog
— MethodreadAvailDiagnosticsLog(fname,fldname)
Get the information for a particular field from the available_diagnostics.log
file (MITgcm
output).
MITgcmTools.read_SPM
— Methodread_SPM(dirIn::String)
Reads pre-computed interpolation (sparse matrix) from dirIn*"interp_precomputed.mat"
.
MITgcmTools.read_bin
— Methodread_bin(fil::String,kt::Union{Int,Missing},kk::Union{Int,Missing},prec::DataType,mygrid::gcmgrid)
Read model output from binary file and convert to MeshArray. Other methods:
read_bin(fil::String,prec::DataType,mygrid::gcmgrid)
read_bin(fil::String,mygrid::gcmgrid)
MITgcmTools.read_nctiles
— Methodread_nctiles(fileName,fldName,mygrid)
Read model output from NCTiles file and convert to MeshArray instance.
mygrid=GridSpec("LatLonCap")
fileName="nctiles_grid/GRID"
Depth=read_nctiles(fileName,"Depth",mygrid)
hFacC=read_nctiles(fileName,"hFacC",mygrid)
hFacC=read_nctiles(fileName,"hFacC",mygrid,I=(:,:,1))