[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gnuastro-commits] master 0facf365 16/69: Book: adding documentation of
From: |
Mohammad Akhlaghi |
Subject: |
[gnuastro-commits] master 0facf365 16/69: Book: adding documentation of 'psf-model-scattered-light' script |
Date: |
Wed, 26 Jan 2022 12:39:10 -0500 (EST) |
branch: master
commit 0facf36508fa3dca37a03118648b426106b6e954
Author: Raul Infante-Sainz <infantesainz@gmail.com>
Commit: Mohammad Akhlaghi <mohammad@akhlaghi.org>
Book: adding documentation of 'psf-model-scattered-light' script
Until this commit, the documentation and information of this script was
missing. With this commit, the basic information and the options of this
script have been added into the book of Gnuastro.
---
doc/gnuastro.texi | 104 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 104 insertions(+)
diff --git a/doc/gnuastro.texi b/doc/gnuastro.texi
index 980b9958..aa68847d 100644
--- a/doc/gnuastro.texi
+++ b/doc/gnuastro.texi
@@ -660,6 +660,7 @@ PSF construction and correction
* Invoking astscript-psf-create-make-stamp:: How to call
astscript-psf-create-make-stamp
* Invoking astscript-psf-create-junction:: How to call
astscript-psf-create-junction
* Invoking astscript-psf-model-flux-factor:: How to call
astscript-psf-model-flux-factor
+* Invoking astscript-psf-model-scattered-light:: How to call
astscript-psf-model-scattered-light
Library
@@ -23443,6 +23444,7 @@ For more on installed scripts please see (see
@ref{Installed scripts}).
*Invoking astscript-psf-create-make-stamp:: How to call
astscript-psf-create-make-stamp
*Invoking astscript-psf-create-junction:: How to call
astscript-psf-create-junction
*Invoking astscript-psf-model-flux-factor:: How to call
astscript-psf-model-flux-factor
+*Invoking astscript-psf-model-scattered-light:: How to call
astscript-psf-model-scattered-light
@end menu
@@ -23847,6 +23849,108 @@ For example, to check that the intermediate images
have the desired center, they
+@node Invoking astscript-psf-model-scattered-light
+@subsection Invoking astscript-psf-model-scattered-light
+This installed script will put the PSF provided into a given position of the
sky within the input image.
+It is aimed to model the scattered light field of an input image.
+
+This script can be used with the following general template:
+
+@example
+$ astscript-psf-model-scattered-light [OPTION...] FITS-file
+@end example
+
+@noindent
+Examples:
+
+@example
+## Multiply the the PSF (psf.fits) by 3 and put it into the the
+## pixel position (x,y)=(53,69) of the input image (image.fits).
+$ astscript-psf-model-scattered-light image.fits \
+ --psf=psf.fits \
+ --mode=img \
+ --fluxfactor=3 \
+ --center=53,69 \
+ --output=star-53_69.fits
+
+## Consider that in image.fits are some stars that are going to
+## be modeled. If catalog.fits is a catalog containing the centers
+## (in WCS), then this loop will generate an individual stamp for
+## each star, one for each star in the catalog. These stamps can be
+## later sumed in order to obtain the entire scattered light field.
+$ asttable catalog.fits | while read -r ra dec mag; do
+ fluxfactor=$(cat fluxfactor-"$ra"_"$dec".txt)
+ astscript-psf-model-scattered-light image.fits \
+ --mode=wcs \
+ --psf=psf.fits \
+ --fluxfactor=$fluxfactor \
+ --center=$ra,$dec; done
+
+@end example
+
+The input is an image from which the star is considered.
+The result is an image with the same dimensions than the input, but with the
PSF (@option{--psf}) situated in the position specified by @option{--center},
and with the flux level specified by @option{--fluxfactor}.
+The region not covered by the PSF are set to zero values.
+Note that this script works over individual objects.
+As a consequence, to generate a scattered light field of many stars it is
necessary to make multiple calls and then combine all the individual modeled
stars.
+
+A full description of each option is given below.
+
+@table @option
+
+@item -h STR
+@itemx --hdu=STR
+The HDU/extension of the input image to use.
+
+@item -p STR
+@itemx --psf=STR
+Filename of the PSF image.
+The PSF is assumed to be centered in this image.
+
+@item -P STR
+@itemx --psfhdu=STR
+The HDU/extension of the PSF image.
+
+@item -O STR
+@itemx --mode=STR
+Interpret the center position of the object (values given to
@option{--center}) in image or WCS coordinates.
+This option thus accepts only two values: @option{img} or @option{wcs}.
+
+@item -c FLT[,FLT[,...]]
+@itemx --center=FLT[,FLT[,...]]
+The central position of the object.
+This parameter is used in @ref{Crop} to center and crop the image.
+The positions along each dimension must be separated by a comma (@key{,}).
+The number of values given to this option must be the same as the dimensions
of the input dataset.
+The units of the coordinates are read based on the value to the
@option{--mode} option, see above.
+
+@item -f FLT
+@itemx --fluxfactor=FLT
+Factor by which the PSF (@option{--psf}) is multiplied.
+This factor is necessary to put the PSF with the desired flux level.
+A convenient way of obtaining this value is by using the script
@file{astscript-model-flux-factor}, see @ref{Invoking
astscript-psf-model-flux-factor}.
+
+@item -t STR
+@itemx --tmpdir=STR
+Several intermediate files are necessary to obtain the output.
+All of these temporal files are saved into a temporal directory.
+With this option, you can directly specify this directory.
+By default (when this option isn't called), it will be built in the running
directory and given an input-based name.
+If the directory doesn't exist at run-time, this script will create it.
+Once all temporal files are not necessary, this directory is removed.
+You can disable the deletion of the temporary directory with the
@option{--keeptmp} option, see below.
+
+@item -k
+@itemx --keeptmp
+Don't delete the temporary directory (see description of @option{--tmpdir}
above).
+This option is useful for debugging.
+For example, to check that the intermediate images have the desired center,
flux level, etc.
+@end table
+
+
+
+
+
- [gnuastro-commits] master cf6335a6 18/69: PSF stamp: enabling the use of sigma-clip parameters, (continued)
- [gnuastro-commits] master cf6335a6 18/69: PSF stamp: enabling the use of sigma-clip parameters, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master 00b08df2 28/69: PSF stamp: add --saturation option for masking the saturated pixels, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master 2718494e 19/69: PSF stamp: allowing to run the script without making normalization, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master da6eea59 33/69: Scripts: changing 'wcstoimg' to 'wcs-to-img' in several scripts, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master 50fd424f 66/69: PSF tutorial: adding information to choose proper --normradii values, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master 86ac2dd1 42/69: PSF select-stars: corrected bug in checking the catalog-image overlap, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master cf58a078 62/69: PSF select-stars: give the default value to the two variables, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master db2d55be 37/69: PSF select-stars: changing some variable names to follow conventions, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master cd14a366 44/69: PSF select-stars: including the make check step for this script, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master 85648ac3 45/69: PSF select-stars: The script has been changed for use in general scenario, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master 0facf365 16/69: Book: adding documentation of 'psf-model-scattered-light' script,
Mohammad Akhlaghi <=
- [gnuastro-commits] master b1e3da80 34/69: PSF junction: fixed bug when centering the different parts of the PSF, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master 7c398567 36/69: Book: Correct the some parts of the making the PSF, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master b82adcfc 46/69: Book: some essential option was add to astscript-psf-select-stars section, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master ff3bb03f 38/69: PSF select-stars: removing not used options and polishing the comments, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master b5525411 48/69: PSF select-stars: delete the value of some options and ask them from the user, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master 075bc680 58/69: PSF select-stars: remove the stars that have stars., Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master 9aae5f5c 65/69: Book: Edits to the tutorial on creating the extended PSF, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master b1e2eb54 68/69: Book: Extended PSF tutorial moved to Tutorials chapter, Mohammad Akhlaghi, 2022/01/26
- [gnuastro-commits] master 9db9e205 11/69: PSF junction: new script for joining two PSF images, Mohammad Akhlaghi, 2022/01/26