astropy / astropy/ccdproc

Combined image's uncertainty can use the wrong class

Open
#742 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
93
Forks
92
Avg merge
14h 44m
Merged PRs (30d)
30

Description

If I give `CCDData` objects with a `VarianceUncertainty` to the combiner, I get a `VarianceUncertainty` in the output object, but I guess this should be a `StdDevUncertainty` since this is what is computed (or the stddev values should be converted to the ouput object's uncertainty type).
Problem is that the values are copied directly to the output's uncertainty, though this one is copied from the input list and can be a different type.

https://github.com/astropy/ccdproc/blob/89db3547cbfb9ad953d28a3167e4773b86af1140/ccdproc/combiner.py#L428-L430

https://github.com/astropy/ccdproc/blob/89db3547cbfb9ad953d28a3167e4773b86af1140/ccdproc/combiner.py#L810

Contributor guide

Open the contributing guide

Research direction

Start in ccdproc/combiner.py at the referenced lines 428-430 and 810, and trace how combined uncertainty values and their classes are selected. Confirm the behavior with CCDData inputs using VarianceUncertainty, then ensure the output uncertainty class and values agree with the computed representation.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
data
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.