starcall.correction
index
/home/nicho/starcall-docs/starcall/correction.py

 
Modules
       
numpy
skimage
sys

 
Classes
       
builtins.object
ResponseCurve

 
class ResponseCurve(builtins.object)
    ResponseCurve(*args)
 

 
  Methods defined here:
__init__(self, *args)
Initialize self.  See help(type(self)) for accurate signature.

Data descriptors defined here:
__dict__
dictionary for instance variables (if defined)
__weakref__
list of weak references to the object (if defined)

 
Functions
       
calculate_dye_matrix(excitation_wavelengths, dyes, filter_wavelengths)
Calculates the dye response matrix given the parameters used to image.
Parameters:
    excitation_wavelengths: array like of integers, shape (channels,)
        This specifies the wavelengths used to exite the dyes
    dyes: array like of strings, shape (channels,)
        This specifies which dyes are being used, the valid names are (case insensitive):
        DAPI, G, T, A, C, 
    dye_responses: array like of numbers, shape (channels,)
        The wavelengths
color_correct(image, dye_matrix=None)
Takes an image taken and estimates
the dye present by using the given dye response matrix.
This corrects for crosstalk between different channels
and dyes.
 
Params:
    image : np.ndarray, shape (num_channels, width, height)
    dye_matrix : np.ndarray, shape (num_dyes, num_channels)
        if not provided this matrix is estimated by the function estimate_dye_matrix
Returns:
    new_image : np.ndarray, shape (num_dyes, width, height)
crosstalk_plot(image, corrected, dye_matrix, name='image')
estimate_background(images, percent=5, gaussian=8)
estimate_crosstalk(chan, chanref, percent=0.1, bins=8)
Calculates the estimated crosstalk between the two channels,
returns the crosstalk from chanref to chan, or how much chan is dependant
on chanref.
estimate_dye_matrix(image)
Estimates the dye response matrix given an image.
This assumes that each dye corresponds to one channel,
and that the majority of the response to the dye is that
channel.
illumination_correction(images, out=None, background=None)

 
Data
        example_matrix = array([[0.89 , 0.048, 0.028, 0.034], [0.1...89, 0.323], [0.092, 0.068, 0.162, 0.679]])