UNDER DEVELOPMENT

The software package is currently being dramatically improved and updated.
This is a (very) old version, potentially with bugs.

  Shapelets web page     Shapelets IDL code     Installation     Help pages     Simulated images  
List of routines
Instrutions for general code
Instructions for image simulation code

Help for "simage_generate_shapecat" routine:

Repeatedly calls simage_generate_shapecat.pro to generate a shapelet catalogue for a simulated image.

This routine takes an input catalogue of true galaxy morphologies, and resamples it by repeatedly calling simage_resample_pdf.pro. It writes out a new catalogue containing the shapelet coefficients of fake galaxies. These can then be used to generate a simulated image, using simage_assemble_image.pro. This routine can be called from a shell prompt via the generate_catalogue script.

Random positions are assigned to each of the new galaxies, within the limits set by the input variable n_pix. It can be useful to use these positions (rather than creating new, re-randomised ones) when assembling the simulated image, to make it easier to create "repeated observations" at a later date. The objects' positions assigned by this routine also occupy the sky surrounding the image itself, so that the repeat observations can even be dithered by a small amount.

Other input options include n_obj, the number of fake objects to be generated for the catalogue, and n_max, the shapelet order at which these are to be truncated. I tend to run this routine only once or twice, generating very large catalogues containing very many galaxies. It is then much quicker to create a simulated image after that, drawing objects as required (perhaps randomly) from this one catalogue.

The file Masseyetal2004.shape in shapelets_shims.tar.gz contains 20,000 pre-generated objects that were used to create the simulated images needed for the Weak lensing from space: I, II and III series of SNAP papers. Feel free to use these objects if you'd like.

See also the header below, which has been extracted from the source code for this routine.

; NAME: ; SIMAGE_GENERATE_SHAPECAT ; ; CATEGORY: ; Shapelets image simulation. ; ; PURPOSE: ; Uses simage_resample_pdf.pro many times to generate a new random ; catalogue of objects that could be used to populate a simulated image. ; ; INPUTS: ; shapecat - Shapelet catalogue of real data in a similar regime to the ; required simulation (eg HDF galaxies, read in using ; shapelets_read_shapecat_hdf.pro). ; It is recommended, although not necessary, that this contain ; polar rather than Cartesian shapelet coefficients. Objects ; just morph better in polar shapelets. ; ; OPTIONAL INPUTS: ; output_file - Filename for output. ; width - This is slow to calculate, so allow it to be entered by ; hand, or calculated on a previous run to avoid the ; duplication of effort. ; seed - Seed for random number generator. ; n_pix - Integer (x,y). Number of pixels planned for final ; simulated image. This routine does not create the image ; (for that, see simage_assemble_image.pro), but the random ; positions of simulated galaxies can be specified in either ; routine. If they are specified here, and stored in the ; catalogue, it will be easier to duplicate simulated image ; or created dithered simulateed image later. ; Default: . ; n_max - Objects created up to this truncation in shapelet space. ; Default: . ; n_obj - Number of objects in output catalogue. This does not ; determine the number density of objects in the simulated ; image. That is done in simage_assemble_image.pro. ; Default: . ; ; KEYWORD PARAMETERS: ; /PLOT - Plot each newly generated object to screen, for debugging. ; ; OUTPUTS: ; A simulated shapelet catalogue is written to disc. ; ; MODIFICATION HISTORY: ; Mar 04 - Tidied up by RM. ; Mar 03 - Cosmetic changes and modularisation of subroutines by RM. ; Jan 02 - new_hdf.pro written by Richard Massey.

Return to the shapelets web page or the code help menu.


Last modified on 02nd May 2008 by Richard Massey.

Valid HTML 4.01!