Debian Codegraph @

commissioning/log2cases/etclog_to_testcases.txt

raw
1 This document describes the procedure to go from an ETC log file
2 containing (py)synphot commands for a single instrument's set of
3 regression tests to a .py file containing defined testcases.
4
5 ORIGINALLY:
6
7 - Log files were received from Donald in Spring 08; thermback cases came in a
8 separate file
9 - They were hand-parsed to replace the CDBS specification
10 - They were further processed by gencases.py to produce .py files
11
12 Command line procedure:
13 python gencases.py acs_etc_cases.txt
14
15 produced:
16 acs_etc_cases.py
17
18 OVER TIME:
19 - gencases.py was made smart enough to omit duplicate cases without
20 renaming anything by constructing a dictionary keyed by (task,obsmode,spectrum) - support for the "subset" flag was added
21
22 Command line procedure:
23 python gencases.py acs_etc_cases.txt acs_etc_cases_subset.txt
24
25 produced:
26 acs_etc_cases.py
27
28
29 THEN we tried something that didn't work and was abandoned (r705-710)
30
31 CURRENTLY (committed with r716-717):
32
33 - New log files were received. These included the ETC IDs prior to the
34 related set of (py)synphot commands for each id. Also, the syntax
35 was different: field separators were different; some CALCSPEC cases
36 were known to have been removed; all THERMBACK cases were mixed in
37 with the other commands.
38
39 - A new script, parselog.py, was written to handle the
40 pre-processing. It produced a dictionary containing the
41 (task,obsmode,spectrum):etcid mapping, which was pickled.
42
43 - gencases.py was made to read the pickled dictionary if provided, and
44 write out the etcid as an additional attribute of the test case. A
45 value of "None" is given if no etcid exists for this case; the whole
46 list is written out if there are multiple etcids for this case.
47
48
49
50 Separate scripts were written for each of the instruments, along with cleanup
51 scripts and a wrapper for the whole thing. This set of scripts,
52 together with the new log files, have been placed in the log2cases
53 subdirectory of the commissioning directory.
54
55 The procedure to run these scripts is:
56 cd log2cases
57 process_all.csh > process_all.log
58 #.....does the actual work; statistics reported to the log file
59 cleanup_all.csh: removes all files in the log2cases directory
60 **except** process_all.log. It does *not* remove the newly generated
61 test cases in the parent directory.
62