Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HTTM: Responsivity & Compression #34

Closed
noqsi opened this issue Oct 7, 2016 · 1 comment
Closed

HTTM: Responsivity & Compression #34

noqsi opened this issue Oct 7, 2016 · 1 comment
Assignees

Comments

@noqsi
Copy link
Contributor

noqsi commented Oct 7, 2016

Implement formula and inverse to convert electron counts to digital units and make transformations for modifying slices back and forth given these conversions

  • When converting a calibrated FITs image to RAW, this is done by multiplying a constant ψ, which is approximately .2 digital units per electron and comes from calibration data ; consider talking to Joel Villasenor to get an estimate

    To handle compression, apply a near identity, slightly non-linear transformation function (derived empirically). Note that a theoretical model for this exists already due to John Doty.


Make sure to represent whether data is in ADU or Electrons for bookkeeping purposes

@noqsi noqsi added this to the Hot Tub Time Machine milestone Oct 7, 2016
@noqsi noqsi assigned noqsi and xcthulhu and unassigned noqsi Oct 7, 2016
@noqsi
Copy link
Contributor Author

noqsi commented Oct 10, 2016

More details:

Constant: FPE_MAX_ADU (65535).

Parameters from calibration database: video_scale (electrons/adu, ~5.5) and compression_parameter (dimensionless, ~0.01).

Parameter from input image: exposure_count (900 for FFI).

I/O: data_electrons, an array of pixel values and data_ADU, an array of pixel values.

Derived parameters: (note that responsivity is named ψ earlier in this thread).

    responsivity = 1/video_scale
    exposure_max_ADU = FPE_MAX_ADU * exposure_count
    compression_per_ADU = compression_parameter/exposure_max_ADU
    compression_per_electron = responsivity * compression_per_ADU

Function: electrons->ADU

    compression = 1.0 + compression_per_electron * data_electrons
    data_ADU = responsivity * data_electrons/compression

Function: ADU->electrons

    decompression = 1.0 - compression_per_ADU * data_ADU
    data_electrons = video_scale * data_ADU/decompression

@xcthulhu xcthulhu closed this as completed Nov 7, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants