Free cookie consent management tool by TermsFeed Policy Generator

Changeset 773


Ignore:
Timestamp:
11/18/08 17:14:42 (16 years ago)
Author:
gkronber
Message:

fixed bugs in evaluator introduced with r767. #364 (Improve GP evaluation performance)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.GP.StructureIdentification/BakedTreeEvaluator.cs

    r767 r773  
    9292        constExpr &= branchConstExpr;
    9393      }
    94       codeArr[index].exprLength = exprLength;
    9594
    9695      if (constExpr) {
    97         codeArr[index].symbol = EvaluatorSymbolTable.CONSTANT;
    9896        PC = index;
    9997        codeArr[index].d_arg0 = EvaluateBakedCode();
    100       }
     98        codeArr[index].symbol = EvaluatorSymbolTable.CONSTANT;
     99      }
     100      codeArr[index].exprLength = exprLength;
    101101    }
    102102
     
    108108        case EvaluatorSymbolTable.DIFFERENTIAL:
    109109        case EvaluatorSymbolTable.VARIABLE: {
    110             instr.i_arg0 = (byte)f.data[0]; // var
     110            instr.i_arg0 = (short)f.data[0]; // var
    111111            instr.d_arg0 = f.data[1]; // weight
    112             instr.i_arg1 = (byte)f.data[2]; // sample-offset
     112            instr.i_arg1 = (short)f.data[2]; // sample-offset
    113113            instr.exprLength = 1;
    114114            break;
Note: See TracChangeset for help on using the changeset viewer.