Welcome to iraf.net Friday, March 29 2024 @ 02:39 PM GMT


 Forum Index > Help Desk > Applications New Topic Post Reply
 xdimsum
   
skanbur
 06/06/2007 03:53PM (Read 15384 times)  
+----
Newbie

Status: offline


Registered: 06/06/2007
Posts: 11
Hi, Im tryin gto use xdimsum with IRAF 2.11.3 and 2.12 on a PC
running Debian Linux. Ive used the Debain packages and also the linux binaries on the iraf web site.
I installed xdimsum
and for a sample of 15 sky flats, i try and use the xslm command through epar.
The same data were analyzed with the same command on a machine at NOAO
successfully, but when I go it here, I get
Id appreciate any help.
Thanks,
Shashi
PACKAGE = xdimsum,
TASK = xslminlist = @sky.lst List of input images to be sky subtracted
omasks = The input object mask keyword or list
nmean = 9 Number of images to use to make sky frame
outlist = .sub The output sky subtracted images or suffix
(ssmasks= .ssm) The output sky subtraction masks or suffix
(hmasks = .hom) The output holes masks or suffix
(forcesc= yes) Force recalculation of input image medians ?
(useomas= yes) Use object masks to compute sky statistics ?
(statsec= [50:1948,50:1948]) The sky statistics image section
(nsigrej= 5.) The nsigma sky statistics rejection limit
(maxiter= 5) The maximum number of sky statistics iterations
(nskymin= 5) The minimum number of frames to use for sky
(nreject= 2) The number of high and low side pixels to reject
(del_ssm= yes) Delete sky substraction masks on task terminatio
(del_hma= yes) Delete holes masks on task termination ?
(imglist= )
(omskimg= )
(outimgl= )
(ssmskim= )
(hmskimg= )
(mode = ql)
Calculating scaling for SKY_061103_0111.fits
ERROR on line 81: parameter `nclip' not found
iterstat (inlist=SKY_061103_0111.fits, statsec=[50:1948,50:1948], lower=INDEF, upper=INDEF, nsigrej=5., maxiter=5, show=no)
iterstat (inlist=SKY_061103_0111.fits, statsec=[50:1948,50:1948], lower=INDEF, upper=INDEF, nsigrej=5., maxiter=5, show=no)
xslm (mode=h)

 
Profile Email
 Quote
fitz
 06/06/2007 03:53PM  
AAAAA
Admin

Status: offline


Registered: 09/30/2005
Posts: 4040
See https://iraf.net/phpBB2/viewtopic.php?t=81641&highlight=giovanni+xdimsumI would thus expect problems in the v2.11.3 systems, for v2.12 you may just need to "cl> unlearn imstat"-Mike

 
Profile Email
 Quote
skanbur
 06/06/2007 03:53PM  
+----
Newbie

Status: offline


Registered: 06/06/2007
Posts: 11
Hi, thanks for that. I did install v2.12. I downloaded the binaries from
http://iraf.noao.edu/iraf/ftp/iraf/v212/PCIX/
and used
ib.lnux.x86
and
nb.lnux.x86
and put these in
/usr/iraf/irafbin/bin.linux
and /usr/irafbin/noao.bin.linuxWhen I type cl, I still see the header saying its v2.11.3.
SO what else do I need to do?
Thanks,
Shashi

 
Profile Email
 Quote
fitz
 06/06/2007 03:53PM  
AAAAA
Admin

Status: offline


Registered: 09/30/2005
Posts: 4040
V2.12 required a complete reinstall so you'll need the as.pcix.gen.gz distribution file as well. If you're doing a full update anyway then I'd recommend the latest v2.13 release (you can use the redhat (RHUX) binaries) but for Debian install them in 'bin.linux' directories (and [b:9e55253c29]copy[/b:9e55253c29] the contents of iraf$unix/bin.redhat to iraf$unix/bin.linux).Cheers,
-Mike

 
Profile Email
 Quote
skanbur
 06/06/2007 03:53PM  
+----
Newbie

Status: offline


Registered: 06/06/2007
Posts: 11
Hi, thanks that worked. I can now type cl and get v2.12
and lpar imstat does mention nclip.
However, if I type the same message in xdimsum with epar xslm I get:ANy ideas here?
ShashiPACKAGE = xdimsum,
TASK = xslm

inlist = sky.lst List of input images to be sky subtracted
omasks = The input object mask keyword or list
nmean = 9 Number of images to use to make sky frame
outlist = .sub The output sky subtracted images or suffix
(ssmasks= .ssm) The output sky subtraction masks or suffix
(hmasks = .hom) The output holes masks or suffix
(forcesc= yes) Force recalculation of input image medians ?
(useomas= yes) Use object masks to compute sky statistics ?
(statsec= [50:1948,50:1948]) The sky statistics image section
(nsigrej= 5.) The nsigma sky statistics rejection limit
(maxiter= 5) The maximum number of sky statistics iterations
(nskymin= 5) The minimum number of frames to use for sky
(nreject= 2) The number of high and low side pixels to reject
(del_ssm= yes) Delete sky substraction masks on task termination ?
(del_hma= yes) Delete holes masks on task termination ?
(imglist= )
(omskimg= )
(outimgl= )
Calculating scaling for sky.lst
ERROR on line 81: Attempt to access undefined local variable `mn'.
More
iterstat (inlist=sky.lst, statsec=[50:1948,50:1948], lower=INDEF, upper=INDEF, nsigrej=5., maxiter=5, show=no)
xslm (mode=h)

 
Profile Email
 Quote
