comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » saving an output from the find.pro script
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
saving an output from the find.pro script [message #90090] Sat, 24 January 2015 19:56 Go to next message
anes.tziamtzis is currently offline  anes.tziamtzis
Messages: 9
Registered: January 2015
Junior Member
Hi I have created a simple photometric script that reads a series of fits files using find.pro, to detect all the stars on the filelds.

Some information for the find.pro script can be found here
http://www.exelisvis.com/docs/find.html

Everything works fine apart from the fact that I cannot save an output. On the screen it prints the following:
STAR X Y FLUX SHARP ROUND
0 262.7 9.1 1986.9 0.29 0.04
1 73.6 25.6 4735.9 0.31 0.04
2 262.3 31.6 369.2 0.21 0.26
3 584.0 62.8 3408.6 0.30 0.04
4 542.5 68.4 19226.5 0.28 0.07
5 381.3 110.7 629.0 0.21 0.00
6 889.3 113.8 4651.7 0.28 0.06
7 721.9 129.6 651.6 0.30 0.11
8 711.7 177.8 2313.3 0.30 0.12
9 669.2 216.6 3596.2 0.28 0.05

How will it be possible to save a file of this output?

This is given on the description of the script:
Calling Sequence
FIND, image, [ x, y, flux, sharp, round, hmin, fwhm, roundlim, sharplim
PRINT= , /SILENT, /MONITOR]


Thanks a lot in advance
Re: saving an output from the find.pro script [message #90091 is a reply to message #90090] Sat, 24 January 2015 21:51 Go to previous messageGo to next message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
anes.tziamtzis@gmail.com writes:

> Some information for the find.pro script can be found here
> http://www.exelisvis.com/docs/find.html

Humm. Have you tried reading this to find the answer to your question?

Cheers,

David


--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
Sepore ma de ni thue. ("Perhaps thou speakest truth.")
Re: saving an output from the find.pro script [message #90092 is a reply to message #90091] Sat, 24 January 2015 23:06 Go to previous messageGo to next message
anes.tziamtzis is currently offline  anes.tziamtzis
Messages: 9
Registered: January 2015
Junior Member
On Sunday, January 25, 2015 at 1:51:20 PM UTC+8, David Fanning wrote:
> anes.tziamtzis@gmail.com writes:
>
>> Some information for the find.pro script can be found here
>> http://www.exelisvis.com/docs/find.html
>
> Humm. Have you tried reading this to find the answer to your question?
>
> Cheers,
>
> David
>
>
> --
> David Fanning, Ph.D.
> Fanning Software Consulting, Inc.
> Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
> Sepore ma de ni thue. ("Perhaps thou speakest truth.")


Well actually this where i found the script but it seems i don't understand how to save the file.

I am using the following:

;Read the image
fits_read, '4U1543-624_1_sh.fits', image1, image_header1

Then use
find,image1
and then i have this
PRINT='image1.prt'

The find.pro script asks for the desired FWHM, background, etc. and it prints on the screen the values. No file is create though. What am i missing?


This what i see on the screen

% FIND: Input Image Size is 1002 by 999
Enter approximate FWHM: 15
% FIND: RELATIVE ERROR computed from FWHM 0.512254
Enter minimum value above background for threshold detection: 140
Enter low and high cutoffs, press [RETURN] for defaults:
Image Sharpness Statistic (DEFAULT = 0.2,1.0):
Image Roundness Statistic [DEFAULT = -1.0,1.0]:
% FIND: Beginning convolution of image
% FIND: Finished convolution of image
% FIND: 65 local maxima located above threshold

STAR X Y FLUX SHARP ROUND
0 262.9 8.2 779.1 0.32 -0.13
1 73.8 25.1 1835.1 0.27 -0.11
2 262.6 33.1 182.9 0.57 -0.17
3 584.1 62.4 1280.9 0.23 0.03
4 542.4 67.9 7420.4 0.27 0.08
5 381.6 110.4 257.1 0.78 -0.15
6 889.3 113.4 1836.9 0.22 -0.03
7 711.5 177.3 933.0 0.35 -0.01
8 669.2 216.0 1357.1 0.28 -0.09
9 340.6 243.2 510.0 0.24 -0.15
10 283.5 330.3 202.1 0.43 0.19
11 767.3 414.0 938.3 0.21 0.05
12 737.3 427.8 204.9 0.54 0.27
13 425.2 470.2 1809.6 0.26 -0.11
14 589.4 471.9 395.1 0.37 -0.04
15 36.8 563.7 149.0 0.53 0.39
16 242.0 635.8 196.4 0.57 -0.19
17 185.5 638.9 759.2 0.36 -0.19
18 514.0 645.2 1987.7 0.32 -0.13
19 485.1 668.9 157.6 0.39 0.10
20 661.5 682.1 226.8 0.27 -0.16
21 465.6 783.4 27608.6 0.31 -0.08
22 382.4 807.7 289.9 0.49 -0.12
23 55.6 900.1 186.0 0.25 0.34
24 403.9 898.8 194.7 0.51 0.00
25 361.2 962.9 6863.0 0.25 -0.06
26 405.1 986.5 1749.8 0.28 -0.06
No. of sources rejected by SHARPNESS criteria 32
No. of sources rejected by ROUNDNESS criteria 4
No. of sources rejected by CENTROID criteria 2
Threshold above background for this pass was 140.0
Enter new threshold or [RETURN] to exit:
% Compiled module: GETOPT.
Re: saving an output from the find.pro script [message #90093 is a reply to message #90092] Sun, 25 January 2015 05:02 Go to previous messageGo to next message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
anes.tziamtzis@gmail.com writes:

> Well actually this where i found the script but it seems i don't understand how to save the file.
>
> I am using the following:
>
> ;Read the image
> fits_read, '4U1543-624_1_sh.fits', image1, image_header1
>
> Then use
> find,image1
> and then i have this
> PRINT='image1.prt'
>
> The find.pro script asks for the desired FWHM, background, etc. and it prints on the screen the values. No file is create though. What am i missing?

I think you are missing the fact that the PRINT in this case is a
keyword, not a command. (Bad choice of keyword name for whoever wrote
the program.):

Find, image, Print='myfile.txt'

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
Sepore ma de ni thue. ("Perhaps thou speakest truth.")
Re: saving an output from the find.pro script [message #90094 is a reply to message #90093] Sun, 25 January 2015 05:50 Go to previous message
anes.tziamtzis is currently offline  anes.tziamtzis
Messages: 9
Registered: January 2015
Junior Member
On Sunday, January 25, 2015 at 9:02:34 PM UTC+8, David Fanning wrote:
> anes.tziamtzis@gmail.com writes:
>
>> Well actually this where i found the script but it seems i don't understand how to save the file.
>>
>> I am using the following:
>>
>> ;Read the image
>> fits_read, '4U1543-624_1_sh.fits', image1, image_header1
>>
>> Then use
>> find,image1
>> and then i have this
>> PRINT='image1.prt'
>>
>> The find.pro script asks for the desired FWHM, background, etc. and it prints on the screen the values. No file is create though. What am i missing?
>
> I think you are missing the fact that the PRINT in this case is a
> keyword, not a command. (Bad choice of keyword name for whoever wrote
> the program.):
>
> Find, image, Print='myfile.txt'
>
> Cheers,
>
> David
> --
> David Fanning, Ph.D.
> Fanning Software Consulting, Inc.
> Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
> Sepore ma de ni thue. ("Perhaps thou speakest truth.")


Thanks a lot David. I guess this is the difference between knowledge (you) and ignorance (me).
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: IDL inverse matrix problem??
Next Topic: Writing a dat file and opening in ENVI

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 09:14:07 PDT 2025

Total time taken to generate the page: 0.00395 seconds