MOM_io_file module reference

This module contains the MOM file handler types

Data Types

MOM_axis

Handle for axis in MOM file

axis_list_infra

Linked list of framework axes

axis_node_infra

Framework axis linked list node

axis_list_nc

Linked list of framework axes

axis_node_nc

Framework axis linked list node

MOM_field

Handle for field in MOM file

field_list_infra

Linked list of framework fields

field_node_infra

Framework field linked list node

field_list_nc

Linked list of framework fields

field_node_nc

Framework field linked list node

MOM_file

Generic MOM file abstraction for common operations

MOM_infra_file

MOM file from the supporting framework ("infra") layer

MOM_netcdf_file

MOM file using netCDF backend

Procedure Interfaces

i_open_file

Interface for opening a MOM file

i_close_file

Interface for closing a MOM file

i_flush_file

Interface for flushing I/O in a MOM file

i_register_axis

Interface to register an axis to a MOM file

i_register_field

Interface to register a field to a netCDF file

i_write_attribute

Interface for writing global metata to a MOM file

i_write_field_4d

Interface to write_field_4d()

i_write_field_3d

Interface to write_field_3d()

i_write_field_2d

Interface to write_field_2d()

i_write_field_1d

Interface to write_field_1d()

i_write_field_0d

Interface to write_field_0d()

i_write_field_axis

Interface to write_field_axis()

i_file_is_open

Interface to file_is_open()

i_get_file_info

Interface to get_file_info()

i_get_file_fields

Interface to get_file_fields()

i_get_field_atts

Interface to get_field_atts()

i_read_field_chksum

Interface to read_field_chksum

Functions/Subroutines

initialize_axis_list_infra

Initialize the linked list of framework axes

append_axis_list_infra

Append a new axis to the list

get_axis_list_infra

Get axis based on label

finalize_axis_list_infra

Deallocate axes of list

initialize_axis_list_nc

Initialize the linked list of framework axes

append_axis_list_nc

Append a new axis to the list

get_axis_list_nc

Get axis based on label

finalize_axis_list_nc

Deallocate axes of list

initialize_field_list_infra

Initialize the linked list of framework axes

append_field_list_infra

Append a new field to the list

get_field_list_infra

Get axis based on label

finalize_field_list_infra

Deallocate fields of list

initialize_field_list_nc

Initialize the linked list of framework axes

append_field_list_nc

Append a new field to the list

get_field_list_nc

Get axis based on label

finalize_field_list_nc

Deallocate fields of list

open_file_infra

Open a MOM framework file

close_file_infra

Close a MOM framework file

flush_file_infra

Flush the buffer of a MOM framework file

register_axis_infra

Register an axis to the MOM framework file

register_field_infra

Register a field to the MOM framework file

write_field_4d_infra

Write a 4D field to the MOM framework file

write_field_3d_infra

Write a 3D field to the MOM framework file

write_field_2d_infra

Write a 2D field to the MOM framework file

write_field_1d_infra

Write a 1D field to the MOM framework file

write_field_0d_infra

Write a 0D field to the MOM framework file

write_field_axis_infra

Write an axis field to the MOM framework file

write_attribute_infra

Write global metadata to the MOM framework file

file_is_open_infra

True if the framework file has been opened

get_file_info_infra

Return number of dimensions, variables, or time levels in a MOM infra file

get_file_fields_infra

Return the field metadata associated with a MOM framework file

get_file_times_infra

Get time levels of a MOM framework file

get_field_atts_infra

Get attributes from a field

read_field_chksum_infra

Interface to read_field_chksum

get_file_fieldtypes

Get the native (fieldtype) fields of a MOM framework file

open_file_nc

Open a MOM netCDF file

close_file_nc

Close a MOM netCDF file

flush_file_nc

Flush the buffer of a MOM netCDF file

register_axis_nc

Register an axis to the MOM netcdf file

register_field_nc

Register a field to the MOM netcdf file

write_attribute_nc

Write global metadata to the MOM netcdf file

write_field_4d_nc

Write a 4D field to the MOM netcdf file

write_field_3d_nc

Write a 3D field to the MOM netcdf file

write_field_2d_nc

Write a 2D field to the MOM netcdf file

write_field_1d_nc

Write a 1D field to the MOM netcdf file

write_field_0d_nc

Write a 0D field to the MOM netcdf file

write_field_axis_nc

Write an axis field to the MOM netcdf file

file_is_open_nc

True if the framework file has been opened

get_file_info_nc

Return number of dimensions, variables, or time levels in a MOM netcdf file

update_file_contents_nc

Update the axes and fields descriptors of a MOM netCDF file

get_file_fields_nc

Return the field descriptors of a MOM netCDF file

get_field_atts_nc

Get attributes from a netCDF field

read_field_chksum_nc

Interface to read_field_chksum

get_field_nc

Read the values of a netCDF field into an array that might have halos

Detailed Description

This file defines the MOM_file classes used to inferface with the internal IO handlers, such as the configured "infra" layer (FMS) or native netCDF.

MOM_file: The generic class used to reference any file type Cannot be used in a variable declaration.

MOM_infra_file: A file handler for use by the infra layer. Currently this means an FMS file, such a restart or diagnostic output.

MOM_netcdf_file: A netCDF file handler for MOM-specific I/O. This may include operations outside the scope of FMS or other infra frameworks.

Type Documentation

type :: MOM_axis

Handle for axis in MOM file

Parameters
  • label

    Identifier for the axis in handle's list

type :: axis_list_infra

Linked list of framework axes

Parameters
  • head

    Head of axis linked list

  • tail

    Tail of axis linked list

