Welcome to iraf.net Thursday, May 02 2024 @ 01:20 PM GMT


 Forum Index > Help Desk > General IRAF New Topic Post Reply
 Imalign will not shift images
   
riley
 07/25/2018 05:52PM (Read 973 times)  
+----
Newbie

Status: offline


Registered: 07/19/2018
Posts: 2
Hi, I'm running pyRAF 2.1.15 with DS9 7.6, on Ubuntu 18.04. I'm trying to use imalign, and it refuses to shift my image. The command executes, but it just outputs the image as it was before. Here's my lpar:
PHP Formatted Code
 input = "image1.fits"    Input images
    reference = "image2.fits"    Reference image
       coords = "image2.fits.coo.3" Reference coordinates file
       output = "aimage1.fits"   Output images
      (shifts = "")             Initial shifts file
     (boxsize = 11)             Size of the small centering box
      (bigbox = 15)             Size of the big centering box
    (negative = no)             Are the features negative ?
  (background = INDEF)          Reference background level
       (lower = INDEF)          Lower threshold for data
       (upper = INDEF)          Upper threshold for data
    (niterate = 3)              Maximum number of iterations
   (tolerance = 0)              Tolerance for convergence
    (maxshift = INDEF)          Maximum acceptable pixel shift
 (shiftimages = yes)            Shift the images ?
 (interp_type = "linear")       Interpolant
(boundary_typ = "nearest")      Boundary type
    (constant = 0.0)            Constant for constant boundary extension
  (trimimages = yes)            Trim the shifted images ?
     (verbose = yes)            Print the centers, shifts, and trim section ?
        (list = )              
        (mode = "ql")


My coords file contains a lot of reference objects, but a fair amount give the error message "Warning: failed to converge near (2040,1853)" or something similar. After it's gone through all the reference objects, here's the output for shifts and trims:
PHP Formatted Code
#Shifts        Image    X-shift   Err      Y-shift   Err      N      Internal
         image1.fits      0.189 (0.009)      0.576 (0.009)  753   (0.114,0.119)

# Shifting images:

Images not trimmed ! Trim section is undefined.


So it's clear that pyRAF is actually calculating the shifts, just not shifting or trimming the images. The strangest part is that I had run this exact same command, only with a different input/output image, everything else the same, and it worked perfectly. Between running those two commands I had changed nothing, so I wonder if the data is just behaving oddly. Any help is appreciated.



 
Profile Email
 Quote
riley
 08/01/2018 06:17PM  
+----
Newbie

Status: offline


Registered: 07/19/2018
Posts: 2
I suppose the problem hasn't been solved, but I did find a work-around. Since my images were nearly identical, and their shifts were simple x-y differences, I manually calculated the shift and shifted image1.fits with imshift, which worked. I should note I tried to use xregister, but it seemed there was a similar problem as with imalign-- however at this point I suspect it's a data issue.

 
Profile Email
 Quote
fitz
 08/01/2018 06:25PM  
AAAAA
Admin

Status: offline


Registered: 09/30/2005
Posts: 4040
Glad you found a workaround. A 'failed to converge' is usually a problem in setting the appropriate centering box sizes but is data dependent. If you are confident in the WCS of each image you might also look at the WREGISTER or SREGISTER tasks.

 
Profile Email
 Quote
   
Content generated in: 0.21 seconds
New Topic Post Reply

Normal Topic Normal Topic
Sticky Topic Sticky Topic
Locked Topic Locked Topic
New Post New Post
Sticky Topic W/ New Post Sticky Topic W/ New Post
Locked Topic W/ New Post Locked Topic W/ New Post
View Anonymous Posts 
Anonymous users can post 
Filtered HTML Allowed 
Censored Content 
dog allergies remedies cialis 20 mg chilblain remedies


Privacy Policy
Terms of Use

User Functions

Login