[Swift-user] Output Files, ReadData and Order of Execution

Carolyn Phillips cphillips at mcs.anl.gov
Fri Aug 31 18:55:17 CDT 2012


So I execute an atomic procedure to generate a datafile, and then next I want to do something with that data file.  However, my program is trying to do something with the datafile before it has been written to.  So something with order of execution is not working.  I think the problem is that the name of my file exists, but the file itself does not yet, but execution proceeds anyway!

Here are my lines

type pointfile {
unlabeleddata points;
errorlog error;
}

    # Generate Parameters
    pointfile np <simple_mapper;prefix="mypoints.",suffix=".dat">; 
    np = generatepoints(config,labeledpoints, "uniform", 50);
    
    int checkforerror = readData(@np.error);

This gives an error :
mypoints.error.dat (No such file or directory)

If I comment out the last line.. all the files show up in the directory.  (e.g. mypoints.points.dat and mypoints.error.dat) )  and if forget to remove the .dat files from a prior run, it also runs fine!

How do you fix a problem like that?




More information about the Swift-user mailing list