type :: axis_node_infra

Framework axis linked list node

Parameters
  • label

    Axis identifier

  • next

    Pointer to next axis node

  • axis

    Axis node contents

type :: axis_list_nc

Linked list of framework axes

Parameters
  • head

    Head of axis linked list

  • tail

    Tail of axis linked list

type :: axis_node_nc

Framework axis linked list node

Parameters
  • label

    Axis identifier

  • next

    Pointer to next axis node

  • axis

    Axis node contents

type :: MOM_field

Handle for field in MOM file

Parameters
  • label

    Identifier for the field in the handle's list

  • conversion

    A factor to use to rescale the field before output [a A-1 ~> 1]

type :: field_list_infra

Linked list of framework fields

Parameters
  • head

    Head of field linked list

  • tail

    Tail of field linked list

type :: field_node_infra

Framework field linked list node

Parameters
  • label

    Field identifier

  • field

    Field node contents

  • next

    Pointer to next field node

type :: field_list_nc

Linked list of framework fields

Parameters
  • head

    Head of field linked list

  • tail

    Tail of field linked list

type :: field_node_nc

Framework field linked list node

Parameters
  • label

    Field identifier

  • field

    Field node contents

  • next

    Pointer to next field node

type, abstract :: MOM_file

Generic MOM file abstraction for common operations

type, extends(MOM_file) :: MOM_infra_file

MOM file from the supporting framework ("infra") layer

Parameters
  • domain

    Internal domain used for single-file IO

  • handle_infra

    Framework-specific file handler content

  • axes

    List of axes in file

  • fields

    List of fields in file

type, extends(MOM_file) :: MOM_netcdf_file

MOM file using netCDF backend

Parameters
  • handle_nc

    List of netCDF axes

  • axes

    List of netCDF fields

  • fields

    True if the file has been opened

  • is_open

    True if I/O content is domain-decomposed

  • domain_decomposed

    True if I/O content is domain-decomposed

Procedure Interface Documentation

subroutine i_open_file(handle, filename, action, MOM_domain, threading, fileset)

Interface for opening a MOM file

Parameters
  • handle [inout]

    The handle for the opened file

  • filename [in]

    The path name of the file being opened

  • action [in]

    A flag indicating whether the file can be read or written to and how to handle existing files. The default is WRITE_ONLY.

  • MOM_Domain [in]

    A MOM_Domain that describes the decomposition

  • threading [in]

    A flag indicating whether one (SINGLE_FILE) or multiple PEs (MULTIPLE) participate in I/O. With the default, the root PE does I/O.

  • fileset [in]

    A flag indicating whether multiple PEs doing I/O due to threading=MULTIPLE write to the same file (SINGLE_FILE) or to one file per PE (MULTIPLE, the default).

subroutine i_close_file(handle)

Interface for closing a MOM file

Parameters
  • handle [inout]

    The MOM file to be closed

subroutine i_flush_file(handle)

Interface for flushing I/O in a MOM file

Parameters
  • handle [in]

    The MOM file to be flushed

function i_register_axis(handle, label, units, longname, cartesian, sense, domain, data, edge_axis, calendar) result(axis)

Interface to register an axis to a MOM file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • label [in]

    The name in the file of this axis

  • units [in]

    The units of this axis

  • longname [in]

    The long description of this axis

  • cartesian [in]

    A variable indicating which direction this axis corresponds with. Valid values include 'X', 'Y', 'Z', 'T', and 'N' for none.

  • sense [in]

    This is 1 for axes whose values increase upward, or -1 if they increase downward.

  • domain [in]

    The domain decomposion for this axis

  • data [in]

    The coordinate values of the points on this axis

  • edge_axis [in]

    If true, this axis marks an edge of the tracer cells

  • calendar [in]

    The name of the calendar used with a time axis

  • axis

    IO handle for axis in MOM_file

function i_register_field(handle, axes, label, units, longname, pack, standard_name, checksum, conversion) result(field)

Interface to register a field to a netCDF file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • axes [in]

    Handles for the axis used for this variable

  • label [in]

    The name in the file of this variable

  • units [in]

    The units of this variable

  • longname [in]

    The long description of this variable

  • pack [in]

    A precision reduction factor with which the variable. The default, 1, has no reduction, but 2 is not uncommon.

  • standard_name [in]

    The standard (e.g., CMOR) name for this variable

  • checksum [in]

    Checksum values that can be used to verify reads.

  • conversion [in]

    A factor to use to rescale the field before output [a A-1 ~> 1]

  • field

    IO handle for field in MOM_file

subroutine i_write_attribute(handle, name, attribute)

Interface for writing global metata to a MOM file

Parameters
  • handle [in]

    Handle for a file that is open for writing

  • name [in]

    The name in the file of this global attribute

  • attribute [in]

    The value of this attribute

subroutine i_write_field_4d(handle, field_md, MOM_domain, field, tstamp, tile_count, fill_value)

Interface to write_field_4d()

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • field_md [in]

    Field type with metadata

  • MOM_domain [in]

    The MOM_Domain that describes the decomposition

  • field [inout]

    Field to write

  • tstamp [in]

    Model time of this field

  • tile_count [in]

    PEs per tile (default: 1)

  • fill_value [in]

    Missing data fill value

subroutine i_write_field_3d(handle, field_md, MOM_domain, field, tstamp, tile_count, fill_value)

Interface to write_field_3d()

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • field_md [in]

    Field type with metadata

  • MOM_domain [in]

    The MOM_Domain that describes the decomposition

  • field [inout]

    Field to write

  • tstamp [in]

    Model time of this field

  • tile_count [in]

    PEs per tile (default: 1)

  • fill_value [in]

    Missing data fill value

subroutine i_write_field_2d(handle, field_md, MOM_domain, field, tstamp, tile_count, fill_value)

Interface to write_field_2d()

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • field_md [in]

    Field type with metadata

  • MOM_domain [in]

    The MOM_Domain that describes the decomposition

  • field [inout]

    Field to write

  • tstamp [in]

    Model time of this field

  • tile_count [in]

    PEs per tile (default: 1)

  • fill_value [in]

    Missing data fill value

subroutine i_write_field_1d(handle, field_md, field, tstamp)

Interface to write_field_1d()

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • field_md [in]

    Field type with metadata

  • field [in]

    Field to write

  • tstamp [in]

    Model time of this field

subroutine i_write_field_0d(handle, field_md, field, tstamp)

Interface to write_field_0d()

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • field_md [in]

    Field type with metadata

  • field [in]

    Field to write

  • tstamp [in]

    Model time of this field

subroutine i_write_field_axis(handle, axis)

Interface to write_field_axis()

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • axis [in]

    An axis type variable with information to write

logical function i_file_is_open(handle)

Interface to file_is_open()

Parameters
  • handle [in]

    Handle to a file to inquire about

subroutine i_get_file_info(handle, ndim, nvar, ntime)

Interface to get_file_info()

Parameters
  • handle [in]

    Handle for a file that is open for I/O

  • ndim [out]

    The number of dimensions in the file

  • nvar [out]

    The number of variables in the file

  • ntime [out]

    The number of time levels in the file

subroutine i_get_file_fields(handle, fields)

Interface to get_file_fields()

Parameters
  • handle [inout]

    Handle for a file that is open for I/O

  • fields [inout]

    Field-type descriptions of all of the variables in a file.

subroutine i_get_field_atts(handle, field, name, units, longname, checksum)

Interface to get_field_atts()

Parameters
  • handle [in]

    File where field is stored

  • field [in]

    The field to extract information from

  • name [out]

    The variable name

  • units [out]

    The units of the variable

  • longname [out]

    The long name of the variable

  • checksum [out]

    The checksums of the variable in a file

subroutine i_read_field_chksum(handle, field, chksum, valid_chksum)

Interface to read_field_chksum

Parameters
  • handle [in]

    File where field is stored

  • field [in]

    The field whose checksum attribute is to be read

  • chksum [out]

    The checksum for the field.

  • valid_chksum [out]

    If true, chksum has been successfully read

Functions/Subroutine Documentation

subroutine initialize_axis_list_infra(list)

Initialize the linked list of framework axes

subroutine append_axis_list_infra(list, axis, label)

Append a new axis to the list

function get_axis_list_infra(list, label) result(axis)

Get axis based on label

Callees call graph
Callees of mom_io_file::get_axis_list_infra calls cluster_mom_error_handler MOM_error_handler cluster_mom_io_file MOM_io_file mom_error_handler::mom_error MOM_error mom_io_file::get_axis_list_infra get_axis_list_infra [private/internal] mom_io_file::get_axis_list_infra->mom_error_handler::mom_error
Text view
subroutine finalize_axis_list_infra(list)

Deallocate axes of list

subroutine initialize_axis_list_nc(list)

Initialize the linked list of framework axes

subroutine append_axis_list_nc(list, axis, label)

Append a new axis to the list

function get_axis_list_nc(list, label) result(axis)

Get axis based on label

Callees call graph
Callees of mom_io_file::get_axis_list_nc calls cluster_mom_error_handler MOM_error_handler cluster_mom_io_file MOM_io_file mom_error_handler::mom_error MOM_error mom_io_file::get_axis_list_nc get_axis_list_nc [private/internal] mom_io_file::get_axis_list_nc->mom_error_handler::mom_error
Text view
subroutine finalize_axis_list_nc(list)

Deallocate axes of list

subroutine initialize_field_list_infra(list)

Initialize the linked list of framework axes

subroutine append_field_list_infra(list, field, label)

Append a new field to the list

function get_field_list_infra(list, label) result(field)

Get axis based on label

Callees call graph
Callees of mom_io_file::get_field_list_infra calls cluster_mom_error_handler MOM_error_handler cluster_mom_io_file MOM_io_file mom_error_handler::mom_error MOM_error mom_io_file::get_field_list_infra get_field_list_infra [private/internal] mom_io_file::get_field_list_infra->mom_error_handler::mom_error
Text view
subroutine finalize_field_list_infra(list)

Deallocate fields of list

subroutine initialize_field_list_nc(list)

Initialize the linked list of framework axes

subroutine append_field_list_nc(list, field, label)

Append a new field to the list

function get_field_list_nc(list, label) result(field)

Get axis based on label

Callees call graph
Callees of mom_io_file::get_field_list_nc calls cluster_mom_error_handler MOM_error_handler cluster_mom_io_file MOM_io_file mom_error_handler::mom_error MOM_error mom_io_file::get_field_list_nc get_field_list_nc [private/internal] mom_io_file::get_field_list_nc->mom_error_handler::mom_error
Text view
subroutine finalize_field_list_nc(list)

Deallocate fields of list

subroutine open_file_infra(handle, filename, action, MOM_domain, threading, fileset)

Open a MOM framework file

Callees call graph
Callees of mom_io_file::open_file_infra calls cluster_mom_domain_infra MOM_domain_infra cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_domain_infra::interface::clone_mom_domain clone_MOM_domain (interface) mom_io_file::open_file_infra open_file_infra [private/internal] mom_io_file::open_file_infra->mom_domain_infra::interface::clone_mom_domain mom_io_infra::open_file open_file mom_io_file::open_file_infra->mom_io_infra::open_file
Text view
subroutine close_file_infra(handle)

Close a MOM framework file

Callees call graph
Callees of mom_io_file::close_file_infra calls cluster_mom_domain_infra MOM_domain_infra cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_domain_infra::deallocate_mom_domain deallocate_MOM_domain mom_io_file::close_file_infra close_file_infra [private/internal] mom_io_file::close_file_infra->mom_domain_infra::deallocate_mom_domain mom_io_infra::interface::close_file close_file (interface) mom_io_file::close_file_infra->mom_io_infra::interface::close_file
Text view
subroutine flush_file_infra(handle)

Flush the buffer of a MOM framework file

Callees call graph
Callees of mom_io_file::flush_file_infra calls cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_io_file::flush_file_infra flush_file_infra [private/internal] mom_io_infra::flush_file flush_file mom_io_file::flush_file_infra->mom_io_infra::flush_file
Text view
function register_axis_infra(handle, label, units, longname, cartesian, sense, domain, data, edge_axis, calendar) result(axis)

Register an axis to the MOM framework file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • label [in]

    The name in the file of this axis

  • units [in]

    The units of this axis

  • longname [in]

    The long description of this axis

  • cartesian [in]

    A variable indicating which direction this axis corresponds with. Valid values include 'X', 'Y', 'Z', 'T', and 'N' for none.

  • sense [in]

    This is 1 for axes whose values increase upward, or -1 if they increase downward.

  • domain [in]

    The domain decomposion for this axis

  • data [in]

    The coordinate values of the points on this axis

  • edge_axis [in]

    If true, this axis marks an edge of the tracer cells

  • calendar [in]

    The name of the calendar used with a time axis

  • axis

    The axis type where this information is stored

Callees call graph
Callees of mom_io_file::register_axis_infra calls cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_io_file::register_axis_infra register_axis_infra [private/internal] mom_io_infra::interface::write_metadata write_metadata (interface) mom_io_file::register_axis_infra->mom_io_infra::interface::write_metadata
Text view
function register_field_infra(handle, axes, label, units, longname, pack, standard_name, checksum, conversion) result(field)

Register a field to the MOM framework file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • axes [in]

    Handles for the axis used for this variable

  • label [in]

    The name in the file of this variable

  • units [in]

    The units of this variable

  • longname [in]

    The long description of this variable

  • pack [in]

    A precision reduction factor with which the variable. The default, 1, has no reduction, but 2 is not uncommon.

  • standard_name [in]

    The standard (e.g., CMOR) name for this variable

  • checksum [in]

    Checksum values that can be used to verify reads.

  • conversion [in]

    A factor to use to rescale the field before output [a A-1 ~> 1]

  • field

    The field type where this information is stored

Callees call graph
Callees of mom_io_file::register_field_infra calls cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_io_file::register_field_infra register_field_infra [private/internal] mom_io_infra::interface::write_metadata write_metadata (interface) mom_io_file::register_field_infra->mom_io_infra::interface::write_metadata
Text view
subroutine write_field_4d_infra(handle, field_md, MOM_domain, field, tstamp, tile_count, fill_value)

Write a 4D field to the MOM framework file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • field_md [in]

    Field type with metadata

  • MOM_domain [in]

    The MOM_Domain that describes the decomposition

  • field [inout]

    Field to write

  • tstamp [in]

    Model time of this field

  • tile_count [in]

    PEs per tile (default: 1)

  • fill_value [in]

    Missing data fill value

Callees call graph
Callees of mom_io_file::write_field_4d_infra calls cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_io_file::write_field_4d_infra write_field_4d_infra [private/internal] mom_io_infra::interface::write_field write_field (interface) mom_io_file::write_field_4d_infra->mom_io_infra::interface::write_field
Text view
subroutine write_field_3d_infra(handle, field_md, MOM_domain, field, tstamp, tile_count, fill_value)

Write a 3D field to the MOM framework file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • field_md [in]

    Field type with metadata

  • MOM_domain [in]

    The MOM_Domain that describes the decomposition

  • field [inout]

    Field to write, perhaps in arbitrary rescaled units [A ~> a]

  • tstamp [in]

    Model time of this field

  • tile_count [in]

    PEs per tile (default: 1)

  • fill_value [in]

    Missing data fill value

Callees call graph
Callees of mom_io_file::write_field_3d_infra calls cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_io_file::write_field_3d_infra write_field_3d_infra [private/internal] mom_io_infra::interface::write_field write_field (interface) mom_io_file::write_field_3d_infra->mom_io_infra::interface::write_field
Text view
subroutine write_field_2d_infra(handle, field_md, MOM_domain, field, tstamp, tile_count, fill_value)

Write a 2D field to the MOM framework file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • field_md [in]

    Field type with metadata

  • MOM_domain [in]

    The MOM_Domain that describes the decomposition

  • field [inout]

    Field to write

  • tstamp [in]

    Model time of this field

  • tile_count [in]

    PEs per tile (default: 1)

  • fill_value [in]

    Missing data fill value

Callees call graph
Callees of mom_io_file::write_field_2d_infra calls cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_io_file::write_field_2d_infra write_field_2d_infra [private/internal] mom_io_infra::interface::write_field write_field (interface) mom_io_file::write_field_2d_infra->mom_io_infra::interface::write_field
Text view
subroutine write_field_1d_infra(handle, field_md, field, tstamp)

Write a 1D field to the MOM framework file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • field_md [in]

    Field type with metadata

  • field [in]

    Field to write

  • tstamp [in]

    Model time of this field

Callees call graph
Callees of mom_io_file::write_field_1d_infra calls cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_io_file::write_field_1d_infra write_field_1d_infra [private/internal] mom_io_infra::interface::write_field write_field (interface) mom_io_file::write_field_1d_infra->mom_io_infra::interface::write_field
Text view
subroutine write_field_0d_infra(handle, field_md, field, tstamp)

Write a 0D field to the MOM framework file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • field_md [in]

    Field type with metadata

  • field [in]

    Field to write

  • tstamp [in]

    Model time of this field

Callees call graph
Callees of mom_io_file::write_field_0d_infra calls cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_io_file::write_field_0d_infra write_field_0d_infra [private/internal] mom_io_infra::interface::write_field write_field (interface) mom_io_file::write_field_0d_infra->mom_io_infra::interface::write_field
Text view
subroutine write_field_axis_infra(handle, axis)

Write an axis field to the MOM framework file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • axis [in]

    An axis type variable with information to write

  • axis_infra

    An axis type variable with information to write

Callees call graph
Callees of mom_io_file::write_field_axis_infra calls cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_io_file::write_field_axis_infra write_field_axis_infra [private/internal] mom_io_infra::interface::write_field write_field (interface) mom_io_file::write_field_axis_infra->mom_io_infra::interface::write_field
Text view
subroutine write_attribute_infra(handle, name, attribute)

Write global metadata to the MOM framework file

Parameters
  • handle [in]

    Handle for a file that is open for writing

  • name [in]

    The name in the file of this global attribute

  • attribute [in]

    The value of this attribute

Callees call graph
Callees of mom_io_file::write_attribute_infra calls cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_io_file::write_attribute_infra write_attribute_infra [private/internal] mom_io_infra::interface::write_metadata write_metadata (interface) mom_io_file::write_attribute_infra->mom_io_infra::interface::write_metadata
Text view
logical function file_is_open_infra(handle)

True if the framework file has been opened

Parameters
  • handle [in]

    Handle to a file to inquire about

Callees call graph
Callees of mom_io_file::file_is_open_infra calls cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_io_file::file_is_open_infra file_is_open_infra [private/internal] mom_io_infra::file_is_open file_is_open mom_io_file::file_is_open_infra->mom_io_infra::file_is_open
Text view
subroutine get_file_info_infra(handle, ndim, nvar, ntime)

Return number of dimensions, variables, or time levels in a MOM infra file

Parameters
  • handle [in]

    Handle for a file that is open for I/O

  • ndim [out]

    The number of dimensions in the file

  • nvar [out]

    The number of variables in the file

  • ntime [out]

    The number of time levels in the file

Callees call graph
Callees of mom_io_file::get_file_info_infra calls cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_io_file::get_file_info_infra get_file_info_infra [private/internal] mom_io_infra::get_file_info get_file_info mom_io_file::get_file_info_infra->mom_io_infra::get_file_info
Text view
subroutine get_file_fields_infra(handle, fields)

Return the field metadata associated with a MOM framework file

Parameters
  • handle [inout]

    Handle for a file that is open for I/O

  • fields [inout]

    Field-type descriptions of all of the variables in a file.

Callees call graph
Callees of mom_io_file::get_file_fields_infra calls cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_io_file::get_file_fields_infra get_file_fields_infra [private/internal] mom_io_infra::get_field_atts get_field_atts mom_io_file::get_file_fields_infra->mom_io_infra::get_field_atts mom_io_infra::get_file_fields get_file_fields mom_io_file::get_file_fields_infra->mom_io_infra::get_file_fields
Text view
subroutine get_file_times_infra(handle, time_values, ntime)

Get time levels of a MOM framework file

Parameters
  • handle [in]

    Handle for a file that is open for I/O

  • time_values [inout]

    The real times for the records in file.

  • ntime [out]

    The number of time levels in the file

Callees call graph
Callees of mom_io_file::get_file_times_infra calls cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_io_file::get_file_times_infra get_file_times_infra [private/internal] mom_io_infra::get_file_times get_file_times mom_io_file::get_file_times_infra->mom_io_infra::get_file_times
Text view
subroutine get_field_atts_infra(handle, field, name, units, longname, checksum)

Get attributes from a field

Parameters
  • handle [in]

    File where field is stored

  • field [in]

    The field to extract information from

  • name [out]

    The variable name

  • units [out]

    The units of the variable

  • longname [out]

    The long name of the variable

  • checksum [out]

    The checksums of the variable in a file

Callees call graph
Callees of mom_io_file::get_field_atts_infra calls cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_io_file::get_field_atts_infra get_field_atts_infra [private/internal] mom_io_infra::get_field_atts get_field_atts mom_io_file::get_field_atts_infra->mom_io_infra::get_field_atts
Text view
subroutine read_field_chksum_infra(handle, field, chksum, valid_chksum)

Interface to read_field_chksum

Parameters
  • handle [in]

    File where field is stored

  • field [in]

    The field whose checksum attribute is to be read

  • chksum [out]

    The checksum for the field.

  • valid_chksum [out]

    If true, chksum has been successfully read

Callees call graph
Callees of mom_io_file::read_field_chksum_infra calls cluster_mom_io_file MOM_io_file cluster_mom_io_infra MOM_io_infra mom_io_file::read_field_chksum_infra read_field_chksum_infra [private/internal] mom_io_infra::read_field_chksum read_field_chksum mom_io_file::read_field_chksum_infra->mom_io_infra::read_field_chksum
Text view
subroutine get_file_fieldtypes(handle, fields)

