omni.nvcf.core Functions

Functions Summary:

api_call

Single call to run an NVCF function end-to-end.

api_call_async

Single call to run an NVCF function end-to-end.

compress_image_dict

Compress and base 64 encode a dictionary of images to reduce upload data payload.

compress_image_list

Compress and base 64 encode a list of images to reduce upload data payload.

create_asset

Create an NVCF asset named `asset_name` of the desired content type.

create_asset_async

Create an NVCF asset named `asset_name` of the desired content type.

decode_payload

Decode and uncompress a base 64 encoded numpy npz archive.

format_request

Format input parameters for an NVCF function to produce request body and and request headers.

get_token

Given an SSA client and secret, request and return a JWT authorization token allowing calls to invoke NVCF functions.

get_token_async

Given an SSA client and secret, request and return a JWT authorization token allowing calls to invoke NVCF functions.

numpy_to_pil

Convert a numpy array to a PIL Image.

poll_response

Poll a pending NVCF request (status 202) until it is no longer pending.

prepare_image_asset

Helper to create and then upload asset data with an asset name. Provides the generated asset ID as output.

prepare_image_asset_async

Helper to create and then upload asset data with an asset name. Provides the generated asset ID as output.

unpack_zip_response

Retrieve and unpack an API call response that provides a reference to output assets.

unpack_zip_response_async

Retrieve and unpack an API call response that provides a reference to output assets.

upload_asset

Upload asset data of a content type to a named asset with associated URL.

upload_asset_async

Upload asset data of a content type to a named asset with associated URL.