openmmtools.storage.iodrivers.NetCDFIODriver

class openmmtools.storage.iodrivers.NetCDFIODriver(file_name, access_mode=None)[source]

Driver to handle all NetCDF IO operations, variable creation, and other operations. Can be extended to add new or modified type codecs

Attributes:
access_mode

Access mode of file on disk

file_name

File name of on hard drive

Methods

add_metadata(name, value[, path])

Add metadata to self on disk, extra bits of information that can be used for flags or other variables

check_infinite_dimension([name])

Check that the arbitrary infinite dimension exists on file and create it if not.

check_iterable_dimension([length])

Check that the dimension of appropriate size for a given iterable exists on file and create it if not

check_scalar_dimension()

Check that the scalar dimension exists on file and create it if not

close()

Instruct how to safely close down the file.

create_storage_variable(path, type_key)

Create a new variable on the disk and at the path location and store it as the given type.

generate_infinite_dimension()

Generate a new infinite dimension and return the name of that dimension

get_directory(path[, create])

Get the group (directory) on the NetCDF file, create the full path if not present

get_storage_variable(path)

Get a variable IO object from disk at path.

set_codec(type_key, codec)

Add new codifier to the specific driver class.

sync

__init__(file_name, access_mode=None)[source]

Methods

__init__(file_name[, access_mode])

add_metadata(name, value[, path])

Add metadata to self on disk, extra bits of information that can be used for flags or other variables

check_infinite_dimension([name])

Check that the arbitrary infinite dimension exists on file and create it if not.

check_iterable_dimension([length])

Check that the dimension of appropriate size for a given iterable exists on file and create it if not

check_scalar_dimension()

Check that the scalar dimension exists on file and create it if not

close()

Instruct how to safely close down the file.

create_storage_variable(path, type_key)

Create a new variable on the disk and at the path location and store it as the given type.

generate_infinite_dimension()

Generate a new infinite dimension and return the name of that dimension

get_directory(path[, create])

Get the group (directory) on the NetCDF file, create the full path if not present

get_storage_variable(path)

Get a variable IO object from disk at path.

set_codec(type_key, codec)

Add new codifier to the specific driver class.

sync()

Attributes

access_mode

Access mode of file on disk

file_name

File name of on hard drive