Skip to main content

get_stream

Get a stream of data from a remote location. This is useful for downloading streaming data from a remote location.

def get_stream(
path: str,
chunk_size: int = 10 * 2**20,
kwargs: kwargs
) - > AsyncGenerator[bytes, None]

Get a stream of data from a remote location. This is useful for downloading streaming data from a remote location.

Parameters

NameTypeDescription
pathstrPath to the remote location where the data will be downloaded.
chunk_sizeint = 10 * 2**20Size of each chunk to be read from the file.
kwargskwargsAdditional arguments to be passed to the underlying filesystem.

Returns

TypeDescription
AsyncGenerator[bytes, None]An async iterator that yields chunks of bytes.