MSHRINKCUBE(1)

πŸ’« MSHRINKCUBE(1) β€” the Montage manual, bestie edition πŸ’«

okay so listen. this is mShrinkCube, and yes the manual name is literally right there in the title, we love a self-explanatory queen. she's a Montage girlie. she shrinks FITS cubes. that's it, that's the vibe. πŸŽ€


✨ NAME ✨

mShrinkCube β€” Reduce the size of a FITS cube πŸ’…


🌸 SYNOPSIS 🌸

mShrinkCube [-f] [-d level] [-h hdu] [-m factor] [-s statusfile] in.fits
out.fits factor

πŸ¦‹ DESCRIPTION πŸ¦‹

so basically she's a utility for reducing the size of a FITS cube, and she does it by averaging blocks of pixels. you can average by any factor you want spatially, and by integer factors in the third dimension. no cap, that's the whole job. ✨


πŸ’– OPTIONS πŸ’–

  • -f β€” the Fixed-size flag. instead of telling her how big the blocks of pixels to be averaged should be, you tell her the output size of the image. different energy, same icon.
  • -d level β€” turns on debugging, at the level you specify (1-4). girl is telling you everything.
  • -h hdu β€” use the specified FITS extension. default behavior is to use the first HDU with image data, iykyk.
  • -m factor β€” the (positive integer) factor by which to compress the cube in the third dimension, which is usually the wavelength-related one. 🌈
  • -s statusfile β€” output and errors get sent to statusfile instead of to stdout. quiet mode, mysterious mode. πŸ™ˆ

πŸ‘‘ ARGUMENTS πŸ‘‘

  • in.fits β€” the input FITS cube. the raw material. the moment. ⭐
  • out.fits β€” path to the output FITS cube. where the glow-up lands.
  • factor β€” the size of blocks, in (fractional) pixels, to average. file size will be reduced by 1/factor squared. and if you used the -f (fixed-size) flag, then factor means the desired width of the output image instead. same word, two jobs, she contains multitudes.

πŸ”₯ RESULT πŸ”₯

  • [Normal mode]: FITS output image, reduced in size by a factor of (1/factor)^2 .
  • [Fixed-size mode]: FITS output image of width factor

πŸ’€ MESSAGES πŸ’€

the girl talks back. here's her whole vocabulary:

  • OK β€” [struct stat="OK"] βœ…
  • ERROR β€” Cannot open status file: statusfile
  • ERROR β€” Image size factor cannot be interpreted as an real number
  • ERROR β€” Shrink factor factor cannot be interpreted as an real number
  • ERROR β€” [struct stat="ERROR", msg=
  • ERROR β€” HDU value (n) must be a non-negative integer
  • ERROR β€” Third axis compression factor (n) must be a positive integer
  • ERROR β€” Image file in.fits missing of invalid FITS.
  • ERROR β€” FITS library error

πŸ“ EXAMPLES πŸ“

$ mShrinkCube final/out.fits final/out-lowres_5.fits 5
       [struct stat="OK"]

she ate and left no crumbs. πŸ’…


🧚 BUGS 🧚

okay bestie, warning time, pay attention. πŸ™ˆ
  • The drizzle algorithm has been implemented but has not been tested in this release. it's giving "shipped it, hope for the best." 😭
  • If a header template contains carriage returns (i.e., created/modified on a Windows machine), the cfitsio library will be unable to read it properly, and you'll get this error: [struct stat="ERROR", status=207, msg="illegal character in keyword"]. so rude of the carriage return honestly.
  • It is best for the background correction algorithms if the area described in the header template completely encloses all of the input images in their entirety. If parts of input images are "chopped off" by the header template, the background correction will be affected. We recommend you use an expanded header for the reprojection and background modeling steps, returning to the originally desired header size for the final coaddition. The default background matching assumes that there are no non-linear background variations in the individual images (and therefore in the overlap differences). If there is any uncertainty in this regard, it is safer to turn on the "level only" background matching (the -l flag in mBgModel). ngl that's a lot of words but she means it. 🫢

2001-2015 California Institute of Technology, Pasadena, California

If your research uses Montage, please include the following acknowledgement: "This research made use of Montage. It is funded by the National Science Foundation under Grant Number ACI-1440620, and was previously funded by the National Aeronautics and Space Administration's Earth Science Technology Office, Computation Technologies Project, under Cooperative Agreement Number NCC5-626 between NASA and the California Institute of Technology."

The Montage distribution includes an adaptation of the MOPEX algorithm developed at the Spitzer Science Center.


k that's the whole page bestie, go shrink some cubes, you got this πŸ’œ

this has been Montage 5, dated Dec 2016, signing off β€” MSHRINKCUBE(1), periodt. πŸ‘‘βœ¨