$darkmode
DENOPTIM
denoptim.gui.GUIInspectGARun Class Reference

A panel that allows to inspect the output of an artificial evolution experiment. More...

Inheritance diagram for denoptim.gui.GUIInspectGARun:
[legend]
Collaboration diagram for denoptim.gui.GUIInspectGARun:
[legend]

Classes

class  GenerationChoiceDialog
 Modal dialog that asks the user for a generation number. More...
 
class  PlottedCandidatesComparator
 

Public Member Functions

 GUIInspectGARun (GUIMainPanel mainPanel)
 Constructor. More...
 
void importGARunData (File file, JComponent parent)
 
- Public Member Functions inherited from denoptim.gui.GUICardPanel
 GUICardPanel (GUIMainPanel mainPanel, String newPanelName)
 Constructor for JPanel meant to be a single "card" in the deck of cards. More...
 
boolean hasUnsavedChanges ()
 Check for unsaved changes in the components included in this card. More...
 

Static Public Attributes

static AtomicInteger evolInspectorTabUID = new AtomicInteger(1)
 Unique identified for instances of this handler. More...
 

Private Member Functions

void initialize ()
 Initialize the panel and add buttons. More...
 
void readOneGeneration (File genFolder, String summaryName, int genId, Component parent, Map< Integer, double[]> popProperties)
 
void buildAndFillMonitorPlot (File runFolder, JComponent parent)
 Modal dialog to display visual examples of line colors and strokes. More...
 
List< CandidateLWgetOverlappingItems (CandidateLW item, int maxNeighbours)
 
CandidateLW choseAmongPossiblyOverlapping (JComponent parent, List< CandidateLW > overlappingItems)
 
void renderViewWithSelectedItem (CandidateLW item)
 
void renderViewWithoutSelectedItems ()
 

Private Attributes

JPanel ctrlPanel
 
JPanel ctrlPanelRow1
 
JPanel ctrlPanelRow1Left
 
JPanel ctrlPanelRow1Right
 
JPanel ctrlPanelRow2Left
 
JSplitPane centralPanel
 
JSplitPane rightPanel
 
JPanel rightUpPanel
 
JPanel rightDownPanel
 
MoleculeViewPanel molViewer
 
File srcFolder
 
ArrayList< CandidateLWallIndividuals
 
int molsWithFitness = 0
 
boolean warnedAboutMissingCandFiles = false
 
JLabel lblTotItems
 
Map< Integer, CandidateLWcandsWithFitnessMap
 
DefaultXYDataset datasetAllFit = new DefaultXYDataset()
 
DefaultXYDataset datasetSelected = new DefaultXYDataset()
 
DefaultXYDataset datasetPopMin = new DefaultXYDataset()
 
DefaultXYDataset datasetPopMax = new DefaultXYDataset()
 
DefaultXYDataset datasetPopMean = new DefaultXYDataset()
 
DefaultXYDataset datasetPopMedian = new DefaultXYDataset()
 
XYPlot evoPlot
 
JFreeChart evoChart
 
ChartPanel evoChartPanel
 
JPopupMenu evoSeriesCheckList
 
JButton evoSeriesBtn
 
Map< CounterID, DefaultXYDataset > monitorDatasets
 
XYPlot monitorPlot
 
JFreeChart monitorChart
 
ChartPanel monitorChartPanel
 
ScrollableJPupupMenu monitorSeriesCheckList
 
JButton monitorSeriesBtn
 
final String NL = System.getProperty("line.separator")
 
JButton openSingleGraph
 Button offering the possibility to load the graph inspector for a selected item. More...
 
String pathToSelectedItem
 Storage of pathname to the item selected in the chart. More...
 
JButton openGeneratinGraphs
 Button offering the possibility to load the graphs of the population at a given time (i.e., generation). More...
 
JButton openFinalPopGraphs
 Button offering the possibility to load the graphs of the final population. More...
 
Map< Integer, List< String > > candsPerGeneration
 Pathways of population members collected by generation id. More...
 
final Color[] colors
 Predefined list of data series colors. More...
 
final BasicStroke[] strokes
 Predefined line strokes. More...
 
String nameFirstMonitorSeries = "unset"
 Records the name of the first series in the monitor plot to facilitate its recovery upon chart reset. More...
 

Static Private Attributes

static final long serialVersionUID = -8303012362366503382L
 Version UID. More...
 

Additional Inherited Members

- Protected Attributes inherited from denoptim.gui.GUICardPanel
GUIMainPanel mainPanel
 The main panel (cards deck) More...
 

Detailed Description

A panel that allows to inspect the output of an artificial evolution experiment.

