| 1 |
\ |
| 2 |
.\" This man page was generated by the Netpbm tool 'makeman' from HTML source. |
| 3 |
.\" Do not hand-hack it! If you have bug fixes or improvements, please find |
| 4 |
.\" the corresponding HTML page on the Netpbm website, generate a patch |
| 5 |
.\" against that, and send it to the Netpbm maintainer. |
| 6 |
.TH "Fitstopnm User Manual" 1 "02 August 2015" "netpbm documentation" |
| 7 |
|
| 8 |
.SH NAME |
| 9 |
fitstopnm - convert a FITS file into a PNM image |
| 10 |
|
| 11 |
.UN synopsis |
| 12 |
.SH SYNOPSIS |
| 13 |
|
| 14 |
\fBfitstopnm\fP |
| 15 |
[\fB-image=\fP\fIN\fP] |
| 16 |
[\fB-scanmax\fP] |
| 17 |
[\fB-printmax\fP] |
| 18 |
[\fB-min=\fP\fIf\fP] |
| 19 |
[\fB-max=\fP\fIf\fP] |
| 20 |
[\fB-omaxval=\fP\fIN\fP |
| 21 |
[\fIFITSfile\fP] |
| 22 |
.PP |
| 23 |
Minimum unique abbreviation of option is acceptable. You may use double |
| 24 |
hyphens instead of single hyphen to denote options. You may use white |
| 25 |
space in place of the equals sign to separate an option name from its value. |
| 26 |
|
| 27 |
|
| 28 |
.UN description |
| 29 |
.SH DESCRIPTION |
| 30 |
.PP |
| 31 |
This program is part of |
| 32 |
.BR "Netpbm" (1)\c |
| 33 |
\&. |
| 34 |
.PP |
| 35 |
\fBfitstopnm\fP reads a FITS (Flexible Image Transport System) file as |
| 36 |
input and produces a PPM image if the FITS file consists of 3 image planes |
| 37 |
(NAXIS = 3 and NAXIS3 = 3), or a PGM image if the FITS file consists of 2 |
| 38 |
image planes (NAXIS = 2), or if you specify the \fB-image\fP option. |
| 39 |
.PP |
| 40 |
Note that the PPM image is highly unlikely to be a true PPM image, as it is |
| 41 |
not normal for a FITS image to use the third axis as R, G, and B components of |
| 42 |
the pixels. The most common interpretation when there are 3 axes is that the |
| 43 |
third one is time. So the image is instead a pseudo-PPM in which the three |
| 44 |
sample values of a pixel represent something other than color components, for |
| 45 |
example gray levels at three instants (this variation on PPM is common in |
| 46 |
programs such as \fBfitstopnm\fP that predate the PAM format). |
| 47 |
.PP |
| 48 |
If you work with FITS images with 3 axes, you should probably always use |
| 49 |
the \fB-image\fP option to avoid getting an unwanted pseudo-PPM image. |
| 50 |
.PP |
| 51 |
The program tells you what kind of PNM image it is writing. |
| 52 |
|
| 53 |
|
| 54 |
.UN options |
| 55 |
.SH OPTIONS |
| 56 |
.PP |
| 57 |
In addition to the options common to all programs based on libnetpbm |
| 58 |
(most notably \fB-quiet\fP, see |
| 59 |
.UR index.html#commonoptions |
| 60 |
Common Options |
| 61 |
.UE |
| 62 |
\&), \fBfitstopnm\fP recognizes the following |
| 63 |
command line options: |
| 64 |
|
| 65 |
|
| 66 |
|
| 67 |
.TP |
| 68 |
\fB-image=\fP\fIN\fP |
| 69 |
This is for FITS files with three axes. This option says that the third |
| 70 |
axis is for multiple images, and the option value \fIN\fP tells which one you |
| 71 |
want. |
| 72 |
|
| 73 |
.TP |
| 74 |
\fB-omaxval=\fP\fIN\fP |
| 75 |
.sp |
| 76 |
This is the maxval that the output PNM image is to have. |
| 77 |
.sp |
| 78 |
By default, the maxval is the least possible to retain all the |
| 79 |
precision of the FITS input. That means the difference between the |
| 80 |
highest and lowest sample value in the input. If the values range |
| 81 |
from -5 to 100, for example, the default maxval would be 106 and each |
| 82 |
PNM sample value would correspond to one FITS sample value. |
| 83 |
.sp |
| 84 |
For a FITS input with floating point sample values, the precision is |
| 85 |
essentially unlimited, so this is not possible. In that case, the default |
| 86 |
maxval is simply 255. |
| 87 |
.sp |
| 88 |
This option was new in Netpbm 10.39 (June 2007). Before that, the |
| 89 |
output maxval is always the default. |
| 90 |
|
| 91 |
.TP |
| 92 |
\fB-min=\fP\fIfloat\fP |
| 93 |
.TP |
| 94 |
\fB-max=\fP\fIfloat\fP |
| 95 |
.sp |
| 96 |
You can use these options to override the min and max values as |
| 97 |
read from the FITS header or the image data if the header has no |
| 98 |
DATAMIN and DATAMAX keywords. |
| 99 |
|
| 100 |
.TP |
| 101 |
\fB-scanmax\fP |
| 102 |
Use this option to force the program to scan the data even when the |
| 103 |
header has DATAMIN and DATAMAX. |
| 104 |
|
| 105 |
.TP |
| 106 |
\fB-printmax\fP |
| 107 |
With this option, the program just prints the min and max values |
| 108 |
and quits without doing its normal job. |
| 109 |
.sp |
| 110 |
This is for use in shell programs. Example: |
| 111 |
|
| 112 |
.nf |
| 113 |
\f(CW |
| 114 |
eval 'fitstopnm -printmax $filename | \e |
| 115 |
awk {min = $1; max = $2} \e |
| 116 |
END {print "min=" min; " max=" max}' |
| 117 |
\fP |
| 118 |
|
| 119 |
.fi |
| 120 |
|
| 121 |
|
| 122 |
|
| 123 |
.UN notes |
| 124 |
.SH NOTES |
| 125 |
|
| 126 |
.UN pixelorder |
| 127 |
.SS Pixel Order |
| 128 |
.PP |
| 129 |
You may need to pass the output of \fBfitstopnm\fP through \fBpamflip |
| 130 |
-topbottom\fP. See |
| 131 |
.UR pamtofits.html#pixelorder |
| 132 |
\fBpamtofits\fP |
| 133 |
.UE |
| 134 |
\& |
| 135 |
|
| 136 |
|
| 137 |
.UN seealso |
| 138 |
.SH SEE ALSO |
| 139 |
.BR "pamtofits" (1)\c |
| 140 |
\&, |
| 141 |
.BR "pamflip" (1)\c |
| 142 |
\&, |
| 143 |
.BR "pgm" (1)\c |
| 144 |
\& |
| 145 |
|
| 146 |
.UN author |
| 147 |
.SH AUTHOR |
| 148 |
|
| 149 |
Copyright (C) 1989 by Jef Poskanzer, with modifications by Daniel |
| 150 |
Briggs (\[email protected]\fP) and |
| 151 |
Alberto Accomazzi (\[email protected]\fP). |
| 152 |
.SH DOCUMENT SOURCE |
| 153 |
This manual page was generated by the Netpbm tool 'makeman' from HTML |
| 154 |
source. The master documentation is at |
| 155 |
.IP |
| 156 |
.B http://netpbm.sourceforge.net/doc/fitstopnm.html |
| 157 |
.PP |