8
How to use galfit (and galphot) Gijs Verdoes Kleijn

How to use galfit (and galphot) Gijs Verdoes Kleijn

Embed Size (px)

Citation preview

Page 1: How to use galfit (and galphot) Gijs Verdoes Kleijn

How to use galfit (and galphot)

Gijs Verdoes Kleijn

Page 2: How to use galfit (and galphot) Gijs Verdoes Kleijn

Galfit (& Galphot)

• Galfit: 2-D galaxy profile fitting routines (C)– Author: Chien Peng (STScI)– Awe-status: basics incorporated– Reference:

• zwicky.as.arizona.edu/~cyp/work/galfit/galfit.html • Peng etal 2002 AJ 124, 266

• Galphot: ellipse fitting routine (fortran)– Author: Marijn Franx (Leiden)– To be incorporated– ref: www.strw.leidenuniv.nl/~franx– Franx etal 1989 AJ 98, 538

Page 3: How to use galfit (and galphot) Gijs Verdoes Kleijn

What galfit does

• fitting 2-D parameterized axisymmetric functions to images

• Any (in)dependent combination of Sersic(devauc/expo),nuker,gaussian,king,moffat,sky

• Disky/boxy shapes• Error weighing• Inclusion PSF via FFT• Meant for well resolved galaxies: explore sub-structure

– Future plans of galfit: more profiles, more isophotal shapes, allow for axial twists, spiral structure.

– No batch mode perl scripts exist (used for GEMS survey)

Page 4: How to use galfit (and galphot) Gijs Verdoes Kleijn

Astro-WISE implementation

• Python wrapper: – Give input to galfit c-code from python– Input+output+links to SourceList contained in classes instances

of which are stored in database– no alteration c-code– Written by Ewout Helmich, help from C. Trachternach & GVK

• Description– Input: SLID, SID, cut-out via cut-out server, configuration

parameters– Defaults for configuration parameters based on SourceList

• Initial guess x position: SourceList x position• Size cut-out image: 15* SourceList r_eff

Page 5: How to use galfit (and galphot) Gijs Verdoes Kleijn

Examples of usage (see how-to)

awe>from DBRecipes.GalFit import GalFitTask awe>task = GalFitTask(instrument='WFI', slid=57424, sids=[31,52,73], models=['sersic', 'sky'], commit=1) awe>task.execute()

awe>from astro.net.dpu import Processor awe> from astro.local.Environment import Envawe>dpu = Processor(Env['dpu_name']) awe>dpu.run('GalFit', i='WFI', slid=57424, sids=[31,52,,73], m=['sersic', 'sky'], commit=1)

Run galfit using local cpu:

Run galfit using parallel cluster:

Page 6: How to use galfit (and galphot) Gijs Verdoes Kleijn

Examples continued

awe> mysources = [(57424, 31), (57424, 52), (57424, 73)] awe>models = [] awe>for slid, sid in mysources: awe> q = (GalFitModel.SLID == slid) & (GalFitModel.SID == sid) awe> model = q.max('GFID') awe> models.append(model) awe>for m in models: awe> m.show_model_parameters()

Show model parameters for SLID=57424, SID=[31,52,73] for last run:

Page 7: How to use galfit (and galphot) Gijs Verdoes Kleijn

Now & Future

• Code itself can be found at:– opipe/astro/main/GalFitModel.py (show it)

– opipe/DBRecipes/GalFit.py (Task)

• Current implementation– Sersic+sky on ReducedScienceFrame,RegriddedFrame– Contaminant fitting included

• Next steps– All profiles (Sersic+sky implemented: rest coming soon– Psf convolution – Background subtraction statistics right– Constraints file inclusion

Page 8: How to use galfit (and galphot) Gijs Verdoes Kleijn

Summary

• Surface photometry tools getting ready in Astro-WISE for large data sets:– GalFit implemented basics, more coming

soon• Easy (re-)processing and inspecting of galfit

results on large number of galaxies

– GalPhot is coming…..