Author
Marco Foscato

Definition at line 101 of file GUIInspectGARun.java.

Constructor & Destructor Documentation

◆ GUIInspectGARun()

denoptim.gui.GUIInspectGARun.GUIInspectGARun ( GUIMainPanel  mainPanel)

Constructor.

Definition at line 253 of file GUIInspectGARun.java.

References denoptim.gui.GUIInspectGARun.evolInspectorTabUID, denoptim.gui.GUIInspectGARun.initialize(), and denoptim.gui.GUICardPanel.mainPanel.

Here is the call graph for this function:

Member Function Documentation

◆ buildAndFillMonitorPlot()

void denoptim.gui.GUIInspectGARun.buildAndFillMonitorPlot ( File  runFolder,
JComponent  parent 
)
private

◆ choseAmongPossiblyOverlapping()

CandidateLW denoptim.gui.GUIInspectGARun.choseAmongPossiblyOverlapping ( JComponent  parent,
List< CandidateLW overlappingItems 
)
private

Definition at line 1474 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.importGARunData().

Here is the caller graph for this function:

◆ getOverlappingItems()

List< CandidateLW > denoptim.gui.GUIInspectGARun.getOverlappingItems ( CandidateLW  item,
int  maxNeighbours 
)
private

Definition at line 1417 of file GUIInspectGARun.java.

References denoptim.gui.GUIInspectGARun.allIndividuals, denoptim.gui.GUIInspectGARun.evoPlot, denoptim.graph.CandidateLW.getFitness(), denoptim.graph.CandidateLW.getGeneration(), and denoptim.graph.CandidateLW.hasFitness().

Referenced by denoptim.gui.GUIInspectGARun.importGARunData().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ importGARunData()

void denoptim.gui.GUIInspectGARun.importGARunData ( File  file,
JComponent  parent 
)

Definition at line 677 of file GUIInspectGARun.java.

References denoptim.gui.GUIInspectGARun.allIndividuals, denoptim.gui.GUIInspectGARun.buildAndFillMonitorPlot(), denoptim.gui.GUIInspectGARun.candsPerGeneration, denoptim.gui.GUIInspectGARun.candsWithFitnessMap, denoptim.gui.GUIPreferences.chartPointSize, denoptim.gui.GUIInspectGARun.choseAmongPossiblyOverlapping(), denoptim.gui.GUIInspectGARun.datasetAllFit, denoptim.gui.GUIInspectGARun.datasetPopMax, denoptim.gui.GUIInspectGARun.datasetPopMean, denoptim.gui.GUIInspectGARun.datasetPopMedian, denoptim.gui.GUIInspectGARun.datasetPopMin, denoptim.gui.GUIInspectGARun.datasetSelected, denoptim.gui.GUIInspectGARun.evoChart, denoptim.gui.GUIInspectGARun.evoChartPanel, denoptim.gui.GUIInspectGARun.evoPlot, denoptim.gui.GUIInspectGARun.evoSeriesCheckList, denoptim.graph.CandidateLW.getFitness(), denoptim.graph.CandidateLW.getGeneration(), denoptim.gui.GUIInspectGARun.getOverlappingItems(), denoptim.utils.GeneralUtils.getPaddedString(), denoptim.graph.CandidateLW.hasFitness(), denoptim.gui.GUIInspectGARun.lblTotItems, denoptim.gui.GUICardPanel.mainPanel, denoptim.gui.GUIInspectGARun.molsWithFitness, denoptim.gui.GUIInspectGARun.readOneGeneration(), denoptim.gui.GUIInspectGARun.renderViewWithoutSelectedItems(), denoptim.gui.GUIInspectGARun.renderViewWithSelectedItem(), denoptim.gui.GUIInspectGARun.rightUpPanel, denoptim.gui.GUIPreferences.showLegenInEvolutionPlot, and denoptim.gui.GUIInspectGARun.srcFolder.

Referenced by denoptim.gui.HomePanel.initialize(), and denoptim.gui.MainToolBar.openFile().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ initialize()

void denoptim.gui.GUIInspectGARun.initialize ( )
private

Initialize the panel and add buttons.

Definition at line 266 of file GUIInspectGARun.java.

