Changeset 42462
- Timestamp:
- May 12, 2023, 9:21:20 AM (3 years ago)
- Location:
- trunk/tools/eam/rawfix.20230221/src
- Files:
-
- 16 edited
-
advance.rawfix.pl (modified) (1 diff)
-
check_chip_locations.pl (modified) (9 diffs)
-
check_md5s_dateobs.pl (modified) (9 diffs)
-
check_night_status.pl (modified) (3 diffs)
-
finish.fixchip.sh (modified) (3 diffs)
-
fix_chip_failures.pl (modified) (1 diff)
-
fix_chip_locations.pl (modified) (12 diffs)
-
get_hosts_fixchip.sh (modified) (2 diffs)
-
get_hosts_md5s.sh (modified) (1 diff)
-
get_md5s_instances.pl (modified) (4 diffs)
-
rawfix.burntool.pt (modified) (1 diff)
-
rawfix.ckchip.pt (modified) (2 diffs)
-
rawfix.fixchip.pt (modified) (1 diff)
-
rawfix.md5chk.pt (modified) (1 diff)
-
rawfix.md5sum.pt (modified) (1 diff)
-
update_chip_stats.pl (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/tools/eam/rawfix.20230221/src/advance.rawfix.pl
r42452 r42462 13 13 14 14 # USAGE: advance.rawfix.pl --mode (all/night) --dateobs (night) --topdir (dirname) --Nmax Nmax 15 # topdir used only to find the nebulous config 15 16 16 17 my ($mode, $topdir, $fulldate, $dateword, $Nmax) = &parse_cmdopts; -
trunk/tools/eam/rawfix.20230221/src/check_chip_locations.pl
r42457 r42462 16 16 # USAGE: check_chip_locations.pl --dateobs 2010/05/01 --chiplist gpc1.chips.txt --stage 0 17 17 18 my ($fulldate, $dateword, $chiplist, $stage, $topdir ) = &parse_cmdopts;18 my ($fulldate, $dateword, $chiplist, $stage, $topdir, $basedir) = &parse_cmdopts; 19 19 my ($neb_dbh, $gpc_dbh, $raw_dbh) = &parse_db_config ("$topdir/nebulous.config"); 20 20 … … 27 27 28 28 # put output files in a directory defined by the night 29 mkdir "$ topdir/$dateword";29 mkdir "$basedir/$dateword"; 30 30 31 31 # output files: … … 48 48 my $Nfail = 0; 49 49 50 my ($goodchips_r, $failchips_r) = &get_good_or_fail_chiplists ($ topdir, $dateword, $stage);50 my ($goodchips_r, $failchips_r) = &get_good_or_fail_chiplists ($basedir, $dateword, $stage); 51 51 52 52 foreach my $chip_id (@chip_ids) { 53 53 54 54 my $outfh; 55 open ($outfh, ">$ topdir/$dateword/$chip_id.uris.$stage.txt");56 57 # print "open $ topdir/$dateword/$chip_id.uris.$stage.txt\n";55 open ($outfh, ">$basedir/$dateword/$chip_id.uris.$stage.txt"); 56 57 # print "open $basedir/$dateword/$chip_id.uris.$stage.txt\n"; 58 58 59 59 # get the list of chip neb paths for one chip … … 87 87 # now save the host count for this chip 88 88 my $hostfh; 89 open ($hostfh, ">$ topdir/$dateword/$chip_id.hosts.txt");89 open ($hostfh, ">$basedir/$dateword/$chip_id.hosts.txt"); 90 90 91 91 # save the host count for this chip … … 277 277 278 278 if (not defined $hostfile{$hostname}) { 279 open ($hostfile{$hostname}, ">$ topdir/$dateword/$hostname.inst.$stage.txt");279 open ($hostfile{$hostname}, ">$basedir/$dateword/$hostname.inst.$stage.txt"); 280 280 ## XXX deal with open failure here 281 281 } … … 408 408 sub get_good_or_fail_chiplists { 409 409 410 my $ topdir = $_[0];410 my $basedir = $_[0]; 411 411 my $dateword = $_[1]; 412 412 my $stage = $_[2]; … … 414 414 # load the lists of good and fail chips 415 415 my $prev = $stage - 1; 416 my $goodfile = "$ topdir/$dateword/goodchips.$prev.txt";416 my $goodfile = "$basedir/$dateword/goodchips.$prev.txt"; 417 417 my %goodchips; 418 418 if (-e $goodfile) { … … 426 426 } 427 427 } 428 my $failfile = "$ topdir/$dateword/failchips.$prev.txt";428 my $failfile = "$basedir/$dateword/failchips.$prev.txt"; 429 429 my %failchips; 430 430 if (-e $failfile) { … … 466 466 my $dateword = sprintf ("%4d%02d%02d", $date_year, $date_month, $date_day); 467 467 468 return ($fulldate, $dateword, $chiplist, $stage, $topdir) 468 my $yearobs = substr ($dateword, 0, 4); 469 my $basedir = "$topdir/$yearobs"; 470 471 return ($fulldate, $dateword, $chiplist, $stage, $topdir, $basedir) 469 472 } 470 473 -
trunk/tools/eam/rawfix.20230221/src/check_md5s_dateobs.pl
r42452 r42462 14 14 # USAGE: check_md5s_dateobs.pl --dateobs (night) --topdir (topdir) 15 15 16 my ($dateword, $stage, $topdir) = &parse_cmdopts; 17 18 my $instlist_r = &load_instlist_filenames ($topdir, $dateword, $stage); 19 my $md5slist_r = &load_md5slist_filenames ($topdir, $dateword, $stage, $instlist_r); 16 my ($dateword, $stage, $topdir, $basedir) = &parse_cmdopts; 17 # basedir used only for night-level files 18 19 my $instlist_r = &load_instlist_filenames ($basedir, $dateword, $stage); 20 my $md5slist_r = &load_md5slist_filenames ($basedir, $dateword, $stage, $instlist_r); 20 21 21 22 my $Nfail = 0; … … 36 37 close (FILE); 37 38 38 my $instdata_r = &load_instance_list ($ topdir, $dateword, $stage, $instfile);39 my $instdata_r = &load_instance_list ($basedir, $dateword, $stage, $instfile); 39 40 40 41 # if these do not match, complain and move on … … 94 95 95 96 # save both good and fail chip lists 96 open (OUTFILE, ">$ topdir/$dateword/goodchips.$stage.txt");97 open (OUTFILE, ">$basedir/$dateword/goodchips.$stage.txt"); 97 98 my @goodchipURIs = keys %goodchips; 98 99 foreach my $uri (@goodchipURIs) { … … 101 102 close (OUTFILE); 102 103 103 open (OUTFILE, ">$ topdir/$dateword/failchips.$stage.txt");104 open (OUTFILE, ">$basedir/$dateword/failchips.$stage.txt"); 104 105 my @failchipURIs = keys %failchips; 105 106 foreach my $uri (@failchipURIs) { … … 120 121 } 121 122 122 # use global $ topdir, $dateword, $myhost, $stage123 # use global $basedir, $dateword, $myhost, $stage 123 124 sub load_instance_list { 124 my $ topdir = $_[0];125 my $basedir = $_[0]; 125 126 my $dateword = $_[1]; 126 127 my $stage = $_[2]; … … 134 135 # there may be additional instances in files with names like HOSTNAME.XYnn.inst.STAGE 135 136 my ($myhost) = $instfile =~ m|$dateword/([0-9a-zA-Z]*).inst.$stage.txt|; 136 my @instlist = glob ("$ topdir/$dateword/$myhost.XY??.inst.$stage.txt");137 my @instlist = glob ("$basedir/$dateword/$myhost.XY??.inst.$stage.txt"); 137 138 foreach my $infile (@instlist) { 138 139 &load_instance_list_onefile ($infile, \@instdata_list); … … 160 161 sub load_instlist_filenames { 161 162 162 my $ topdir = $_[0];163 my $basedir = $_[0]; 163 164 my $dateword = $_[1]; 164 165 my $stage = $_[2]; 165 166 166 my @instlist_all = glob ("$ topdir/$dateword/*.inst.$stage.txt");167 my @instlist_all = glob ("$basedir/$dateword/*.inst.$stage.txt"); 167 168 168 169 my @instlist = (); … … 181 182 sub load_md5slist_filenames { 182 183 183 my $ topdir = $_[0];184 my $basedir = $_[0]; 184 185 my $dateword = $_[1]; 185 186 my $stage = $_[2]; 186 187 my $instlist_r = $_[3]; 187 188 188 my @md5slist = glob ("$ topdir/$dateword/*.md5s.txt");189 my @md5slist = glob ("$basedir/$dateword/*.md5s.txt"); 189 190 190 191 my %md5shash; … … 252 253 my $dateword = sprintf ("%4d%02d%02d", $date_year, $date_month, $date_day); 253 254 254 return ($dateword, $stage, $topdir); 255 my $yearobs = substr ($dateword, 0, 4); 256 my $basedir = "$topdir/$yearobs"; 257 258 return ($dateword, $stage, $topdir, $basedir); 255 259 } 256 260 -
trunk/tools/eam/rawfix.20230221/src/check_night_status.pl
r42445 r42462 1 1 #! /usr/bin/env perl 2 # this program must be run at the top-level rawfix directory 2 3 3 4 my $DEBUG = 4; … … 18 19 19 20 my ($fulldate, $dateword, $chiplist, $stage) = &parse_cmdopts; 21 my $yearobs = substr ($dateword, 0, 4); 20 22 21 23 # read the list of chip_ids: … … 36 38 foreach my $chip_id (@chip_ids) { 37 39 38 my $urifile = "$ dateword/$chip_id.uris.$stage.txt";40 my $urifile = "$yearobs/$dateword/$chip_id.uris.$stage.txt"; 39 41 unless (-e $urifile) { die "missing chip URI list $urifile\n"; } 40 42 -
trunk/tools/eam/rawfix.20230221/src/finish.fixchip.sh
r42449 r42462 1 1 #!/bin/csh 2 3 # this script is not actually used in regular rawfix processing? 2 4 3 5 if ($#argv != 4) then … … 16 18 endif 17 19 18 if (! -d $topdir/$dateobs) then 19 echo "ERROR: missing dateobs directory $topdir/$dateobs" 20 set yearobs = `echo $dateobs | awk '{print substr($1,1,4)}'` 21 set basedir = $topdir/$yearobs 22 23 if (! -d $basedir/$dateobs) then 24 echo "ERROR: missing dateobs directory $basedir/$dateobs" 20 25 exit 3 21 26 endif … … 24 29 echo $fulldate 25 30 26 $topdir/update_chip_stats.pl --topdir $topdir --dateobs $fulldate --stage $iter --chiplist gpc1.chips.txt31 update_chip_stats.pl --topdir $topdir --dateobs $fulldate --stage $iter --chiplist gpc1.chips.txt 27 32 28 33 if ($QUALITY == "OK") then 29 $topdir/update.rawfix.sh $dateobs fixchip.done34 update.rawfix.sh $dateobs fixchip.done 30 35 else 31 $topdir/update.rawfix.sh $dateobs fixchip.fail36 update.rawfix.sh $dateobs fixchip.fail 32 37 endif 33 38 -
trunk/tools/eam/rawfix.20230221/src/fix_chip_failures.pl
r42445 r42462 1 1 #! /usr/bin/env perl 2 2 3 XXX: not yet ready 3 die "not yet ready"; 4 4 5 5 # NOTE: in this script, we are using database connections to both NEBULOUS and GPC1 databases -
trunk/tools/eam/rawfix.20230221/src/fix_chip_locations.pl
r42451 r42462 18 18 # for each chip, target a single host? 19 19 20 my ($fulldate, $dateword, $chiplist, $chipID, $stage, $topdir ) = &parse_cmdopts;20 my ($fulldate, $dateword, $chiplist, $chipID, $stage, $topdir, $basedir) = &parse_cmdopts; 21 21 my ($neb_dbh, $raw_dbh) = &parse_db_config ("$topdir/nebulous.config"); 22 # topdir used for nebulous.config and chiplist.txt, basedir used for night-level data 22 23 23 24 # choose ITC machines on which to place backup copies: … … 40 41 my $Nfail = 0; 41 42 42 my ($goodchips_r, $failchips_r) = &get_good_or_fail_chiplists ($ topdir, $dateword, $stage);43 my ($goodchips_r, $failchips_r) = &get_good_or_fail_chiplists ($basedir, $dateword, $stage); 43 44 44 45 # read the list of chip_ids: … … 80 81 } else { 81 82 82 open (OUTFILE, ">$ topdir/$dateword/$chipID.stats.$stage.txt");83 open (OUTFILE, ">$basedir/$dateword/$chipID.stats.$stage.txt"); 83 84 84 85 print OUTFILE "Nchip: $Nchip\n"; … … 106 107 107 108 # read from chip_id file, update to next stage number 108 my $urifile = "$ topdir/$dateword/$chip_id.uris.$stage.txt";109 my $urifile = "$basedir/$dateword/$chip_id.uris.$stage.txt"; 109 110 if (! -e $urifile) { die "missing file $urifile\n"; } 110 111 open (URIFILE, $urifile); … … 145 146 my ($newfile, $newhost, $newxattr) = &get_new_instance ($ext_id); 146 147 unless ($newxattr == 1) { die "new instance is not at ATRC? $ext_id : $newfile : $newhost : $newxattr\n"; } 147 open (OUTFILE, ">>$ topdir/$dateword/$newhost.$chip_id.inst.$stage.txt");148 open (OUTFILE, ">>$basedir/$dateword/$newhost.$chip_id.inst.$stage.txt"); 148 149 print OUTFILE "$newfile $datast $md5sum\n"; 149 150 close (OUTFILE); … … 160 161 my ($newfile, $newhost, $newxattr) = &get_new_instance ($ext_id); 161 162 unless ($newxattr == 0) { die "new instance is not at ITC? $ext_id : $newfile : $newhost : $newxattr\n"; } 162 open (OUTFILE, ">>$ topdir/$dateword/$newhost.$chip_id.inst.$stage.txt");163 open (OUTFILE, ">>$basedir/$dateword/$newhost.$chip_id.inst.$stage.txt"); 163 164 print OUTFILE "$newfile $datast $md5sum\n"; 164 165 close (OUTFILE); … … 175 176 my ($newfile, $newhost, $newxattr) = &get_new_instance ($ext_id); 176 177 unless ($newxattr == 1) { die "new instance is not at ATRC? $ext_id : $newfile : $newhost : $newxattr\n"; } 177 open (OUTFILE, ">>$ topdir/$dateword/$newhost.$chip_id.inst.$stage.txt");178 open (OUTFILE, ">>$basedir/$dateword/$newhost.$chip_id.inst.$stage.txt"); 178 179 print OUTFILE "$newfile $datast $md5sum\n"; 179 180 close (OUTFILE); … … 197 198 my ($newfile, $newhost, $newxattr) = &get_new_instance ($ext_id); 198 199 unless ($newxattr == 0) { die "new instance is not at ITC? $ext_id : $newfile : $newhost : $newxattr\n"; } 199 open (OUTFILE, ">>$ topdir/$dateword/$newhost.$chip_id.inst.$stage.txt");200 open (OUTFILE, ">>$basedir/$dateword/$newhost.$chip_id.inst.$stage.txt"); 200 201 print OUTFILE "$newfile $datast $md5sum\n"; 201 202 close (OUTFILE); … … 327 328 sub get_good_or_fail_chiplists { 328 329 329 my $ topdir = $_[0];330 my $basedir = $_[0]; 330 331 my $dateword = $_[1]; 331 332 my $stage = $_[2]; … … 333 334 # load the lists of good and fail chips 334 335 my $prev = $stage - 1; 335 my $goodfile = "$ topdir/$dateword/goodchips.$prev.txt";336 my $goodfile = "$basedir/$dateword/goodchips.$prev.txt"; 336 337 my %goodchips; 337 338 if (-e $goodfile) { … … 345 346 } 346 347 } 347 my $failfile = "$ topdir/$dateword/failchips.$prev.txt";348 my $failfile = "$basedir/$dateword/failchips.$prev.txt"; 348 349 my %failchips; 349 350 if (-e $failfile) { … … 464 465 my $dateword = sprintf ("%4d%02d%02d", $date_year, $date_month, $date_day); 465 466 466 return ($fulldate, $dateword, $chiplist, $chipID, $stage, $topdir); 467 my ($yearobs) = substr ($dateword, 0, 4); 468 my $basedir = "$topdir/$yearobs"; 469 470 return ($fulldate, $dateword, $chiplist, $chipID, $stage, $topdir, $basedir); 467 471 } 468 472 -
trunk/tools/eam/rawfix.20230221/src/get_hosts_fixchip.sh
r42457 r42462 15 15 endif 16 16 17 if (! -d $topdir/$dateobs) then 18 echo "ERROR: missing dateobs directory $topdir/$dateobs" 17 set yearobs = `echo $dateobs | awk '{print substr($1,1,4)}'` 18 set basedir = $topdir/$yearobs 19 20 if (! -d $basedir/$dateobs) then 21 echo "ERROR: missing dateobs directory $basedir/$dateobs" 19 22 exit 3 20 23 endif … … 23 26 echo "dateobs chipID iter fixhost" 24 27 25 foreach f ($ topdir/$dateobs/XY??.hosts.txt)28 foreach f ($basedir/$dateobs/XY??.hosts.txt) 26 29 set myhost = `cat $f | grep -v ippb | sort -k 2n | tail -n 1 | prcol 1` 27 30 set chipID = `echo $f | awk -F/ '{print $NF}' | awk -F. '{print $1}'` -
trunk/tools/eam/rawfix.20230221/src/get_hosts_md5s.sh
r42452 r42462 15 15 endif 16 16 17 if (! -d $topdir/$dateobs) then 18 echo "ERROR: missing dateobs directory $topdir/$dateobs" 17 set yearobs = `echo $dateobs | awk '{print substr($1,1,4)}'` 18 set basedir = $topdir/$yearobs 19 20 if (! -d $basedir/$dateobs) then 21 echo "ERROR: missing dateobs directory $basedir/$dateobs" 19 22 exit 3 20 23 endif 21 24 22 25 # report both the dateobs and the hostnames 23 ls $ topdir/$dateobs/*.inst.$stage.txt | grep -v "XY...inst" | awk -v dateobs=$dateobs -v stage=$stage -F/ '(NR == 1){print "dateobs stage md5host"}{print dateobs, stage, $NF}' | sed s/.inst.$stage.txt//26 ls $basedir/$dateobs/*.inst.$stage.txt | grep -v "XY...inst" | awk -v dateobs=$dateobs -v stage=$stage -F/ '(NR == 1){print "dateobs stage md5host"}{print dateobs, stage, $NF}' | sed s/.inst.$stage.txt// 24 27 exit 0 -
trunk/tools/eam/rawfix.20230221/src/get_md5s_instances.pl
r42451 r42462 14 14 15 15 my $input; 16 my ($myhost, $dateword, $topdir, $ stage) = &parse_cmdopts;16 my ($myhost, $dateword, $topdir, $basedir, $stage) = &parse_cmdopts; 17 17 18 18 # check that we are running this script on 'myhost' … … 23 23 my ($ins_list_r, $dst_list_r, $md5_list_r) = &load_instance_list (); 24 24 25 my $output = "$ topdir/$dateword/$myhost.md5s.txt";25 my $output = "$basedir/$dateword/$myhost.md5s.txt"; 26 26 27 27 # read in existing md5s … … 66 66 exit 0; 67 67 68 # use global $ topdir, $dateword, $myhost, $stage68 # use global $basedir, $dateword, $myhost, $stage 69 69 sub load_instance_list { 70 70 my (@ins_list, @dst_list, @md5_list); 71 71 72 72 # load the master list 73 my $input = "$ topdir/$dateword/$myhost.inst.$stage.txt";73 my $input = "$basedir/$dateword/$myhost.inst.$stage.txt"; 74 74 &load_instance_list_onefile ($input, \@ins_list, \@dst_list, \@md5_list); 75 75 76 76 # there may be additional instances in files with names like HOSTNAME.XYnn.inst.STAGE 77 my @instlist = glob ("$ topdir/$dateword/$myhost.XY??.inst.$stage.txt");77 my @instlist = glob ("$basedir/$dateword/$myhost.XY??.inst.$stage.txt"); 78 78 foreach my $infile (@instlist) { 79 79 &load_instance_list_onefile ($infile, \@ins_list, \@dst_list, \@md5_list); … … 144 144 unless ($stage >= 0) { die "stage must be a non-negative integer\n"; } 145 145 146 return ($myhost, $dateobs, $topdir, $stage); 146 my $yearobs = substr ($dateobs, 0, 4); 147 my $basedir = "$topdir/$yearobs"; 148 149 return ($myhost, $dateobs, $topdir, $basedir, $stage); 147 150 } 148 151 -
trunk/tools/eam/rawfix.20230221/src/rawfix.burntool.pt
r42460 r42462 168 168 end 169 169 170 sprintf psvidOutput "%s/%s " $mypath$DATEOBS170 sprintf psvidOutput "%s/%s/%s" $mypath $YEAR $DATEOBS 171 171 172 172 # if we are able to run the 'exec', use a short retry time to launch all outstanding jobs -
trunk/tools/eam/rawfix.20230221/src/rawfix.ckchip.pt
r42454 r42462 59 59 periods -timeout 60 60 60 host -required $HOST_CKCHIP 61 npending 161 npending 2 62 62 63 63 task.exec … … 78 78 option $pageName 79 79 80 # this is the first place in the proces that this location is known81 mkdir $mypath/$DATEOBS82 stdout $mypath/$DATEOBS/log.ckchip.runhosts.v$ITER83 stderr $mypath/$DATEOBS/log.ckchip.runhosts.v$ITER84 85 80 substr $DATEOBS 0 4 YEAR 86 81 substr $DATEOBS 4 2 MONTH 87 82 substr $DATEOBS 6 2 DAY 83 84 # this is the first place in the proces that this location is known 85 mkdir $mypath/$YEAR/$DATEOBS 86 stdout $mypath/$YEAR/$DATEOBS/log.ckchip.runhosts.v$ITER 87 stderr $mypath/$YEAR/$DATEOBS/log.ckchip.runhosts.v$ITER 88 88 89 89 sprintf FULLDATE "%s/%s/%s" $YEAR $MONTH $DAY -
trunk/tools/eam/rawfix.20230221/src/rawfix.fixchip.pt
r42454 r42462 151 151 option $pageName $DATEOBS 152 152 153 stdout $DATEOBS/log.fixchip.run.$CHIP_ID.v$ITER154 stderr $DATEOBS/log.fixchip.run.$CHIP_ID.v$ITER155 156 153 substr $DATEOBS 0 4 YEAR 157 154 substr $DATEOBS 4 2 MONTH 158 155 substr $DATEOBS 6 2 DAY 159 156 sprintf FULLDATE "%s/%s/%s" $YEAR $MONTH $DAY 157 158 stdout $mypath/$YEAR/$DATEOBS/log.fixchip.run.$CHIP_ID.v$ITER 159 stderr $mypath/$YEAR/$DATEOBS/log.fixchip.run.$CHIP_ID.v$ITER 160 160 161 161 host -required $FIXHOST -
trunk/tools/eam/rawfix.20230221/src/rawfix.md5chk.pt
r42454 r42462 82 82 83 83 # does the output go here? 84 stdout $mypath/$ DATEOBS/log.md5chk.v$ITER85 stderr $mypath/$ DATEOBS/log.md5chk.v$ITER84 stdout $mypath/$YEAR/$DATEOBS/log.md5chk.v$ITER 85 stderr $mypath/$YEAR/$DATEOBS/log.md5chk.v$ITER 86 86 87 87 ## this command does NOT use Nebulous or GPC so it can run anywhere -
trunk/tools/eam/rawfix.20230221/src/rawfix.md5sum.pt
r42454 r42462 156 156 # save DATEOBS so we can find the md5sum.book entry 157 157 158 substr $DATEOBS 0 4 YEAR 159 158 160 # does the output go here? 159 stdout $mypath/$ DATEOBS/log.md5sum.runhosts.v$ITER160 stderr $mypath/$ DATEOBS/log.md5sum.runhosts.v$ITER161 stdout $mypath/$YEAR/$DATEOBS/log.md5sum.runhosts.v$ITER 162 stderr $mypath/$YEAR/$DATEOBS/log.md5sum.runhosts.v$ITER 161 163 162 164 $USE_HOST = $MD5HOST -
trunk/tools/eam/rawfix.20230221/src/update_chip_stats.pl
r42449 r42462 13 13 14 14 # USAGE: update_chip_locations.pl --dateobs (night) --stage (0,1,etc) --chiplist (file) 15 16 my ($fulldate, $dateword, $chiplist, $stage, $topdir) = &parse_cmdopts; 15 # nebulous.config & chiplist.txt are at topdir 16 17 my ($fulldate, $dateword, $chiplist, $stage, $topdir, $basedir) = &parse_cmdopts; 17 18 my ($raw_dbh) = &parse_db_config ("$topdir/nebulous.config"); 18 19 … … 38 39 foreach my $chip_id (@chip_ids) { 39 40 40 open (STATFILE, "$ topdir/$dateword/$chip_id.stats.$stage.txt");41 open (STATFILE, "$basedir/$dateword/$chip_id.stats.$stage.txt"); 41 42 my @lines = <STATFILE>; 42 43 close (STATFILE); … … 154 155 my $dateword = sprintf ("%4d%02d%02d", $date_year, $date_month, $date_day); 155 156 156 return ($fulldate, $dateword, $chiplist, $stage, $topdir); 157 my ($yearobs) = substr ($dateword, 0, 4); 158 my $basedir = "$topdir/$yearobs"; 159 160 return ($fulldate, $dateword, $chiplist, $stage, $topdir, $basedir); 157 161 } 158 162
Note:
See TracChangeset
for help on using the changeset viewer.
