📄 snow.h
字号:
// -*-c++-*-//===========================================================//= University of Illinois at Urbana-Champaign =//= Department of Computer Science =//= Dr. Dan Roth - Cognitive Computation Group =//= =//= Project: SNoW =//= =//= Module: Snow.cpp =//= Version: 3.1.4 =//= Authors: Jeff Rosen, Andrew Carlson, Nick Rizzolo =//= Date: xx/xx/99 = //= =//= Comments: =//===========================================================#ifndef SNOW_H#define SNOW_H#include "GlobalParams.h"#include "SnowParam.h"#include "Cloud.h"#include "Network.h"// #ifdef SERVER_MODE_// #include "SendReceive.h"// #endif#include <stdlib.h>#ifndef WIN32#include <unistd.h>#endif#include <errno.h>#include <stdio.h>#include <ctype.h>#include <string.h>#ifndef WIN32#include <strings.h>#endif#include <algorithm>#include <iostream>#include <fstream>//#include <strstream>#include <iomanip>#ifndef WIN32extern "C"{ extern int getopt(int, char* const*, const char*); extern char * optarg;}#endifclass Snow {public: Snow( GlobalParams & gp_ ); ~Snow(); void Train(); void Test(); void Interactive(); void BasicTest( Network& network ); void Output( TargetRanking &rank, ofstream* errorStream, Example &ex, int &correct, int &suppressed, int examples, int not_labeled ); void FinalOutput( ostream& out, int correct, int suppressed, int examples, int not_labeled ); bool Predict( TargetRanking& rank ); FeatureID Evaluate(); void EvaluateExample(Example & example, TargetRanking & rank); void EvaluateExample(istream * testStream, int & correct, int & suppressed, int & examples, int not_labeled, ofstream * errorStream ); void presentTrainExample(Example * example = 0, ofstream * outputConjunctionStream = 0); void Pause(); void WriteAlgorithms(ostream * out); static const char * logo[]; Network * network; GlobalParams globalParams; TargetRanking * holdRank; bool DEBUG_ME;private: int mistakes;};#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -