[Swift-devel] mappers on files that are inputs and outputs
Mihael Hategan
hategan at mcs.anl.gov
Wed May 16 10:29:02 CDT 2007
You should probably also add the input=true mapping parameter?
Mihael
On Wed, 2007-05-16 at 15:26 +0000, Ben Clifford wrote:
> Here's a code fragment:
>
> type volume {
> imagefile img;
> headerfile hdr;
> };
>
> volume atlas <simple_mapper;prefix="atlas">;
> atlas = softmean(slices);
>
> string directions[] = [ "x", "y", "z"];
>
> foreach direction in directions {
> giffile outputgif
> <single_file_mapper;file=@strcat("atlas-",direction,".gif")>;
> string option = @strcat("-",direction);
> outputgif = slice_to_gif(atlas, option, ".5");
> }
>
> When this is run as part of a workflow, there are no atlas.* files and the
> atlas = softmean(slices) line causes atlas.hdr and atlas.img files to be
> created and placed in my working directory, and also used in the
> subsequent slice_to_gif calls.
>
> If I prune the program in a text editor so that the altas = ... line is
> not called, and leave the atlas.hdr and atlas.img files in place in my
> current directory (so that the files are now input files, rather than
> intermediate files), I get this error:
>
> $ swift -debug -tc.file tc.data play.swift
> WARN - Failed to configure log file name
>
> Swift v0.1-dev
>
> RunID: mx49u8a36d1m0
> Execution failed:
> java.lang.RuntimeException: Data set initialization failed for
> true. Missing required field: img mapped to atlas
>
>
> I think its probably a desirable feature that the same mapping that maps
> ok for intermediate files to map for input files too.
>
More information about the Swift-devel
mailing list