Dust Grain Fitter

DGFit is a python package to derive dust grain size and composition distributions based on fitting observations of interstellar dust.


GitHub: DGFit

Quick Start

Material needed.

Reporting Issues

If you have found a bug in DGFit please report it by creating a new issue on the DGFit GitHub issue tracker.

Please include an example that demonstrates the issue sufficiently so that the developers can reproduce and fix the problem. You may also be asked to provide information about your operating system and a full Python stack trace. The developers will walk you through obtaining a stack trace if it is necessary.


Like the Astropy project, DGFit is made both by and for its users. We accept contributions at all levels, spanning the gamut from fixing a typo in the documentation to developing a major new feature. We welcome contributors who will abide by the Python Software Foundation Code of Conduct.

DGFit follows the same workflow and coding guidelines as Astropy. The following pages will help you get started with contributing fixes, code, or documentation (no git or GitHub experience necessary):

For the complete list of contributors please see the DGFit contributors page on Github.

Reference API

dgfit.obsdata Module

ObsData class

observed data that will be used to constrain the dust model


ObsData(ext_filenames, avnhi_filename, …)

ObsData Class

Class Inheritance Diagram

Inheritance diagram of dgfit.obsdata.ObsData

dgfit.dustgrains Module

DustGrains class

dust grain properties stored by dust size/composition



DustGrains Class

Class Inheritance Diagram

Inheritance diagram of dgfit.dustgrains.DustGrains

dgfit.dustmodel Module


DustModel([componentnames, path, dustmodel, …])

Full dust model including arbirary size and composition distributions.


Dust model that uses powerlaw size distributions with min/max sizes (MRN).


Dust model that uses the Weingartner & Draine (2001) size distributions.

Class Inheritance Diagram

Inheritance diagram of dgfit.dustmodel.DustModel, dgfit.dustmodel.MRNDustModel, dgfit.dustmodel.WDDustModel