{ "metadata": { "name": "", "signature": "sha256:0ee9c7da09611ff7add13dd2f731121451eea46c140ed72a1cf34618c67c4ec9" }, "nbformat": 3, "nbformat_minor": 0, "worksheets": [ { "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "Suppose that you are interested in a subset of RC3 galaxies that are large enough that it can affect the imaging data of a part of the sky that your telescope is pointing at. " ] }, { "cell_type": "markdown", "metadata": {}, "source": [ " SELECT *FROM RC3 WHERE radius >0.1\n", " AND 10 < new_ra < 50\n", " AND 50 ', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '']\n" ] } ], "prompt_number": 6 }, { "cell_type": "code", "collapsed": false, "input": [ "print(subsetlst[0])" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "\n" ] } ], "prompt_number": 7 }, { "cell_type": "markdown", "metadata": {}, "source": [ "We can now perform mosaicing functions to the whole subset of the catalog by storing this list inside the instance variable __allObj__." ] }, { "cell_type": "code", "collapsed": false, "input": [ "subset.allObj = subsetlst" ], "language": "python", "metadata": {}, "outputs": [], "prompt_number": 8 }, { "cell_type": "markdown", "metadata": {}, "source": [ "Additional information stored inside RC3 Catalog Objects" ] }, { "cell_type": "code", "collapsed": false, "input": [ "print (subset.equinox)\n", "print(subset.frame)" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "J2000\n", "fk5\n" ] } ], "prompt_number": 9 }, { "cell_type": "code", "collapsed": false, "input": [ "from sdss import SDSS\n", "sdss = SDSS()" ], "language": "python", "metadata": {}, "outputs": [], "prompt_number": 10 }, { "cell_type": "markdown", "metadata": {}, "source": [ "You can mosaic all the RC3 objects inside the Catalog subset" ] }, { "cell_type": "code", "collapsed": false, "input": [ "subset.mosaicAll(sdss)" ], "language": "python", "metadata": {}, "outputs": [] }, { "cell_type": "markdown", "metadata": {}, "source": [ "This mosaics all the galaxies that lies inside the subset. Then we display all the mosaiced color image as a single png by montaging them together using GraphicsMagick." ] }, { "cell_type": "code", "collapsed": false, "input": [ "import os" ], "language": "python", "metadata": {}, "outputs": [], "prompt_number": 1 }, { "cell_type": "code", "collapsed": false, "input": [ "os.mkdir(\"Mosaic\")" ], "language": "python", "metadata": {}, "outputs": [], "prompt_number": 3 }, { "cell_type": "code", "collapsed": false, "input": [ "os.system(\"find . -name '*.tiff' -type f -exec cp {} ./Mosaic \\;\")\n", "os.system (\"gm montage *.tiff montage.png\")" ], "language": "python", "metadata": {}, "outputs": [ { "metadata": {}, "output_type": "pyout", "prompt_number": 6, "text": [ "256" ] } ], "prompt_number": 6 }, { "cell_type": "code", "collapsed": false, "input": [ "from IPython.core.display import Image\n", "Image(filename=\"montage.png\")" ], "language": "python", "metadata": {}, "outputs": [], "prompt_number": 1 }, { "cell_type": "code", "collapsed": false, "input": [], "language": "python", "metadata": {}, "outputs": [] } ], "metadata": {} } ] }