fitz
 06/06/2007 03:53PM  
AAAAA
Admin

Status: offline


Registered: 09/30/2005
Posts: 4040
See https://iraf.net/phpBB2/viewtopic.php?t=82446&highlight=xdimsum++iterstat for a possible solution-Mike

 
Profile Email
 Quote
skanbur
 06/06/2007 03:53PM  
+----
Newbie

Status: offline


Registered: 06/06/2007
Posts: 11
THanks, I made sure imstat <image> returned something for all the 15
images in my list. I tried d_trace and here is the output afte epar xslm.
Shashi
6498+3: addpipe
6501+2: redir
6503+2: exec
----- exec external task imstatistics -----
imstatistics > $\nimages="_sclmsktemp[50:1948,50:1948]"\n
fields="mean,stddev,npix,midpt,mode"\nlower=INDEF\n
upper=INDEF\nnclip=5\nlsigma=5.\nusigma=5.\nbinwidth=0.1\n
format=no\ncache=no\nmode="ql"\n$nargs=1\n
--------------------------------
----- task imstatistics -----
6834+3: call bye
6837+2: exec
----- exec builtin bye -----
6505+4: call scan
6509+8: pushconst `iterstat.mn'
6517+3: indirposset 0
6520+9: pushconst `iterstat.sig'
6529+3: indirposset 1
6532+9: pushconst `iterstat.npx'
6541+3: indirposset 2
6544+9: pushconst `iterstat.med'
6553+3: indirposset 3
6556+9: pushconst `iterstat.mod'
6565+3: indirposset 4
6568+4: getpipe
6572+2: redirin
6574+2: exec
----- exec builtin scan -----
6576+3: rmpipes 1
6579+4: pushparam show
6583+3: biff +99
6685+3: pushparam mn
ERROR on line 81: Attempt to access undefined local variable `mn'. iterstat (inlist=_sclmsktemp, statsec=[50:1948,50:1948], lower=INDEF, upper=INDEF, nsigrej=5., maxiter=5, show=no)
xslm (mode=h)

 
Profile Email
 Quote
fitz
 06/06/2007 03:53PM  
AAAAA
Admin

Status: offline


