WfGroupResult#
- class lsst.ts.wep.blitz.WfGroupResult(group_id, group_size, zk_dev, success, donut_results, det_names, imgs, model_imgs, fit_elapsed, fit_nfev, fit_cost, fit_optimality, fit_njev, fit_status, fit_message, fit_error, fit_outcome)#
Bases:
objectOne fit group’s outputs, produced by
WavefrontFittingTask.run.A group is what gets fit jointly – a pair in paired mode, one donut unpaired, a whole corner in
corner_groupmode – so everything here is a property of the fit, not of a donut. The per-donut half of the same fit is theWfDonutResultlist indonut_results, one per member, each carrying its own copy of the group’s values for the output catalog’sgroup_*columns.The
fit_*fields are flattened from what used to be a nestedfit_infodict, so a group that never fit reports typed NaN/0/""rather than a missing key.fit_outcomeis one of_FIT_OUTCOMESand says which of the mutually exclusive paths ran; it subsumessuccess.imgsandmodel_imgsare dropped by_shed_imagesin full-array mode when the config says not to save them, since they dominate the size of what a worker pickles home.- zk_dev#
Sparse wavefront deviations, one entry per fitted Noll index, in meters.
- Type:
numpy.ndarray
- donut_results#
The per-donut half of the fit, one per group member.
- Type:
- model_imgs#
The per-member model images, or None when dropped to save size.
- Type:
list of numpy.ndarray or None
- fit_nfev, fit_njev
Function and Jacobian evaluation counts.
- Type:
- fit_cost, fit_optimality
Final cost and first-order optimality of the fit.
- Type:
- fit_status#
least_squarestermination status, or_FIT_STATUS_ABSENTfor a group that never fit.- Type:
- fit_message, fit_error
The solver’s termination message and any error string.
- Type:
- fit_outcome#
Which mutually exclusive fit path ran; subsumes
success.- Type:
FitOutcome
- Parameters:
group_id (
str)group_size (
int)success (
bool)donut_results (
list[WfDonutResult])model_imgs (
list[ndarray[tuple[Any,...],dtype[float64]] |None] |None)fit_elapsed (
float)fit_nfev (
int)fit_cost (
float)fit_optimality (
float)fit_njev (
int)fit_status (
int)fit_message (
str)fit_error (
str)fit_outcome (
Literal['ok','nonconvergent','timeout','exception','x0_only',''])
Attributes Summary
Methods Summary
dead(group, reason, n_zk)Stand-in for a fit group whose worker was killed outright.
empty(group_id, n_zk)Result for a group with no donuts in it.
Attributes Documentation
-
donut_results:
list[WfDonutResult] = <dataclasses._MISSING_TYPE object>#
-
fit_outcome:
Literal['ok','nonconvergent','timeout','exception','x0_only',''] = <dataclasses._MISSING_TYPE object>#
-
model_imgs:
list[ndarray[tuple[Any,...],dtype[float64]] |None] |None= <dataclasses._MISSING_TYPE object>#
Methods Documentation
- classmethod dead(group, reason, n_zk)#
Stand-in for a fit group whose worker was killed outright.
No Python runs in a process the kernel has already destroyed, so the parent reports the group as failed on its behalf and the surviving groups’ Zernikes still reach the output.
The group’s donuts are carried through even though none was fit: they still get catalog rows, and dropping them here would lose them silently. They arrive as
_NULL_WF_DONUTcopies rather than theDonut`s themselves, since that is what `_build_donut_catalogreads – identity and intrinsics survive, and everything the lost fit would have measured is NaN.fit_outcomeis"exception"and not"", which would claim no group ever took the donut.- Parameters:
- Returns:
A failed result carrying the group’s donuts as
_NULL_WF_DONUTcopies withfit_outcome="exception".- Return type:
- classmethod empty(group_id, n_zk)#
Result for a group with no donuts in it.
Nothing was fit, so every fit field takes its no-fit value and
fit_outcomeis""– the same spelling_NULL_WF_DONUTuses for “no fit consumed this”.- Parameters:
- Returns:
A result with no donuts, all-NaN Zernikes, and every fit field at its no-fit value.
- Return type: