Changeset 33949
- Timestamp:
- May 29, 2012, 5:08:07 PM (14 years ago)
- Location:
- branches/eam_branches/ipp-20120405
- Files:
-
- 69 edited
- 12 copied
-
Nebulous-Server/bin/neb-admin (modified) (1 diff)
-
Nebulous-Server/lib/Nebulous/Server/SQL.pm (modified) (1 diff)
-
ippMonitor (modified) (1 prop)
-
ippMonitor/Makefile.in (modified) (2 diffs)
-
ippMonitor/czartool/czarpoll.pl (modified) (2 diffs)
-
ippMonitor/czartool/czartool.pl (modified) (8 diffs)
-
ippMonitor/czartool/czartool/CzarDb.pm (modified) (2 diffs)
-
ippMonitor/czartool/czartool/DayMetrics.pm (modified) (9 diffs)
-
ippMonitor/czartool/czartool/Gpc1Db.pm (modified) (4 diffs)
-
ippMonitor/czartool/czartool/Plotter.pm (modified) (2 diffs)
-
ippMonitor/czartool/roboczar.pl (modified) (1 diff)
-
ippMonitor/def/addRunRun.d (modified) (1 diff)
-
ippMonitor/def/addRunSummary.d (copied) (copied from trunk/ippMonitor/def/addRunSummary.d )
-
ippMonitor/def/dvodbFaulted.d (copied) (copied from trunk/ippMonitor/def/dvodbFaulted.d )
-
ippMonitor/def/dvodbStatus.d (copied) (copied from trunk/ippMonitor/def/dvodbStatus.d )
-
ippMonitor/def/exposureStatus.d (modified) (1 diff)
-
ippMonitor/def/gpc1MysqlProcessList.d (modified) (1 diff)
-
ippMonitor/def/maskStats.d (modified) (1 diff)
-
ippMonitor/def/mergedvodbCopy.d (copied) (copied from trunk/ippMonitor/def/mergedvodbCopy.d )
-
ippMonitor/def/mergedvodbProcessed.d (copied) (copied from trunk/ippMonitor/def/mergedvodbProcessed.d )
-
ippMonitor/def/mergedvodbRun.d (copied) (copied from trunk/ippMonitor/def/mergedvodbRun.d )
-
ippMonitor/def/minidvodbProcessed.d (modified) (1 diff)
-
ippMonitor/def/minidvodbRun.d (modified) (1 diff)
-
ippMonitor/def/mopsStatus.d (modified) (1 diff)
-
ippMonitor/def/warpProcessedSkyfiles_Images.d (modified) (1 diff)
-
ippMonitor/raw/czartool_ipptopsps.php (modified) (2 diffs)
-
ippMonitor/raw/czartool_labels.php (modified) (8 diffs)
-
ippMonitor/raw/ipp.czar.dat (copied) (copied from trunk/ippMonitor/raw/ipp.czar.dat )
-
ippMonitor/raw/ipp.czar.php (copied) (copied from trunk/ippMonitor/raw/ipp.czar.php )
-
ippMonitor/raw/ipp.dvodb.dat (modified) (1 diff)
-
ippMonitor/raw/ipp.menu.dat (modified) (1 diff)
-
ippMonitor/raw/ipp.science.dat (modified) (1 diff)
-
ippMonitor/raw/nightSummary.php (modified) (1 diff)
-
ippScripts/scripts/destreak_restore_camera.pl (modified) (1 diff, 1 prop)
-
ippScripts/scripts/ipp_apply_burntool_single.pl (modified) (1 prop)
-
ippScripts/scripts/magic_destreak.pl (modified) (1 prop)
-
ippScripts/scripts/nightly_science.pl (modified) (4 diffs)
-
ippScripts/scripts/staticsky.pl (modified) (2 diffs)
-
ippTasks/pstamp.pro (modified) (4 diffs)
-
ippTools/share/Makefile.am (modified) (1 diff)
-
ippTools/share/camtool_find_pendingimfile.sql (modified) (1 prop)
-
ippTools/share/chiptool_pendingimfile.sql (modified) (1 diff)
-
ippTools/share/chiptool_setimfiletoupdate.sql (modified) (1 prop)
-
ippTools/share/pstamptool_revertreq_deletejobs.sql (modified) (1 diff)
-
ippTools/share/pxadmin_create_tables.sql (modified) (1 prop)
-
ippTools/share/sctool_list.sql (copied) (copied from trunk/ippTools/share/sctool_list.sql )
-
ippTools/share/staticskytool_definebyquery_inputs.sql (modified) (1 diff)
-
ippTools/share/staticskytool_definebyquery_select.sql (modified) (2 diffs)
-
ippTools/share/staticskytool_result.sql (modified) (1 diff)
-
ippTools/share/warptool_towarped.sql (modified) (1 prop)
-
ippTools/src (modified) (1 prop)
-
ippTools/src/addtool.c (modified) (1 diff)
-
ippTools/src/magictool.c (modified) (1 prop)
-
ippTools/src/pstamptoolConfig.c (modified) (1 diff)
-
ippTools/src/pxspace.c (modified) (1 diff)
-
ippTools/src/pxspace.h (modified) (2 diffs)
-
ippTools/src/sctool.c (modified) (3 diffs)
-
ippTools/src/sctool.h (modified) (1 diff)
-
ippTools/src/sctoolConfig.c (copied) (copied from trunk/ippTools/src/sctoolConfig.c )
-
ippTools/src/stacktool.c (modified) (2 diffs)
-
ippTools/src/stacktoolConfig.c (modified) (2 diffs)
-
ippTools/src/staticskytool.c (modified) (5 diffs)
-
ippTools/src/staticskytoolConfig.c (modified) (3 diffs)
-
ppImage/src (modified) (1 prop)
-
ppImage/src/ppImage.h (modified) (1 diff)
-
ppImage/src/ppImageDetrendReadout.c (modified) (3 diffs)
-
ppImage/src/ppImageOptions.c (modified) (3 diffs)
-
ppImage/src/ppImageParseCamera.c (modified) (2 diffs)
-
ppMerge/src/ppMergeCamera.c (modified) (2 diffs)
-
psastro/src/psastroLoadCrosstalk.c (modified) (4 diffs)
-
psastro/src/psastroLoadGhosts.c (modified) (3 diffs)
-
psastro/src/psastroMaskUpdates.c (modified) (1 diff)
-
psastro/src/psastroMaskUtils.c (modified) (1 diff)
-
tools/czarcal (modified) (1 diff)
-
tools/dlapstacks (modified) (1 diff)
-
tools/heather/dvomergecheck.pl (copied) (copied from trunk/tools/heather/dvomergecheck.pl )
-
tools/listcmf (copied) (copied from trunk/tools/listcmf )
-
tools/repair_bad_instance (modified) (1 diff)
-
tools/runbgchip.pl (modified) (1 diff)
-
tools/runchipimfile.pl (modified) (1 diff)
-
tools/runwarpskycell.pl (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/ipp-20120405/Nebulous-Server/bin/neb-admin
r33414 r33949 625 625 # OFFSET $offset 626 626 # "); 627 my $query = $dbh->prepare( 628 " 629 SELECT Z.so_id,ext_id,Z.ins_id,Z.uri,substr(Z.uri,-10,5) AS class_id,Z.vol_id,vol_name,vol_host, 630 instance.vol_id AS second_vol_id,volume.name AS second_name,volume.host AS second_host FROM ( 631 SELECT S.so_id,ext_id,ins_id,uri,substr(uri,-10,5) AS class_id,vol_id,name AS vol_name,host AS vol_host,MAXins_id FROM ( 632 select * FROM ( 633 select MAX(ins_id) AS MAXins_id, MIN(ins_id) AS MINins_id, so_id,ext_id FROM storage_object 634 JOIN storage_object_xattr USING(so_id) 635 RIGHT JOIN instance USING(so_id) 636 WHERE name = 'user.copies' 637 AND value >= 2 638 AND ext_id LIKE '%ota%fits' 639 AND so_id >= $so_id_start 640 AND so_id < $so_id_end 641 GROUP BY so_id 642 ) AS V 643 WHERE MAXins_id != MINins_id 644 ) AS S 645 JOIN instance ON (S.MINins_id = instance.ins_id AND S.so_id = instance.so_id) 646 JOIN volume USING(vol_id) WHERE volume.available = 1 647 AND volume.name AS $requested_source 648 ) AS Z 649 JOIN instance ON (MAXins_id = instance.ins_id AND Z.so_id = instance.so_id) 650 JOIN volume ON(instance.vol_id = volume.vol_id) WHERE volume.available = 1 651 LIMIT $limit 652 OFFSET $offset 653 "); 627 628 print STDERR "This query is broken so I have disabled it to get the MHPCC->ATRC shuffle going.\n"; 629 exit 0; 630 my $query; 631 # my $query = $dbh->prepare( 632 # " 633 # SELECT Z.so_id,ext_id,Z.ins_id,Z.uri,substr(Z.uri,-10,5) AS class_id,Z.vol_id,vol_name,vol_host, 634 # instance.vol_id AS second_vol_id,volume.name AS second_name,volume.host AS second_host FROM ( 635 # SELECT S.so_id,ext_id,ins_id,uri,substr(uri,-10,5) AS class_id,vol_id,name AS vol_name,host AS vol_host,MAXins_id FROM ( 636 # select * FROM ( 637 # select MAX(ins_id) AS MAXins_id, MIN(ins_id) AS MINins_id, so_id,ext_id FROM storage_object 638 # JOIN storage_object_xattr USING(so_id) 639 # RIGHT JOIN instance USING(so_id) 640 # WHERE name = 'user.copies' 641 # AND value >= 2 642 # AND ext_id LIKE '%ota%fits' 643 # AND so_id >= $so_id_start 644 # AND so_id < $so_id_end 645 # GROUP BY so_id 646 # ) AS V 647 # WHERE MAXins_id != MINins_id 648 # ) AS S 649 # JOIN instance ON (S.MINins_id = instance.ins_id AND S.so_id = instance.so_id) 650 # JOIN volume USING(vol_id) WHERE volume.available = 1 651 # AND volume.name AS $requested_source 652 # ) AS Z 653 # JOIN instance ON (MAXins_id = instance.ins_id AND Z.so_id = instance.so_id) 654 # JOIN volume ON(instance.vol_id = volume.vol_id) WHERE volume.available = 1 655 # LIMIT $limit 656 # OFFSET $offset 657 # "); 654 658 655 659 $query->execute(); -
branches/eam_branches/ipp-20120405/Nebulous-Server/lib/Nebulous/Server/SQL.pm
r31410 r33949 750 750 ### 751 751 752 CREATE TABLE lost_instances ( 753 id BIGINT NOT NULL AUTO_INCREMENT, 754 ins_id BIGINT NOT NULL DEFAULT -1, 755 so_id BIGINT NOT NULL DEFAULT -1, 756 vol_id INT NOT NULL DEFAULT -1, 757 uri CHAR(255) NOT NULL DEFAULT 'undefined', 758 epoch TIMESTAMP DEFAULT CURRENT_TIMESTAMP, 759 mtime TIMESTAMP, 760 PRIMARY KEY(id), 761 KEY(so_id), 762 KEY(vol_id), 763 KEY(uri(40)) 764 ) ENGINE=innodb DEFAULT CHARSET=latin1; 765 766 ### 767 752 768 CREATE TABLE log ( 753 769 timestamp TIMESTAMP, -
branches/eam_branches/ipp-20120405/ippMonitor
- Property svn:mergeinfo changed
/trunk/ippMonitor (added) merged: 33800-33806,33808,33814-33816,33846-33847
- Property svn:mergeinfo changed
-
branches/eam_branches/ipp-20120405/ippMonitor/Makefile.in
r32782 r33949 47 47 $(DESTWWW)/ipp.dvodb.dat \ 48 48 $(DESTWWW)/ipp.dvodb.php \ 49 $(DESTWWW)/ipp.czar.dat \ 50 $(DESTWWW)/ipp.czar.php \ 49 51 $(DESTWWW)/phptest.php \ 50 52 $(DESTWWW)/site.php \ … … 222 224 $(DESTWWW)/minidvodbCopy.php \ 223 225 $(DESTWWW)/minidvodbProcessed.php \ 226 $(DESTWWW)/mergedvodbRun.php \ 227 $(DESTWWW)/mergedvodbCopy.php \ 228 $(DESTWWW)/mergedvodbProcessed.php \ 229 $(DESTWWW)/dvodbStatus.php \ 230 $(DESTWWW)/dvodbFaulted.php \ 224 231 $(DESTWWW)/addRunRun.php \ 225 232 $(DESTWWW)/addRunProcessed.php \ 233 $(DESTWWW)/addRunSummary.php \ 226 234 $(DESTWWW)/lapSequenceSummary.php \ 227 235 $(DESTWWW)/lapRuns.php \ -
branches/eam_branches/ipp-20120405/ippMonitor/czartool/czarpoll.pl
r32775 r33949 38 38 39 39 my @stages = ( 40 "burntool",41 40 "chip", 42 41 "cam", … … 44 43 "warp", 45 44 "stack", 45 "staticsky", 46 46 "diff", 47 "magic",48 "magicDS",49 47 "dist", 50 "pub"); 48 "pub", 49 "chipbackground"); 51 50 52 51 my @ippToPspsStages = ( -
branches/eam_branches/ipp-20120405/ippMonitor/czartool/czartool.pl
r32093 r33949 32 32 my @publishingLabels = undef; 33 33 34 my @stages = ("chip", "cam", "fake", "warp", "stack", " diff", "magic", "magicDS", "dist", "pub");34 my @stages = ("chip", "cam", "fake", "warp", "stack", "staticsky", "diff", "dist", "pub", "chipbackground"); 35 35 promptPoll(); 36 36 … … 155 155 156 156 chomp($label); 157 158 printf("\n+----------------------------------------------------------------------------------------------------------------------------------------------+\n"); 159 printf("| %32s |\n", $label); 160 printf("+------------+------------+------------+------------+------------+------------+------------+------------+------------+------------+------------+\n"); 161 printf("| state | chip | cam | fake | warp | stack | diff | magic | destreak | dist | publish |\n"); 162 printf("+------------+------------+------------+------------+------------+------------+------------+------------+------------+------------+------------+\n"); 157 my $stage; 158 159 printf("\n| %32s \n", $label); 160 printf("+------------+"); 161 foreach $stage (@stages) { 162 print "--------------+" 163 } 164 printf("\n"); 165 printf("| state |"); 166 foreach $stage (@stages) { 167 168 printf("%14s|", $stage) 169 } 170 printf("\n"); 171 printf("+------------+"); 172 foreach $stage (@stages) { 173 print "--------------+" 174 } 175 printf("\n"); 163 176 164 177 my $state; 165 my $stage;166 178 my $i=0; 167 179 foreach $state (@states) { … … 172 184 foreach $stage (@stages) { 173 185 174 printf("| %10s", getStateAndFaultsString($label, $state, $stage));186 printf("|%14s", getStateAndFaultsString($label, $state, $stage)); 175 187 } 176 188 … … 179 191 } 180 192 181 printf("+------------+------------+------------+------------+------------+------------+------------+------------+------------+------------+------------+\n"); 193 printf("+------------+"); 194 foreach $stage (@stages) { 195 print "--------------+" 196 } 197 printf("\n"); 182 198 183 199 } … … 191 207 my ($state) = @_; 192 208 #print time, $/; 193 printf("\n+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+\n"); 194 printf("| %10s (any faults are shown in parentheses) |\n", $state); 195 printf("+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+------------+\n"); 196 printf("| no | label | distributing? | publishing? | chip | cam | fake | warp | stack | diff | magic | destreak | dist | publish |\n"); 197 printf("+-----+----------------------------------+---------------+---------------+------------+------------+------------+------------+------------+------------+------------+------------+------------+------------+\n"); 209 my $stage; 210 211 printf("|\n"); 212 printf("+-----+----------------------------------+---------------+---------------+"); 213 foreach $stage (@stages) { 214 print "--------------+" 215 } 216 printf("\n"); 217 printf("| no | label | distributing? | publishing? |"); 198 218 199 219 my $stdsLabel; … … 202 222 my $distributing; 203 223 my $publishing; 204 my $stage;205 224 my $i=1; 225 foreach $stage (@stages) { 226 227 printf("%14s|", $stage) 228 } 229 printf("\n"); 230 printf("+-----+----------------------------------+---------------+---------------+"); 231 foreach $stage (@stages) { 232 print "--------------+" 233 } 234 printf("\n"); 235 206 236 foreach $stdsLabel (@stdscienceLabels) { 207 237 … … 225 255 foreach $stage (@stages) { 226 256 227 printf("| %10s", getStateAndFaultsString($stdsLabel, $state, $stage));257 printf("|%14s", getStateAndFaultsString($stdsLabel, $state, $stage)); 228 258 } 229 259 … … 232 262 } 233 263 234 printf("+-----+----------------------------------+---------------+---------------+------------+------------+------------+------------+------------+------------+------------+------------+------------+------------+\n"); 264 printf("+-----+----------------------------------+---------------+---------------+"); 265 foreach $stage (@stages) { 266 print "--------------+" 267 } 268 printf("\n"); 235 269 236 270 } -
branches/eam_branches/ipp-20120405/ippMonitor/czartool/czartool/CzarDb.pm
r32797 r33949 9 9 10 10 my @stages = ( 11 "burntool",12 11 "chip", 13 12 "cam", … … 16 15 "stack", 17 16 "diff", 18 "magic",19 "magicDS",20 17 "dist", 21 "pub"); # TODO put elsewhere 18 "pub", 19 "chipbackground"); # TODO put elsewhere 22 20 23 21 my @ippToPspsStages = ( -
branches/eam_branches/ipp-20120405/ippMonitor/czartool/czartool/DayMetrics.pm
r32093 r33949 40 40 $self->{begin} = "$yesterday " . $self->{config}->getMetricsStartTime(); 41 41 $self->{end} = $self->{czarDb}->addInterval($self->{begin}, "1 DAY"); 42 $self->{ burntoolEnd} = $self->{czarDb}->addInterval($self->{begin}, "12 HOUR");42 $self->{chipEnd} = $self->{czarDb}->addInterval($self->{begin}, "12 HOUR"); 43 43 44 44 # create path, dir and html file … … 67 67 my $htmlFile = $self->{htmlFile}; 68 68 69 # summit and burntoolexposures69 # summit and chip exposures 70 70 my $summitExposures = $self->{gpc1Db}->countScienceExposuresFromLastNight($self->{day}); 71 my $ burntoolMetrics = new czartool::StageMetrics("burntool", "all_stdscience_labels", $self->{begin}, $self->{burntoolEnd});72 $self->{czarDb}->runAnalysis($ burntoolMetrics);71 my $chipMetrics = new czartool::StageMetrics("chip", "all_stdscience_labels", $self->{begin}, $self->{chipEnd}); 72 $self->{czarDb}->runAnalysis($chipMetrics); 73 73 74 74 my $previousDay = $self->{czarDb}->subtractInterval($self->{day}, "1 DAY"); … … 78 78 print $htmlFile "<a href=\"../$previousDay/index.html\"> \< previous day</a> | <a href=\"../index.html\">all</a> | <a href=\"../$nextDay/index.html\">next day \></a><br>\n"; 79 79 print $htmlFile "Measured from $self->{begin} to $self->{end} HST<br>\n"; 80 printf ( $htmlFile "%d exposures taken on summit last night, %d through burntooltoday</h5>\n",81 $summitExposures, $ burntoolMetrics->getProcessed() ? $burntoolMetrics->getProcessed() : 0 );80 printf ( $htmlFile "%d exposures taken on summit last night, %d through chip today</h5>\n", 81 $summitExposures, $chipMetrics->getProcessed() ? $chipMetrics->getProcessed() : 0 ); 82 82 print $htmlFile "</head>\n"; 83 83 print $htmlFile "<body>\n"; … … 98 98 my %labelTables; 99 99 100 my @stages = ("burntool", "chip", "cam", "fake", "warp", "stack", "diff", "magic", "magicDS", "dist"); 100 my @stages = ( 101 "chip", 102 "cam", 103 "fake", 104 "warp", 105 "stack", 106 "staticsky", 107 "diff", 108 "dist", 109 "chipbackground"); 101 110 102 111 … … 126 135 foreach my $stage ( @stages ){ 127 136 128 my $stageMetrics = new czartool::StageMetrics($stage, $label, $self->{begin}, ($stage eq " burntool") ? $self->{burntoolEnd} : $self->{end});137 my $stageMetrics = new czartool::StageMetrics($stage, $label, $self->{begin}, ($stage eq "chip") ? $self->{chipEnd} : $self->{end}); 129 138 if (!$self->{czarDb}->runAnalysis($stageMetrics)) {next;} 130 139 … … 253 262 print $htmlFile " <tr>\n"; 254 263 print $htmlFile " <th>Survey</th>\n"; 255 print $htmlFile " <th>Started burntool</th>\n";264 print $htmlFile " <th>Started chip</th>\n"; 256 265 print $htmlFile " <th>Finished distribution</th>\n"; 257 266 print $htmlFile " <th>Time taken</th>\n"; … … 260 269 # OSS survey 261 270 my ($started, $finished, $timeTaken) = undef; 262 $self->{czarDb}->getDayTimings("OSS.nightlyscience", " burntool", "diff", $self->{begin}, \$started, \$finished, \$timeTaken);271 $self->{czarDb}->getDayTimings("OSS.nightlyscience", "chip", "diff", $self->{begin}, \$started, \$finished, \$timeTaken); 263 272 $self->printSurveyDetails("OSS", $started, $finished, $timeTaken); 264 273 … … 285 294 foreach $mdf (@mdfs) { 286 295 287 if ($self->{czarDb}->getDayTimings($mdf, " burntool", "dist", $self->{begin}, \$started, \$finished, \$timeTaken)) {296 if ($self->{czarDb}->getDayTimings($mdf, "chip", "dist", $self->{begin}, \$started, \$finished, \$timeTaken)) { 288 297 289 298 if ($started && $self->{czarDb}->isBefore($started, $earliest)) {$earliest = $started; $haveStart = 1;} … … 299 308 $self->printSurveyDetails("MDF", $earliest, $latest, $timeTaken); 300 309 301 $self->{czarDb}->getDayTimings("all_stdscience_labels", " burntool", "dist", $self->{begin}, \$started, \$finished, \$timeTaken);310 $self->{czarDb}->getDayTimings("all_stdscience_labels", "chip", "dist", $self->{begin}, \$started, \$finished, \$timeTaken); 302 311 $self->printSurveyDetails("All", $started, $finished, $timeTaken); 303 312 -
branches/eam_branches/ipp-20120405/ippMonitor/czartool/czartool/Gpc1Db.pm
r32567 r33949 24 24 elsif ($stage eq "warp") {${$joinTable}="warpSkyfile";} 25 25 elsif ($stage eq "stack") {${$joinTable}="stackSumSkyfile";} 26 elsif ($stage eq "staticsky") {${$id} = "sky_id"; ${$joinTable}="staticskyResult";} 26 27 elsif ($stage eq "diff") {${$joinTable}="diffSkyfile";} 27 28 elsif ($stage eq "magic") {${$joinTable}="magicNodeResult";} … … 29 30 elsif ($stage eq "dist") {${$joinTable}="distComponent";} 30 31 elsif ($stage eq "pub") {${$joinTable}="publishDone";} 32 elsif ($stage eq "chipbackground") {${$id}="chip_bg_id"; ${$joinTable}="chipBackgroundImfile";} 31 33 else { 32 34 … … 51 53 elsif ($stage eq "warp" ) {return "warpRun";} 52 54 elsif ($stage eq "stack" ) {return "stackRun";} 55 elsif ($stage eq "staticsky" ) {return "staticskyRun";} 53 56 elsif ($stage eq "diff" ) {return "diffRun";} 54 57 elsif ($stage eq "magic" ) {return "magicRun";} … … 56 59 elsif ($stage eq "dist" ) {return "distRun";} 57 60 elsif ($stage eq "pub" ) {return "publishRun";} 61 elsif ($stage eq "chipbackground" ) {return "chipBackgroundRun";} 58 62 59 63 return "ERROR"; -
branches/eam_branches/ipp-20120405/ippMonitor/czartool/czartool/Plotter.pm
r32763 r33949 11 11 12 12 my @allStages = ( 13 "burntool",14 13 "chip", 15 14 "cam", … … 17 16 "warp", 18 17 "stack", 18 "staticsky", 19 19 "diff", 20 "magic",21 "magicDS",22 20 "dist", 23 "pub"); 21 "pub", 22 "chipbackground"); 24 23 25 24 my @allIppToPspsStages = ( -
branches/eam_branches/ipp-20120405/ippMonitor/czartool/roboczar.pl
r32098 r33949 21 21 my $czarDb = $config->getCzarDbInstance(); 22 22 23 my @stages = ("burntool", "chip", "cam", "fake", "warp", "stack", "diff", "magic", "magicDS", "dist"); # TODO get from Pantasks 23 my @stages = ( 24 "chip", 25 "cam", 26 "fake", 27 "warp", 28 "stack", 29 "staticsky", 30 "diff", 31 "dist", 32 "chipbackground"); # TODO get from Pantasks 24 33 25 34 my @interestedServers = $config->getRoboczarInterestedServers(); -
branches/eam_branches/ipp-20120405/ippMonitor/def/addRunRun.d
r31320 r33949 9 9 10 10 # field size format name show link to extras 11 FIELD distinct(addRun.add_id), 5, %d, addID11 FIELD addRun.add_id, 5, %d, addID 12 12 FIELD addRun.stage, 5, %s, stage 13 FIELD addRun.stage_id, 5, %d, stage ID 14 FIELD addRun.add_id, 5, %d, add ID 13 FIELD addRun.stage_id, 5, %d, stageID 14 FIELD addRun.stage_extra1, 5, %d, stageExtra1 15 #FIELD addRun.add_id, 5, %d, addID 15 16 FIELD addRun.state, 5, %s, state 16 FIELD addRun.workdir, 5, %s, workdir17 FIELD addRun.reduction, 5, %s, reduction17 FIELD addRun.workdir, 5, %s, workdir 18 FIELD addRun.reduction, 5, %s, reduction 18 19 FIELD addRun.label, 5, %s, label 19 FIELD addRun.data_group, 5, %s, data_group20 FIELD addRun.data_group, 5, %s, data_group 20 21 FIELD addRun.dvodb, 5, %s, dvodb 21 FIELD addRun.note, 5, %s, note 22 FIELD addRun.image_only, 5, %d, image_only 23 FIELD addRun.minidvodb, 5, %d, minidvodb 24 FIELD addRun.minidvodb_group, 5, %s, minidvodb_group 25 FIELD addRun.minidvodb_name, 5, %s, minidvodb_name 26 27 22 FIELD addRun.note, 5, %s, note 23 FIELD addRun.image_only, 5, %d, image_only 24 FIELD addRun.minidvodb, 5, %d, minidvodb 25 FIELD addRun.minidvodb_group, 5, %s, minidvodb_group 26 FIELD addRun.minidvodb_name, 5, %s, minidvodb_name -
branches/eam_branches/ipp-20120405/ippMonitor/def/exposureStatus.d
r29404 r33949 2 2 TITLE Exposures Status 3 3 FILE exposureStatus.php 4 MENU ipp. imfiles.dat4 MENU ipp.czar.dat 5 5 6 6 WHERE object != 'ENGINEERING' -
branches/eam_branches/ipp-20120405/ippMonitor/def/gpc1MysqlProcessList.d
r29481 r33949 2 2 TITLE GPC 1 MySql Process List 3 3 FILE gpc1MysqlProcessList.php 4 MENU ipp. imfiles.dat4 MENU ipp.czar.dat 5 5 6 6 FIELD ID, 5, %d, Process ID -
branches/eam_branches/ipp-20120405/ippMonitor/def/maskStats.d
r28451 r33949 2 2 TITLE Mask Stats 3 3 FILE maskStats.php 4 MENU ipp. imfiles.dat4 MENU ipp.czar.dat 5 5 6 6 WHERE rawExp.exp_id = chipRun.exp_id -
branches/eam_branches/ipp-20120405/ippMonitor/def/minidvodbProcessed.d
r30453 r33949 9 9 10 10 # field size format name show link to extras 11 FIELD distinct(minidvodbRun.minidvodb_id), 5, %d, Minidvodb ID 12 11 FIELD minidvodbRun.minidvodb_id, 5, %d, Minidvodb ID 13 12 FIELD minidvodbRun.minidvodb_name, 5, %s, minidvodb_name 14 13 FIELD minidvodbRun.minidvodb_group, 5, %s, minidvodb_group 15 FIELD minidvodbProcessed.merge_order, 5, %d, Merge Order16 14 FIELD minidvodbProcessed.dtime_resort, 5, %d, resort time 17 15 FIELD minidvodbProcessed.dtime_relphot, 5, %d, relphot time 18 FIELD minidvodbProcessed.dtime_merge, 5, %d, dvomerge time 19 FIELD minidvodbProcessed.mergedvodb_path, 25, %s, mergedvodb_path 16 FIELD minidvodbProcessed.dtime_script, 5, %d, script time 20 17 FIELD state, 5, %s, State 21 18 FIELD minidvodbProcessed.fault, 5, %d, Fault -
branches/eam_branches/ipp-20120405/ippMonitor/def/minidvodbRun.d
r30453 r33949 9 9 10 10 # field size format name show link to extras 11 FIELD distinct(minidvodbRun.minidvodb_id), 5, %d, Minidvodb ID11 FIELD minidvodbRun.minidvodb_id, 5, %d, Minidvodb ID 12 12 FIELD minidvodbRun.minidvodb_name, 5, %s, minidvodb_name 13 13 FIELD minidvodbRun.minidvodb_group, 5, %s, minidvodb_group 14 14 FIELD minidvodbRun.minidvodb_path, 25, %s, minidvodb_path 15 FIELD minidvodbRun.mergedvodb_path, 25, %s, mergedvodb_path15 #FIELD minidvodbRun.mergedvodb_path, 25, %s, mergedvodb_path 16 16 FIELD state, 5, %s, State 17 17 FIELD creation_date, 5, %T, epoch -
branches/eam_branches/ipp-20120405/ippMonitor/def/mopsStatus.d
r32278 r33949 2 2 TITLE MOPS Status 3 3 FILE mopsStatus.php 4 MENU ipp. imfiles.dat4 MENU ipp.czar.dat 5 5 #WHERE rawExp.obs_mode!='ENGINEERING' 6 6 -
branches/eam_branches/ipp-20120405/ippMonitor/def/warpProcessedSkyfiles_Images.d
r32369 r33949 1 1 TABLE rawExp JOIN chipRun USING(exp_id) JOIN camRun USING(chip_id) JOIN fakeRun USING(cam_id) JOIN warpRun USING(fake_id) JOIN warpSkyfile USING(warp_id) 2 2 TITLE Warp Processed Skyfiles 3 FILE warpProcessedSkyfiles .php3 FILE warpProcessedSkyfiles_Images.php 4 4 MENU ipp.science.dat 5 5 -
branches/eam_branches/ipp-20120405/ippMonitor/raw/czartool_ipptopsps.php
r33441 r33949 23 23 24 24 if ($ID['menu']) {$myMenu = $ID['menu'];} 25 else {$myMenu = "ipp. imfiles.dat";}25 else {$myMenu = "ipp.czar.dat";} 26 26 27 27 menu($myMenu, 'Czartool on '.$lastUpdateTime, 'ipp.css', $ID['link'], $ID['proj']); … … 78 78 79 79 $debug = 0; 80 $table = "<table bgcolor=\"#FFFFFF\" width=\" 700\" align=\"middle\" border=\"1\" cellspacing=\"0\" cellpadding=\"4\" style=\"font-size:80%\">\n";80 $table = "<table bgcolor=\"#FFFFFF\" width=\"900\" align=\"middle\" border=\"1\" cellspacing=\"0\" cellpadding=\"4\" style=\"font-size:80%\">\n"; 81 81 82 82 -
branches/eam_branches/ipp-20120405/ippMonitor/raw/czartool_labels.php
r33063 r33949 23 23 24 24 if ($ID['menu']) {$myMenu = $ID['menu'];} 25 else {$myMenu = "ipp. imfiles.dat";}25 else {$myMenu = "ipp.czar.dat";} 26 26 27 27 menu($myMenu, 'Czartool on '.$lastUpdateTime, 'ipp.css', $ID['link'], $ID['proj']); 28 28 29 29 $stages=array( 30 "burntool",31 30 "chip", 32 31 "cam", … … 34 33 "warp", 35 34 "stack", 35 "staticsky", 36 36 "diff", 37 "magic",38 "magicDS",39 37 "dist", 40 "pub"); 38 "pub", 39 "chipbackground"); 41 40 42 41 $servers=array( … … 92 91 93 92 $debug = 0; 94 $table = "<table bgcolor=\"#FFFFFF\" width=\" 700\" align=\"middle\" border=\"1\" cellspacing=\"0\" cellpadding=\"4\" style=\"font-size:80%\">\n";93 $table = "<table bgcolor=\"#FFFFFF\" width=\"900\" align=\"middle\" border=\"1\" cellspacing=\"0\" cellpadding=\"4\" style=\"font-size:80%\">\n"; 95 94 96 95 $labels = getLabels($czardb, $selectedMode); … … 441 440 $anyFaults = false; 442 441 443 $link = $defaultlink;444 getStateAndFaults($db, $thisLabel, $selectedState, "burntool", $str, $anyFaults);445 createFormattedTableCell($anyFaults, $link, $str, $anyFaults, 0);446 447 442 $link = "failedChipProcessedImfile.php?pass=" . $pass . "&proj=" . $proj . "&chipRun.label=" . $thisLabel . "&chipRun.state=".$searchState; 448 443 getStateAndFaults($db, $thisLabel, $selectedState, "chip", $str, $anyFaults); … … 465 460 createFormattedTableCell($anyFaults, $link, $str, $anyFaults, 0); 466 461 462 $link = $defaultlink; 463 getStateAndFaults($db, $thisLabel, $selectedState, "staticsky", $str, $anyFaults); 464 createFormattedTableCell($anyFaults, $link, $str, $anyFaults, 0); 465 467 466 $link = "failedDiffSkyfile.php?pass=" . $pass . "&proj=" . $proj . "&diffRun.label=" . $thisLabel . "&diffRun.state=".$searchState; 468 467 getStateAndFaults($db, $thisLabel, $selectedState, "diff", $str, $anyFaults); … … 470 469 471 470 $link = $defaultlink; 472 getStateAndFaults($db, $thisLabel, $selectedState, "magic", $str, $anyFaults);473 createFormattedTableCell($anyFaults, $link, $str, $anyFaults, (!$isUpdate && !$distributing) ? "gray" : null);474 475 $link = $defaultlink;476 getStateAndFaults($db, $thisLabel, $selectedState, "magicDS", $str, $anyFaults);477 createFormattedTableCell($anyFaults, $link, $str, $anyFaults, (!$isUpdate && !$distributing) ? "gray" : null);478 479 $link = $defaultlink;480 471 getStateAndFaults($db, $thisLabel, $selectedState, "dist", $str, $anyFaults); 481 472 createFormattedTableCell($anyFaults, $link, $str, $anyFaults, (!$isUpdate && !$distributing) ? "gray" : null); … … 485 476 createFormattedTableCell($anyFaults, $link, $str, $anyFaults, (!$isUpdate && !$publishing) ? "gray" : null); 486 477 478 $link = $defaultlink; 479 getStateAndFaults($db, $thisLabel, $selectedState, "chipbackground", $str, $anyFaults); 480 createFormattedTableCell($anyFaults, $link, $str, $anyFaults, 0); 481 487 482 echo "</tr>\n"; 488 483 } … … 492 487 createFormattedTableCell(($selectedLabel != "all"), $link, "All labels", 0, null); 493 488 494 createFormattedTableCell(0, null, "Reverting?", 0, "$columnHeaderColor");495 496 489 foreach ($stages as &$stage) { 497 490 498 if ($stage == "burntool") continue;499 491 $reverting = getRevertStatus($db, $stage); 500 #$link = 501 # "czartool_labels.php?pass=".$pass 502 # ."&proj=".$proj 503 # ."&mode=" .$selectedMode 504 # ."&label=".$selectedLabel 505 # ."&stage=".$selectedStage 506 # ."&plottype=".$plotType 507 # ."&revertstage=".$stage 508 # ."&revertmode="; 509 # 510 #if(!$reverting) {$label = "Start";$link = $link . "on";} 511 #if($reverting) {$label = "Stop";$link = $link . "off";} 512 if(!$reverting) {$label = "no";} 513 if($reverting) {$label = "yes";} 492 if(!$reverting) {$label = "";} 493 if($reverting) {$label = "reverting";} 514 494 unset($reverting); 515 #createFormattedTableCell(1, $link, $label, 0, "$columnHeaderColor");516 495 createFormattedTableCell(0, null, $label, 0, "$columnHeaderColor"); 517 #echo "<td><a href=\"$link\"><font color=\"blue\">$label</font></td>";518 519 496 } 520 497 -
branches/eam_branches/ipp-20120405/ippMonitor/raw/ipp.dvodb.dat
r30453 r33949 9 9 10 10 menulink | menuselect | link | minidvodbRun | minidvodbRun.php 11 menulink | menuselect | link | minidvodbProcessed | minidvodbProcessed.php 11 menulink | menuselect | link | minidvodbProcessed | minidvodbProcessed.php 12 12 menulink | menuselect | link | minidvodbCopy | minidvodbCopy.php 13 13 14 menutop | menutop | plain | | 15 16 menulink | menuselect | link | mergedvodbRun | mergedvodbRun.php 17 menulink | menuselect | link | mergedvodbProcessed | mergedvodbProcessed.php 18 menulink | menuselect | link | mergedvodbCopy | mergedvodbCopy.php 19 20 menutop | menutop | plain | | 21 22 menulink | menuselect | link | dvodbStatus | dvodbStatus.php 23 menulink | menuselect | link | dvodbFaulted | dvodbFaulted.php 24 menulink | menuselect | link | addRun Summary | addRunSummary.php -
branches/eam_branches/ipp-20120405/ippMonitor/raw/ipp.menu.dat
r31816 r33949 27 27 menutop | menutop | link | Calibration | ipp.cal.php 28 28 menutop | menutop | link | Plots | ipp.plots.php 29 menutop | menutop | link | Czar | ipp.czar.php 29 30 menutop | menutop | link | Admin and Debug | ipp.imfiles.php -
branches/eam_branches/ipp-20120405/ippMonitor/raw/ipp.science.dat
r28688 r33949 38 38 menulink | menuselect | link | Warp Skyfile Inputs | warpStageSkyfileInputs.php 39 39 menulink | menuselect | link | Warp Processed Skyfiles | warpProcessedSkyfiles.php 40 #menulink | menuselect | link | Warp Processed Skyfiles w/ Images | warpProcessedSkyfiles_images.php 40 41 menulink | menuselect | link | Warp Failed Skyfiles | warpFailedSkyfiles.php 41 42 -
branches/eam_branches/ipp-20120405/ippMonitor/raw/nightSummary.php
r33004 r33949 52 52 $myMenu = $ID['menu']; 53 53 } else { 54 $myMenu = "ipp. imfiles.dat";54 $myMenu = "ipp.czar.dat"; 55 55 } 56 56 -
branches/eam_branches/ipp-20120405/ippScripts/scripts/destreak_restore_camera.pl
-
Property svn:mergeinfo
set to (toggle deleted branches)
/tags/ipp-20120404/ippScripts/scripts/destreak_restore_camera.pl merged eligible /trunk/ippScripts/scripts/destreak_restore_camera.pl merged eligible /branches/czw_branch/20101203/ippScripts/scripts/destreak_restore_camera.pl 29907-30631 /branches/eam_branches/ipp-20101103/ippScripts/scripts/destreak_restore_camera.pl 29657-29920 /branches/eam_branches/ipp-20101205/ippScripts/scripts/destreak_restore_camera.pl 29959-30585 /branches/eam_branches/ipp-20110213/ippScripts/scripts/destreak_restore_camera.pl 30628-31149 /branches/eam_branches/ipp-20110404/ippScripts/scripts/destreak_restore_camera.pl 31166-31444 /branches/eam_branches/ipp-20110505/ippScripts/scripts/destreak_restore_camera.pl 31458-31658 /branches/eam_branches/ipp-20110710/ippScripts/scripts/destreak_restore_camera.pl 31852-32345 /branches/eam_branches/ipp-20110906/ippScripts/scripts/destreak_restore_camera.pl 32363-32631 /branches/eam_branches/ipp-20111110/ippScripts/scripts/destreak_restore_camera.pl 32645-32694 /branches/haf_add201112/ippScripts/scripts/destreak_restore_camera.pl 32980-33029
r33618 r33949 422 422 # looks like a censored one 423 423 if (scalar @{$file{bad_instances}}) { 424 my $bad = ${$file{bad_instances}} ->[0];424 my $bad = ${$file{bad_instances}}[0]; 425 425 $file{censored} = ($bad =~ /SR_/); 426 426 print "no good instances found setting censored based on $bad\n"; -
Property svn:mergeinfo
set to (toggle deleted branches)
-
branches/eam_branches/ipp-20120405/ippScripts/scripts/ipp_apply_burntool_single.pl
- Property svn:mergeinfo changed (with no actual effect on merging)
-
branches/eam_branches/ipp-20120405/ippScripts/scripts/magic_destreak.pl
- Property svn:mergeinfo changed (with no actual effect on merging)
-
branches/eam_branches/ipp-20120405/ippScripts/scripts/nightly_science.pl
r33371 r33949 1539 1539 $cmd .= " -simple -set_label $label -exp_id $input_exp_id -template_exp_id $template_exp_id "; 1540 1540 # $cmd .= " -pretend "; 1541 if (defined($reduction)) { 1542 $cmd .= " -set_reduction $reduction "; 1543 } 1544 1541 1545 if (defined($pretend)) { 1542 1546 $cmd .= ' -pretend '; … … 1670 1674 $cmd .= "-set_workdir $workdir -set_dist_group $dist_group -set_data_group $new_data_group "; 1671 1675 $cmd .= " -simple -set_label $label -exp_id $input_exp_id -template_exp_id $template_exp_id "; 1676 if (defined($reduction)) { 1677 $cmd .= " -set_reduction $reduction "; 1678 } 1679 1672 1680 # $cmd .= " -pretend "; 1673 1681 if (defined($pretend)) { … … 1724 1732 $check_cmd .= " -pretend -simple -rerun -set_label $label -filter $filter "; 1725 1733 $check_cmd .= " -dateobs_begin ${lunation_start}T00:00:00 -dateobs_end ${lunation_end}T23:59:59 -distance 1.5 "; 1734 if (defined($reduction)) { 1735 $check_cmd .= " -set_reduction $reduction "; 1736 } 1726 1737 1727 1738 my ($success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) = … … 1745 1756 $cmd .= " -simple -rerun -set_label $label -filter $filter "; 1746 1757 $cmd .= " -dateobs_begin ${lunation_start}T00:00:00 -dateobs_end ${lunation_end}T23:59:59 -distance 1.5 "; 1758 if (defined($reduction)) { 1759 $cmd .= " -set_reduction $reduction "; 1760 } 1747 1761 1748 1762 if (defined($pretend)) { -
branches/eam_branches/ipp-20120405/ippScripts/scripts/staticsky.pl
r33690 r33949 144 144 my $path_base = $file->{path_base}; 145 145 print "input: $path_base\n"; 146 my $stack_id = $file->{stack_id}; 146 147 147 148 my $imageCnv = $ipprc->filename("PPSTACK.OUTPUT", $path_base ); # Image name … … 172 173 &my_die("Couldn't find input: $sources", $sky_id, $PS_EXIT_SYS_ERROR) unless $ipprc->file_exists("$sources"); 173 174 175 print $listFile " STACK_ID S64 " . $stack_id . "\n"; 174 176 print $listFile " RAW:IMAGE STR " . $imageRaw . "\n"; 175 177 print $listFile " RAW:MASK STR " . $maskRaw . "\n"; -
branches/eam_branches/ipp-20120405/ippTasks/pstamp.pro
r33671 r33949 13 13 $pstampFin_DB = 0 14 14 $pstampRev_DB = 0 15 $pstampRevReq_DB = 0 15 16 $pstampDep_DB = 0 16 17 $pstampRevDep_DB = 0 … … 117 118 118 119 macro pstamp.revert.on 120 task pstamp.request.revert 121 active true 122 end 119 123 task pstamp.job.revert 120 124 active true … … 128 132 end 129 133 macro pstamp.revert.off 134 task pstamp.request.revert 135 active false 136 end 130 137 task pstamp.job.revert 131 138 active false … … 662 669 end 663 670 671 task pstamp.request.revert 672 host local 673 674 periods -poll $LOADPOLL 675 periods -exec 1200 676 periods -timeout 20 677 npending 1 678 679 task.exec 680 stdout NULL 681 stderr $LOGSUBDIR/pstamp.request.revert.log 682 $run = pstamptool -revertreq 683 if ($DB:n == 0) 684 option DEFAULT 685 else 686 $run = $run $PS_DBSERVER -dbname $DB:$pstampRevReq_DB 687 $pstampRevReq_DB ++ 688 if ($pstampRevReq_DB >= $DB:n) set pstampRevReq_DB = 0 689 end 690 add_poll_args run 691 add_poll_labels run 692 command $run 693 end 694 695 task.exit $EXIT_SUCCESS 696 # nothing to do 697 end 698 699 task.exit default 700 showcommand failure 701 end 702 703 task.exit crash 704 showcommand crash 705 end 706 707 task.exit timeout 708 showcommand timeout 709 end 710 end 664 711 task pstamp.job.revert 665 712 host local -
branches/eam_branches/ipp-20120405/ippTools/share/Makefile.am
r33525 r33949 450 450 vptool_pendingrun.sql \ 451 451 vptool_processedcell.sql \ 452 vptool_revertrun.sql 452 vptool_revertrun.sql \ 453 sctool_list.sql 453 454 -
branches/eam_branches/ipp-20120405/ippTools/share/camtool_find_pendingimfile.sql
- Property svn:mergeinfo changed (with no actual effect on merging)
-
branches/eam_branches/ipp-20120405/ippTools/share/chiptool_pendingimfile.sql
r27926 r33949 6 6 rawImfile.magicked as raw_magicked, 7 7 (rawImfile.user_1 is not NULL and rawImfile.user_1 > 0.5) as deburned, 8 rawImfile.burntool_state as burntool_state, 9 rawImfile.video_cells as video_cells, 8 10 rawExp.exp_tag, 9 11 rawExp.exp_name, -
branches/eam_branches/ipp-20120405/ippTools/share/chiptool_setimfiletoupdate.sql
- Property svn:mergeinfo changed (with no actual effect on merging)
-
branches/eam_branches/ipp-20120405/ippTools/share/pstamptool_revertreq_deletejobs.sql
r25199 r33949 3 3 FROM pstampJob 4 4 JOIN pstampRequest USING(req_id) 5 WHERE pstampRequest.state = 'new' 5 WHERE pstampRequest.state = 'new' 6 AND pstampRequest.fault > 0 -
branches/eam_branches/ipp-20120405/ippTools/share/pxadmin_create_tables.sql
- Property svn:mergeinfo changed (with no actual effect on merging)
-
branches/eam_branches/ipp-20120405/ippTools/share/staticskytool_definebyquery_inputs.sql
r31689 r33949 6 6 FROM stackRun 7 7 JOIN stackSumSkyfile USING(stack_id) 8 JOIN skycell USING(tess_id, skycell_id) 8 9 WHERE stackRun.state = 'full' 9 10 AND stackSumSkyfile.fault = 0 -
branches/eam_branches/ipp-20120405/ippTools/share/staticskytool_definebyquery_select.sql
r31687 r33949 10 10 FROM stackRun 11 11 JOIN stackSumSkyfile USING(stack_id) 12 JOIN skycell using(tess_id, skycell_id) 12 13 WHERE stackRun.state = 'full' 13 14 AND stackSumSkyfile.fault = 0 … … 29 30 JOIN stackRun USING(stack_id) 30 31 JOIN stackSumSkyfile USING(stack_id) 32 JOIN skycell USING(tess_id, skycell_id) 31 33 WHERE 1 32 34 -- restrict by selected filters, stackSumSkyfile.good_frac, stackRun.skycell_id, stackRun.label -
branches/eam_branches/ipp-20120405/ippTools/share/staticskytool_result.sql
r33384 r33949 6 6 stackRun.tess_id, 7 7 stackRun.skycell_id, 8 count(stackRun.filter) AS num_filters 8 count(stackRun.filter) AS num_filters, 9 skycell.glong, 10 skycell.glat 9 11 FROM staticskyRun 10 12 JOIN staticskyResult USING(sky_id) 11 13 JOIN staticskyInput USING(sky_id) 12 JOIN stackRun using(stack_id) 14 JOIN stackRun USING(stack_id) 15 LEFT JOIN skycell USING(tess_id, skycell_id) -
branches/eam_branches/ipp-20120405/ippTools/share/warptool_towarped.sql
- Property svn:mergeinfo changed (with no actual effect on merging)
-
branches/eam_branches/ipp-20120405/ippTools/src
- Property svn:mergeinfo changed
/trunk/ippTools/src (added) merged: 33730,33744,33779,33809,33821,33919-33922
- Property svn:mergeinfo changed
-
branches/eam_branches/ipp-20120405/ippTools/src/addtool.c
r33705 r33949 1417 1417 psString query = NULL; 1418 1418 psStringAppend(&query, bare_query, minidvodb_group); 1419 psStringAppend(&query, where_string);1419 psStringAppend(&query," %s ", where_string); 1420 1420 1421 1421 -
branches/eam_branches/ipp-20120405/ippTools/src/magictool.c
- Property svn:mergeinfo changed (with no actual effect on merging)
-
branches/eam_branches/ipp-20120405/ippTools/src/pstamptoolConfig.c
r33337 r33949 125 125 psMetadataAddStr(revertreqArgs, PS_LIST_TAIL, "-state", 0, "state to revert", NULL); 126 126 psMetadataAddStr(revertreqArgs, PS_LIST_TAIL, "-label", PS_META_DUPLICATE_OK, "search by pstampRequest label (LIKE comparision)", NULL); 127 // this argument is supplied by pantasks so we accept it but don't use it 128 psMetadataAddU64(revertreqArgs, PS_LIST_TAIL, "-limit", 0, "not used", 0); 127 129 128 130 // -pendingcleanup -
branches/eam_branches/ipp-20120405/ippTools/src/pxspace.c
r25770 r33949 56 56 psMetadataAddF64(md, PS_LIST_TAIL, "-decl", 0, "DEC value for radius search (degrees)", false); 57 57 } 58 59 void pxskycellAddArguments(psMetadata *md) 60 { 61 psMetadataAddF32(md, PS_LIST_TAIL, "-ra_min", 0, "search by right ascension (degrees)", NAN); 62 psMetadataAddF32(md, PS_LIST_TAIL, "-dec_min", 0, "search by declination (degrees)", NAN); 63 psMetadataAddF32(md, PS_LIST_TAIL, "-ra_max", 0, "search by right ascension (degrees)", NAN); 64 psMetadataAddF32(md, PS_LIST_TAIL, "-dec_max", 0, "search by declination (degrees)", NAN); 65 psMetadataAddF32(md, PS_LIST_TAIL, "-glong_min", 0, "search by galactic longitude (degrees)", NAN); 66 psMetadataAddF32(md, PS_LIST_TAIL, "-glat_min", 0, "search by galactic latitude (degrees)", NAN); 67 psMetadataAddF32(md, PS_LIST_TAIL, "-glong_max", 0, "search by galactic longitude (degrees)", NAN); 68 psMetadataAddF32(md, PS_LIST_TAIL, "-glat_max", 0, "search by galactic latitude (degrees)", NAN); 69 } 70 71 bool pxskycellAddWhere(pxConfig *config, psMetadata *where) 72 { 73 PXOPT_COPY_F32(config->args, where, "-ra_min", "skycell.radeg", ">="); 74 PXOPT_COPY_F32(config->args, where, "-dec_min", "skycell.decdeg", ">="); 75 PXOPT_COPY_F32(config->args, where, "-ra_max", "skycell.radeg", "<"); 76 PXOPT_COPY_F32(config->args, where, "-dec_max", "skycell.decdeg", "<"); 77 PXOPT_COPY_F32(config->args, where, "-glong_min", "skycell.glong", ">="); 78 PXOPT_COPY_F32(config->args, where, "-glat_min", "skycell.glat", ">="); 79 PXOPT_COPY_F32(config->args, where, "-glong_max", "skycell.glong", "<"); 80 PXOPT_COPY_F32(config->args, where, "-glat_max", "skycell.glat", "<"); 81 return true; 82 } -
branches/eam_branches/ipp-20120405/ippTools/src/pxspace.h
r25770 r33949 1 1 /* 2 * px magic.h2 * pxspace.h 3 3 * 4 4 * Copyright (C) 2009 IfA … … 24 24 extern void pxspaceAddArguments(psMetadata *md); 25 25 26 extern bool pxskycellAddWhere(pxConfig *config, psMetadata *where); 27 extern void pxskycellAddArguments(psMetadata *md); 28 26 29 #endif // PXSPACE_H -
branches/eam_branches/ipp-20120405/ippTools/src/sctool.c
r33720 r33949 31 31 #include "pxdata.h" 32 32 #include "pxchip.h" 33 #include "pxspace.h" 33 34 34 35 #include "sctool.h" 35 36 36 37 static bool defineskycellsMode(pxConfig *config); 38 static bool listMode(pxConfig *config); 37 39 38 40 # define MODECASE(caseName, func) \ … … 53 55 54 56 switch (config->mode) { 55 MODECASE(SCTOOL_MODE_DEFINESKYCELLS, defineskycellsMode); 57 MODECASE(SCTOOL_MODE_DEFINESKYCELLS, defineskycellsMode); 58 MODECASE(SCTOOL_MODE_LIST, listMode); 56 59 default: 57 60 psAbort("invalid option (this should not happen)"); … … 131 134 return true; 132 135 } 136 static bool listMode(pxConfig *config) 137 { 138 PS_ASSERT_PTR_NON_NULL(config, NULL); 139 140 PXOPT_LOOKUP_U64(limit, config->args, "-limit", false, false); 141 PXOPT_LOOKUP_BOOL(simple, config->args, "-simple", false); 142 psMetadata *where = psMetadataAlloc(); 143 144 PXOPT_COPY_STR(config->args, where, "-skycell_id", "skycell.skycell_id", "LIKE"); 145 PXOPT_COPY_STR(config->args, where, "-tess_id", "skycell.tess_id", "LIKE"); 146 pxskycellAddWhere(config, where); 147 148 psString query = pxDataGet("sctool_list.sql"); 149 if (!query) { 150 psError(PXTOOLS_ERR_SYS, false, "failed to retreive SQL statement"); 151 return false; 152 } 153 154 if (!psListLength(where->list)) { 155 psError(PXTOOLS_ERR_CONFIG, false, "search paramters are required\n"); 156 psFree(where); 157 return false; 158 } 159 psString whereClause = psDBGenerateWhereConditionSQL(where, NULL); 160 psStringAppend(&query, " WHERE %s", whereClause); 161 psFree(whereClause); 162 163 if (limit) { 164 psString limitString = psDBGenerateLimitSQL(limit); 165 psStringAppend(&query, " %s", limitString); 166 psFree(limitString); 167 } 168 169 if (!p_psDBRunQuery(config->dbh, query)) { 170 psError(PS_ERR_UNKNOWN, false, "database error"); 171 psFree(query); 172 return false; 173 } 174 psFree(query); 175 176 psArray *output = p_psDBFetchResult(config->dbh); 177 if (!output) { 178 psError(PS_ERR_UNKNOWN, false, "database error"); 179 return false; 180 } 181 182 if (!psArrayLength(output)) { 183 psTrace("sctool", PS_LOG_INFO, "no rows found"); 184 psFree(output); 185 return true; 186 } 187 188 if (!ippdbPrintMetadatas(stdout, output, "skycell", !simple)) { 189 psError(PS_ERR_UNKNOWN, false, "failed to print array"); 190 psFree(output); 191 return false; 192 } 193 194 psFree(output); 195 196 197 return true; 198 } -
branches/eam_branches/ipp-20120405/ippTools/src/sctool.h
r33720 r33949 26 26 SCTOOL_MODE_NONE = 0x0, 27 27 SCTOOL_MODE_DEFINESKYCELLS, 28 SCTOOL_MODE_LIST, 28 29 } sctoolMode; 29 30 -
branches/eam_branches/ipp-20120405/ippTools/src/stacktool.c
r31957 r33949 232 232 PXOPT_COPY_F32(config->args, where, "-select_fwhm_minor_min", "camProcessedExp.fwhm_minor", ">="); 233 233 PXOPT_COPY_F32(config->args, where, "-select_fwhm_minor_max", "camProcessedExp.fwhm_minor", "<="); 234 PXOPT_COPY_F32(config->args, where, "-select_elong_max", "(camProcessedExp.fwhm_major / camProcessedExp.fwhm_minor)", "<="); 235 PXOPT_COPY_F32(config->args, where, "-select_iq_elong_max", "(camProcessedExp.iq_fwhm_major / camProcessedExp.iq_fwhm_minor)", "<="); 234 236 PXOPT_COPY_F32(config->args, where, "-select_iq_m2_max", "camProcessedExp.iq_m2", "<="); 235 237 PXOPT_COPY_F32(config->args, where, "-select_iq_m2_min", "camProcessedExp.iq_m2", ">="); … … 239 241 PXOPT_COPY_F32(config->args, where, "-select_zpt_obs_min", "camProcessedExp.zpt_obs", ">="); 240 242 PXOPT_COPY_F32(config->args, where, "-select_zpt_obs_max", "camProcessedExp.zpt_obs", "<="); 243 PXOPT_COPY_F32(config->args, where, "-select_bg_max", "camProcessedExp.bg", "<="); 244 PXOPT_COPY_F32(config->args, where, "-select_bg_stdev_max", "camProcessedExp.bg_stdev", "<="); 241 245 PXOPT_COPY_F32(config->args, where, "-select_astrom", "sqrt(POWER(camProcessedExp.sigma_ra, 2) + POWER(camProcessedExp.sigma_dec, 2))", "<="); 242 246 -
branches/eam_branches/ipp-20120405/ippTools/src/stacktoolConfig.c
r31792 r33949 82 82 psMetadataAddF64(definebyqueryArgs, PS_LIST_TAIL, "-select_fwhm_minor_min", 0, "define min fwhm (minor axis)", NAN); 83 83 psMetadataAddF64(definebyqueryArgs, PS_LIST_TAIL, "-select_fwhm_minor_max", 0, "define max fwhm (minor axis)", NAN); 84 psMetadataAddF64(definebyqueryArgs, PS_LIST_TAIL, "-select_elong_max", 0, "define max elongation from fwhm ", NAN); 85 psMetadataAddF64(definebyqueryArgs, PS_LIST_TAIL, "-select_iq_elong_max", 0, "define max elongation from iq_fwhm ", NAN); 84 86 psMetadataAddF64(definebyqueryArgs, PS_LIST_TAIL, "-select_iq_m2_min", 0, "define min iq_m2", NAN); 85 87 psMetadataAddF64(definebyqueryArgs, PS_LIST_TAIL, "-select_iq_m2_max", 0, "define max iq_m2", NAN); … … 90 92 psMetadataAddF64(definebyqueryArgs, PS_LIST_TAIL, "-select_zpt_obs_min", 0, "define min zero point", NAN); 91 93 psMetadataAddF64(definebyqueryArgs, PS_LIST_TAIL, "-select_zpt_obs_max", 0, "define max zero point", NAN); 94 psMetadataAddF64(definebyqueryArgs, PS_LIST_TAIL, "-select_bg_max", 0, "define max background", NAN); 95 psMetadataAddF64(definebyqueryArgs, PS_LIST_TAIL, "-select_bg_stdev_max", 0, "define max background stdev", NAN); 92 96 psMetadataAddF64(definebyqueryArgs, PS_LIST_TAIL, "-select_astrom", 0, "define max astrometry rms", NAN); 93 97 psMetadataAddS64(definebyqueryArgs, PS_LIST_TAIL, "-warp_id", PS_META_DUPLICATE_OK, "include this warp ID (multiple OK)", 0); -
branches/eam_branches/ipp-20120405/ippTools/src/staticskytool.c
r33385 r33949 29 29 30 30 #include "pxtools.h" 31 #include "pxspace.h" 31 32 #include "staticskytool.h" 32 33 … … 131 132 pxAddLabelSearchArgs(config, whereMD, "-select_data_group", "stackRun.data_group", "LIKE"); 132 133 pxAddLabelSearchArgs(config, whereMD, "-select_filter", "stackRun.filter", "LIKE"); 134 PXOPT_COPY_F32(config->args, whereMD, "-select_glat_min", "skycell.glat", ">="); 135 PXOPT_COPY_F32(config->args, whereMD, "-select_glat_max", "skycell.glat", "<="); 133 136 134 137 // find the number of requested filters: … … 390 393 391 394 psMetadata *where = psMetadataAlloc(); 392 PXOPT_COPY_S64(config->args, where, "-sky_id", "sky_id", "=="); 393 PXOPT_COPY_STR(config->args, where, "-label", "label", "=="); 394 PXOPT_COPY_STR(config->args, where, "-state", "state", "=="); 395 PXOPT_COPY_S64(config->args, where, "-sky_id", "sky_id", "=="); 396 PXOPT_COPY_STR(config->args, where, "-label", "staticskyRun.label", "=="); 397 PXOPT_COPY_STR(config->args, where, "-state", "staticskyRun.state", "=="); 398 PXOPT_COPY_STR(config->args, where, "-tess_id", "stackRun.tess_id", "=="); 399 PXOPT_COPY_STR(config->args, where, "-skycell_id", "stackRun.skycell_id", "=="); 400 if (!pxskycellAddWhere(config, where)) { 401 psError(PXTOOLS_ERR_CONFIG, false, "failed to add skycell search arguments"); 402 return false; 403 } 395 404 if (!psListLength(where->list)) { 396 405 psFree(where); … … 399 408 } 400 409 401 psString query = psStringCopy("UPDATE staticskyRun ");410 psString query = psStringCopy("UPDATE staticskyRun JOIN staticskyInput USING(sky_id) JOIN stackRun using(stack_id) JOIN skycell USING(tess_id, skycell_id)"); 402 411 403 412 // pxUpdateRun gets parameters from config->args and updates … … 638 647 PXOPT_COPY_STR(config->args, where, "-skycell_id", "stackRun.skycell_id", "LIKE"); 639 648 PXOPT_COPY_S16(config->args, where, "-fault", "staticskyResult.fault", "=="); 649 pxskycellAddWhere(config, where); 640 650 PXOPT_LOOKUP_S32(num_filters, config->args, "-num_filters", false, false); 641 651 -
branches/eam_branches/ipp-20120405/ippTools/src/staticskytoolConfig.c
r33385 r33949 55 55 psMetadataAddStr(definebyqueryArgs, PS_LIST_TAIL, "-select_data_group", PS_META_DUPLICATE_OK, "search by stackRun data_group (LIKE comparison, multiple OK)", NULL); 56 56 psMetadataAddStr(definebyqueryArgs, PS_LIST_TAIL, "-select_filter", PS_META_DUPLICATE_OK, "search by filter (LIKE comparison, multiple OK)", NULL); 57 psMetadataAddF32(definebyqueryArgs, PS_LIST_TAIL, "-select_glat_min", 0, "define min galactic latitude", NAN); 58 psMetadataAddF32(definebyqueryArgs, PS_LIST_TAIL, "-select_glat_max", 0, "define max galactic latitude", NAN); 57 59 psMetadataAddStr(definebyqueryArgs, PS_LIST_TAIL, "-set_workdir", 0, "define workdir (required)", NULL); 58 60 psMetadataAddStr(definebyqueryArgs, PS_LIST_TAIL, "-set_label", 0, "define label (required)", NULL); … … 73 75 psMetadataAddStr(updaterunArgs, PS_LIST_TAIL, "-state", 0, "search by state", NULL); 74 76 psMetadataAddStr(updaterunArgs, PS_LIST_TAIL, "-label", 0, "search by label", 0); 77 psMetadataAddStr(updaterunArgs, PS_LIST_TAIL, "-tess_id", 0, "search by tess_id", NULL); 78 psMetadataAddStr(updaterunArgs, PS_LIST_TAIL, "-skycell_id", 0, "search by skycell_id", NULL); 79 pxskycellAddArguments(updaterunArgs); 75 80 psMetadataAddStr(updaterunArgs, PS_LIST_TAIL, "-set_label", 0, "define new value for label", NULL); 76 81 psMetadataAddStr(updaterunArgs, PS_LIST_TAIL, "-set_state", 0, "define new state", NULL); … … 113 118 psMetadataAddStr(resultArgs, PS_LIST_TAIL, "-data_group", 0, "search by data_group (LIKE comparison)", NULL); 114 119 psMetadataAddS16(resultArgs, PS_LIST_TAIL, "-num_filters", 0, "search by number of filters in the inputs (>=)", 0); 120 pxskycellAddArguments(resultArgs); 115 121 psMetadataAddS16(resultArgs, PS_LIST_TAIL, "-fault", 0, "search by fault code", 0); 116 122 psMetadataAddU64(resultArgs, PS_LIST_TAIL, "-limit", 0, "limit result set to N items", 0); -
branches/eam_branches/ipp-20120405/ppImage/src
- Property svn:mergeinfo changed
/trunk/ppImage/src (added) merged: 33848
- Property svn:mergeinfo changed
-
branches/eam_branches/ipp-20120405/ppImage/src/ppImage.h
r33590 r33949 57 57 bool addNoise; // Add noise to degrade MD image to 3pi 58 58 59 bool hasVideo; // Determine if this OTA has a video cell 60 bool useVideoDark; // Should we use a video dark if we can? 61 bool useVideoMask; // Should we use a video mask if we can? 62 59 63 // output files requested 60 64 bool BaseFITS; -
branches/eam_branches/ipp-20120405/ppImage/src/ppImageDetrendReadout.c
r33590 r33949 35 35 } 36 36 } 37 37 // Check to see if we're in a chip that contains video 38 bool hasVideo = false; 39 { 40 if (psMetadataLookupStr(NULL,input->parent->parent->hdu->header,"CELLMODE")) { 41 psWarning("VIDEO: %d %d %d\n",(int) options->hasVideo,(int) options->useVideoDark, (int) options->useVideoMask); 42 char *Vptr = strchr(psMetadataLookupStr(NULL,input->parent->parent->hdu->header,"CELLMODE"),'V'); 43 if (Vptr) { 44 hasVideo = true; 45 psWarning("VIDEO: %d %d %d\n",(int) options->hasVideo,(int) options->useVideoDark, (int) options->useVideoMask); 46 } 47 } 48 } 49 50 38 51 // Masking on the basis of pixel value needs to be done before anything else, so the values are pristine. 39 52 if (options->doMaskBuild) { … … 44 57 // apply the externally supplied mask to the input->mask pixels 45 58 if (options->doMask) { 46 pmReadout *mask = pmFPAfileThisReadout(config->files, detview, "PPIMAGE.MASK"); 47 pmMaskBadPixels(input, mask, options->maskValue); 59 pmReadout *mask; 60 if ((options->useVideoMask)&&(hasVideo)) { 61 mask = pmFPAfileThisReadout(config->files, detview, "PPIMAGE.VIDEOMASK"); 62 } 63 else { 64 mask = pmFPAfileThisReadout(config->files, detview, "PPIMAGE.MASK"); 65 } 66 pmMaskBadPixels(input, mask, options->maskValue); 48 67 } 49 68 if (options->doMaskBurntool) { … … 80 99 psMetadata *recipe = psMetadataLookupPtr (&mdok, config->recipes, RECIPE_NAME); 81 100 assert(mdok && recipe); 82 if (psMetadataLookupBool(&mdok, recipe, "OLDDARK")) { 101 102 if ((options->useVideoDark)&&(hasVideo)) { 103 if (psMetadataLookupBool(&mdok, recipe, "OLDDARK")) { 104 oldDark = pmFPAfileThisReadout(config->files, detview, "PPIMAGE.VIDEODARK"); 105 } else { 106 dark = pmFPAfileThisCell(config->files, detview, "PPIMAGE.VIDEODARK"); 107 } 108 } 109 else { 110 if (psMetadataLookupBool(&mdok, recipe, "OLDDARK")) { 83 111 oldDark = pmFPAfileThisReadout(config->files, detview, "PPIMAGE.DARK"); 84 } else {112 } else { 85 113 dark = pmFPAfileThisCell(config->files, detview, "PPIMAGE.DARK"); 86 } 114 } 115 } 87 116 } 88 117 -
branches/eam_branches/ipp-20120405/ppImage/src/ppImageOptions.c
r33590 r33949 45 45 options->doMaskStats = false; // Calculate mask fractions 46 46 options->addNoise = false; //Degrade an MD image to a 3pi image 47 47 options->hasVideo = false; // Determine if this OTA has a video cell 48 options->useVideoDark = false; // Use video dark if we can? 49 options->useVideoMask = false; // Use video mask if we can? 48 50 // output files requested 49 51 options->BaseFITS = false; // create output image … … 362 364 options->fringeKeep = psMetadataLookupF32(NULL, recipe, "FRINGE.KEEP"); 363 365 366 // Video cell options 367 if (psMetadataLookup(recipe, "USE.VIDEO.DARK")) { 368 options->useVideoDark = psMetadataLookupBool(NULL,recipe,"USE.VIDEO.DARK"); 369 } 370 if (psMetadataLookup(recipe, "USE.VIDEO.MASK")) { 371 options->useVideoMask = psMetadataLookupBool(NULL,recipe,"USE.VIDEO.MASK"); 372 } 373 364 374 // Pattern correction 365 375 if (psMetadataLookup(format, "PATTERN.ROW.ORDER")) { … … 418 428 options->patternContinuityEdgeWidth = psMetadataLookupS32(NULL, recipe, "PATTERN.CONTINUITY.WIDTH"); 419 429 } 420 430 421 431 422 432 // Remnance options -
branches/eam_branches/ipp-20120405/ppImage/src/ppImageParseCamera.c
r29833 r33949 22 22 ppImageOptions *options = ppImageOptionsParse(config); 23 23 24 // parse the header to extract out whether this OTA has video cells. 25 // CZW: 2012-05-01 I'm somewhat ashamed of what needs to be done to get to the header. There has to be a simpler way, right? 26 /* pmFPAview *view = pmFPAviewAlloc(0);// View for level of interest */ 27 /* pmChip *chip; // Chip from FPA */ 28 /* while ((chip = pmFPAviewNextChip(view, input->fpa, 1)) != NULL) { */ 29 /* if (!chip->process || !chip->file_exists) { */ 30 /* continue; */ 31 /* } */ 32 /* /\* if (!pmFPAfileIOChecks(config, view, PM_FPA_BEFORE)) { *\/ */ 33 /* /\* continue; *\/ */ 34 /* /\* } *\/ */ 35 /* psWarning("VIDEO: %d %d %d\n",(int) options->hasVideo,(int) options->useVideoDark, (int) options->useVideoMask); */ 36 /* if (psMetadataLookupStr(NULL,chip->hdu->header,"CELLMODE")) { */ 37 /* psWarning("VIDEO: %d %d %d\n",(int) options->hasVideo,(int) options->useVideoDark, (int) options->useVideoMask); */ 38 /* char *Vptr = strchr(psMetadataLookupStr(NULL,chip->hdu->header,"CELLMODE"),'V'); */ 39 /* if (Vptr) { */ 40 /* options->hasVideo = true; */ 41 /* psWarning("VIDEO: %d %d %d\n",(int) options->hasVideo,(int) options->useVideoDark, (int) options->useVideoMask); */ 42 /* } */ 43 /* } */ 44 /* } */ 45 /* pmFPAviewReset(view); */ 46 /* psFree(view); */ 47 24 48 // the following are defined from the argument list, if given, 25 49 // otherwise they revert to the config information … … 42 66 } 43 67 if (options->doDark) { 44 if (!ppImageDefineFile(config, input->fpa, "PPIMAGE.DARK", "DARK", 45 PM_FPA_FILE_DARK, PM_DETREND_TYPE_DARK)) { 68 // Always load the regular Dark 69 if (!ppImageDefineFile(config, input->fpa, "PPIMAGE.DARK", "DARK", 70 PM_FPA_FILE_DARK, PM_DETREND_TYPE_DARK)) { 71 psError(PS_ERR_IO, false, "Can't find a dark image source"); 72 psFree(options); 73 return NULL; 74 } 75 // Sometimes load the video dark if we need it. 76 if (options->useVideoDark) { 77 if (!ppImageDefineFile(config, input->fpa, "PPIMAGE.VIDEODARK", "DARK", 78 PM_FPA_FILE_DARK, PM_DETREND_TYPE_VIDEODARK)) { 46 79 psError(PS_ERR_IO, false, "Can't find a dark image source"); 47 80 psFree(options); 48 81 return NULL; 49 82 } 83 } 50 84 } 51 85 if (options->doMask) { 52 if (!ppImageDefineFile(config, input->fpa, "PPIMAGE.MASK", "MASK", 53 PM_FPA_FILE_MASK, PM_DETREND_TYPE_MASK)) { 86 // Always load the regular mask 87 if (!ppImageDefineFile(config, input->fpa, "PPIMAGE.MASK", "MASK", 88 PM_FPA_FILE_MASK, PM_DETREND_TYPE_MASK)) { 89 psError(PS_ERR_IO, false, "Can't find a mask image source"); 90 psFree(options); 91 return NULL; 92 } 93 94 if (options->useVideoMask) { 95 if (!ppImageDefineFile(config, input->fpa, "PPIMAGE.VIDEOMASK", "MASK", 96 PM_FPA_FILE_MASK, PM_DETREND_TYPE_VIDEOMASK)) { 54 97 psError(PS_ERR_IO, false, "Can't find a mask image source"); 55 98 psFree(options); 56 99 return NULL; 57 100 } 101 } 58 102 } 59 103 if (options->doShutter) { -
branches/eam_branches/ipp-20120405/ppMerge/src/ppMergeCamera.c
r33666 r33949 224 224 format = (HDU)->format; \ 225 225 } else if (format != (HDU)->format) { \ 226 psError(PS_ERR_UNKNOWN, true, "Camera format %d doesn't match: %p vs %p", \227 i, format, (HDU)->format); \226 psError(PS_ERR_UNKNOWN, true, "Camera format %d doesn't match: %p vs %p on %s %s", \ 227 i, format, (HDU)->format, (HDU)->extname, psMetadataLookupStr(NULL,(HDU)->header,"FILENAME")); \ 228 228 psFree(phuView); \ 229 229 return false; \ … … 232 232 } \ 233 233 } 234 // CZW: 2012-04-10 Version of above to allow different camera formats to be processed together. 235 /* #define CHECK_LEVEL(HDU, CHIP, CELL) { \ */ 236 /* if (HDU) { \ */ 237 /* if (!phuView) { \ */ 238 /* phuView = pmFPAviewAlloc(0); \ */ 239 /* phuView->chip = CHIP; \ */ 240 /* phuView->cell = CELL; \ */ 241 /* } else if ((phuView->chip != (CHIP)) && (phuView->cell != (CELL))) { \ */ 242 /* psError(PS_ERR_UNKNOWN, true, "Differing PHU for input %d", i); \ */ 243 /* psFree(phuView); \ */ 244 /* return false; \ */ 245 /* } \ */ 246 /* if (!format) { \ */ 247 /* format = (HDU)->format; \ */ 248 /* } else if (format != (HDU)->format) { \ */ 249 /* } \ */ 250 /* continue; \ */ 251 /* } \ */ 252 /* } */ 234 253 235 254 psMetadata *format = NULL; ///< Camera format -
branches/eam_branches/ipp-20120405/psastro/src/psastroLoadCrosstalk.c
r26826 r33949 53 53 pmFPAview *viewMask = pmFPAviewAlloc (0); 54 54 55 float zeropt, exptime, MAX_MAG ;55 float zeropt, exptime, MAX_MAG, SPIKE_MAX_MAG; 56 56 57 57 psLogMsg ("psastro", PS_LOG_INFO, "determine crosstalk positions"); … … 105 105 MAX_MAG += MagOffset; 106 106 107 // Get the spike maximum, as well 108 SPIKE_MAX_MAG = psMetadataLookupF32(&status, recipe, "REFSTAR_MASK_BLEED_MAG_MAX"); 109 SPIKE_MAX_MAG += MagOffset; 110 107 111 psTrace("psastro.crosstalk",2,"%f %f %f %f\n",zeropt,exptime,MAX_MAG,MagOffset); 108 112 … … 259 263 260 264 pmAstromObj *crosstalk = pmAstromObjAlloc(); 261 265 262 266 crosstalk->Mag = ref->Mag - MagOffset; 263 267 crosstalk->chip->x = x_t_chip; … … 274 278 } 275 279 psArrayAdd(crosstalks,100,crosstalk); 276 280 277 281 psFree(targetChipName); 278 282 psFree(targetCellName); 279 283 psFree(crosstalk); 284 285 // Determine if we need to add a spike mask. 286 /* psWarning("BLAH: %g %g %g\n",ref->Mag,MagOffset,SPIKE_MAX_MAG); */ 287 if (ref->Mag < SPIKE_MAX_MAG) { 288 if ((X == 2)&&(! ((U == 3)||(U == 5)||(U == 6)))) { 289 psTrace ("psastro.crosstalk",2,"Cell (%d%d) on chip (%d%d) not a known crosstalk source.",U,V,X,Y); 290 continue; 291 } 292 if ((X == 3)&&(! ((U == 3)))) { 293 psTrace ("psastro.crosstalk",2,"Cell (%d%d) on chip (%d%d) not a known crosstalk source.",U,V,X,Y); 294 continue; 295 } 296 if ((X == 4)&&(! ((U == 3)))) { 297 psTrace ("psastro.crosstalk",2,"Cell (%d%d) on chip (%d%d) not a known crosstalk source.",U,V,X,Y); 298 continue; 299 } 300 if ((X == 5)&&(! ((U == 3)||(U == 5)||(U == 6)))) { 301 psTrace ("psastro.crosstalk",2,"Cell (%d%d) on chip (%d%d) not a known crosstalk source.",U,V,X,Y); 302 continue; 303 } 304 305 Xt = X; 306 Yt = Y; 307 Vt = V; 308 309 for (Ut = 0; Ut < 8; Ut++) { 310 311 psString targetChipName = NULL; 312 psStringAppend(&targetChipName,"XY%d%d",Xt,Yt); 313 psString targetCellName = NULL; 314 psStringAppend(&targetCellName,"xy%d%d",Ut,Vt); 315 316 psTrace ("psastro.crosstalk",2,"CTsource @ OTA%d%dxy%d%d@%f,%f CTtarget OTA%d%dxy%d%d@%f,%f [%s %s]", 317 X,Y,U,V,x_cell,y_cell,Xt,Yt,Ut,Vt,x_t_cell,y_t_cell, 318 targetChipName,targetCellName); 319 /* psWarning ("CT bleed ct @ OTA%d%dxy%d%d@%f,%f CTtarget OTA%d%dxy%d%d@%f,%f [%s %s]", */ 320 /* X,Y,U,V,x_cell,y_cell,Xt,Yt,Ut,Vt,x_t_cell,y_t_cell, */ 321 /* targetChipName,targetCellName); */ 322 323 pmCell *CTtargetCell = getCellByName (CTsourceChip,targetCellName); 324 if (!CTtargetCell) continue; 325 326 pmChipCoordsForCell(&x_t_chip,&y_t_chip,CTtargetCell,x_t_cell,y_t_cell); 327 328 psTrace ("psastro.crosstalk",2,"CTsource @ OTA%d%dxy%d%d@%f,%f CTtarget OTA%d%dxy%d%d@%f,%f ChipLoc: (%f,%f)", 329 X,Y,U,V,x_cell,y_cell,Xt,Yt,Ut,Vt,x_t_cell,y_t_cell,x_t_chip,y_t_chip); 330 331 // Hunt down the readout for the target, and save the chip position and magnitude of source star. 332 pmChip *targetChip = getChipByName(fpa,targetChipName); 333 if (!targetChip) continue; 334 if (!targetChip->cells) continue; 335 if (!targetChip->cells->n) continue; 336 337 pmCell *targetCell = targetChip->cells->data[0]; 338 if (!targetCell) continue; 339 if (!targetCell->readouts) continue; 340 if (!targetCell->readouts->n) continue; 341 pmReadout *targetReadout = targetCell->readouts->data[0]; 342 if (!targetReadout) continue; 343 344 pmAstromObj *crosstalk = pmAstromObjAlloc(); 345 346 crosstalk->Mag = ref->Mag; 347 crosstalk->chip->x = x_t_chip; 348 crosstalk->chip->y = y_t_chip; 349 350 psArray *crosstalks = psMetadataLookupPtr (&status, targetReadout->analysis, "PSASTRO.CROSSTALKS.SPIKES"); 351 if (crosstalks == NULL) { 352 crosstalks = psArrayAllocEmpty(100); 353 if (!psMetadataAdd(targetReadout->analysis,PS_LIST_TAIL,"PSASTRO.CROSSTALKS.SPIKES", PS_DATA_ARRAY, "crosstalk locations", crosstalks)) { 354 psError(PSASTRO_ERR_CONFIG, false, "failure to add crosstalks to readout"); 355 goto escape; 356 } 357 psFree(crosstalks); 358 } 359 psArrayAdd(crosstalks,100,crosstalk); 360 361 psFree(targetChipName); 362 psFree(targetCellName); 363 psFree(crosstalk); 364 } 365 } // End satspike crosstalks 366 367 280 368 } // refstars 281 369 } // readout -
branches/eam_branches/ipp-20120405/psastro/src/psastroLoadGhosts.c
r26259 r33949 128 128 for (int i = 0; i < refstars->n; i++) { 129 129 pmAstromObj *ref = refstars->data[i]; 130 psTrace("psastro.ghost",5,"Begin ghost %d/%ld: MAX_MAG: %g; ref_mag: %g @ (%.10g,%.10g)",i,refstars->n,MAX_MAG,ref->Mag,ref->sky->r * 180 / M_PI,ref->sky->d * 180.0 / M_PI); 130 131 if (ref->Mag > MAX_MAG) continue; 131 132 … … 163 164 pmChip *ghostChip = psastroFindChip (&ghost->chip->x, &ghost->chip->y, fpa, -ghost->srcFP->x, -ghost->srcFP->y); 164 165 // fprintf (stderr, "raw chip position: %f, %f ", ghost->chip->x, ghost->chip->y); 165 166 /* float ref_chip_x = ghost->chip->x; */ 167 /* float ref_chip_y = ghost->chip->y; */ 166 168 ghostChip = psastroFindChip (&ghost->chip->x, &ghost->chip->y, fpa, ghost->FP->x, ghost->FP->y); 167 169 // fprintf (stderr, "-> model chip position: %f, %f\n", ghost->chip->x, ghost->chip->y); 168 170 171 if (ghostChip) { 172 psTrace("psastro.ghost",5," in ghost: %d/%ld: ref: (%f,%f) or (%s) ghost: (%f,%f) or (%f,%f,%s) %f inner: (%f,%f,%f) outer: (%f,%f,%f)", 173 i,refstars->n, 174 ref->FP->x,ref->FP->y, 175 psMetadataLookupStr(NULL,chip->concepts,"CHIP.NAME"), 176 ghost->FP->x,ghost->FP->y, 177 ghost->chip->x,ghost->chip->y,psMetadataLookupStr(NULL,ghostChip->concepts,"CHIP.NAME"), 178 rSrc, 179 ghost->inner.major,ghost->inner.minor,ghost->inner.theta, 180 ghost->outer.major,ghost->outer.minor,ghost->outer.theta); 181 /* psWarning(" GHOST_DATA: %d/%ld: ref: (%f,%f) or (%f,%f,%s) ghost: (%f,%f) or (%f,%f,%s) %f inner: (%f,%f,%f) outer: (%f,%f,%f)", */ 182 /* i,refstars->n, */ 183 /* ref->FP->x,ref->FP->y, */ 184 /* ref_chip_x,ref_chip_y,psMetadataLookupStr(NULL,chip->concepts,"CHIP.NAME"), */ 185 /* ghost->FP->x,ghost->FP->y, */ 186 /* ghost->chip->x,ghost->chip->y,psMetadataLookupStr(NULL,ghostChip->concepts,"CHIP.NAME"), */ 187 /* rSrc, */ 188 /* ghost->inner.major,ghost->inner.minor,ghost->inner.theta, */ 189 /* ghost->outer.major,ghost->outer.minor,ghost->outer.theta); */ 190 } 191 else { 192 psTrace("psastro.ghost",5," in ghost: %d/%ld: ref: (%f,%f) ghost: (%f,%f) or (%f,%f,%s) inner: (%f,%f,%f) outer: (%f,%f,%f)", 193 i,refstars->n, 194 ref->FP->x,ref->FP->y, 195 ghost->FP->x,ghost->FP->y, 196 ghost->chip->x,ghost->chip->y,"NONE", 197 ghost->inner.major,ghost->inner.minor,ghost->inner.theta, 198 ghost->outer.major,ghost->outer.minor,ghost->outer.theta); 199 } 200 201 202 169 203 if (!ghostChip) goto skip; 170 204 if (!ghostChip->cells) goto skip; 171 205 if (!ghostChip->cells->n) goto skip; 206 207 172 208 pmCell *ghostCell = ghostChip->cells->data[0]; 173 209 if (!ghostCell) goto skip; … … 190 226 191 227 skip: 228 192 229 psFree (ghost); 193 230 } -
branches/eam_branches/ipp-20120405/psastro/src/psastroMaskUpdates.c
r30873 r33949 406 406 // XXX for now, assume cell binning is 1x1 relative to chip 407 407 psastroMaskCircle (readoutMask->mask, crosstalkMaskValue, ref->chip->x, ref->chip->y, radius, radius); 408 } 409 } 410 // Crosstalk Bleeds 411 psArray *bleedcrosstalks = psMetadataLookupPtr (&status, readout->analysis, "PSASTRO.CROSSTALKS.SPIKES"); 412 if (bleedcrosstalks) { 413 for (int i = 0; i < bleedcrosstalks->n; i++) { 414 pmAstromObj *ref = bleedcrosstalks->data[i]; 415 float width = REFSTAR_MASK_BLEED_MAG_SLOPE * (REFSTAR_MASK_BLEED_MAG_MAX - ref->Mag); 416 psTrace("psastro.crosstalk",2,"Masking spike on Chip %s @ (%f,%f) Magnitude: %f Radius %f\n", 417 psMetadataLookupStr(&status,readout->parent->parent->concepts,"CHIP.NAME"), 418 ref->chip->x,ref->chip->y,ref->Mag,width); 419 // XXX for now, assume cell binning is 1x1 relative to chip 420 pmCell *refCell = pmCellInChip(refChip,ref->chip->x,ref->chip->y); 421 if (refCell) { 422 float xCell = 0.0; 423 float yCell = 0.0; 424 pmCellCoordsForChip (&xCell, &yCell, refCell, ref->chip->x, ref->chip->y); 425 int ySize = psMetadataLookupS32(NULL,refCell->concepts,"CELL.YSIZE"); 426 /* psWarning("Masking CTspike on Chip %s @ (%f,%f) Magnitude: %f (%f %f) Radius %f Z: %d %d %d %d\n", */ 427 /* psMetadataLookupStr(&status,readout->parent->parent->concepts,"CHIP.NAME"), */ 428 /* ref->chip->x,ref->chip->y,ref->Mag,REFSTAR_MASK_BLEED_MAG_SLOPE,REFSTAR_MASK_BLEED_MAG_MAX,width, */ 429 /* (int) (ref->chip->x - 0.5 * width), (int) (ref->chip->y - yCell), */ 430 /* (int) (ref->chip->x+0.5 * width + 1), (int) (ref->chip->y + (ySize - yCell))); */ 431 psastroMaskRectangle (readoutMask->mask, crosstalkMaskValue, 432 (int) (ref->chip->x - 0.5 * width), (int) (ref->chip->y - yCell), 433 (int) (ref->chip->x+0.5 * width + 1), (int) (ref->chip->y + (ySize - yCell))); 434 } 408 435 } 409 436 } -
branches/eam_branches/ipp-20120405/psastro/src/psastroMaskUtils.c
r24045 r33949 135 135 // XXX optimize this 136 136 float A = 1.0; 137 float B = shape.sxy*y*PS_SQR(shape.sx);137 float B = 2.0 * shape.sxy*y*PS_SQR(shape.sx); 138 138 float C = PS_SQR(y*shape.sx/shape.sy) - PS_SQR(shape.sx); 139 139 -
branches/eam_branches/ipp-20120405/tools/czarcal
r33317 r33949 24 24 mark 25 25 serge 26 roy27 26 chris 28 27 gene -
branches/eam_branches/ipp-20120405/tools/dlapstacks
r33575 r33949 215 215 } else { 216 216 # otherwise use a temporary directory 217 $outdir = $tempdir; 217 218 print "deasined files will be saved to $outdir\n" if $save_temps; 218 $outdir = $tempdir;219 219 } 220 220 } -
branches/eam_branches/ipp-20120405/tools/repair_bad_instance
r33197 r33949 123 123 return 0; 124 124 } 125 if (! ($nextend =~ /\d+/)) { 126 print "failed to find NEXTEND for $file. command returned $nextend\n"; 127 return 0; 128 } 125 129 print "\t$file: $nextend extensions\n"; 130 126 131 127 132 $command = 'fhead -x ' . ($nextend - 1) . " $file | grep EXTNAME | awk '{print \$3}'"; -
branches/eam_branches/ipp-20120405/tools/runbgchip.pl
r33068 r33949 97 97 exit 0 if $pretend; 98 98 99 exit system $command; 99 my $rc = system $command; 100 my $status = $rc >> 8; 101 if ($rc) { 102 print "command returned $rc $status\n"; 103 } 104 exit $status; 100 105 101 106 -
branches/eam_branches/ipp-20120405/tools/runchipimfile.pl
r33067 r33949 110 110 exit 0 if $pretend; 111 111 112 exit system $command; 112 my $rc = system $command; 113 my $status = $rc >> 8; 114 if ($rc) { 115 print STDERR "command failed with $rc $status\n"; 116 $status = 1 unless $status; 117 } else { 118 print "Successfully rebuilt chip $chip_id $class_id\n"; 119 } 120 exit $status; 113 121 114 122 -
branches/eam_branches/ipp-20120405/tools/runwarpskycell.pl
r31942 r33949 105 105 exit 0 if $pretend; 106 106 107 exit system $command; 107 my $rc = system $command; 108 exit $rc >> 8; 108 109 109 110
Note:
See TracChangeset
for help on using the changeset viewer.