Registered: 09/30/2005
Posts: 4040
Looks fairly normal but doesn't indicate whether the IMSTAT actually ran correctly. One way to find out is to make a local copy of the script and try it instead, i.e.[code:1:fa031bd405]
xd> copy xdimsum$src/iterstat.cl .
xd> redefine iterstat=iterstat.cl
xd> xmosaic
[/code:1:fa031bd405]What I'd do is edit the script to have it print out the IMSTAT result, for instance just copy the three lines of the IMSTAT call and remove the pipe to the scan(). It may also be that your image section is invalid, can you run IMSTAT on the image using that same statsection from the command line?-Mike

 
Profile Email
 Quote
skanbur
 06/06/2007 03:53PM  
+----
Newbie

Status: offline


Registered: 06/06/2007
Posts: 11
Hi, thanks. the thing I dont understand is that the same command with the
same SKY files works on one of the machines in NOAO: I was just there a
few weeks ago and also my colleague just ran the epar xslm command also on
PC IRAF there last night and it worked.
So its the iterstat.cl script I edit?
Then whats the purpose of the xmosaic command in the last post?
Shashi

 
Profile Email
 Quote
fitz
 06/06/2007 03:53PM  
AAAAA
Admin

Status: offline


Registered: 09/30/2005
Posts: 4040
Sorry, I was doing a cut-n-paste from another message -- Yes, it's 'iterstat' you run and not 'xmosaic'.In any case, executing the IMSTAT either on the commandline or separately within the script should tell us something.-Mike

 
Profile Email
 Quote
skanbur
 06/06/2007 03:53PM  
+----
Newbie

Status: offline


Registered: 06/06/2007
Posts: 11
Hi, sorry to be slow,
but to run a local copy of iterstat, I type at the xd prompt when in
xdimsum?iterstat.cl?But which images will it look at ? Previously I typed epar xslm...?
Shashi

 
Profile Email
 Quote
fitz
 06/06/2007 03:53PM  
AAAAA
Admin

Status: offline


Registered: 09/30/2005
Posts: 4040
You would just type the task name, 'iterstat'. Using 'xslm' as you'd done earlier will work as well if it's easier, so long as you edit/redefine the task as mentioned earlier.All you really need is the name of the first image in your list and then do[code:1:3eecd1d3ce]cl> imstat myimage[50:1948,50:1948] nclip=5 lsigma=5 usigma=5[/code:1:3eecd1d3ce]
-Mike

 
Profile Email
 Quote
skanbur
 06/06/2007 03:53PM  
+----
Newbie

Status: offline


Registered: 06/06/2007
Posts: 11
For the second thing you suggested; that is typing imstat on the images, here is the result. Ive also checked all the 15 images with imstat and it does produce some statistics for them.
I still dont understand the stuff with iterstat.cl. I have copy of that in my local directory. SO I need to edit it , take out the pipe to scan in the code and then
run it from xd command line as iterstat.cl? With what options?
Shashixd> imstat SKY_061103_0111.fits[50:1948,50:1948] nclip=5 lsigma=5 usigma=5
# IMAGE NPIX MEAN STDDEV MIN MAX
SKY_061103_0111.fits[50:1948,50:1948] 3602475 27295. 3494. 9843. 44767.

 
Profile Email
 Quote
fitz
 06/06/2007 03:53PM  
AAAAA
Admin

Status: offline


