models
Model primitives and Amigo model subclasses used for resolved sources.
Full API
Models and Amigo model subclasses used for resolved sources.
This module implements resolved-source models for both image plane fitting and interferometric data (DISCO).
ResolvedAmigoModel
¤
Bases: _AmigoModel, _BaseResolvedModel
Amigo model specialised for resolved (image-plane) sources.
This class composes the internal _AmigoModel parameter initialisation
behaviour with the _BaseResolvedModel helpers for retrieving a
resolved-source distribution. It is the primary model used in the
examples to represent a resolved astronomical source for use with the
amigo fitting machinery.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
exposures
|
sequence
|
Sequence of exposure / fit objects describing each observation. |
required |
optics
|
Amigo-style objects used to build the forward model (see amigo documentation for expected types). |
required | |
detector
|
Amigo-style objects used to build the forward model (see amigo documentation for expected types). |
required | |
ramp_model
|
Amigo-style objects used to build the forward model (see amigo documentation for expected types). |
required | |
read
|
Amigo-style objects used to build the forward model (see amigo documentation for expected types). |
required | |
state
|
mapping
|
Optional calibration state used to override optics/detector/ramp initial values. |
required |
rotate
|
bool
|
If True (default) apply exposure rotation to distributions. |
True
|
source_oversample
|
int
|
Oversampling factor for source-plane operations. When setting an oversampling factor > 1, the optics model must be initialised with an oversample to match (e.g. 3 times source_oversample). |
1
|
param_initers
|
dict
|
Parameter initialiser values forwarded to exposure initialisation. |
None
|
Source code in src/dorito/models.py
119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 | |
TransformedResolvedModel
¤
Bases: ResolvedAmigoModel
Resolved model that stores and operates in a compact image basis.
This class wraps a provided ImageBasis object and stores the
source distribution as basis coefficients. When initialising, if a
distribution is provided in param_initers it is converted to
basis coefficients and stored under the coeffs initialiser key.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
basis
|
ImageBasis
|
Basis object providing |
required |
window
|
Array
|
Optional multiplicative window applied to reconstructed images. |
None
|
source_oversample
|
int
|
Oversampling factor for source-plane operations. |
1
|
param_initers
|
dict
|
Parameter initialisers; accepts a |
{}
|
Source code in src/dorito/models.py
168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 | |
ResolvedDiscoModel
¤
Bases: _BaseResolvedModel
Resolved-source model container for DISCO / interferometric fits.
This lightweight container holds parameters required to transform an
image-plane distribution into the complex visibilities used by the
DISCO-style fitting code. The constructor collects per-oi parameters by
calling each oi.initialise_params(self, distribution) and assembling a
parameter mapping compatible with the rest of the amigo pipeline.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
ois
|
list
|
List of OI-like exposure objects providing |
required |
distribution
|
Array
|
Initial image-plane distribution used to derive initial parameters. |
required |
uv_npixels
|
int
|
Number of pixels in the output u/v plane used for transforms. |
required |
uv_pscale
|
float
|
Pixel scale in the u/v plane. |
required |
oversample
|
float
|
Image-plane oversampling factor used by the model (default: 1.0). |
1.0
|
psf_pixel_scale
|
float
|
PSF pixel scale in arcseconds per pixel (default chosen for examples). |
0.065524085
|
rotate
|
bool
|
If True, model-dirty images and transforms will be rotated by the exposure parallactic angle when requested. |
True
|
Attributes:
| Name | Type | Description |
|---|---|---|
pscale_in |
float
|
Property returning the image-plane pixel scale in radians per pixel. |
Source code in src/dorito/models.py
265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 | |
pscale_in
property
¤
The pixel scale of the image plane, in radians per pixel.