DirectorySpool
DirectorySpool(
base_path = .,
index_path = None,
preferred_format = None,
select_kwargs = None,
merge_kwargs = None,
)
A spool for interacting with DAS files on disk.
FileSpool creates and index of all files then allows for simple querying and bulk processing of the files.
Parameters
Parameter | Description |
---|---|
base_path | The path to the directory to index. |
index_path |
The path to the index file containing the contents of the directory. By default it will be created in the top-level of the data directory. |
preferred_format |
A string to specify the format of the data. Specifying this parameter will save time in indexing. |
select_kwargs | Dict of keyword arguments to restrict output contents. |
Methods
Name | Description |
---|---|
chunk | Chunk the data in the spool along specified dimension. |
concatenate | Concatenate the patches together. |
get_contents | Get a dataframe of the spool contents. |
map | Map a function of all the contents of the spool. |
new_from_df | Create a new instance from dataframes. |
select | Sub-select parts of the spool. |
sort | Sort the Spool based on a specific attribute. |
split | Yield sub-patches based on specified parameters. |
stack_patches | Stack (add) all patches compatible with first patch together. |
update | Updates the contents of the spool, return the updated spool. |