Registered: 09/30/2005
Posts: 4040
Okay, so the input image is fine and we can assume it's the processed image to XSLM that gets passed that is causing trouble. So, if you copy the xdimsum$src/iterstat.cl file to another directory you can edit it and use the local copy for testing, e.g.[code:1:8e1b25f1b6]
cl> copy xdimsum$src/iterstat.cl /tmp
cl> edit /tmp/iterstat.clthen change the l ines which read: imstatistics (img // usec, fields="mean,stddev,npix,midpt,mode",
lower=lower, upper=upper, nclip=maxiter, lsigma=nsigrej,
usigma=nsigrej, binwidth=0.1, format-, cache-) | scan (mn,
sig, npx, med, mod)to insted read:
imstatistics (img // usec, fields="mean,stddev,npix,midpt,mode",
lower=lower, upper=upper, nclip=maxiter, lsigma=nsigrej,
usigma=nsigrej, binwidth=0.1, format-, cache-) imstatistics (img // usec, fields="mean,stddev,npix,midpt,mode",
lower=lower, upper=upper, nclip=maxiter, lsigma=nsigrej,
usigma=nsigrej, binwidth=0.1, format-, cache-) | scan (mn,
sig, npx, med, mod)
[/code:1:8e1b25f1b6]This just runs the IMSTAT command twice, once to output to the screen so you can see the results, and second to do it as before. I think what's happening is that the IMSTAT is failing somehow and so the 'mn' variable isn't being loaded in the scan() call, what you may see instead is an error of some kind.-Mike

 
Profile Email
 Quote
skanbur
 06/06/2007 03:53PM  
+----
Newbie

Status: offline


Registered: 06/06/2007
Posts: 11
Ok, thanks: one question.
Once Ive edited the local copy of iterstatc.l, how do I run that copy on the images rather than the original one?
Thats what Im confused about.
Shashi

 
Profile Email
 Quote
fitz
 06/06/2007 03:53PM  
AAAAA
Admin

Status: offline


