Class JDialogProstate2DSlicesPngTextFileConverter

java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
java.awt.Dialog
javax.swing.JDialog
gov.nih.mipav.view.dialogs.JDialogBase
gov.nih.mipav.view.renderer.WildMagic.ProstateFramework.JDialogProstate2DSlicesPngTextFileConverter
All Implemented Interfaces:
AlgorithmInterface, DialogDefaultsInterface, ActionListener, FocusListener, ItemListener, WindowListener, ImageObserver, MenuContainer, Serializable, EventListener, Accessible, RootPaneContainer, WindowConstants

public class JDialogProstate2DSlicesPngTextFileConverter extends JDialogBase implements AlgorithmInterface
For rest of the papers: this class generates the training list from the training fold. 5 fold cross-validation, each training fold contains the png slices from all other folds. The training list generator reads the png files, converts their name into a file list. HED deep leaning model read the list in order to train one model. For simplicity, readKeyImageDir() and writePngFile() two methods specify the reading dir and list file saving place.
Author:
Ruida Cheng
See Also:
  • Field Details

    • serialVersionUID

      private static final long serialVersionUID
      See Also:
    • UI

      private ViewUserInterface UI
      The main user interface.
    • keyImageVector1

      private Vector<String> keyImageVector1
    • keyImageVOIVector1

      private Vector<String> keyImageVOIVector1
    • textFieldSaveImage

      private JTextField textFieldSaveImage
      saved 2D slices atlas dir.
    • saveImageChooser

      private JFileChooser saveImageChooser
    • saveImageDirectory

      private String saveImageDirectory
  • Constructor Details

    • JDialogProstate2DSlicesPngTextFileConverter

      public JDialogProstate2DSlicesPngTextFileConverter(Frame theParentFrame)
      Constructor.
      Parameters:
      theParentFrame -
  • Method Details

    • disposeLocal

      public void disposeLocal()
      dispose memory
    • actionPerformed

      public void actionPerformed(ActionEvent event)
      Dialog local actionPerformed handler.
      Specified by:
      actionPerformed in interface ActionListener
      Overrides:
      actionPerformed in class JDialogBase
    • recordSaveImageDir

      private void recordSaveImageDir()
      Let user specify the saved 2D slices atlas, record the save directory.
    • readKeyImageDir

      private void readKeyImageDir()
      Read 3D images atlas directory.
    • writePngPair

      private void writePngPair()
    • traverse_folder

      private void traverse_folder(File dir)
    • processDir_folder

      private void processDir_folder(File dir)
    • sortKeyImage

      public void sortKeyImage()
    • printImages

      public void printImages()
      Debugger for test the image and VOis reading.
    • algorithmPerformed

      public void algorithmPerformed(AlgorithmBase algorithm)
      This method is required if the AlgorithmPerformed interface is implemented. It is called by the algorithms when it has completed or failed to to complete, so that the dialog can be display the result image and/or clean up.
      Specified by:
      algorithmPerformed in interface AlgorithmInterface
      Parameters:
      algorithm - Algorithm that caused the event.
    • init

      public void init()
      Initial panel
    • buildKeyImagePanel

      public void buildKeyImagePanel()
      Panel contains both the 3D image dir and saved 2D slices atlas dir.