- added tool tips

git-svn-id: http://moon:8086/svn/software/trunk/projects/Rbm@666 b431acfa-c32f-4a4a-93f1-934dc6c82436
This commit is contained in:
2019-11-13 19:08:22 +00:00
parent fecf93a012
commit 690b992e3d
+30 -3
View File
@@ -49,26 +49,29 @@ MainComponent::MainComponent (const String prjname)
, m_file(prjname)
{
addAndMakeVisible (trainButton = new TextButton ("Train button"));
trainButton->setTooltip (TRANS("Start/Stop training"));
trainButton->setButtonText (TRANS("Train"));
trainButton->addListener (this);
addAndMakeVisible (addButton = new TextButton ("Add button"));
addButton->setTooltip (TRANS("Add training pattern"));
addButton->setButtonText (TRANS("Add"));
addButton->addListener (this);
addAndMakeVisible (patterSlider = new Slider ("Pattern slider"));
patterSlider->setTooltip (TRANS("Training index"));
patterSlider->setTooltip (TRANS("Browse training patterns"));
patterSlider->setRange (0, 0, 1);
patterSlider->setSliderStyle (Slider::LinearBar);
patterSlider->setTextBoxStyle (Slider::TextBoxLeft, false, 80, 20);
patterSlider->addListener (this);
addAndMakeVisible (ShakeButton = new TextButton ("Shake button"));
ShakeButton->setTooltip (TRANS("Shake weights"));
ShakeButton->setButtonText (TRANS("Shake"));
ShakeButton->addListener (this);
addAndMakeVisible (WeightsSlider = new Slider ("Weights slider"));
WeightsSlider->setTooltip (TRANS("Weight index"));
WeightsSlider->setTooltip (TRANS("Browse weights"));
WeightsSlider->setRange (0, 0, 1);
WeightsSlider->setSliderStyle (Slider::LinearBar);
WeightsSlider->setTextBoxStyle (Slider::TextBoxLeft, false, 80, 20);
@@ -76,6 +79,7 @@ MainComponent::MainComponent (const String prjname)
addAndMakeVisible (numEpochslabel = new Label ("Num Epochs label",
TRANS("1000")));
numEpochslabel->setTooltip (TRANS("Number of epochs to run on a mini batch"));
numEpochslabel->setFont (Font (15.00f, Font::plain));
numEpochslabel->setJustificationType (Justification::centred);
numEpochslabel->setEditable (true, true, false);
@@ -85,6 +89,7 @@ MainComponent::MainComponent (const String prjname)
addAndMakeVisible (learningRateLabel = new Label ("Learning Rate label",
TRANS("0.01")));
learningRateLabel->setTooltip (TRANS("Learning rate for updating of weights and biases"));
learningRateLabel->setFont (Font (15.00f, Font::plain));
learningRateLabel->setJustificationType (Justification::centred);
learningRateLabel->setEditable (true, true, false);
@@ -124,6 +129,7 @@ MainComponent::MainComponent (const String prjname)
addAndMakeVisible (projectNameLabel = new Label ("Project Name label",
m_file.getFileNameWithoutExtension()));
projectNameLabel->setTooltip (TRANS("Name of project"));
projectNameLabel->setFont (Font (15.00f, Font::plain));
projectNameLabel->setJustificationType (Justification::centred);
projectNameLabel->setEditable (true, true, false);
@@ -132,10 +138,12 @@ MainComponent::MainComponent (const String prjname)
projectNameLabel->addListener (this);
addAndMakeVisible (loadButton = new TextButton ("Load button"));
loadButton->setTooltip (TRANS("Load project from disk"));
loadButton->setButtonText (TRANS("Load"));
loadButton->addListener (this);
addAndMakeVisible (saveButton = new TextButton ("Save button"));
saveButton->setTooltip (TRANS("Save project to disk"));
saveButton->setButtonText (TRANS("Save"));
saveButton->addListener (this);
@@ -150,18 +158,22 @@ MainComponent::MainComponent (const String prjname)
numVisibleYLabel->addListener (this);
addAndMakeVisible (loadTrainingButton = new TextButton ("Load Training button"));
loadTrainingButton->setTooltip (TRANS("Load training patterns from disk"));
loadTrainingButton->setButtonText (TRANS("Load T"));
loadTrainingButton->addListener (this);
addAndMakeVisible (saveTrainingButton = new TextButton ("Save Training button"));
saveTrainingButton->setButtonText (TRANS("Save T"));
saveTrainingButton->setTooltip (TRANS("Save training patterns to disk"));
saveTrainingButton->setButtonText (TRANS("Save T"));
saveTrainingButton->addListener (this);
addAndMakeVisible (clearTrainingButton = new TextButton ("Clear Training button"));
clearTrainingButton->setTooltip (TRANS("Clear all training patterns"));
clearTrainingButton->setButtonText (TRANS("Clear T"));
clearTrainingButton->addListener (this);
addAndMakeVisible (removeTrainingButton = new TextButton ("Remove Training button"));
removeTrainingButton->setTooltip (TRANS("Remove current training pattern"));
removeTrainingButton->setButtonText (TRANS("Remove T"));
removeTrainingButton->addListener (this);
@@ -184,6 +196,7 @@ MainComponent::MainComponent (const String prjname)
addAndMakeVisible (lambdaLabel = new Label ("Lambda label",
TRANS("1.0")));
lambdaLabel->setTooltip (TRANS("Unused"));
lambdaLabel->setFont (Font (15.00f, Font::plain));
lambdaLabel->setJustificationType (Justification::centred);
lambdaLabel->setEditable (true, true, false);
@@ -193,6 +206,7 @@ MainComponent::MainComponent (const String prjname)
addAndMakeVisible (sigmaLabel = new Label ("Sigma label",
TRANS("1.0")));
sigmaLabel->setTooltip (TRANS("Unused"));
sigmaLabel->setFont (Font (15.00f, Font::plain));
sigmaLabel->setJustificationType (Justification::centred);
sigmaLabel->setEditable (true, true, false);
@@ -201,15 +215,18 @@ MainComponent::MainComponent (const String prjname)
sigmaLabel->addListener (this);
addAndMakeVisible (rbmUseVisibleGaussianToggleButton = new ToggleButton ("rbmUseVisibleGaussian toggle button"));
rbmUseVisibleGaussianToggleButton->setTooltip (TRANS("Unused"));
rbmUseVisibleGaussianToggleButton->setButtonText (TRANS("Use gaussian visible"));
rbmUseVisibleGaussianToggleButton->addListener (this);
addAndMakeVisible (rbmDoSparseToggleButton = new ToggleButton ("rbmDoSparse toggle button"));
rbmDoSparseToggleButton->setTooltip (TRANS("Unused"));
rbmDoSparseToggleButton->setButtonText (TRANS("Do sparse"));
rbmDoSparseToggleButton->addListener (this);
addAndMakeVisible (sparsityLabel = new Label ("Sparsity label",
TRANS("0.05")));
sparsityLabel->setTooltip (TRANS("Unused"));
sparsityLabel->setFont (Font (15.00f, Font::plain));
sparsityLabel->setJustificationType (Justification::centred);
sparsityLabel->setEditable (true, true, false);
@@ -219,6 +236,7 @@ MainComponent::MainComponent (const String prjname)
addAndMakeVisible (sigmaDecayLabel = new Label ("SigmaDecay label",
TRANS("1.0")));
sigmaDecayLabel->setTooltip (TRANS("Unused"));
sigmaDecayLabel->setFont (Font (15.00f, Font::plain));
sigmaDecayLabel->setJustificationType (Justification::centred);
sigmaDecayLabel->setEditable (true, true, false);
@@ -228,6 +246,7 @@ MainComponent::MainComponent (const String prjname)
addAndMakeVisible (weightDecayLabel = new Label ("WeightDecay label",
TRANS("0")));
weightDecayLabel->setTooltip (TRANS("Penalize large weights during training"));
weightDecayLabel->setFont (Font (15.00f, Font::plain));
weightDecayLabel->setJustificationType (Justification::centred);
weightDecayLabel->setEditable (true, true, false);
@@ -244,6 +263,7 @@ MainComponent::MainComponent (const String prjname)
addAndMakeVisible (momentumLabel = new Label ("Momentum label",
TRANS("0.5")));
momentumLabel->setTooltip (TRANS("Momentum during training"));
momentumLabel->setFont (Font (15.00f, Font::plain));
momentumLabel->setJustificationType (Justification::centred);
momentumLabel->setEditable (true, true, false);
@@ -253,6 +273,7 @@ MainComponent::MainComponent (const String prjname)
addAndMakeVisible (sparsityLearningRateLabel = new Label ("SparsityLearn label",
TRANS("0.01")));
sparsityLearningRateLabel->setTooltip (TRANS("Ununsed"));
sparsityLearningRateLabel->setFont (Font (15.00f, Font::plain));
sparsityLearningRateLabel->setJustificationType (Justification::centred);
sparsityLearningRateLabel->setEditable (true, true, false);
@@ -262,6 +283,7 @@ MainComponent::MainComponent (const String prjname)
addAndMakeVisible (weightInitLabel = new Label ("WeightInit label",
TRANS("0.01")));
weightInitLabel->setTooltip (TRANS("Std. deviation for weight shaking"));
weightInitLabel->setFont (Font (15.00f, Font::plain));
weightInitLabel->setJustificationType (Justification::centred);
weightInitLabel->setEditable (true, true, false);
@@ -270,14 +292,17 @@ MainComponent::MainComponent (const String prjname)
weightInitLabel->addListener (this);
addAndMakeVisible (rbmLearnVarianceButton = new ToggleButton ("rbmLearnVariance button"));
rbmLearnVarianceButton->setTooltip (TRANS("Unused"));
rbmLearnVarianceButton->setButtonText (TRANS("Learn Variance"));
rbmLearnVarianceButton->addListener (this);
addAndMakeVisible (rbmNormalizeDataToggleButton = new ToggleButton ("rbmNormalizeData toggle button"));
rbmNormalizeDataToggleButton->setTooltip (TRANS("Remove mean from training data and normalize to variance=1"));
rbmNormalizeDataToggleButton->setButtonText (TRANS("Normalize data"));
rbmNormalizeDataToggleButton->addListener (this);
addAndMakeVisible (m_rbmSelect = new ComboBox ("RBM Selector"));
m_rbmSelect->setTooltip (TRANS("Select RBM from stack"));
m_rbmSelect->setEditableText (false);
m_rbmSelect->setJustificationType (Justification::centredLeft);
m_rbmSelect->setTextWhenNothingSelected (String::empty);
@@ -285,6 +310,7 @@ MainComponent::MainComponent (const String prjname)
m_rbmSelect->addListener (this);
addAndMakeVisible (rbmDoSampleBatch = new ToggleButton ("rbmDoSampleBatch button"));
rbmDoSampleBatch->setTooltip (TRANS("Do stochastic sampling from training data"));
rbmDoSampleBatch->setTooltip (TRANS("Sample training data during learning\n"));
rbmDoSampleBatch->setButtonText (TRANS("Sample training"));
rbmDoSampleBatch->addListener (this);
@@ -300,6 +326,7 @@ MainComponent::MainComponent (const String prjname)
sizeMiniBatch->addListener (this);
addAndMakeVisible (rbmUseHiddenGaussianToggleButton = new ToggleButton ("rbmUseHiddenGaussian toggle button"));
rbmUseHiddenGaussianToggleButton->setTooltip (TRANS("Unused"));
rbmUseHiddenGaussianToggleButton->setButtonText (TRANS("Use gaussian hidden"));
rbmUseHiddenGaussianToggleButton->addListener (this);