Registered: 09/30/2005
Posts: 4040
(Sorry, I'm doing too many things at once today....)Once you edit the script, redefine the task to use the new copy:[code:1:6a8b206e2c]cl> redefine iterstat = /tmp/iterstat.cl[/code:1:6a8b206e2c]Then run as you did before and you should use your local copy and see the imstat output/error.-Mike

 
Profile Email
 Quote
skanbur
 06/06/2007 03:53PM  
+----
Newbie

Status: offline


Registered: 06/06/2007
Posts: 11
What I did was made a copy of the original iterstat .cl in the src, then edited it
to include the lines you suggested and then ran the same command I wa srunning before iei epar xsln. Im not sure that Ive done what you suggested correctly, but heres what I got:
31626.21 2217.495 3796693 31129.68 30130.14
Setting scaling factor to 1 / 31129.68
Calculating scaling for SKY_061103_0125.fits
31826.05 2023.484 3796606 31411.97 30409.15
Setting scaling factor to 1 / 31411.97
Creating sky subtracted image SKY_061103_0111.sub
Frame 1 Sky frames: start = 1 finish = 6 nreject = 2
Warning: Cannot open pixel file (_skytemp)- Maybe min_lenuserarea is too large
_skytemp is not an image or a number
Error reading image _sclmsktemp[50:1998,50:1998] ...
ERROR on line 90: Attempt to access undefined local variable `mn'. iterstat (inlist=_sclmsktemp, statsec=[50:1998,50:1998], lower=INDEF, upper=INDEF, nsigrej=5., maxiter=5, show=no)
xslm (mode=h)

 
Profile Email
 Quote
fitz
 06/06/2007 03:53PM  
AAAAA
Admin

Status: offline


Registered: 09/30/2005
Posts: 4040
[quote:567622f44d]
Warning: Cannot open pixel file (_skytemp)- Maybe min_lenuserarea is too large
_skytemp is not an image or a number
Error reading image _sclmsktemp[50:1998,50:1998] ...
[/quote:567622f44d]These are the errors: The cannot open pixel file may mean you've got an invalid 'imdir' variable defined, this is the location the pixel files are stored for .imh format images. You can reset this in your login.cl file, or on the command-line as[code:1:567622f44d]cl> reset imdir = HDR$orcl> reset imtype = "fits"
[/code:1:567622f44d]The first command says to put the .pix file in the same directory as the .imh file, the second says to use FITS files instead. Either way, do a 'flpr 0' (zero not oh) and try the task again. Let me know what happens.-Mike

 
Profile Email
 Quote
skanbur
 06/06/2007 03:53PM  
+----
Newbie

Status: offline


Registered: 06/06/2007
Posts: 11
Hi, It worked. Thanks very much for your help. Its very much appreciated.
Shashi Creating sky subtracted image SKY_061103_0115.sub
Frame 5 Sky frames: start = 1 finish = 10 nreject = 2
Creating sky subtracted image SKY_061103_0116.sub
Frame 6 Sky frames: start = 2 finish = 11 nreject = 2
Creating sky subtracted image SKY_061103_0117.sub
Frame 7 Sky frames: start = 3 finish = 12 nreject = 2
Creating sky subtracted image SKY_061103_0118.sub
Frame 8 Sky frames: start = 4 finish = 13 nreject = 2
Creating sky subtracted image SKY_061103_0119.sub
Frame 9 Sky frames: start = 5 finish = 14 nreject = 2
Creating sky subtracted image SKY_061103_0120.sub
Frame 10 Sky frames: start = 6 finish = 15 nreject = 2
Creating sky subtracted image SKY_061103_0121.sub
Frame 11 Sky frames: start = 7 finish = 15 nreject = 2
Creating sky subtracted image SKY_061103_0122.sub
Frame 12 Sky frames: start = 9 finish = 15 nreject = 2
Creating sky subtracted image SKY_061103_0123.sub
Frame 13 Sky frames: start = 10 finish = 15 nreject = 2
Creating sky subtracted image SKY_061103_0124.sub
Frame 14 Sky frames: start = 10 finish = 15 nreject = 2
Creating sky subtracted image SKY_061103_0125.sub
Frame 15 Sky frames: start = 10 finish = 15 nreject = 2

 
Profile Email
 Quote
skanbur
 06/06/2007 03:53PM  
+----
Newbie

Status: offline


Registered: 06/06/2007
Posts: 11
HI, now ive moved onto makemaske and get the following error.
Any ideas - probably something very simple Ive forgotten. Thanks,
ShashiPACKAGE = xdimsum,
TASK = makemaskinlist = @Sky_K.lst The input images used to compute the masks
outlist = @skykmask_k1.lst The output masks
(hinlist= ) The list of images to add BPM keywords to
(subsamp= 1) Block averaging factor before median filtering
(checkli= yes) Check data limits before filtering?
(zmin = -1000.) Minimum data value for fmedian
(zmax = 1000.) Maximum data value for fmedian
(filtsiz= 15) Median filter size for local sky evaluation
(nsmooth= 3) Boxcar smoothing size before thresholding
(statsec= [50:1998,50:1998]) Image region for computing sky statistics
(nsigrej= 3.) The nsigma sky statistics rejection limit
(maxiter= 20) The maximum number of sky statistics iterations
(thresht= nsigma) Thresholding type: nsigma or constant
(nsigthr= 2.) Threshold for masking in sky sigma
(constth= 0.) Constant threshold above sky for masking
(negthre= no) Set negative as well as positive thresholds ?
(ngrow = 0) Half-width of box to grow around masked objects
(verbose= no) Verbose output?
(imglist= )
(outimgl= )
(hdrimgl= )
(mode = ql)
ERROR on line 358: Cannot open file (skykmask_k1.lst)
makemask (mode=h)

 
Profile Email
 Quote
fitz
 06/06/2007 03:53PM  
AAAAA
Admin

Status: offline


Registered: 09/30/2005
Posts: 4040
Dunno, the only place that parameter gets used is to expand the file list. For instance, do[code:1:d9601ea1b8]cl> sections @skykmask_k1.lst opt=fullname[/code:1:d9601ea1b8]Otherwise check the file permission, that the file has something in it, and that you're not is some other directory than you think you are.-Mike

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