References denoptim.gui.ButtonsBar.add(), denoptim.gui.GUIMainPanel.add(), denoptim.gui.GUIInspectGARun.candsPerGeneration, denoptim.gui.GUIInspectGARun.centralPanel, denoptim.gui.GUIInspectGARun.ctrlPanel, denoptim.gui.GUIInspectGARun.ctrlPanelRow1, denoptim.gui.GUIInspectGARun.ctrlPanelRow1Left, denoptim.gui.GUIInspectGARun.ctrlPanelRow1Right, denoptim.gui.GUIInspectGARun.ctrlPanelRow2Left, denoptim.gui.GUIInspectGARun.evoPlot, denoptim.gui.GUIInspectGARun.evoSeriesBtn, denoptim.gui.GUIInspectGARun.evoSeriesCheckList, denoptim.constants.DENOPTIMConstants.FITFILENAMEEXTOUT, denoptim.gui.ScrollableJPupupMenu.getAllBChekBoxes(), denoptim.gui.Utils.getTempFile(), denoptim.gui.GUIGraphHandler.importGraphsFromFile(), denoptim.gui.GUIInspectGARun.lblTotItems, denoptim.gui.GUICardPanel.mainPanel, denoptim.files.FileUtils.mergeIntoOneFile(), denoptim.gui.GUIInspectGARun.molViewer, denoptim.gui.GUIInspectGARun.monitorPlot, denoptim.gui.GUIInspectGARun.monitorSeriesBtn, denoptim.gui.GUIInspectGARun.monitorSeriesCheckList, denoptim.gui.GUIInspectGARun.nameFirstMonitorSeries, denoptim.gui.GUIInspectGARun.openFinalPopGraphs, denoptim.gui.GUIInspectGARun.openGeneratinGraphs, denoptim.gui.GUIInspectGARun.openSingleGraph, denoptim.gui.GUIInspectGARun.pathToSelectedItem, denoptim.gui.GUIInspectGARun.rightDownPanel, denoptim.gui.GUIInspectGARun.rightPanel, denoptim.gui.GUIInspectGARun.rightUpPanel, denoptim.gui.GUIModalDialog.showDialog(), denoptim.gui.ScrollableJPupupMenu.showMenu(), and denoptim.gui.GUIInspectGARun.srcFolder.

Referenced by denoptim.gui.GUIInspectGARun.GUIInspectGARun().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ readOneGeneration()

void denoptim.gui.GUIInspectGARun.readOneGeneration ( File  genFolder,
String  summaryName,
int  genId,
Component  parent,
Map< Integer, double[]>  popProperties 
)
private

◆ renderViewWithoutSelectedItems()

void denoptim.gui.GUIInspectGARun.renderViewWithoutSelectedItems ( )
private

Definition at line 1558 of file GUIInspectGARun.java.

References denoptim.gui.MoleculeViewPanel.clearAll(), denoptim.gui.GUIInspectGARun.datasetSelected, denoptim.gui.GUIInspectGARun.molViewer, and denoptim.gui.GUIInspectGARun.openSingleGraph.

Referenced by denoptim.gui.GUIInspectGARun.importGARunData().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ renderViewWithSelectedItem()

void denoptim.gui.GUIInspectGARun.renderViewWithSelectedItem ( CandidateLW  item)
private

Definition at line 1531 of file GUIInspectGARun.java.

References denoptim.gui.GUIInspectGARun.datasetSelected, denoptim.gui.GUIInspectGARun.evoPlot, denoptim.graph.CandidateLW.getFitness(), denoptim.graph.CandidateLW.getGeneration(), denoptim.graph.CandidateLW.getPathToFile(), denoptim.gui.MoleculeViewPanel.loadChemicalStructureFromFile(), denoptim.gui.GUICardPanel.mainPanel, denoptim.gui.GUIInspectGARun.molViewer, denoptim.gui.GUIInspectGARun.openSingleGraph, and denoptim.gui.GUIInspectGARun.pathToSelectedItem.

Referenced by denoptim.gui.GUIInspectGARun.importGARunData().

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ allIndividuals

ArrayList<CandidateLW> denoptim.gui.GUIInspectGARun.allIndividuals
private

◆ candsPerGeneration

Map<Integer,List<String> > denoptim.gui.GUIInspectGARun.candsPerGeneration
private

Pathways of population members collected by generation id.

This info is taken from the generation summary files, so in absence of such file for a generation, that generation will not be present here.

Definition at line 194 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.importGARunData(), denoptim.gui.GUIInspectGARun.initialize(), and denoptim.gui.GUIInspectGARun.readOneGeneration().

◆ candsWithFitnessMap

Map<Integer,CandidateLW> denoptim.gui.GUIInspectGARun.candsWithFitnessMap
private

Definition at line 130 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.importGARunData().

◆ centralPanel

JSplitPane denoptim.gui.GUIInspectGARun.centralPanel
private

Definition at line 118 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.initialize().

◆ colors

