argopy.utilities.Chunker

class Chunker(request: dict, chunks: str = 'auto', chunksize: dict = {})[source]

To chunk fetcher requests

__init__(request: dict, chunks: str = 'auto', chunksize: dict = {})[source]

Create a request Chunker

Allow to easily split an access point request into chunks

Parameters
request: dict

Access point request to be chunked. One of the following: {‘box’: [lon_min, lon_max, lat_min, lat_max, dpt_min, dpt_max, time_min, time_max]} {‘box’: [lon_min, lon_max, lat_min, lat_max, dpt_min, dpt_max]} {‘wmo’: [wmo1, wmo2, …], ‘cyc’: [0,1, …]}

chunks: ‘auto’ or dict

Dictionary with request access point as keys and number of chunks to create as values. Eg: {‘wmo’:10} will create a maximum of 10 chunks along WMOs.

chunksize: dict, optional

Dictionary with request access point as keys and chunk size as values (used as maximum values in ‘auto’ chunking). Eg: {‘wmo’: 5} will create chunks with as many as 5 WMOs each.

Methods

__init__(request[, chunks, chunksize])

Create a request Chunker

fit_transform()

Chunk a fetcher request

Attributes

default_chunksize