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

Feature/noise scaling snr #149

Merged
merged 2 commits into from
Nov 26, 2024
Merged

Feature/noise scaling snr #149

merged 2 commits into from
Nov 26, 2024

Conversation

Jammy2211
Copy link
Owner

    Apply a mask to the imaging dataset using noise scaling, whereby the maskmay zero the data and increase
    noise-map values to change how they enter the likelihood calculation.

    Given this data region is masked, it is likely thr data itself should not be included and therefore
    the masked data values are set to zero. This can be disabled by setting `should_zero_data=False`.

    Two forms of scaling are supported depending on whether the `signal_to_noise_value` is input:

    - `noise_value`: The noise-map values in the masked region are set to this value, typically a very large value,
    such that they are never included in the likelihood calculation.

    - `signal_to_noise_value`: The noise-map values in the masked region are set to values such that they give
    this signal-to-noise ratio. This overwrites the `noise_value` parameter.

    For certain modeling tasks, the mask defines regions of the data that are used to calculate the likelihood.
    For example, all data points in a mask may be used to create a pixel-grid, which is used in the likelihood.
    When data points are moved via `apply_mask`, they would be omitted from this grid entirely, which would
    lead to an incorrect likelihood calculation. Noise scaling retains these data points in the likelihood
    calculation, but ensures they do not contribute to the fit.

    This function can only be applied before actual masking.

@Jammy2211 Jammy2211 merged commit 824bf07 into main Nov 26, 2024
4 checks passed
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

Successfully merging this pull request may close these issues.

1 participant