Get the native (fieldtype) fields of a MOM framework file

Callees call graph
Callees of mom_io_file::get_file_fieldtypes calls cluster_mom_error_handler MOM_error_handler cluster_mom_io_file MOM_io_file mom_error_handler::mom_error MOM_error mom_io_file::get_file_fieldtypes get_file_fieldtypes [private/internal] mom_io_file::get_file_fieldtypes->mom_error_handler::mom_error
Text view
subroutine open_file_nc(handle, filename, action, MOM_domain, threading, fileset)

Open a MOM netCDF file

Callees call graph
Callees of mom_io_file::open_file_nc calls cluster_mom_error_infra MOM_error_infra cluster_mom_hor_index MOM_hor_index cluster_mom_io_file MOM_io_file cluster_mom_netcdf MOM_netcdf mom_error_infra::is_root_pe is_root_pe mom_hor_index::hor_index_init hor_index_init mom_io_file::open_file_nc open_file_nc [private/internal] mom_io_file::open_file_nc->mom_error_infra::is_root_pe mom_io_file::open_file_nc->mom_hor_index::hor_index_init mom_netcdf::open_netcdf_file open_netcdf_file mom_io_file::open_file_nc->mom_netcdf::open_netcdf_file
Text view
subroutine close_file_nc(handle)

Close a MOM netCDF file

Callees call graph
Callees of mom_io_file::close_file_nc calls cluster_mom_error_infra MOM_error_infra cluster_mom_io_file MOM_io_file cluster_mom_netcdf MOM_netcdf mom_error_infra::is_root_pe is_root_pe mom_io_file::close_file_nc close_file_nc [private/internal] mom_io_file::close_file_nc->mom_error_infra::is_root_pe mom_netcdf::close_netcdf_file close_netcdf_file mom_io_file::close_file_nc->mom_netcdf::close_netcdf_file
Text view
subroutine flush_file_nc(handle)

Flush the buffer of a MOM netCDF file

Callees call graph
Callees of mom_io_file::flush_file_nc calls cluster_mom_error_infra MOM_error_infra cluster_mom_io_file MOM_io_file cluster_mom_netcdf MOM_netcdf mom_error_infra::is_root_pe is_root_pe mom_io_file::flush_file_nc flush_file_nc [private/internal] mom_io_file::flush_file_nc->mom_error_infra::is_root_pe mom_netcdf::flush_netcdf_file flush_netcdf_file mom_io_file::flush_file_nc->mom_netcdf::flush_netcdf_file
Text view
function register_axis_nc(handle, label, units, longname, cartesian, sense, domain, data, edge_axis, calendar) result(axis)

Register an axis to the MOM netcdf file

Parameters
  • handle [inout]

    Handle for a netCDF file that is open for writing

  • label [in]

    The name in the file of this axis

  • units [in]

    The units of this axis

  • longname [in]

    The long description of this axis

  • cartesian [in]

    A variable indicating which direction this axis corresponds with. Valid values include 'X', 'Y', 'Z', 'T', and 'N' for none.

  • sense [in]

    This is 1 for axes whose values increase upward, or -1 if they increase downward.

  • domain [in]

    The domain decomposion for this axis

  • data [in]

    The coordinate values of the points on this axis

  • edge_axis [in]

    If true, this axis marks an edge of the tracer cells

  • calendar [in]

    The name of the calendar used with a time axis

Callees call graph
Callees of mom_io_file::register_axis_nc calls cluster_mom_error_infra MOM_error_infra cluster_mom_io_file MOM_io_file cluster_mom_netcdf MOM_netcdf mom_error_infra::is_root_pe is_root_pe mom_io_file::register_axis_nc register_axis_nc [private/internal] mom_io_file::register_axis_nc->mom_error_infra::is_root_pe mom_netcdf::register_netcdf_axis register_netcdf_axis mom_io_file::register_axis_nc->mom_netcdf::register_netcdf_axis
Text view
function register_field_nc(handle, axes, label, units, longname, pack, standard_name, checksum, conversion) result(field)

Register a field to the MOM netcdf file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • axes [in]

    Handles for the axis used for this variable

  • label [in]

    The name in the file of this variable

  • units [in]

    The units of this variable

  • longname [in]

    The long description of this variable

  • pack [in]

    A precision reduction factor with which the variable. The default, 1, has no reduction, but 2 is not uncommon.

  • standard_name [in]

    The standard (e.g., CMOR) name for this variable

  • checksum [in]

    Checksum values that can be used to verify reads.

  • conversion [in]

    A factor to use to rescale the field before output [a A-1 ~> 1]

Callees call graph
Callees of mom_io_file::register_field_nc calls cluster_mom_error_infra MOM_error_infra cluster_mom_io_file MOM_io_file cluster_mom_netcdf MOM_netcdf mom_error_infra::is_root_pe is_root_pe mom_io_file::register_field_nc register_field_nc [private/internal] mom_io_file::register_field_nc->mom_error_infra::is_root_pe mom_netcdf::register_netcdf_field register_netcdf_field mom_io_file::register_field_nc->mom_netcdf::register_netcdf_field
Text view
subroutine write_attribute_nc(handle, name, attribute)

Write global metadata to the MOM netcdf file

Parameters
  • handle [in]

    Handle for a file that is open for writing

  • name [in]

    The name in the file of this global attribute

  • attribute [in]

    The value of this attribute

