Changeset 7701 for trunk/MagicSoft


Ignore:
Timestamp:
05/05/06 14:02:25 (19 years ago)
Author:
tbretz
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/Changelog

    r7700 r7701  
    7676     - implemented usage of weights
    7777
     78   * mjtrain/MJTrainSeparation.[h,cc]:
     79     - implemented the usage of weights
     80     - implemented a random source position to train with wobble
     81       data
     82     - added some more output
     83     - added an option to switch between classification and regression
     84     - added th epossibility to change the MC flux
     85
    7886
    7987
  • trunk/MagicSoft/Mars/mjtrain/MJTrainSeparation.h

    r7671 r7701  
    2424    UInt_t fNumTestOff;
    2525
     26    TList fPreTasksOn;
     27    TList fPreTasksOff;
     28    TList fPostTasksOn;
     29    TList fPostTasksOff;
     30
    2631    Bool_t fAutoTrain;
    2732    Bool_t fUseRegression;
     33    Bool_t fEnableWeightsOn;
     34    Bool_t fEnableWeightsOff;
     35
     36    Float_t fFlux;
    2837
    2938    void DisplayResult(MH3 &h31, MH3 &h32);
     
    3847        fNumTrainOn((UInt_t)-1), fNumTrainOff((UInt_t)-1),
    3948        fNumTestOn((UInt_t)-1), fNumTestOff((UInt_t)-1),
    40         fAutoTrain(kFALSE), fUseRegression(kTRUE)
     49        fAutoTrain(kFALSE), fUseRegression(kFALSE),
     50        fEnableWeightsOn(kFALSE), fEnableWeightsOff(kFALSE), fFlux(2e-7)
    4151    { }
    4252
     
    6070    }
    6171
     72    void AddPreTaskOn(MTask *t)                     { Add(fPreTasksOn,  t); }
     73    void AddPreTaskOn(const char *rule,
     74                      const char *name="MWeight")   { AddPar(fPreTasksOn, rule, name); }
     75
     76    void AddPreTaskOff(MTask *t)                    { Add(fPreTasksOff, t); }
     77    void AddPreTaskOff(const char *rule,
     78                       const char *name="MWeight")  { AddPar(fPreTasksOff, rule, name); }
     79
     80    void AddPostTaskOn(MTask *t)                    { Add(fPostTasksOn,  t); }
     81    void AddPostTaskOn(const char *rule,
     82                       const char *name="MWeight")  { AddPar(fPostTasksOn, rule, name); }
     83
     84    void AddPostTaskOff(MTask *t)                   { Add(fPostTasksOff, t); }
     85    void AddPostTaskOff(const char *rule,
     86                        const char *name="MWeight") { AddPar(fPostTasksOff, rule, name); }
     87
     88    void SetWeightsOn(const char *rule)  { if (fEnableWeightsOn) return;  fEnableWeightsOn=kTRUE;  AddPostTaskOn(rule); }
     89    void SetWeightsOn(MTask *t)          { if (fEnableWeightsOn) return;  fEnableWeightsOn=kTRUE;  AddPostTaskOn(t);    }
     90
     91    void SetWeightsOff(const char *rule) { if (fEnableWeightsOff) return; fEnableWeightsOff=kTRUE; AddPostTaskOff(rule); }
     92    void SetWeightsOff(MTask *t)         { if (fEnableWeightsOff) return; fEnableWeightsOff=kTRUE; AddPostTaskOff(t);    }
     93
     94    void SetFlux(Float_t f) { fFlux = f; }
     95
    6296    void EnableAutoTrain(Bool_t b=kTRUE)      { fAutoTrain     =  b; }
    6397    void EnableRegression(Bool_t b=kTRUE)     { fUseRegression =  b; }
Note: See TracChangeset for help on using the changeset viewer.