Class GroupFiles
Object
org.anchoranalysis.bean.AnchorBean<org.anchoranalysis.io.input.bean.InputManager<T>>
org.anchoranalysis.io.input.bean.InputManager<T>
org.anchoranalysis.image.io.bean.stack.reader.InputManagerWithStackReader<org.anchoranalysis.image.io.channel.input.NamedChannelsInput>
org.anchoranalysis.plugin.io.bean.file.group.GroupFiles
public class GroupFiles
extends org.anchoranalysis.image.io.bean.stack.reader.InputManagerWithStackReader<org.anchoranalysis.image.io.channel.input.NamedChannelsInput>
An
InputManagerWithStackReader that can unify separate images in separate files to form a
single Stack.
A time-series of Stacks may also be formed.
The criteria on how to unify is defined by a pattern in the file path (via regular expressions).
A regular expression is applied on the set of input file paths, to identify one or more groups:
- One group is the image key (something that uniquely identifies each image).
- One group is the slice-identifier (identifies the z slice, must be positive integer.
- One group is the channel-identifier (identifies the channel, must be positive integer).
For each image key, an image is loaded using the slice and channel-identifiers.
Integer numbers are simply loaded in ascending numerical order. So gaps are allowed, and starting numbers are irrelevant.
It is more powerful than MultiFileReader, which expects only one image per directory.
This class allows multiple images per directory and only performs a single glob for filenames.
- Author:
- Owen Feehan
-
Constructor Summary
Constructors Constructor Description GroupFiles() -
Method Summary
Modifier and Type Method Description CheckParsedFilePathBaggetCheckParsedFilePathBag()Imposes a condition on each parsed-file-path-bag which must be-fulfilled if a file is to be included.NamedFilesgetFileInput()org.anchoranalysis.image.io.bean.channel.ChannelMapCreatorgetImgChannelMapCreator()org.anchoranalysis.io.input.bean.namer.FileNamergetNamer()FilePathParsergetPathParser()org.anchoranalysis.io.input.InputsWithDirectory<org.anchoranalysis.image.io.channel.input.NamedChannelsInput>inputs(org.anchoranalysis.io.input.bean.InputManagerParameters parameters)booleanisRequireAllFilesMatch()voidsetCheckParsedFilePathBag(CheckParsedFilePathBag checkParsedFilePathBag)Imposes a condition on each parsed-file-path-bag which must be-fulfilled if a file is to be included.voidsetFileInput(NamedFiles fileInput)voidsetImgChannelMapCreator(org.anchoranalysis.image.io.bean.channel.ChannelMapCreator imgChannelMapCreator)voidsetNamer(org.anchoranalysis.io.input.bean.namer.FileNamer namer)voidsetPathParser(FilePathParser pathParser)voidsetRequireAllFilesMatch(boolean requireAllFilesMatch)Methods inherited from class org.anchoranalysis.image.io.bean.stack.reader.InputManagerWithStackReader
getStackReader, setStackReader
-
Constructor Details
-
GroupFiles
public GroupFiles()
-
-
Method Details
-
inputs
public org.anchoranalysis.io.input.InputsWithDirectory<org.anchoranalysis.image.io.channel.input.NamedChannelsInput> inputs(org.anchoranalysis.io.input.bean.InputManagerParameters parameters) throws org.anchoranalysis.io.input.InputReadFailedException- Specified by:
inputsin classorg.anchoranalysis.io.input.bean.InputManager<org.anchoranalysis.image.io.channel.input.NamedChannelsInput>- Throws:
org.anchoranalysis.io.input.InputReadFailedException
-
getFileInput
-
setFileInput
-
getPathParser
-
setPathParser
-
isRequireAllFilesMatch
public boolean isRequireAllFilesMatch() -
setRequireAllFilesMatch
public void setRequireAllFilesMatch(boolean requireAllFilesMatch) -
getImgChannelMapCreator
public org.anchoranalysis.image.io.bean.channel.ChannelMapCreator getImgChannelMapCreator() -
setImgChannelMapCreator
public void setImgChannelMapCreator(org.anchoranalysis.image.io.bean.channel.ChannelMapCreator imgChannelMapCreator) -
getNamer
public org.anchoranalysis.io.input.bean.namer.FileNamer getNamer() -
setNamer
public void setNamer(org.anchoranalysis.io.input.bean.namer.FileNamer namer) -
getCheckParsedFilePathBag
Imposes a condition on each parsed-file-path-bag which must be-fulfilled if a file is to be included. -
setCheckParsedFilePathBag
Imposes a condition on each parsed-file-path-bag which must be-fulfilled if a file is to be included.
-