Ignore:
Timestamp:
05/04/16 11:55:23 (9 years ago)
Author:
sherbold
Message:
  • fixed some minor problems found by FindBugs?
Location:
trunk/CrossPare/src/de/ugoe/cs/cpdp/training
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/CrossPare/src/de/ugoe/cs/cpdp/training/WekaLASERTraining.java

    r64 r74  
    110110                    boolean allEqual = true; 
    111111                    for( Integer index : closestToTrainingInstance ) { 
    112                         if( label == Double.NaN ) { 
     112                        if( Double.isNaN(label) ) { 
    113113                            label = traindata.get(closestToTrainingInstance.get(index)).classValue(); 
    114114                        } 
     
    129129                boolean allEqual = true; 
    130130                for( Integer index : closestInstances ) { 
    131                     if( label == Double.NaN ) { 
     131                    if( Double.isNaN(label) ) { 
    132132                        label = traindata.get(closestInstances.get(index)).classValue(); 
    133133                    } 
  • trunk/CrossPare/src/de/ugoe/cs/cpdp/training/WekaLocalFQTraining.java

    r41 r74  
    399399 
    400400            double[][] X = FMAP.getX(); 
    401             distmat = new double[0][0]; 
    402             System.gc(); 
    403401 
    404402            // quadtree payload generation 
  • trunk/CrossPare/src/de/ugoe/cs/cpdp/training/WekaTraining.java

    r42 r74  
    4848    public void apply(Instances traindata) { 
    4949        classifier = setupClassifier(); 
     50        if( classifier==null ) { 
     51            Console.printerr("classifier of WekaTraining is null"); 
     52            throw new RuntimeException("classifier of WekaTraining is null"); 
     53        } 
    5054        PrintStream errStr = System.err; 
    5155        System.setErr(new PrintStream(new NullOutputStream())); 
Note: See TracChangeset for help on using the changeset viewer.