Changeset 15691
- Timestamp:
- Nov 26, 2007, 2:44:00 PM (18 years ago)
- File:
-
- 1 edited
-
trunk/ippScripts/scripts/warp_overlap.pl (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippScripts/scripts/warp_overlap.pl
r15644 r15691 18 18 use PS::IPP::Metadata::List qw( parse_md_list ); 19 19 use File::Temp qw( tempfile ); 20 use File::Spec; 21 use Getopt::Long qw( GetOptions :config auto_help auto_version gnu_getopt ); 22 use Pod::Usage qw( pod2usage ); 20 23 21 24 use PS::IPP::Config qw($PS_EXIT_SUCCESS … … 31 34 file_scheme 32 35 ); 36 use PS::IPP::Operations qw( generate_skycells ); 37 33 38 my $ipprc = PS::IPP::Config->new(); # IPP configuration 34 use File::Spec;35 36 use Getopt::Long qw( GetOptions :config auto_help auto_version gnu_getopt );37 use Pod::Usage qw( pod2usage );38 39 39 40 my ($warp_id, $camera, $dbname, $workdir, $no_update, $no_op); … … 60 61 my $warptool = can_run('warptool') or (warn "Can't find warptool" and $missing_tools = 1); 61 62 my $dvoImageOverlaps = can_run('dvoImageOverlaps') or (warn "Can't find dvoImageOverlaps" and $missing_tools = 1); 62 my $dvoImageExtract = can_run('dvoImageExtract') or (warn "Can't find dvoImageExtract" and $missing_tools = 1);63 63 my $ppConfigDump = can_run('ppConfigDump') or (warn "Can't find ppConfigDump" and $missing_tools = 1); 64 64 if ($missing_tools) { … … 145 145 } 146 146 } 147 147 148 148 # Extract the skycells to images, used as warp templates. 149 foreach my $skycell_id (keys %unique_skycells) { 150 my $skyDir = caturi($workdir, "tess_" . $tess_id, "sky_" . $skycell_id ); 151 my $skyFile = $ipprc->file_prepare( $skycell_id, $skyDir ); 152 unless ($ipprc->file_exists( $skyFile )) { 153 my $skyFileResolved = $ipprc->file_create( $skyFile ); # Resolved filename, for Nebulous 154 my $command = "$dvoImageExtract -D CATDIR $tess_dir $skycell_id -o $skyFileResolved"; 155 my ( $success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) = 156 run(command => $command, verbose => 1); 157 unless ($success) { 158 $error_code = (($error_code >> 8) or $PS_EXIT_PROG_ERROR); 159 &my_die("Unable to perform dvoImageExtract: $error_code", $warp_id, $error_code); 160 } 161 } 162 } 149 my @skycells = keys %unique_skycells; 150 generate_skycells($ipprc, $tess_id, \@skycells, $workdir) or 151 &my_die("Unable to generate skycells for tessellation $tess_id", $warp_id, $PS_EXIT_SYS_ERROR); 163 152 } 164 153 } else {
Note:
See TracChangeset
for help on using the changeset viewer.
