Changeset 33615
- Timestamp:
- Mar 28, 2012, 8:10:40 AM (14 years ago)
- Location:
- branches/eam_branches/ipp-20111122/Ohana/src/opihi
- Files:
-
- 1 added
- 10 edited
-
dvo/Makefile (modified) (2 diffs)
-
dvo/catlist.c (added)
-
dvo/dvo.c.in (modified) (1 diff)
-
dvo/dvo_client.c (modified) (1 diff)
-
dvo/gcat.c (modified) (1 diff)
-
dvo/hosts.c (modified) (1 diff)
-
dvo/init.c (modified) (4 diffs)
-
dvo/mextract.c (modified) (7 diffs)
-
dvo/region_list.c (modified) (1 diff)
-
dvo/skyregion.c (modified) (2 diffs)
-
lib.shell/parse.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/ipp-20111122/Ohana/src/opihi/dvo/Makefile
r33600 r33615 50 50 $(SRC)/fitsed.$(ARCH).o \ 51 51 $(SRC)/gcat.$(ARCH).o \ 52 $(SRC)/catlist.$(ARCH).o \ 52 53 $(SRC)/gimages.$(ARCH).o \ 53 54 $(SRC)/gstar.$(ARCH).o \ … … 72 73 $(SRC)/paverage.$(ARCH).o \ 73 74 $(SRC)/procks.$(ARCH).o \ 75 $(SRC)/remote.$(ARCH).o \ 74 76 $(SRC)/skycat.$(ARCH).o \ 75 77 $(SRC)/skycoverage.$(ARCH).o \ -
branches/eam_branches/ipp-20111122/Ohana/src/opihi/dvo/dvo.c.in
r33563 r33615 29 29 set_str_variable ("PROMPT", opihi_prompt); 30 30 set_str_variable ("RCFILE", opihi_rcfile); 31 set_int_variable ("DVO_CLIENT", FALSE); 31 32 32 33 { -
branches/eam_branches/ipp-20111122/Ohana/src/opihi/dvo/dvo_client.c
r33563 r33615 28 28 free (modules); 29 29 } 30 31 set_int_variable ("DVO_CLIENT", TRUE); 32 set_int_variable ("SCRIPT", FALSE); 30 33 31 34 // dvo_client should have 2 standard arguments: -hostID and -hostdir -
branches/eam_branches/ipp-20111122/Ohana/src/opihi/dvo/gcat.c
r33563 r33615 27 27 28 28 if ((argc != 3) && (argc != 4)) { 29 gprint (GP_ERR, "USAGE: gcat RA DEC [Radius] \n");29 gprint (GP_ERR, "USAGE: gcat RA DEC [Radius] [-host] [-backup] [-flags]\n"); 30 30 return (FALSE); 31 31 } -
branches/eam_branches/ipp-20111122/Ohana/src/opihi/dvo/hosts.c
r33614 r33615 74 74 75 75 if (!strncmp(argv[1], "get.results", MAX(strlen(argv[1]), 3))) { 76 int N; 76 77 77 78 char *varname = NULL; -
branches/eam_branches/ipp-20111122/Ohana/src/opihi/dvo/init.c
r33600 r33615 23 23 int fitsed PROTO((int, char **)); 24 24 int gcat PROTO((int, char **)); 25 int catlist PROTO((int, char **)); 25 26 int getxtra PROTO((int, char **)); 26 27 int gimages PROTO((int, char **)); … … 48 49 int paverage PROTO((int, char **)); 49 50 int procks PROTO((int, char **)); 51 int remote PROTO((int, char **)); 50 52 int showtile PROTO((int, char **)); 51 53 int skycat PROTO((int, char **)); … … 78 80 {1, "fitsed", fitsed, "fit stellar SEDs to objects"}, 79 81 {1, "gcat", gcat, "get catalog at location"}, 82 {1, "catlist", catlist, "get list of catalogs for region / host"}, 80 83 {1, "gimages", gimages, "get images at location"}, 81 84 {1, "gstar", gstar, "get star statistics"}, … … 101 104 {1, "paverage", paverage, "plot average magnitude"}, 102 105 {1, "procks", procks, "plot rocks"}, 106 {1, "remote", remote, "generic remote dvo client operation"}, 103 107 {1, "showtile", showtile, "plot tile pattern"}, 104 108 {1, "skycat", skycat, "show sky catalog boundaries"}, -
branches/eam_branches/ipp-20111122/Ohana/src/opihi/dvo/mextract.c
r33600 r33615 25 25 selection = NULL; 26 26 27 fprintf (stderr, "start..."); 27 28 if ((N = get_argument (argc, argv, "-h"))) goto help; 28 29 if ((N = get_argument (argc, argv, "--help"))) goto help; … … 145 146 interrupt = FALSE; 146 147 148 fprintf (stderr, "done setup..."); 149 147 150 for (i = 0; (i < skylist[0].Nregions) && !interrupt; i++) { 148 151 … … 168 171 /* XXX need to call dvo_catalog_chipcoords here passing the loaded images */ 169 172 173 fprintf (stderr, "done read..."); 174 170 175 for (j = 0; (j < catalog.Naverage) && !interrupt; j++) { 171 176 m = catalog.average[j].measureOffset; … … 175 180 } 176 181 177 dbExtractMeasuresInitAve (); // reset counters for saved fields 182 dbExtractMeasuresInitAve (); // reset counters for saved fields (costs very little 178 183 179 184 for (k = 0; (k < catalog.average[j].Nmeasure); k++, m++) { … … 184 189 185 190 // extract the relevant values for this measurement 186 dbExtractMeasuresInitMeas (); // reset counters for saved fields 191 dbExtractMeasuresInitMeas (); // reset counters for saved fields (costs very little 187 192 for (n = 0; n < Nfields; n++) { 188 193 values[n] = dbExtractMeasures (&catalog.average[j], &catalog.secfilt[j*Nsecfilt], &catalog.measure[m], &fields[n]); … … 218 223 interrupt = FALSE; 219 224 225 fprintf (stderr, "done load..."); 226 220 227 for (n = 0; n < Nreturn; n++) { 221 228 ResetVector (vec[n], fields[n].type, Npts); … … 236 243 SkyListFree (skylist); 237 244 FreeSkyRegionSelection (selection); 245 246 fprintf (stderr, "done extr...\n"); 238 247 return (TRUE); 239 248 -
branches/eam_branches/ipp-20111122/Ohana/src/opihi/dvo/region_list.c
r33313 r33615 195 195 sprintf (filename, "%s/%s.cpt", CATDIR, selection->name); 196 196 skylist[0].filename[0] = strcreate (filename); 197 skylist[0].Nregions = 1; 197 198 return (skylist); 198 199 } -
branches/eam_branches/ipp-20111122/Ohana/src/opihi/dvo/skyregion.c
r33543 r33615 1 1 # include "dvoshell.h" 2 3 #ifdef NO_MOVED_TO_DVO4 static double RAs = 0.0;5 static double RAe = 0.0;6 static double DECs = 0.0;7 static double DECe = 0.0;8 #endif9 2 10 3 // define the sky region for which extractions are limited 11 4 int skyregion (int argc, char **argv) { 12 5 6 int N; 7 8 // dvo_client should have 2 standard arguments: -hostID and -hostdir 9 int SaveRegion = FALSE; 10 if ((N = get_argument (argc, argv, "-save"))) { 11 remove_argument (N, &argc, argv); 12 SaveRegion = TRUE; 13 } 14 13 15 if (argc == 1) { 14 double R As, RAe, DECs, DECe;15 get_skyregion(&R As, &RAe, &DECs, &DECe);16 double Rmin, Rmax, Dmin, Dmax; 17 get_skyregion(&Rmin, &Rmax, &Dmin, &Dmax); 16 18 17 gprint (GP_ERR, "current skyregion: %f - %f : %f - %f\n", RAs, RAe, DECs, DECe); 18 gprint (GP_ERR, "USAGE: skyregion (min RA) (max RA) (min DEC) (max DEC)\n"); 19 return (FALSE); 19 if (SaveRegion) { 20 set_variable ("Rmin", Rmin); 21 set_variable ("Rmax", Rmax); 22 set_variable ("Dmin", Dmin); 23 set_variable ("Dmax", Dmax); 24 return TRUE; 25 } else { 26 gprint (GP_ERR, "current skyregion: %f - %f : %f - %f\n", Rmin, Rmax, Dmin, Dmax); 27 gprint (GP_ERR, "USAGE: skyregion (min RA) (max RA) (min DEC) (max DEC)\n"); 28 return FALSE; 29 } 20 30 } 21 31 … … 29 39 return (TRUE); 30 40 } 31 #ifdef NOT_MOVED_TO_LIBDVO32 int get_skyregion (double *Rs, double *Re, double *Ds, double *De) {33 34 *Rs = RAs;35 *Re = RAe;36 *Ds = DECs;37 *De = DECe;38 39 return TRUE;40 }41 42 int set_skyregion (double Rs, double Re, double Ds, double De) {43 44 RAs = Rs;45 RAe = Re;46 DECs = Ds;47 DECe = De;48 49 return TRUE;50 }51 #endif52 41 53 42 /* find region which overlaps c at given depth (-1 : populated ) */ -
branches/eam_branches/ipp-20111122/Ohana/src/opihi/lib.shell/parse.c
r30614 r33615 101 101 V1 ++; 102 102 while (isspace (*V1)) V1++; 103 if (*V1 == 0) goto error; 103 if (*V1 == 0) { 104 // assign empty vector 105 set_str_variable (V0, ""); 106 goto escape; 107 } 104 108 105 109 /* command replacement. execute the line, place answer in val. */
Note:
See TracChangeset
for help on using the changeset viewer.
