traveler.core.omx.OMX.change_atom_type#

OMX.change_atom_type(name, dtype, matrix=True, lookup=True, require_smaller=True)[source]#

Change the data type of a named matrix or lookup.

Parameters:
  • name (str) – Dataset name to convert.

  • dtype (numpy.dtype or str) – Target data type.

  • matrix (bool, optional) – Whether to search the matrix datasets.

  • lookup (bool, optional) – Whether to search the lookup datasets.

  • require_smaller (bool, optional) – If True, retain the original dataset unless conversion reduces its uncompressed byte size.

Warns:

UserWarning – If require_smaller is true and conversion does not reduce size.