[RBM]
- pulled LayerArray out of RbmComponent git-svn-id: http://moon:8086/svn/software/trunk/projects/RBM@293 b431acfa-c32f-4a4a-93f1-934dc6c82436
This commit is contained in:
+23
-1
@@ -39,6 +39,7 @@
|
||||
*/
|
||||
class MainComponent : public Component,
|
||||
public RbmComponentListener,
|
||||
public LayerArrayListener,
|
||||
public Thread,
|
||||
public ButtonListener,
|
||||
public SliderListener,
|
||||
@@ -51,7 +52,7 @@ public:
|
||||
|
||||
//==============================================================================
|
||||
//[UserMethods] -- You can add your own custom methods in this section.
|
||||
void onLayerSizeChanged(size_t size) override;
|
||||
void onChanged(const LayerArray &obj) override;
|
||||
void onRbmEpochTrained(size_t progressPercent) override;
|
||||
//[/UserMethods]
|
||||
|
||||
@@ -75,6 +76,7 @@ private:
|
||||
//[UserVariables] -- You can add your own custom variables in this section.
|
||||
ScopedPointer<Weights> m_weights;
|
||||
ScopedPointer<RbmComponent> m_pRbmComponent;
|
||||
LayerArray m_layers;
|
||||
void load();
|
||||
void save();
|
||||
void create(juce::String const &projectName="");
|
||||
@@ -82,6 +84,26 @@ private:
|
||||
const juce::String& getBaseDir();
|
||||
void run();
|
||||
String m_baseDir;
|
||||
void clearTraining()
|
||||
{
|
||||
m_layers.clear();
|
||||
}
|
||||
|
||||
void loadTraining(const char *pFilename)
|
||||
{
|
||||
m_layers.clear();
|
||||
m_layers.load(pFilename);
|
||||
}
|
||||
|
||||
void saveTraining(const char *pFilename)
|
||||
{
|
||||
m_layers.save(pFilename);
|
||||
}
|
||||
|
||||
void removeTrainingAt(size_t index)
|
||||
{
|
||||
m_layers.removeAt(index);
|
||||
}
|
||||
//[/UserVariables]
|
||||
|
||||
//==============================================================================
|
||||
|
||||
Reference in New Issue
Block a user