Qt tool for the visual inspection and classification of astronomical stamps. This is a fork of Visualisation-tool using the Qt framework.
Originally developed with single-band .fits files in mind, it can also be used with (mutichannel) .png, .jpg and .jpeg files, albeit with limited functionality.
- Fast classification of thousands of images using the mosaic app.
- Easy access to Legacy Survey stamps using the sequential app.
- Nice visualization of single band astronomical images with different color maps and color scales.
- Easy handling of many different classifications for the same dataset using the argument:
-N name_of_the_classification. - Easy handling of different datasets using the argument:
-p /path/to/the/dataset. - Direct access to ds9 and the Legacy Survey webapp for detailed inspection.
- Keyboard shortcuts for even faster classification!
python mosaic_viewer.py -p /path/to/the/files -N name_of_the_classification -s seed
optional arguments:
-h, --help Show help message and exit.
-p PATH, --path PATH Path to the images to inspect.
-N NAME, --name NAME Name of the classifying session.
-l NCOLS, --ncols NCOLS Number of columns per page.
(default: 10).
-m NROWS, --nrows NROWS Number of rows per page.
(default: 10).
-s SEED, --seed SEED Seed used to shuffle the images, must
be a positive integer. (default: None).
--minimum_size MINIMUM_SIZE Minimum size of the stamps in the mosaic.
The optimal value depends on your screen
and on the stampsize.
--printname, --no-printname Whether to print the filename when you
click. (default: False).
--page PAGE Initial page.
--resize, --no-resize Set to allow the resizing of the stamps
with the window. (default: False).
--fits, --no-fits Forces app to only use fits (--fits)
or png/jp(e)g (--no-fits).
If unset, the app searches for fits files
in the path, but defaults to png/jp(e)g
if no fits files are found. (default: None).
left clickto mark a stamp as a gravitational lens candidate.shift+leftclick to mark a stamp as interesting.left clickon an already marked stamp to undo the classification.dgo to previous page.fgo to following page.
python single_viewer.py -p /path/to/the/files -N name_of_the_classification -s seed
optional arguments:
-h, --help Show this help message and exit.
-p PATH, --path PATH Path to the images to inspect. (default: Stamps_to_inspect).
-N NAME, --name NAME Name of the classifying session.
--reset-config Removes the configuration dictionary during startup.
--verbose Activates loging to terminal. (default: False).
--clean Cleans the legacy survey folder.
--fits, --no-fits Forces app to only use fits (--fits) or png/jp(e)g (--no-fits).
If unset, the app searches for fits files in the path, but defaults
to png/jp(e)g if no fits files are found. (default: None).
-s SEED, --seed SEED Seed used to shuffle the images. (default: None).
- Toggle
Legacy Survey (LS)to automatically display a Legacy Survey cutout of the same area. - Toggle
Large Fovto display a Legacy Survey cutout covering of 4.5 arcmin². - Toggle
Residualsto display a Legacy Survey cutout of the residuals of the area. - Toggle
Pre-fetchto download in the background the Legacy Survey images of all the stamps to classify. - Toggle
Auto-nextto automatically show the next stamp after making a classification. - Toggle
Keyboard shortcutsto activate the keyboard shortcuts:
| Key | Action | Key | Action |
|---|---|---|---|
q |
Grade A | a |
Merger |
w |
Grade B | s |
Spiral |
e |
Grade C | d |
Ring |
r |
Grade X | f |
Elliptical |
g |
Disc | ||
h |
Edge-on |
Note that classifying an image as Merger, Spiral, Ring, Elliptical, Disc, or Edge-on will also classify them as Grade X.
- Python (>= 3.9, < 3.12)
- numpy
- pandas
- matplotlib
- pyside6
- pillow
- pyparsing
- astropy
First create the environment:
conda create -n qt_classifier -c conda-forge "python<3.12,>=3.9" numpy pandas matplotlib pyside6 pillow pyparsing astropyDon't forget to activate the environment before using the app:
conda activate qt_classifierpip install numpy pandas matplotlib pyside6 pillow pyparsing astropyYou can report bugs, suggest new features, or ask questions about usage by opening an issue on this Github repository.
Also feel free to email me with questions on usage.