Main Page | Namespace List | Data Structures | File List | Data Fields | Globals

learningThread.cpp

Go to the documentation of this file.
00001 # include <learningThread.h>
00002 
00003 void LearningThread::run() {
00004         network->learning(filename, errorThreshold, maxNbEpoch, convergenceCoeff);
00005 }
00006 
00007 void LearningThread::init(QString f, double eT, int maxNE, double convCoeff) {
00008         filename = f;
00009         errorThreshold= eT;
00010         maxNbEpoch = maxNE;
00011         convergenceCoeff = convCoeff;   
00012 }
00013 
00014 int LearningThread::getState() {
00015         return state;
00016 }
00017 
00018 void LearningThread::setState(int s) {
00019         state = s;
00020 }
00021 
00022 void LearningThread::uwait(unsigned long t) {
00023         while (state == PAUSE) { 
00024                 QThread::usleep(t); 
00025         }
00026         if (state == STEP) QThread::usleep(100000);
00027         else QThread::usleep(t);
00028 }
00029 
00030 void LearningThread::nextStep() {
00031         state = STEP;
00032 }

Generated on Fri Dec 3 14:57:50 2004 for INN by doxygen 1.3.6