Main Content

openInParallelToAppend

Open destination on parallel worker to append blocks

    Description

    openInParallelToAppend(obj, destination) opens the location specified by destination on a parallel worker in preparation for appending blocks. This function is only invoked when the UseParallel parameter of blockedImage/apply is set to true. openToWrite is guaranteed to have been called once on a corresponding destination value earlier on a separate instance of the adapter in the main MATLAB session. A copy of the adapter is made for each parallel worker and openInParallelToAppend is called once before subsequent setIOBlock. The adapter uses the AlternateFileSystemRoots property of the blocked image to resolve destination on the worker.

    An adapter which implements this method must be able to support multiple adapter instances (one on each parallel worker) appending blocks to the same destination simultaneously. This is usually handled by writing independent files for each block in a single destination folder.

    Input Arguments

    collapse all

    Adapter object, specified as an instance of an adapter class that is subclassed from the images.blocked.Adapter class.

    Location, specified as a string scalar or char vector.

    Data Types: char | string

    Introduced in R2021a