Plot polarization maps from SKIRT simulation output. More...
Functions | |
def | _circArrow (ax, posx, posy, size) |
This helper function draws a circular polarization arrow in the given matplotlib axes. More... | |
def | _roundUp (x, slack=0.01) |
This helper function rounds up a given number (away from zero) to one significant digit, in a logarithmic fashion. More... | |
def | plotPolarization (simulation, *plotLinMap=True, plotDegMap=False, plotDegAvg=False, plotCirMap=False, wavelength=None, binSize=(7, 7), degreeScale=None, decades=5, outDirPath=None, figSize=(8, 6), interactive=None) |
This function creates PDF polarization maps for the output of polarization-enabled SKIRT simulations that include instruments generating surface brightness frames or data cubes (*.fits files). More... | |
Plot polarization maps from SKIRT simulation output.
The function in this module creates PDF polarization maps for the output of polarization-enabled SKIRT simulations that include instruments generating surface brightness frames or data cubes (*_total.fits and *_stokes*.fits files).
|
private |
This helper function draws a circular polarization arrow in the given matplotlib axes.
|
private |
This helper function rounds up a given number (away from zero) to one significant digit, in a logarithmic fashion.
The slack argument allows a number just larger than the nearest limit to be clamped to that limit.
def pts.visual.plotpolarization.plotPolarization | ( | simulation, | |
* | plotLinMap = True , |
||
plotDegMap = False , |
|||
plotDegAvg = False , |
|||
plotCirMap = False , |
|||
wavelength = None , |
|||
binSize = (7,7) , |
|||
degreeScale = None , |
|||
decades = 5 , |
|||
outDirPath = None , |
|||
figSize = (8, 6) , |
|||
interactive = None |
|||
) |
This function creates PDF polarization maps for the output of polarization-enabled SKIRT simulations that include instruments generating surface brightness frames or data cubes (*.fits files).
Specifically, the function accepts a sequence of Simulation and/or Instrument instances (or a single instance of either of these types), and it creates polarization maps for each of the instruments that actually produced both *_total.fits and *_stokes*.fits files. Other instruments are silently ignored.
By default, the figures are saved in the output directory of the corresponding instrument, using a name starting with the simulation prefix and instrument name, and ending with ".pdf". The output directory can be overridden. In interactive mode (see the pts.utils.interactive() function), the figures are not saved and are left open for display in notebooks.
The function takes the following arguments: