COMPS.Data.AssetManager module#

COMPS.Data.AssetManager.retrieve_asset_files(asset_files, as_zip=False)[source]#
COMPS.Data.AssetManager.retrieve_output_file_info(entity_type, entity_id, paths, job=None)[source]#
COMPS.Data.AssetManager.retrieve_output_files_from_info(entity_type, entity_id, metadata, job=None, as_zip=False)[source]#
COMPS.Data.AssetManager.retrieve_partial_output_file_from_info(metadata, startbyte, endbyte=None, actualrange=None)[source]#

Retrieve part of an output file from a Simulation or WorkItem.

Parameters:
  • metadata – An OutputFileMetadata object representing the output files to retrieve; this is likely obtained by calling the retrieve_output_file_info() method on Simulation or WorkItem.

  • startbyte – An integer representing the first byte in the request range, or if negative, the number of bytes at the end of the file to return (in which case, endbyte must be None).

  • endbyte – An integer representing the last byte in the request range. If this value is None and startbyte is positive, this represents the end of the file.

  • actualrange – An optional list argument which, if passed, will contain the start byte, end byte, and total file-size upon return. This is useful if requesting “the last N bytes in the file” or “from byte N to the end” in order to know the exact bytes which were returned.

Returns:

A byte-array of the partial output file retrieved.

COMPS.Data.AssetManager.upload_large_asset(checksum, datastream, status_callback=None)[source]#
class COMPS.Data.AssetManager.EntityType(value)[source]#

Bases: Enum

An enumeration.

Simulations = 0#
WorkItems = 1#