Add version number to Network
Remove uneeded console output
This commit is contained in:
parent
71b88e2c65
commit
c22eba3d5c
@ -226,6 +226,7 @@ int main(int argc, char** argv)
|
|||||||
//showCPDS(network);
|
//showCPDS(network);
|
||||||
cout << "Score: " << network.score(Xd, y) << endl;
|
cout << "Score: " << network.score(Xd, y) << endl;
|
||||||
cout << "PyTorch version: " << TORCH_VERSION << endl;
|
cout << "PyTorch version: " << TORCH_VERSION << endl;
|
||||||
|
cout << "BayesNet version: " << network.version() << endl;
|
||||||
unsigned int nthreads = std::thread::hardware_concurrency();
|
unsigned int nthreads = std::thread::hardware_concurrency();
|
||||||
cout << "Computer has " << nthreads << " cores." << endl;
|
cout << "Computer has " << nthreads << " cores." << endl;
|
||||||
return 0;
|
return 0;
|
||||||
|
@ -100,7 +100,6 @@ namespace bayesnet {
|
|||||||
if (maxThreadsRunning < 1) {
|
if (maxThreadsRunning < 1) {
|
||||||
maxThreadsRunning = 1;
|
maxThreadsRunning = 1;
|
||||||
}
|
}
|
||||||
cout << "Using " << maxThreadsRunning << " threads" << " maxThreads: " << maxThreads << endl;
|
|
||||||
vector<thread> threads;
|
vector<thread> threads;
|
||||||
mutex mtx;
|
mutex mtx;
|
||||||
condition_variable cv;
|
condition_variable cv;
|
||||||
|
@ -36,6 +36,7 @@ namespace bayesnet {
|
|||||||
vector<int> predict(const vector<vector<int>>&);
|
vector<int> predict(const vector<vector<int>>&);
|
||||||
vector<pair<int, double>> predict_proba(const vector<vector<int>>&);
|
vector<pair<int, double>> predict_proba(const vector<vector<int>>&);
|
||||||
double score(const vector<vector<int>>&, const vector<int>&);
|
double score(const vector<vector<int>>&, const vector<int>&);
|
||||||
|
inline string version() { return "0.1.0"; }
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
Loading…
Reference in New Issue
Block a user