Caltech-IPAC / hiresprv

Keck HIRES PRV pipeline service access
4 stars 0 forks source link

KOA queries not returned sorted by date time #32

Closed bjfultn closed 4 years ago

bjfultn commented 4 years ago

Logsheets must be generated in order of monotonically increasing time, but KOA doesn't always return results in this way. The KOA query should be sorted by datetime before starting to download and number files.

bjfultn commented 4 years ago

20130802 is an example that seemed to come out in the wrong order for me. Here is what the logsheet ended up looking like.

                 HIRES Spectrograph Observing Log 
__________________________________________________________________________
Observer: Marcy,Isaacson Tape:j176 Telescope: KeckI
UT Date 02 08 2013        Chip: LincolnLab 4096x3, 15micron 
Windowing:   Cols: 4096        Rows: 2048 (binned)    Binning: 3r x 1c    
Ech: XXXXXXX  X-Dis: XXXXXXX   Slit: B5/C2 (0.86 x 3.5/14 arcsec)         
CAFRAW: 7        COFRAW: 70482   low gain     Filter: clear,KV370 out     
Red Collimator in.   --> FWHM=2.377 (used Th-Ar#2, 10sec, kv370 OUT)      
--------------------------------------------------------------------------
nn.fits   Object     I2   Mid-Time  Exp.   Comment                        
number    Name     (y/n)   (UT)     time                                  
1-1       wideflat     n   3:49:52     1  (03:49:53) C1   0k    
2         143761       y   5:24:18     8  (05:24:19) C2 259k  0.8"   
3         143761       y   5:25:11     9  (05:25:10) C2 275k  0.8"   
4         143761       y   5:26:02     8  (05:26:03) C2 277k  0.8"   
5         95735        y   5:30:46    71  (05:30:46) C2 253k  0.9"   
6             thar     n   3:03:57     2  (03:03:59) B1   0k    
7             thar     n   3:04:44     2  (03:04:46) B1   0k    
8           iodine     y   3:05:56     3  (03:05:58) B1   0k    
9           iodine     y   3:06:43     3  (03:06:45) B1   0k    
10          iodine     y   3:07:43     2  (03:07:45) B5   0k    
11          iodine     y   3:08:29     2  (03:08:31) B5   0k    
12        132142       y   5:33:25    71  (05:33:26) C2 252k  0.8"   
13        147506       y   5:36:38   156  (05:36:38) C2 251k  0.8"   
14        151288       y   5:43:06   107  (05:43:06) C2 252k  0.8"   
15        151288       y   5:45:33    97  (05:45:33) C2 250k  0.7"   
16        151288       y   5:47:55    99  (05:47:55) C2 251k  0.7"   
17        155358       y   5:50:20    43  (05:50:20) C2 254k  0.7"   
18-23     wideflat     n   3:16:34     1  (03:16:35) C1   0k    
24        158038       y   5:52:17    28  (05:52:17) C2 126k  0.7"   
25        HIP94931     y   5:57:06   229  (05:57:05) C2 250k  0.8"   
26        HIP94931     y   6:01:41   235  (06:01:41) C2 250k  0.8"   
27        HIP94931     y   6:06:18   231  (06:06:19) C2 250k  0.8"   
28-29     wideflat     n   3:18:04     1  (03:18:05) C1   0k    
30        K01120       n  13:32:17    90  (13:32:15) C2   4k  1.2"   
31        CK04184      n  13:40:56   713  (13:40:59) C2  10k  1.2"   
32-33     wideflat     n   3:19:35     1  (03:19:36) C1   0k    
34        CK03573      n  13:55:05   651  (13:55:03) C2  10k  1.1"   
35        CK04665      n  14:08:17   715  (14:08:31) C2  10k  1.1"   
36        CK04613      n  14:23:13   945  (14:23:26) C2  10k  1.2"   
37-48     wideflat     n   3:28:40     1  (03:28:41) C1   0k    
49        216259       y  14:34:54   148  (14:34:55) B5 250k  1.0"   
50        199305       y  14:40:51   233  (14:40:52) B5 250k  1.0"   
51        SN2013dy     n  14:46:53   300  (14:46:55) C2  11k  1.1"   
52        SN2013dy     n  14:52:37   300  (14:52:38) C2  11k  1.1"   
53        221354       y  14:57:13    34  (14:57:14) C2 250k  0.9"   
54        216520       y  14:59:47    83  (14:59:48) C2 251k  1.0"   
55        7924         y  15:02:17    58  (15:02:16) C2 254k  1.1"   
56        7924         y  15:03:56    54  (15:03:56) C2 254k  1.0"   
57        7924         y  15:05:33    54  (15:05:34) C2 254k  1.0"   
58        12051        y  15:08:20    40  (15:08:21) C2 253k  0.8"   
59        12051        y  15:09:47    43  (15:09:47) C2 255k  0.9"   
60        12051        y  15:11:14    42  (15:11:14) C2 256k  0.8"   
61-64     wideflat     n   3:31:42     1  (03:31:43) C1   0k    
65        16160        y  15:15:03    12  (15:15:04) C2 263k  0.8"   
66        14412        y  15:16:56    20  (15:16:57) C2 251k  0.8"   
67-76     wideflat     n   3:39:16     1  (03:39:17) C1   0k    
77        14412        y  15:17:59    21  (15:18:00) C2 255k  0.9"   
78        14412        y  15:19:03    20  (15:19:04) C2 254k  0.8"   
79        1205         y  15:21:12    50  (15:21:12) C2 127k  1.0"   
80        1461         y  15:23:05    28  (15:23:06) C2 257k  1.1"   
81        4628         y  15:24:50    14  (15:24:51) C2 255k  1.0"   
82        4628         y  15:25:47    13  (15:25:47) C2 257k  1.0"   
83        4628         y  15:26:45    15  (15:26:45) C2 267k  1.0"   
84          iodine     y  15:31:04     0  (15:31:05) B5   0k    
85            flat     y  15:32:00     3  (15:32:02) B1   0k    
86            thar     n  15:33:24     2  (15:33:26) B1   0k    
87            thar     n  15:34:11     1  (15:34:12) B5   0k    
88-94     wideflat     n   3:44:34     1  (03:44:35) C1   0k    
95           focus     n   2:06:00     0  (02:06:01) D5   0k    
96           focus     n   2:07:04    10  (02:07:10) D5   0k    
97           focus     n   2:22:37    10  (02:22:43) D5   0k    
98-103    wideflat     n   3:49:07     1  (03:49:08) C1   0k    
104          focus     n   2:52:10     0  (02:52:11) D5   0k    
105          focus     n   2:54:34    10  (02:54:40) D5   0k    
106           thar     n   3:00:04     1  (03:00:05) B5   0k    
107           thar     n   3:00:49     1  (03:00:50) B5   0k    
108       186427       y   8:21:10    16  (08:21:11) B5 258k  0.7"   
109       186427       y   8:22:11    17  (08:22:11) B5 256k  0.7"   
110       186427       y   8:23:13    17  (08:23:13) B5 262k  0.8"   
111       182488       y   8:24:56    19  (08:24:56) B5 262k  0.7"   
112       182488       y   8:26:01    20  (08:26:01) B5 262k  0.8"   
113       182488       y   8:27:04    20  (08:27:04) B5 261k  0.8"   
114       K00377       y   8:39:01  1236  (08:39:13) C2  15k  0.8"   
115       CK01241      y   9:00:59  1155  (09:00:59) C2  40k  0.8"   
116       LHS6343      n   9:20:00   179  (09:19:59) B5   5k  1.3"   
117       K00082       y   9:37:05  1594  (09:37:08) C2 125k  0.9"   
118       K00069       y   9:56:10   488  (09:56:10) C2 200k  0.9"   
119       K00069       y  10:05:09   509  (10:05:11) C2 200k  0.9"   
120       K00069       y  10:14:45   555  (10:14:47) C2 200k  1.0"   
121       K00116       y  10:41:04  2370  (10:40:47) C2  60k  0.9"   
122       K00148       y  11:15:25  1568  (11:15:23) C2  30k  0.9"   
123       K00305       y  11:52:00  2700  (11:52:06) C2  49k  1.0"   
124       HIP94931     y  12:19:04   262  (12:19:08) C2 251k  1.2"   
125       HIP94931     y  12:24:11   264  (12:24:15) C2 251k  1.2"   
126       HIP94931     y  12:29:24   273  (12:29:25) C2 250k  1.2"   
127   KIC007830637     n  12:41:45   959  (12:41:43) C2   7k  1.0"   
128     KIC6023859     n  12:53:52    60  (12:53:48) C2   0k    
129     KIC3830820     n  12:57:05    90  (12:56:47) C2   0k    
130   KIC006137704     n  13:05:06   731  (13:04:58) C2   7k  1.5"   
131     KIC9821078     n  13:16:14    45  (13:16:16) C2   0k    
132     KIC5871918     n  13:18:44    70  (13:18:40) C2   0k    
133     KIC2442084     n  13:20:52    60  (13:21:01) C2   0k    
134    KIC10979716     n  13:23:34    80  (13:23:31) C2   0k    
135     KIC9775253     n  13:27:02   180  (13:26:56) C2   0k    
136       gl699        y   6:14:19   425  (06:14:19) C2 250k  0.8"   
137       K00365       y   6:41:00  1521  (06:41:01) C2 200k  0.8"   
138       K01431       y   7:09:51  1783  (07:10:01) C2  30k  0.8"   
139       K00245       y   7:29:33   422  (07:29:29) C2 250k  0.8"   
140       K00245       y   7:37:08   407  (07:37:08) C2 250k  0.8"   
141       K00245       y   7:44:43   417  (07:44:44) C2 251k  0.8"   
142       K00041       y   8:00:38     0  (07:49:18) C2 200k  0.8"  Two midpts differ by 679 s
143       185144       y   8:13:31     5  (08:13:32) C2 293k  0.8"   
144       185144       y   8:14:21     4  (08:14:22) C2 287k  0.8"   
145       185144       y   8:15:12     5  (08:15:12) B5 283k  0.8"   
146       185144       y   8:16:01     5  (08:16:01) B5 270k  0.8"   
147       186408       y   8:17:43    14  (08:17:43) B5 260k  0.8"   
148       186408       y   8:18:42    13  (08:18:41) B5 268k  0.7"   
149       186408       y   8:19:39    14  (08:19:39) B5 264k  0.8"   
bjfultn commented 4 years ago

This has been fixed in the hiresprv code.