This program generates the run script and .INN files required for batch processing using lithos. You must also generate a seed file containing the required lithos commands.
make_scriptF is a generic script maker for batch lithos processing tasks. You specify the set of landmarks to process in make_script.in and the sequence of commands to process in make_scriptF.seed.
make_scriptF generates the .INN files and run scripts to batch process the landmarks, and generates .OOT files and saves display files during processing for user inspection.
You should test the command sequence in lithos before running the script generated by make_scriptF.
make_script.in - Text file containing the names of landmarks to be processed.
make_scriptF.seed - Text file containing the lithos option commands intended during batch processing.
TESTFILES/ - Directory in which to store copies of LMRK_DISPLAY1.pgm (output by lithos) for each landmark.
TESTFILES1/ - Directory in which to store copies of tmpl.pgm (output by lithos) for each landmark.
lithos requires a number of directories and files. Refer to lithos for more information.
- run_script.b - Run script for batch processing.
.INN files - lithos command seed file for each landmark.
- rem_script.b - Script for removal of temporary files (working directory clean-up).
.OOT files - standard output from lithos for each landmark.
processed files outputs:
TESTFILES/ - A copy of LMRK_DISPLAY1.pgm (output by lithos) is saved for each landmark.
TESTFILES1/ - A copy of tmpl.pgm (output by lithos) is saved for each landmark.
SUMFILES/ - S/C and camera information are updated by lithos if image shifts occur.
LMKFILES/ - LMKFILES for each landmark are updated by lithos.
MAPFILES/ - MAPFILES for each landmark are updated by lithos.
Several information text and display files in the working directory are modified by lithos. Refer to the entries for those files for more information.
The make_scriptF.seed file must start with a set of commands which deal with the lithos Check for more images? y[n] option sequence.
The make_scriptF.seed file must end with the lithos quit command, q, and the end-of-file identifier, END.
You should test the make_scriptF.seed lithos command sequence before running the script generated by make_scriptF.
1. Create Input Files
Here is a sample make_script.in file (see that entry for further information):
EE0001 EE0002 EE0003 END
lithos expects a sequence of start and end commands which must be contained in the seed file before and after the processing commands.
Here is an annotated sample make_scriptF.seed file. The required start and end command sequences are explained below.
# Seed file to attach map to overlapping maps #start commands n <- don't check for more images n <- don't include a single image #processing commands o RECENT y 1 o RECENT n 3 y 1, 3, 5 w i RECENT n n v 1 u 1 o RECENT n 1 #end command q <- quit #end-of-file identifier END <- end-of-file
The .INN file starts with the command i: input landmark, and the landmark name. lithos then asks you whether to check for more images. The following samples show the prompts and responses for both 'y' and 'n' responses to this prompt:
Check for more images? y[n] n Include a single image? y[n] n
Check for more images? y[n] y Enter fractional width (0=center). .5 Reject invisibles? y[n] n
When you create the make_scriptF.seed file, you must start with a sequence that deals with this set of options. In the sample, the Start Commands lines are annotated to indicate these responses.
make_scriptF expects you to quit lithos on completion of each landmark. The make_scriptF.seed file must contain the quit command q on the second-to-last-line.
make_scriptF expects the seed file to end with the end-of-file identifier, END. Any commands following this will not be appended to the .INN file.
Use # at the beginning of any comment line you want to include. make_scriptF does not append these to the .INN file.
2. Run make_scriptF
make_scriptF generates a .INN file for each landmark listed in make_script.in.
Here is a sample .INN file for landmark EE0001.INN:
i EE0001 n n o RECENT y 1 o RECENT n 3 y 1, 3, 5 w i RECENT n n v 1 u 1 o RECENT n 1 q
The first two lines of the .INN file load the next landmark into lithos. The remainder of the .INN file lists the lithos commands contained in make_scriptF.seed.
make_scriptF also generates the run_script.b script, which looks like this:
rm -f EE0001.OOT /usr/local/bin/LITHOS < EE0001.INN > EE0001.OOT cp LMRK_DISPLAY1.pgm ./TESTFILES/EE0001.pgm cp tmpl.pgm ./TESTFILES1/EE0001.pgm rm -f EE0002.OOT /usr/local/bin/LITHOS < EE0002.INN > EE0002.OOT cp LMRK_DISPLAY1.pgm ./TESTFILES/EE0002.pgm cp tmpl.pgm ./TESTFILES1/EE0002.pgm rm -f EE0003.OOT /usr/local/bin/LITHOS < EE0003.INN > EE0003.OOT cp LMRK_DISPLAY1.pgm ./TESTFILES/EE0003.pgm cp tmpl.pgm ./TESTFILES1/EE0003.pgm
3. Execute the Run Script
Here is a sample command line for running run_script.b:
You can also run this in the background using this command line:
nohup sh run_script.b &
The lithos standard output for each image is captured in the .OOT files. The LMRKDISPLAY1.pgm and tmpl.pgm files output by lithos are copied once a landmark has been processed. These are stored under the landmark's name in TESTFILES/ and TESTFILES1/ respectively.
4. Quality Check the New Maplets
You must review the .OOT files to determine the success of the tiling process.
5. Clean Working Directory
You can use rem_script.b to clean out the directory of make_scriptF working files once tiling is complete and you have quality checked the resulting suite of maplets.
Here is a sample rem_script.b file:
rm -f *.INN rm -f *.OOT rm -f run_script*
(Compiled by DL)