Gamma Filtering Tool

Notebook name: gamma_filtering_tool.ipynb


This notebook will allow you to compare data loaded without any correction against data loaded with gamma filtering on. You will be able to change the gamma filtering coefficient to optimize the cleaning of the gammas without dammaging the images.

Start the notebook

If you need help accessing this notebook, check the How To > Start the python notebooks tutorial.

How to Use It?

Select your IPTS

Check the full tutorial here

Select Images

Simply select all the images you want to work on.

Check the file selection tool tutorial to learn how to use the file selector tool.

Display Images

click the Auto scale to initialize the image just after launching the UI.

Mouse Infos / Zoom and Pan

Moving the mouse over the raw or filtered image will give you its value in the status bar (bottom left) of the UI. Also any zoom or pan transformation in one of the image will be reproduced in the other image.

Changing the filtering coefficient

After changing the gamma filtering coefficient and hitting ENTER, the entire stack of data will be reloaded using the new filter coefficient. The table will show you the new percentage and number of pixels cleaned. The gamma filtered plot will be refreshed to display the new cleaned selected image.

Gamma Filtering Algorithm

If you wonder how the gamma filtering algorithm works and what is the meaning behind this magic gamma filtering coefficient

Here is the workflow:

  • user determine the gamma filtering coefficient (coefficient). Value between 0 and 1.
  • Image per image, the program calculate the average counts (image_average_counts).
  • if the coefficient * pixel_value > image_average_counts then this pixel is considered to be a gamma and is replaced by the average value of its 8 neighbor pixels.

Feel free to move the plot around and resize them!

Histogram of Raw and Filtered Data Sets

A newer version of the UI offers the histogram of the images before and after filtering. This helps figuring out where the gamma are located.