Difference between revisions of "Make a simple mosaic"

From CoolWiki
Jump to navigationJump to search
Line 48: Line 48:
  
 
[[image:oncch1.png]]
 
[[image:oncch1.png]]
 +
 +
 +
10. Repeat as necessary for other channels, other observations....

Revision as of 23:53, 26 July 2007

OK, you've downloaded more than one post-BCD mosaic of your target, in this example, the Orion Nebula Cluster. How can you combine them into one mosaic?

Step 0. Make a directory called something useful, like "orion." Put all the zip files that Leopard gives you in there. Unzip them. After you unzip all the files that Leopard downloads, you will have several directories on your disk, each of which is labeled by the letter "r" followed by a 7-digit number. For my example, I downloaded all four channels of the post-BCD data from program 43, but nothing from any other program. I have nine directories: r4097792, r4098048, r4098304, r4098560, r4099840, r4100096, r4100352, r4100608, and r4182528.


Now, we will use a program called MOPEX to combine the mosaics. In order to do this, we need to tell MOPEX which files we want to combine. MOPEX needs not only the individual mosaics from each one of these AORs, but also the individual mosaics of the errors. Optionally, you can also give it the individual mosaics of something called "coverage maps" - these tell you how many frames of coverage there is on each patch of sky in the map.


1. If you need to, go and grab the MOPEX software for your platform, follow the directions, install it, and start it up. Make sure that, under the "Options" menu, the option "Use Automatic Version Update" is selected. If this is the first time you have installed MOPEX, you will probably have to wait a few seconds, and then MOPEX will say that there is a new version of the software available. Let it go and grab the new version and restart.


2. Create lists of files for MOPEX to use. As described above, it needs at least the main data (*maic.fits) and the errors (*munc.fits). On a linux machine or from a Mac terminal window, you can get these lists as follows. cd into your 'useful' directory (called "orion" above) where you unpacked all the data. Then do this:

ls r*/ch1/pbcd/*maic.fits > ch1mos.txt
ls r*/ch2/pbcd/*maic.fits > ch2mos.txt
ls r*/ch3/pbcd/*maic.fits > ch3mos.txt
ls r*/ch4/pbcd/*maic.fits > ch4mos.txt
ls r*/ch1/pbcd/*munc.fits > ch1err.txt
ls r*/ch2/pbcd/*munc.fits > ch2err.txt
ls r*/ch3/pbcd/*munc.fits > ch3err.txt
ls r*/ch4/pbcd/*munc.fits > ch4err.txt

Each one of these lists now contains one filename per line, for more than 230 lines per channel.


3. By now, MOPEX should have updated and restarted. Go up to the File menu and choose "new Mosaic pipeline." Pick the channel you want - try IRAC channel 1. When it comes back, it will have a window that looks like this:

Mopexnew.png


4. Under the "Image Stack File" part of the window, click on "add" and pick the file that is the list of the *maic files you want to combine -- make sure you choose the same channel as the template you just selected. (If you picked "IRAC channel 2" on the previous step, pick the list of IRAC channel 2 files.) For this example, try IRAC channel 1 (ch1mos.txt in the above).


5. Under the "Output Directory" part of the window, click on "add" and pick a place for MOPEX to put its (copious) output. You may need to manually create the directory outside of MOPEX first (from a terminal window). You may wish to name the directory something useful like "ch1mosaic" or similar, for whatever channel you are combining.


6. Click on "Optional Input and Mask Files." In the pop-up window, under "sigma list file", click on "add" and pick the file that is the list of the *munc files you want to combine -- make sure you choose the same channel as the template you just selected. (If you picked "IRAC channel 2" on the previous step, pick the list of IRAC channel 2 files.) For this example, try IRAC channel 1 (ch1err.txt in the above).


7. Click OK in the popup window.


8. Go up to the top left of the window and hit the green button that looks like "Play" on a DVD player. Sit back and watch it run. You may need to go get a(nother) soda.


9. After it finishes, you can click on the button in the last part of the last module it runs to load the mosaic. The mosaic is actually stored in the output directory you selected, under a directory called "Combine-mosaic." The file is called "mosaic.fits." Mine looks like this for the ONC for IRAC channel 1:

Oncch1.png


10. Repeat as necessary for other channels, other observations....