final Color [] denoptim.gui.GUIInspectGARun.colors
private
Initial value:
= new Color[] {Color.black,
Color.decode("#354ccd"),
Color.decode("#1e9222"),
Color.decode("#9eca2f"),
Color.decode("#28cbad"),
Color.decode("#dea0c8"),
Color.decode("#dd6835"),
Color.decode("#b70505"),
Color.decode("#a42ac4")}

Predefined list of data series colors.

Definition at line 199 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.buildAndFillMonitorPlot().

◆ ctrlPanel

JPanel denoptim.gui.GUIInspectGARun.ctrlPanel
private

Definition at line 113 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.initialize().

◆ ctrlPanelRow1

JPanel denoptim.gui.GUIInspectGARun.ctrlPanelRow1
private

Definition at line 114 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.initialize().

◆ ctrlPanelRow1Left

JPanel denoptim.gui.GUIInspectGARun.ctrlPanelRow1Left
private

Definition at line 115 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.initialize().

◆ ctrlPanelRow1Right

JPanel denoptim.gui.GUIInspectGARun.ctrlPanelRow1Right
private

Definition at line 116 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.initialize().

◆ ctrlPanelRow2Left

JPanel denoptim.gui.GUIInspectGARun.ctrlPanelRow2Left
private

Definition at line 117 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.initialize().

◆ datasetAllFit

DefaultXYDataset denoptim.gui.GUIInspectGARun.datasetAllFit = new DefaultXYDataset()
private

Definition at line 138 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.importGARunData().

◆ datasetPopMax

DefaultXYDataset denoptim.gui.GUIInspectGARun.datasetPopMax = new DefaultXYDataset()
private

Definition at line 141 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.importGARunData().

◆ datasetPopMean

DefaultXYDataset denoptim.gui.GUIInspectGARun.datasetPopMean = new DefaultXYDataset()
private

Definition at line 142 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.importGARunData().

◆ datasetPopMedian

DefaultXYDataset denoptim.gui.GUIInspectGARun.datasetPopMedian = new DefaultXYDataset()
private

Definition at line 143 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.importGARunData().

◆ datasetPopMin

DefaultXYDataset denoptim.gui.GUIInspectGARun.datasetPopMin = new DefaultXYDataset()
private

Definition at line 140 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.importGARunData().

◆ datasetSelected

DefaultXYDataset denoptim.gui.GUIInspectGARun.datasetSelected = new DefaultXYDataset()
private

◆ evoChart

JFreeChart denoptim.gui.GUIInspectGARun.evoChart
private

Definition at line 145 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.importGARunData().

◆ evoChartPanel

ChartPanel denoptim.gui.GUIInspectGARun.evoChartPanel
private

Definition at line 146 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.importGARunData().

◆ evolInspectorTabUID

AtomicInteger denoptim.gui.GUIInspectGARun.evolInspectorTabUID = new AtomicInteger(1)
static

Unique identified for instances of this handler.

Definition at line 111 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.GUIInspectGARun().

◆ evoPlot

◆ evoSeriesBtn

JButton denoptim.gui.GUIInspectGARun.evoSeriesBtn
private

Definition at line 149 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.initialize().

◆ evoSeriesCheckList

JPopupMenu denoptim.gui.GUIInspectGARun.evoSeriesCheckList
private

◆ lblTotItems

JLabel denoptim.gui.GUIInspectGARun.lblTotItems
private

◆ molsWithFitness

int denoptim.gui.GUIInspectGARun.molsWithFitness = 0
private

◆ molViewer

◆ monitorChart

JFreeChart denoptim.gui.GUIInspectGARun.monitorChart
private

◆ monitorChartPanel

ChartPanel denoptim.gui.GUIInspectGARun.monitorChartPanel
private

◆ monitorDatasets

Map<CounterID,DefaultXYDataset> denoptim.gui.GUIInspectGARun.monitorDatasets
private
Initial value:
=
new HashMap<CounterID,DefaultXYDataset>()

Definition at line 151 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.buildAndFillMonitorPlot().

◆ monitorPlot

XYPlot denoptim.gui.GUIInspectGARun.monitorPlot
private

◆ monitorSeriesBtn

JButton denoptim.gui.GUIInspectGARun.monitorSeriesBtn
private

Definition at line 159 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.initialize().

◆ monitorSeriesCheckList

ScrollableJPupupMenu denoptim.gui.GUIInspectGARun.monitorSeriesCheckList
private

◆ nameFirstMonitorSeries

String denoptim.gui.GUIInspectGARun.nameFirstMonitorSeries = "unset"
private

