reassemble

function of dascore.proc.tile_apply source

reassemble(
    patch: Patch ,
    taper: Any = None,
)-> ‘PatchType’

Blend a stack of tiles back into the patch they were cut from.

The inverse of tile_apply in "stack" mode: each tile is multiplied by a taper with complementary ramps and added where its {dim}_start says it came from, so a stack which was not changed returns the original patch exactly.

Parameters

Parameter Description
patch A patch tile_apply stacked.
taper The window whose edge the taper ramps take; see tile_apply. Hann
when not given. A stack cut with an analysis window is blended under
that window’s dual instead, and takes no taper.

Examples

import dascore as dc
patch = dc.get_example_patch()
tiles = patch.tile_apply(lambda x: x, mode="stack", time=0.2, samples=False)
assert tiles.reassemble().equals(patch, close=True)