[Swift-user] Re: simple_mapper on simple data types.

Allan Espinosa aespinosa at cs.uchicago.edu
Wed Mar 10 17:18:24 CST 2010


I did a quick hack of zero element arrays and it seemed to work

   Hdf4Eos before[] <filesys_mapper;location=getdir(by),
        prefix="MCD12Q1",pattern=getpattern(tile), suffix=".hdf">;
    trace(@filename(before[0]));

2010/3/10 Allan Espinosa <aespinosa at cs.uchicago.edu>:
> Hi,
>
> I'm getting this response from swift:
> /home/wilde/swift/src/stable/cog/modules/swift/dist/swift-svn/bin/swift
> -dryrun -runid test runchange.swift
>
> Swift svn swift-r3255 (swift modified locally) cog-r2723 (cog modified locally)
>
> RunID: test
> Progress:
> Execution failed:
>        java.lang.IllegalStateException: mapper.existing() returned a path
> ..A2001001.h29v08.005.2009342154532 that it cannot subsequently map
>
>
> Here's the script:
> type Hdf4Eos;
> type MapPng;
> type Hdf5;
>
> Hdf4Eos before <simple_mapper;prefix="MCD12Q1",pattern="*h29v08*",
>    suffix=".hdf">;
> trace(@filename(before));
>
> Here's the file that it was trying to map (for input later on).
> $ ls *.hdf
> MCD12Q1.A2001001.h29v08.005.2009342154532.hdf
>
> I haven't found a good reference for doing this as most of the
> examples in tests/language-behavior uses structs or arrays together
> with simple_mapper for output mapping
>
> thanks,
> -Allan



More information about the Swift-user mailing list