Changeset 208 for branches/ExperimentalFunctionsBaking
- Timestamp:
- 04/29/08 13:36:36 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/ExperimentalFunctionsBaking/BakedFunctionTree.cs
r206 r208 283 283 284 284 private double EvaluateBakedCode(Dataset dataset, int sampleIndex) { 285 double arity = code [PC++];286 double functionSymbol = code [PC++];287 double nLocalVariables = code [PC++];285 double arity = codeArr[PC++]; 286 double functionSymbol = codeArr[PC++]; 287 double nLocalVariables = codeArr[PC++]; 288 288 if(functionSymbol == variableSymbol) { 289 int var = (int)code [PC++];290 double weight = code [PC++];291 int offset = (int)code [PC++];289 int var = (int)codeArr[PC++]; 290 double weight = codeArr[PC++]; 291 int offset = (int)codeArr[PC++]; 292 292 return weight * dataset.GetValue(sampleIndex+offset, var); 293 293 } else if(functionSymbol == constantSymbol) { 294 double value = code [PC++];294 double value = codeArr[PC++]; 295 295 return value; 296 296 } else if(functionSymbol == additionSymbol) {
Note: See TracChangeset
for help on using the changeset viewer.