Class JDialogMaximumLikelihoodIteratedBlindDeconvolution

All Implemented Interfaces:
AlgorithmInterface, ScriptableActionInterface, DialogDefaultsInterface, ActionListener, FocusListener, ItemListener, WindowListener, ImageObserver, MenuContainer, Serializable, EventListener, Accessible, RootPaneContainer, WindowConstants

public class JDialogMaximumLikelihoodIteratedBlindDeconvolution extends JDialogScriptableBase implements AlgorithmInterface
Dialog that launches the Maximum likelihood iterated blind deconvolution algorithm. The dialog allows the user to set six parameters to the algorithm: numberIterations: the number of times to iterate in the blind deconvolution algorithm showProgress: Display the deconvolved image every showProgress images objectiveNumericalAperature: a property of the lens used to image the sample wavelength: the wavelength of the reflected (for brightfield) or fluorescence light refractiveIndex: the index of refraction of the sample. useMicroscopeSettings: When true, the lens NA, wavelength, and refractive index are used in the deconvolution process See AlgorithmMaximumLikelihoodIteratedBlindDeconvolution.java for algorithm details.
See Also:
  • Field Details

    • serialVersionUID

      private static final long serialVersionUID
      Use serialVersionUID for interoperability.
      See Also:
    • ibdAlgor

      The MaximumLikelihood Blind Deconvolution algorithm:
    • numberIterations

      private int numberIterations
      The number of iterations for calculating the deconvolution:
    • showProgress

      private int showProgress
      Display the deconvolved image every X images to show progress:
    • objectiveNumericalAperature

      private float objectiveNumericalAperature
      The object numerical aperature, a property of the lens used to image the sample:
    • wavelength

      private float wavelength
      The reflected or fluorescence wavelength of the sample:
    • refractiveIndex

      private float refractiveIndex
      The index of refraction of the sample:
    • useMicroscopeSettings

      private boolean useMicroscopeSettings
      When true the lens NA, wavelength, and refractive index are used in the deconvolution process
    • originalImage

      private ModelImage originalImage
      The original data image to be reconstructed:
    • extents

      private int[] extents
      The extents of original image
    • dim

      private int dim
      Number of dimensions in an image e.g 2D, 3D
    • newExtents

      private int[] newExtents
      The extents of transformed (to the power of 2) image
    • doResample

      private boolean doResample
      The boolean value to determine whether to resample the original image or not.
    • textNumberIterations

      private JTextField textNumberIterations
      User-Interface for entering the number of deconvolution iterations:
    • textShowProgress

      private JTextField textShowProgress
      User-Interface for entering the number of intermediate images to show:
    • textObjectiveNumericalAperature

      private JTextField textObjectiveNumericalAperature
      User-Interface for entering the objective numerical aperature:
    • textWavelength

      private JTextField textWavelength
      User-Interface for entering the sample wavelength:
    • textRefractiveIndex

      private JTextField textRefractiveIndex
      User-Interface for entering the index of refraction:
    • textOriginalExtentX

      private JTextField textOriginalExtentX
      User-Interface for displaying the original extent X
    • textOriginalExtentY

      private JTextField textOriginalExtentY
      User-Interface for displaying the original extent Y
    • textOriginalExtentZ

      private JTextField textOriginalExtentZ
      User-Interface for displaying the original extent Z
    • textExpectedExtentX

      private JTextField textExpectedExtentX
      User-Interface for entering the expected extent X
    • textExpectedExtentY

      private JTextField textExpectedExtentY
      User-Interface for entering the expected extent Y
    • textExpectedExtentZ

      private JTextField textExpectedExtentZ
      User-Interface for entering the expected extent Z
  • Constructor Details

    • JDialogMaximumLikelihoodIteratedBlindDeconvolution

      public JDialogMaximumLikelihoodIteratedBlindDeconvolution(Frame theParentFrame, ModelImage im)
      Creates a new JDialogMaximumLikelihoodIteratedBlindDeconvolution object.
      Parameters:
      theParentFrame - The frame that launched this dialog
      im - The source image to be reconstructed
  • Method Details

    • actionPerformed

      public void actionPerformed(ActionEvent event)
      Closes dialog box when the OK button is pressed and calls the algorithm.
      Specified by:
      actionPerformed in interface ActionListener
      Overrides:
      actionPerformed in class JDialogBase
      Parameters:
      event - Event that triggers function.
    • algorithmPerformed

      public void algorithmPerformed(AlgorithmBase algorithm)
      Called when the AlgorithmMaximumLikelihoodIteratedBlindDeconvolution has finished processing the source image. If the algorithm is completed, the resulting reconstructed image is displayed.
      Specified by:
      algorithmPerformed in interface AlgorithmInterface
      Parameters:
      algorithm - The algorithm that has finished processing.
    • storeParamsFromGUI

      protected void storeParamsFromGUI() throws ParserException
      Record the parameters just used to run this algorithm in a script.
      Specified by:
      storeParamsFromGUI in class JDialogScriptableBase
      Throws:
      ParserException - If there is a problem creating/recording the new parameters.
    • setGUIFromParams

      protected void setGUIFromParams()
      Set the dialog GUI using the script parameters while running this algorithm as part of a script.
      Specified by:
      setGUIFromParams in class JDialogScriptableBase
    • doPostAlgorithmActions

      protected void doPostAlgorithmActions()
      Store the result image in the script runner's image table now that the action execution is finished.
      Overrides:
      doPostAlgorithmActions in class JDialogScriptableBase
    • callAlgorithm

      protected void callAlgorithm()
      Once all the necessary variables are set, call the algorithm based on what type of image this is and whether or not there is a separate destination image.
      Specified by:
      callAlgorithm in class JDialogScriptableBase
    • init

      private void init()
      Initializes the user-interface components of the dialog:
    • setVariables

      private boolean setVariables()
      Gets the user-determined parameters for the algorithm from the user-interface components.
      Returns:
      true
    • isPowerOf2

      private boolean isPowerOf2(int dimValue)
      Check if the dimension value is already a power of 2.
      Parameters:
      dimValue - dimension value
      Returns:
      isPower2 true if dimValue is a power of 2, false otherwise.
    • transformDimPowerOf2

      private int transformDimPowerOf2(int dimValue)
      Calculate the dimension value to power of 2.
      Parameters:
      dimValue - dimension value
      Returns:
      newDimValue dimension value in power of 2.