Records the name of the first series in the monitor plot to facilitate its recovery upon chart reset.

Definition at line 246 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.buildAndFillMonitorPlot(), and denoptim.gui.GUIInspectGARun.initialize().

◆ NL

final String denoptim.gui.GUIInspectGARun.NL = System.getProperty("line.separator")
private

◆ openFinalPopGraphs

JButton denoptim.gui.GUIInspectGARun.openFinalPopGraphs
private

Button offering the possibility to load the graphs of the final population.

Definition at line 187 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.initialize(), and denoptim.gui.GUIInspectGARun.readOneGeneration().

◆ openGeneratinGraphs

JButton denoptim.gui.GUIInspectGARun.openGeneratinGraphs
private

Button offering the possibility to load the graphs of the population at a given time (i.e., generation).

Definition at line 181 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.initialize().

◆ openSingleGraph

JButton denoptim.gui.GUIInspectGARun.openSingleGraph
private

Button offering the possibility to load the graph inspector for a selected item.

Definition at line 168 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.initialize(), denoptim.gui.GUIInspectGARun.renderViewWithoutSelectedItems(), and denoptim.gui.GUIInspectGARun.renderViewWithSelectedItem().

◆ pathToSelectedItem

String denoptim.gui.GUIInspectGARun.pathToSelectedItem
private

Storage of pathname to the item selected in the chart.

This is used to enable loading the graph inspector at any time after selection of the item in the chart.

Definition at line 175 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.initialize(), and denoptim.gui.GUIInspectGARun.renderViewWithSelectedItem().

◆ rightDownPanel

JPanel denoptim.gui.GUIInspectGARun.rightDownPanel
private

◆ rightPanel

JSplitPane denoptim.gui.GUIInspectGARun.rightPanel
private

Definition at line 119 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.initialize().

◆ rightUpPanel

JPanel denoptim.gui.GUIInspectGARun.rightUpPanel
private

◆ serialVersionUID

final long denoptim.gui.GUIInspectGARun.serialVersionUID = -8303012362366503382L
staticprivate

Version UID.

Definition at line 106 of file GUIInspectGARun.java.

◆ srcFolder

File denoptim.gui.GUIInspectGARun.srcFolder
private

◆ strokes

final BasicStroke [] denoptim.gui.GUIInspectGARun.strokes
private
Initial value:
= {
new BasicStroke(1.0f, BasicStroke.CAP_ROUND, BasicStroke.JOIN_ROUND,
0.0f),
new BasicStroke(
1.0f, BasicStroke.CAP_ROUND, BasicStroke.JOIN_ROUND,
1.0f, new float[] {2f, 2f}, 0.0f),
new BasicStroke(
1.0f, BasicStroke.CAP_ROUND, BasicStroke.JOIN_ROUND,
1.0f, new float[] {5f, 2f}, 0.0f),
new BasicStroke(
1.0f, BasicStroke.CAP_ROUND, BasicStroke.JOIN_ROUND,
1.0f, new float[] {2f, 2f, 5f, 2f}, 0.0f),
new BasicStroke(
1.0f, BasicStroke.CAP_ROUND, BasicStroke.JOIN_ROUND,
1.0f, new float[] {2f, 2f, 2f, 2f, 5f, 2f}, 0.0f),
new BasicStroke(
1.0f, BasicStroke.CAP_ROUND, BasicStroke.JOIN_ROUND,
1.0f, new float[] {2f, 2f, 2f, 2f, 2f, 2f, 5f, 2f}, 0.0f),
new BasicStroke(
1.0f, BasicStroke.CAP_ROUND, BasicStroke.JOIN_ROUND,
1.0f, new float[] {2f, 2f, 5f, 2f, 5f, 2f}, 0.0f),
new BasicStroke(
1.0f, BasicStroke.CAP_ROUND, BasicStroke.JOIN_ROUND,
1.0f, new float[] {2f, 2f, 2f, 2f, 5f, 2f, 5f, 2f}, 0.0f),
new BasicStroke(
1.0f, BasicStroke.CAP_ROUND, BasicStroke.JOIN_ROUND,
1.0f, new float[] {2f, 2f, 2f, 2f, 2f, 2f,
5f, 2f, 5f, 2f, 5f, 2f}, 0.0f),
}

Predefined line strokes.

Definition at line 212 of file GUIInspectGARun.java.

Referenced by denoptim.gui.GUIInspectGARun.buildAndFillMonitorPlot().

◆ warnedAboutMissingCandFiles

boolean denoptim.gui.GUIInspectGARun.warnedAboutMissingCandFiles = false
private

The documentation for this class was generated from the following file: