Changeset 39432
- Timestamp:
- Mar 4, 2016, 1:51:25 PM (10 years ago)
- Location:
- branches/eam_branches/ohana.20160226/src/relastro
- Files:
-
- 1 added
- 7 edited
-
Makefile (modified) (1 diff)
-
include/relastro.h (modified) (1 diff)
-
src/ImageOps.c (modified) (1 diff)
-
src/UpdateMeasures.c (modified) (1 diff)
-
src/UpdateStacks.c (added)
-
src/bcatalog.c (modified) (1 diff)
-
src/relastro_parallel_images.c (modified) (1 diff)
-
src/share_meas_pos.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/ohana.20160226/src/relastro/Makefile
r39375 r39432 41 41 $(SRC)/Shutdown.$(ARCH).o \ 42 42 $(SRC)/UpdateChips.$(ARCH).o \ 43 $(SRC)/UpdateStacks.$(ARCH).o \ 43 44 $(SRC)/UpdateMosaic.$(ARCH).o \ 44 45 $(SRC)/UpdateObjects.$(ARCH).o \ -
branches/eam_branches/ohana.20160226/src/relastro/include/relastro.h
r39412 r39432 528 528 int UpdateSimple (Catalog *catalog, int Ncatalog); 529 529 int UpdateChips (Catalog *catalog, int Ncatalog, int Nloop); 530 int UpdateStacks (Catalog *catalog, int Ncatalog); 530 531 int UpdateMosaic (Catalog *catalog, int Ncatalog); 531 532 int UpdateMeasures (Catalog *catalog, int Ncatalog); -
branches/eam_branches/ohana.20160226/src/relastro/src/ImageOps.c
r39411 r39432 1 1 # include "relastro.h" 2 int isGPC1chip (int photcode);3 2 4 3 # define USE_IMAGE_ID 1 -
branches/eam_branches/ohana.20160226/src/relastro/src/UpdateMeasures.c
r39385 r39432 71 71 72 72 double dR = 3600.0*fabs(csdec*(oldR - R)); 73 double dD = 3600.0*fabs(oldD - R);73 double dD = 3600.0*fabs(oldD - D); 74 74 75 75 // complain if the new location is far from the old location -
branches/eam_branches/ohana.20160226/src/relastro/src/bcatalog.c
r39375 r39432 184 184 offset = catalog[0].average[i].measureOffset + j; 185 185 186 // we do not measure astrometry for the warps, so skip: 187 if (isGPC1warp(catalog[0].measure[offset].photcode)) continue; 188 186 189 // filter objects based on user supplied criteria, including SIGMA_LIM 187 190 if (!MeasFilterTest(&catalog[0].measure[offset], TRUE)) { -
branches/eam_branches/ohana.20160226/src/relastro/src/relastro_parallel_images.c
r38986 r39432 141 141 LOGRTIME("slurp_meas_pos loop %d on %s, host %d: %f sec\n", i, myHostName, REGION_HOST_ID, dtime); 142 142 } 143 144 // measure scatter for stacks 145 UpdateStacks (catalog, Ncatalog); 146 LOGRTIME("UpdateStacks on %s, host %d: %f sec\n", myHostName, REGION_HOST_ID, dtime); 147 143 148 // create summary plots of the process 144 149 // relastroVisualSummaryChips(); -
branches/eam_branches/ohana.20160226/src/relastro/src/share_meas_pos.c
r39411 r39432 58 58 off_t i, k; 59 59 60 int Nmeaspos = 0;61 MeasPos *measpos = NULL;62 ALLOCATE (measpos, MeasPos, 1);63 64 60 fprintf (stderr, "grabbing meas object pos from other hosts...\n"); 65 61 … … 78 74 LOGRTIME("meas_load_sync host %d loop %d on %s, host %d: %f sec\n", i, nloop, myHostName, REGION_HOST_ID, dtime); 79 75 80 off_t N subset= 0;76 off_t Nmeaspos = 0; 81 77 char *posfile = make_filename (CATDIR, regionHosts->hosts[i].hostname, regionHosts->hosts[i].hostID, "measpos.fits"); 82 MeasPos *measpos Subset = MeasPosLoad (posfile, &Nsubset);78 MeasPos *measpos = MeasPosLoad (posfile, &Nmeaspos); 83 79 free (posfile); 84 80 LOGRTIME("MeasPosLoad host %d loop %d on %s, host %d: %f sec\n", i, nloop, myHostName, REGION_HOST_ID, dtime); 85 81 86 // merge_meas_pos reallocs measpos and frees the input measposSubset 87 measpos = merge_meas_pos (measpos, &Nmeaspos, measposSubset, Nsubset); 88 LOGRTIME("merge_meas_pos host %d loop %d on %s, host %d: %f sec\n", i, nloop, myHostName, REGION_HOST_ID, dtime); 82 // apply the loaded measurement positions: 83 for (off_t j = 0; j < Nmeaspos; j++) { 84 int objID = measpos[j].objID; 85 int catID = measpos[j].catID; 86 87 // set the meas mag 88 int catSeq; 89 off_t objSeq; 90 if (!catID_and_objID_to_seq (catID, objID, &catSeq, &objSeq)) { 91 // XXX what should I do if this does not match? 92 continue; 93 } 94 myAssert (catSeq < Ncatalog, "oops"); 95 96 off_t m = catalog[catSeq].average[objSeq].measureOffset; 97 for (k = 0; k < catalog[catSeq].average[objSeq].Nmeasure; k++, m++) { 98 if (catalog[catSeq].measureT[m].imageID != measpos[j].imageID) continue; 99 catalog[catSeq].measureT[m].R = measpos[j].R; 100 catalog[catSeq].measureT[m].D = measpos[j].D; 101 if (catalog[catSeq].measure) { 102 catalog[catSeq].measure[m].R = measpos[j].R; 103 catalog[catSeq].measure[m].D = measpos[j].D; 104 } 105 } 106 } 107 free (measpos); 108 LOGRTIME("match_catID_and_objID/meas loop %d on %s, host %d: %f sec\n", nloop, myHostName, REGION_HOST_ID, dtime); 89 109 } 90 110 LOGRTIME("meas_load_done loop %d on %s, host %d: %f sec\n", nloop, myHostName, REGION_HOST_ID, dtime); 91 92 for (i = 0; i < Nmeaspos; i++) {93 int objID = measpos[i].objID;94 int catID = measpos[i].catID;95 96 // set the meas mag97 int catSeq;98 off_t objSeq;99 if (!catID_and_objID_to_seq (catID, objID, &catSeq, &objSeq)) {100 // XXX what should I do if this does not match?101 continue;102 }103 myAssert (catSeq < Ncatalog, "oops");104 105 off_t m = catalog[catSeq].average[objSeq].measureOffset;106 for (k = 0; k < catalog[catSeq].average[objSeq].Nmeasure; k++, m++) {107 if (catalog[catSeq].measureT[m].imageID != measpos[i].imageID) continue;108 catalog[catSeq].measureT[m].R = measpos[i].R;109 catalog[catSeq].measureT[m].D = measpos[i].D;110 if (catalog[catSeq].measure) {111 catalog[catSeq].measure[m].R = measpos[i].R;112 catalog[catSeq].measure[m].D = measpos[i].D;113 }114 }115 }116 free (measpos);117 LOGRTIME("match_catID_and_objID/meas loop %d on %s, host %d: %f sec\n", nloop, myHostName, REGION_HOST_ID, dtime);118 111 119 112 fprintf (stderr, "DONE grabbing meas object pos from other hosts...\n");
Note:
See TracChangeset
for help on using the changeset viewer.
