root/tests/loggers_test.cpp @ 147

Revision 89, 0.5 kB (checked in by smidl, 17 years ago)

logger test

  • Property svn:eol-style set to native
Line 
1#include <itpp/itbase.h>
2#include <stat/loggers.h>
3
4using namespace itpp;
5
6//These lines are needed for use of cout and endl
7using std::cout;
8using std::endl;
9
10int main()
11{
12        int i;
13       
14        RV th = RV ( "1 2","{a b }","1 1","0 0");
15        RV r = RV ( "2","{r }","2","0" );
16
17        dirfilelog L("exp/dirfile",10);
18       
19        int rid;
20        int thid;
21       
22        rid=L.add(r,"");
23        thid=L.add(th,"th");
24       
25        L.init();
26
27        for (i=0; i<150; i++){ 
28                L.logit(rid,vec_2((double)i,(double)(i+1)));
29                L.logit(thid,vec_2((double)(100-i),(double)(i-50)));
30                L.step();
31        }
32        L.step(true);
33}
Note: See TracBrowser for help on using the browser.