Skip to content

Commit

Permalink
no use m51 where smaller will do in t/transform.t
Browse files Browse the repository at this point in the history
  • Loading branch information
mohawk2 committed Sep 27, 2024
1 parent a984c14 commit 99edaec
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Libtmp/Transform/t/transform.t
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ use strict;
use warnings;
use PDL::LiteF;
use PDL::Transform;
use PDL::Transform::Cartography; # raster2fits helps limit mem consumption
use Test::More;
use Test::Exception;

Expand Down Expand Up @@ -110,7 +111,7 @@ EOF

{
use PDL::IO::FITS;
my $m51 = rfits('../../m51.fits');
my $m51 = raster2fits(sequence(long, 10, 10), @PDL::Transform::Cartography::PLATE_CARREE);
my $m51map = $m51->map(t_identity,{method=>'s'}); #SHOULD be a no-op
ok(all($m51==$m51map));

Expand Down Expand Up @@ -197,7 +198,7 @@ EOF
#was segfaulting on 'g' only
use PDL::IO::FITS;
use PDL::Transform::Cartography;
my $m51 = rfits('../../m51.fits');
my $m51 = raster2fits(sequence(long, 10, 10), @PDL::Transform::Cartography::PLATE_CARREE);
my $tp = t_perspective(r0=>200,iu=>'arcmin',origin=>[-10,3]);
foreach my $method(qw/s l c h g j H G/){ #f doesn't work so well on images this big
lives_ok {$m51->map(!$tp,{nofits=>1,method=>$method})} "no map segfault m=>$method";
Expand Down

0 comments on commit 99edaec

Please sign in to comment.