Callees call graph
Callees of mom_io_file::write_attribute_nc calls cluster_mom_error_infra MOM_error_infra cluster_mom_io_file MOM_io_file cluster_mom_netcdf MOM_netcdf mom_error_infra::is_root_pe is_root_pe mom_io_file::write_attribute_nc write_attribute_nc [private/internal] mom_io_file::write_attribute_nc->mom_error_infra::is_root_pe mom_netcdf::write_netcdf_attribute write_netcdf_attribute mom_io_file::write_attribute_nc->mom_netcdf::write_netcdf_attribute
Text view
subroutine write_field_4d_nc(handle, field_md, MOM_domain, field, tstamp, tile_count, fill_value)

Write a 4D field to the MOM netcdf file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • field_md [in]

    Field type with metadata

  • MOM_domain [in]

    The MOM_Domain that describes the decomposition

  • field [inout]

    Field to write

  • tstamp [in]

    Model time of this field

  • tile_count [in]

    PEs per tile (default: 1)

  • fill_value [in]

    Missing data fill value

Callees call graph
Callees of mom_io_file::write_field_4d_nc calls cluster_mom_error_infra MOM_error_infra cluster_mom_io_file MOM_io_file cluster_mom_netcdf MOM_netcdf mom_error_infra::is_root_pe is_root_pe mom_io_file::write_field_4d_nc write_field_4d_nc [private/internal] mom_io_file::write_field_4d_nc->mom_error_infra::is_root_pe mom_netcdf::interface::write_netcdf_field write_netcdf_field (interface) mom_io_file::write_field_4d_nc->mom_netcdf::interface::write_netcdf_field
Text view
subroutine write_field_3d_nc(handle, field_md, MOM_domain, field, tstamp, tile_count, fill_value)

Write a 3D field to the MOM netcdf file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • field_md [in]

    Field type with metadata

  • MOM_domain [in]

    The MOM_Domain that describes the decomposition

  • field [inout]

    Field to write

  • tstamp [in]

    Model time of this field

  • tile_count [in]

    PEs per tile (default: 1)

  • fill_value [in]

    Missing data fill value

Callees call graph
Callees of mom_io_file::write_field_3d_nc calls cluster_mom_error_infra MOM_error_infra cluster_mom_io_file MOM_io_file cluster_mom_netcdf MOM_netcdf mom_error_infra::is_root_pe is_root_pe mom_io_file::write_field_3d_nc write_field_3d_nc [private/internal] mom_io_file::write_field_3d_nc->mom_error_infra::is_root_pe mom_netcdf::interface::write_netcdf_field write_netcdf_field (interface) mom_io_file::write_field_3d_nc->mom_netcdf::interface::write_netcdf_field
Text view
subroutine write_field_2d_nc(handle, field_md, MOM_domain, field, tstamp, tile_count, fill_value)

Write a 2D field to the MOM netcdf file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • field_md [in]

    Field type with metadata

  • MOM_domain [in]

    The MOM_Domain that describes the decomposition

  • field [inout]

    Field to write

  • tstamp [in]

    Model time of this field

  • tile_count [in]

    PEs per tile (default: 1)

  • fill_value [in]

    Missing data fill value

Callees call graph
Callees of mom_io_file::write_field_2d_nc calls cluster_mom_error_infra MOM_error_infra cluster_mom_io_file MOM_io_file cluster_mom_netcdf MOM_netcdf mom_error_infra::is_root_pe is_root_pe mom_io_file::write_field_2d_nc write_field_2d_nc [private/internal] mom_io_file::write_field_2d_nc->mom_error_infra::is_root_pe mom_netcdf::interface::write_netcdf_field write_netcdf_field (interface) mom_io_file::write_field_2d_nc->mom_netcdf::interface::write_netcdf_field
Text view
subroutine write_field_1d_nc(handle, field_md, field, tstamp)

Write a 1D field to the MOM netcdf file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • field_md [in]

    Field type with metadata

  • field [in]

    Field to write

  • tstamp [in]

    Model time of this field

Callees call graph
Callees of mom_io_file::write_field_1d_nc calls cluster_mom_error_infra MOM_error_infra cluster_mom_io_file MOM_io_file cluster_mom_netcdf MOM_netcdf mom_error_infra::is_root_pe is_root_pe mom_io_file::write_field_1d_nc write_field_1d_nc [private/internal] mom_io_file::write_field_1d_nc->mom_error_infra::is_root_pe mom_netcdf::interface::write_netcdf_field write_netcdf_field (interface) mom_io_file::write_field_1d_nc->mom_netcdf::interface::write_netcdf_field
Text view
subroutine write_field_0d_nc(handle, field_md, field, tstamp)

Write a 0D field to the MOM netcdf file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • field_md [in]

    Field type with metadata

  • field [in]

    Field to write

  • tstamp [in]

    Model time of this field

Callees call graph
Callees of mom_io_file::write_field_0d_nc calls cluster_mom_error_infra MOM_error_infra cluster_mom_io_file MOM_io_file cluster_mom_netcdf MOM_netcdf mom_error_infra::is_root_pe is_root_pe mom_io_file::write_field_0d_nc write_field_0d_nc [private/internal] mom_io_file::write_field_0d_nc->mom_error_infra::is_root_pe mom_netcdf::interface::write_netcdf_field write_netcdf_field (interface) mom_io_file::write_field_0d_nc->mom_netcdf::interface::write_netcdf_field
Text view
subroutine write_field_axis_nc(handle, axis)

Write an axis field to the MOM netcdf file

Parameters
  • handle [inout]

    Handle for a file that is open for writing

  • axis [in]

    An axis type variable with information to write

