Code Monkey home page Code Monkey logo

fidelity's People

Contributors

sphemakh avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

fidelity's Issues

Estimating the noise in radio images

I've been thinking of how best to estimate the noise in an image, because simply taking the std dev or mad (median absolute dev) of the pixels does not give accurate results in the presence of bright emission. But, since the sky emission is positive, the negative pixels should give a far better estimate of the noise. This is what I'm thinking:

Let D be a N_x_N image and d be the negative pixels of D (1x_M_, where M is the number of negative pixels).
Then, assuming that the noise is symmetric about zero the noise can be approximated as:
sigma = std_dev[d || (-d)], where || represents concatenation.

In the presence of calibration artefacts (which generally have negative counterparts) this might be a bit off, but it should still be an improvement over using all the pixels.

Local SNR approximation to look for local artefacts

The variance of an image should vary with in an image due to beam response, we should compute a local variance and then look for structures in the residual image which diverge from that variance, these are probably artefacts.

Global (and local) noise distributions

An ideal residual image will have Gaussian noise (with some bias towards positive values be cause sources have positive flux). We can fit multiple (or general) distributions to the histogram of the residual image pixel values. Then ask which distribution best models the residual noise, and if that is close to Gaussian.

It would be useful to try general Gaussian, Lapacian, Cauchy distributions. And compute higher order moments such as skew and kurtosis.

Added stats.py

Just to get us going:

I've add a script that does some of the things we've talking about:

  • It fits a distribution (cauchy, gaussian, laplace, maxwell) to the image pixels and returns the best fit parameters with their errors.
  • Calculates the "local variance" at source locations (this requires a Tigger compatible sky model)

This is an example of how to run the script:

image_stats/stats.py -fit laplace -s -nb 200 -cat nvss6deg.lsm.html foreman_grill_0_s1-briggs-noise.fits

PSF sidelobe / residual image correlation

The artefact structure in a residual image should be 'similar' to that of the PSF sidelobes. Given a PSF image, remove the main lobe, to get only the sidelobe structure, does this have a correlation with the residual image?

Also, perhaps the image should be downsampled (before or after?) correlation to improve correlation?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.