Welcome to iraf.net Monday, May 13 2024 @ 08:07 PM GMT


 Forum Index > Help Desk > General IRAF New Topic Post Reply
 geomap precision
   
mdg
 01/09/2008 10:45PM (Read 4436 times)  
+----
Newbie

Status: offline


Registered: 10/23/2007
Posts: 8
Hi,When running geomap to calculate the transformation from one image frame to another, the x and y pixel shifts are reported to 7 decimal places, enough precision for any need. But the rotations in degrees are reported to just three decimal places. So from center to corner of a 4096x4096 image, this amounts to +/-0.05 pixels, which is easy to measure, even if it does not significantly affect any science, perhaps. When iterating the shifts and rotation solutions, it is impossible to get better than a precision of a few hundredths of a pixel in many cases; I suspect that the crosstalk between the rotation and shifts and the imprecision of the reported rotation is responsible. I suggest that the angles be reported to 10^-5 degrees. I can find the place in the geomap code where the angles are formatted to 10^-3 degrees and it is easy to change; perhaps you could instruct me on how to recompile and install a modified geomap? Or perhaps there is another way to get the higher precision?Thanks,mdg

 
Profile Email Website
 Quote
fitz
 01/09/2008 10:45PM  
AAAAA
Admin

Status: offline


Registered: 09/30/2005
Posts: 4040
If you know where the code is that you want to change (probably just a format statement), all you need to do is edit the file to make a change and then recompile the x_images.e binary. To do this after you've made the change (and assuming you've got write permission on the iraf tree):[code]
% setenv iraf /iraf/iraf/ <-- trailing '/' required
% setenv IRAFARCH redhat <-- or 'linux', or 'macintel', or ...
% source $iraf/unix/hlib/irafuser.csh <-- set proper environment
[code]This simply sets up your environment for compilation. Once done, you actually recompile by doing:[code]
% cd $iraf <-- go to the iraf root directory
% mkpkg <arch> <-- reset the architecure to your $IRAFARCH
% cd pkg/image <-- go to the IMAGES pkg directory
% mkpkg update <-- recompile binaries
[/code]Post back if you have problems or questions.-Mike

 
Profile Email
 Quote
mdg
 01/09/2008 10:45PM  
+----
Newbie

Status: offline


Registered: 10/23/2007
Posts: 8
Hi,Thank you, that worked, geomap nows outputs 5 decimal places and it does indeed affect the derived shifts and rotations by significant amounts. But in recompiling the images package per instructions, I have run into difficulties reading/accessing multiextension fits files. For instances, display no longer can display an image extension, but it can still display simple fits images. Same for other routines, such as listpix. Yet implot still works.Any suggestions? Thanks,mdg[/b]

 
Profile Email Website
 Quote
fitz
 01/09/2008 10:45PM  
AAAAA
Admin

Status: offline


Registered: 09/30/2005
Posts: 4040
Nothing should have changed, to display an MEF file you must still provide the extension number in the name (same for LISTPIX and IMPLOT so I'm a bit confused). For example,[code:1:6e3805b5e3]cl> display mef.fits[1] 1[/code:1:6e3805b5e3]to display the first extension of 'mef.fits' in frame 1. Otherwise you should see some standard message from the FITS kernel about needing to supply an extension when it detects an MEF.-Mike

 
Profile Email
 Quote
mdg
 01/09/2008 10:45PM  
+----
Newbie

Status: offline


Registered: 10/23/2007
Posts: 8
Hi,In trying to diagnose the problem, I have found that it is not quite as I described earlier. I cannot display some simple fits files, such as the image_single_sci.fits images created by multidrizzle, nor some STIS data that I have which has been converted to simple fits. But I can display WIYN hydra images and dev$pix.
All that has changed is the recompile of the images packages. Now when I type (in pyraf): cl>display image.fits[sci,1] 1I get this message:Killing IRAF task `display'
Traceback (innermost last):
File "<CL script CL1>", line 1, in <module>
IrafError: Error running IRAF task display
IRAF task terminated abnormally
ERROR (501, "bus error")I get the same error when trying to extract subfields or extensions from an image.I have done the usual simple things: restarting pyraf, trying it from plain iraf, restarting ds9. Nothing changes. Same with the other tasks that are affected, such as listpix and imcopy.I suspect that there is something missing from the compile that is messing up the images library, but I have no idea what it might be.Suggestions?Thanks for the help,mdg

 
Profile Email Website
 Quote
fitz
 01/09/2008 10:45PM  
AAAAA
Admin

Status: offline


Registered: 09/30/2005
Posts: 4040
Hi Michael,Sorry for the slow reply, I was at the AAS last week and am still catching up. The GEOMAP changes should have only affected the x_images.e binary, tasks like DISPLAY are in a separate executable that should simply have been relinked. Exactly which files did you edit and how?If tasks not recompiled with the change, e.g. IMPLOT in the PLOT package, still fail then I'd suspect something weird about the data file and just coincidence that it was noticed after changing the geomap task.A common mistake that happens when compiling locally is that the binary is put in the wrong place or the architecture is set incorrectly. For your system (a G5 running 10.4.11) the IRAFARCH should be 'macosx'. In my instructions, the first step is to reconfigure the system for the correct arch before compiling; To check this, be sure the $iraf/bin symlink points to 'bin.macosx'. Check in that directory that the date on the x_images.e file is recent, otherwise look for the binary you built to either be in the $iraf/bin.generic directory (meaning the arch change didn't work) or in the $iraf/pkg/images directory somewhere (perhaps meaning your '$iraf' wasn't set correctly, e.g. missing the trailing '/').If things seem hopelessly confused, you can always download the IB binary distribution again and start from scratch to confirm things worked (or not) before making the change. If you want to post a URL to the image I'll have a look here as well.Cheers,
-Mike

 
Profile Email
 Quote
mdg
 01/09/2008 10:45PM  
+----
Newbie

Status: offline


Registered: 10/23/2007
Posts: 8
Hi Mike,This is not coincidence. I had been using the same data files all along. When I recompiled the images package, something changed. It seems that I can no longer read HST fits files. I agree it is weird and should not have happened.Here is what I did: I edited the t_geomap.x and t_geomap.gx files and changed the format statements from %0.3f to %0.5f where it prints out the rotation angles. Those are the only changes I made. Then I recompiled the images pkg exactly as per your detailed instructions. Everything seemed fine. I made no other changes to the iraf installation. Geomap now prints out the rotations to 5 places. Great. But then I went to display one of my drizzled images, made before the recompile (and previously displayed) and got the buffer error message. I can no longer display any raw HST data either, from ACS or STIS. And with some experimentation, I found that I cannot do imcopy or listpix or several other tasks, though implot works still. So perhaps somehow something else got changed, but I don't know where or when that would have happened. I am the only user of my system, including admin stuff, so whatever it is, it was by my hand, and the only change was recompiling the images pkg. And it happened in the same 20 minute interval it took to change geomap and recompile images.pkg.The only thing I could think to do on my own was upgrade to 2.14 and see if that takes care of things. I wanted to do that anyway and have started doing that this morning.Thanks for the help; I'll let you know if 2.14 takes care of it. And I'll modify geomap again, of course. Send the results of any brainstorms this way.Cheers,Michael[/b]

 
Profile Email Website
 Quote
   
Content generated in: 0.20 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