[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gnuastro-commits] master 10841bab 17/23: color-faint-gray: bug correcte
From: |
Mohammad Akhlaghi |
Subject: |
[gnuastro-commits] master 10841bab 17/23: color-faint-gray: bug corrected in the asinh transformation |
Date: |
Sun, 24 Dec 2023 22:26:23 -0500 (EST) |
branch: master
commit 10841babedc099b242b9c38dd86624b4285db80b
Author: Raul Infante-Sainz <infantesainz@gmail.com>
Commit: Mohammad Akhlaghi <mohammad@akhlaghi.org>
color-faint-gray: bug corrected in the asinh transformation
Until this commit, the asinh transformation was not properly done! This was
noticed by Mohammad when changing the --qbright and --stretch parameters,
he noticed that only the ration between them was important. However, these
two parameters controls the different part of the transformation. The asinh
transformation was (wrong):
f(x) = asinh (qbright * x / stretch) / qbright
With this commit, the transformation has been set to the correct one:
f(x) = asinh (qbright * x * stretch ) / qbright
With this transformation, the idea is to set --qbright to very low values.
This will make a linear transformation whose slope is then controled by
--stretch to show the fainter regions. Then change again --qbright to show
the bright parts.
---
bin/script/color-faint-gray.sh | 2 +-
doc/gnuastro.texi | 10 ++++++----
tests/script/{rgb-faint-gray.sh => color-faint-gray.sh} | 0
3 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/bin/script/color-faint-gray.sh b/bin/script/color-faint-gray.sh
index d5b61f11..870cb33b 100644
--- a/bin/script/color-faint-gray.sh
+++ b/bin/script/color-faint-gray.sh
@@ -649,7 +649,7 @@ fi
# pixel values is linear transformed to [minvalrange - maxvalrange].
I_RGB_asinh_norm="$tmpdir/RGB-mean-asinh-norm.fits"
astarithmetic $I_RGB_stack -h1 set-I_RGB \
- I_RGB $qbright_value x $stretch_value / set-i \
+ I_RGB $qbright_value x $stretch_value x set-i \
i asinh \
$qbright_value / \
I_RGB / set-asinhed \
diff --git a/doc/gnuastro.texi b/doc/gnuastro.texi
index e05ed64f..71e71a3e 100644
--- a/doc/gnuastro.texi
+++ b/doc/gnuastro.texi
@@ -8985,17 +8985,19 @@ Finally, let's run @command{astscript-color-faint-gray}
on the three cropped ima
@example
## Download
+$ mkdir inputs
$ url=https://archive.cefca.es/catalogues/vo/siap/jplus-dr3/get_fits?id=
-$ wget "$url"92797 -Oin/i-jplus.fits.fz
-$ wget "$url"92801 -Oin/r-jplus.fits.fz
-$ wget "$url"92803 -Oin/g-jplus.fits.fz
+$ wget "$url"92797 -Oinputs/i-jplus.fits.fz
+$ wget "$url"92801 -Oinputs/r-jplus.fits.fz
+$ wget "$url"92803 -Oinputs/g-jplus.fits.fz
## Crop
+$ mkdir aligned
$ widthdeg=0.35
$ ra=202.4741207
$ dec=47.2171879
$ for f in i r g; do \
- astcrop in/$f-jplus.fits.fz --center=$ra,$dec \
+ astcrop inputs/$f-jplus.fits.fz --center=$ra,$dec \
--width=$widthdeg --output=aligned/$f-jplus.fits; \
done
diff --git a/tests/script/rgb-faint-gray.sh b/tests/script/color-faint-gray.sh
similarity index 100%
rename from tests/script/rgb-faint-gray.sh
rename to tests/script/color-faint-gray.sh
- [gnuastro-commits] master 57b0de9b 06/23: astscript-rgb-asinh: new name for the previous astscript-rgb-image, (continued)
- [gnuastro-commits] master 57b0de9b 06/23: astscript-rgb-asinh: new name for the previous astscript-rgb-image, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master a5b8d601 05/23: Book: correcting several typos in the astscript-rgb-image section, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master 9dd75f9e 01/23: astscript-rgb-image: Adding script for generating color image, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master 81f37667 02/23: astscript-rgb-image: select black or gray background, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master d4d7ab05 03/23: Book: added new section with information of astscript-rgb-image, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master 610986aa 08/23: Book: subsection of rgb-asinh script added to the color images tutorial, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master 1ee413f2 14/23: Book: improving the tutorial for rgb-faint-gray script by using J-PLUS data, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master 016c185a 09/23: Book: improving and correcting typos of rgb-asinh tutorial, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master 63718a46 15/23: Book: edited the color tutorial, typo in rgb script fixed, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master 217ad4ff 16/23: color-faint-gray: new name for the script, --bias replaces --brightness, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master 10841bab 17/23: color-faint-gray: bug corrected in the asinh transformation,
Mohammad Akhlaghi <=
- [gnuastro-commits] master 2a63037e 18/23: color-faint-gray: improving the selection of color, black, and gray regions, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master cd724b3f 19/23: Book: color-faint-gray tutorial improved by including last features, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master 16419fda 11/23: astscript-rgb-faint-gray: following Gnuastro standards for HDU arguments, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master 6d1e2f4a 12/23: astscript-rgb-faint-gray: removing comma-separated arguments, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master 145070a2 21/23: color-faint-gray: new option --segment to define the color regions, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master 73181f88 07/23: Book: new tutorial describing how to generate color images, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master 1c8bf2e8 22/23: color-faint-gray: --regions is new name for --segment, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master a0b7270e 10/23: astscript-rgb-faint-gray: set gray background by default, new script name, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master cf40daba 13/23: Book: edited tutorial on color image production, Mohammad Akhlaghi, 2023/12/24
- [gnuastro-commits] master 4f206b8b 20/23: astscript-color-faint-gray: minor modifications to have better file names, Mohammad Akhlaghi, 2023/12/24