Callees call graph
Callees of mom_io_file::write_field_axis_nc calls cluster_mom_error_infra MOM_error_infra cluster_mom_io_file MOM_io_file cluster_mom_netcdf MOM_netcdf mom_error_infra::is_root_pe is_root_pe mom_io_file::write_field_axis_nc write_field_axis_nc [private/internal] mom_io_file::write_field_axis_nc->mom_error_infra::is_root_pe mom_netcdf::write_netcdf_axis write_netcdf_axis mom_io_file::write_field_axis_nc->mom_netcdf::write_netcdf_axis
Text view
logical function file_is_open_nc(handle)

True if the framework file has been opened

Parameters
  • handle [in]

    Handle to a file to inquire about

subroutine get_file_info_nc(handle, ndim, nvar, ntime)

Return number of dimensions, variables, or time levels in a MOM netcdf file

Parameters
  • handle [in]

    Handle for a file that is open for I/O

  • ndim [out]

    The number of dimensions in the file

  • nvar [out]

    The number of variables in the file

  • ntime [out]

    The number of time levels in the file

Callees call graph
Callees of mom_io_file::get_file_info_nc calls cluster_mom_error_infra MOM_error_infra cluster_mom_io_file MOM_io_file cluster_mom_netcdf MOM_netcdf mom_error_infra::is_root_pe is_root_pe mom_io_file::get_file_info_nc get_file_info_nc [private/internal] mom_io_file::get_file_info_nc->mom_error_infra::is_root_pe mom_netcdf::get_netcdf_size get_netcdf_size mom_io_file::get_file_info_nc->mom_netcdf::get_netcdf_size
Text view
subroutine update_file_contents_nc(handle)

Update the axes and fields descriptors of a MOM netCDF file

Parameters
  • handle [inout]

    Handle for a file that is open for I/O

Callees call graph
Callees of mom_io_file::update_file_contents_nc calls cluster_mom_error_infra MOM_error_infra cluster_mom_io_file MOM_io_file cluster_mom_netcdf MOM_netcdf mom_error_infra::is_root_pe is_root_pe mom_io_file::update_file_contents_nc update_file_contents_nc [private/internal] mom_io_file::update_file_contents_nc->mom_error_infra::is_root_pe mom_netcdf::get_netcdf_fields get_netcdf_fields mom_io_file::update_file_contents_nc->mom_netcdf::get_netcdf_fields
Text view
subroutine get_file_fields_nc(handle, fields)

Return the field descriptors of a MOM netCDF file

Parameters
  • handle [inout]

    Handle for a file that is open for I/O

  • fields [inout]

    Field-type descriptions of all of the variables in a file.

Callees call graph
Callees of mom_io_file::get_file_fields_nc calls cluster_mom_error_infra MOM_error_infra cluster_mom_io_file MOM_io_file mom_error_infra::is_root_pe is_root_pe mom_io_file::get_file_fields_nc get_file_fields_nc [private/internal] mom_io_file::get_file_fields_nc->mom_error_infra::is_root_pe
Text view
subroutine get_field_atts_nc(handle, field, name, units, longname, checksum)

Get attributes from a netCDF field

Parameters
  • handle [in]

    File where field is stored

  • field [in]

    The field to extract information from

  • name [out]

    The variable name

  • units [out]

    The units of the variable

  • longname [out]

    The long name of the variable

  • checksum [out]

    The checksums of the variable in a file

Callees call graph
Callees of mom_io_file::get_field_atts_nc calls cluster_mom_error_handler MOM_error_handler cluster_mom_io_file MOM_io_file mom_error_handler::mom_error MOM_error mom_io_file::get_field_atts_nc get_field_atts_nc [private/internal] mom_io_file::get_field_atts_nc->mom_error_handler::mom_error
Text view
subroutine read_field_chksum_nc(handle, field, chksum, valid_chksum)

Interface to read_field_chksum

Parameters
  • handle [in]

    File where field is stored

  • field [in]

    The field whose checksum attribute is to be read

  • chksum [out]

    The checksum for the field.

  • valid_chksum [out]

    If true, chksum has been successfully read

Callees call graph
Callees of mom_io_file::read_field_chksum_nc calls cluster_mom_error_handler MOM_error_handler cluster_mom_io_file MOM_io_file mom_error_handler::mom_error MOM_error mom_io_file::read_field_chksum_nc read_field_chksum_nc [private/internal] mom_io_file::read_field_chksum_nc->mom_error_handler::mom_error
Text view
subroutine get_field_nc(handle, label, values, rescale)

Read the values of a netCDF field into an array that might have halos

Parameters
  • handle [in]

    Handle of netCDF file to be read

  • label [in]

    Field variable name

  • values [inout]

    Field values read from the file. It would be intent(out) but for the need to preserve any initialized values in the halo regions.

  • rescale [in]

    A multiplicative rescaling factor for the values that are read. Omitting this is the same as setting it to 1.

Callees call graph
Callees of mom_io_file::get_field_nc calls cluster_mom_error_handler MOM_error_handler cluster_mom_io_file MOM_io_file cluster_mom_netcdf MOM_netcdf mom_error_handler::mom_error MOM_error mom_io_file::get_field_nc get_field_nc [private/internal] mom_io_file::get_field_nc->mom_error_handler::mom_error mom_netcdf::get_netcdf_filename get_netcdf_filename mom_io_file::get_field_nc->mom_netcdf::get_netcdf_filename mom_netcdf::read_netcdf_field read_netcdf_field mom_io_file::get_field_nc->mom_netcdf::read_netcdf_field
Text view
API generated with Flint · Rendered from reStructuredText