Pages: [1]
Author Topic: [SOLVED] Performance (Costs) - NullPointerException  (Read 1079 times)
Jr. Member
Posts: 69

« on: January 13, 2013, 07:21:47 PM »


   I think I have misconfigured the Performance (Costs) node, but do not see the error. It results in the following exception:
SEVERE: Process failed: operator cannot be executed. Check the log messages...
        at com.rapidminer.example.Example.getNominalValue(
        at com.rapidminer.operator.performance.cost.ClassificationCostCriterion.countExample(
        at com.rapidminer.operator.performance.cost.CostEvaluator.doWork(
        at com.rapidminer.operator.Operator.execute(
        at com.rapidminer.operator.execution.SimpleUnitExecutor.execute(
        at com.rapidminer.operator.ExecutionUnit.execute(
        at com.rapidminer.operator.validation.ValidationChain.executeEvaluator(
        at com.rapidminer.operator.validation.ValidationChain.evaluate(
        at com.rapidminer.operator.validation.SplitValidationOperator.estimatePerformance(
        at com.rapidminer.operator.validation.ValidationChain.doWork(
        at com.rapidminer.operator.Operator.execute(
        at com.rapidminer.operator.execution.SimpleUnitExecutor.execute(
        at com.rapidminer.operator.ExecutionUnit.execute(
        at com.rapidminer.operator.OperatorChain.doWork(
        at com.rapidminer.operator.Operator.execute(

With the following process:
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<process version="5.2.008">
  <operator activated="true" class="process" compatibility="5.2.008" expanded="true" name="Process">
    <process expanded="true" height="152" width="145">
      <operator activated="true" class="split_validation" compatibility="5.2.008" expanded="true" height="112" name="Validation" width="90" x="45" y="30">
        <process expanded="true" height="445" width="258">
          <operator activated="true" class="auto_mlp" compatibility="5.2.008" expanded="true" height="76" name="AutoMLP" width="90" x="45" y="30"/>
          <connect from_port="training" to_op="AutoMLP" to_port="training set"/>
          <connect from_op="AutoMLP" from_port="model" to_port="model"/>
          <portSpacing port="source_training" spacing="0"/>
          <portSpacing port="sink_model" spacing="0"/>
          <portSpacing port="sink_through 1" spacing="0"/>
        <process expanded="true" height="445" width="258">
          <operator activated="true" class="performance_costs" compatibility="5.2.008" expanded="true" height="76" name="Performance" width="90" x="45" y="30">
            <parameter key="cost_matrix" value="[0.0 1.0 10.0;3.0 0.0 0.3;1.0 1.0 0.0]"/>
            <enumeration key="class_order_definition">
              <parameter key="class_name" value="Iris-setosa"/>
              <parameter key="class_name" value="Iris-virginica"/>
              <parameter key="class_name" value="Iris-versicolor"/>
          <connect from_port="test set" to_op="Performance" to_port="example set"/>
          <connect from_op="Performance" from_port="performance" to_port="averagable 1"/>
          <portSpacing port="source_model" spacing="0"/>
          <portSpacing port="source_test set" spacing="0"/>
          <portSpacing port="source_through 1" spacing="0"/>
          <portSpacing port="sink_averagable 1" spacing="0"/>
          <portSpacing port="sink_averagable 2" spacing="0"/>
      <connect from_port="input 1" to_op="Validation" to_port="training"/>
      <connect from_op="Validation" from_port="model" to_port="result 2"/>
      <connect from_op="Validation" from_port="training" to_port="result 1"/>
      <connect from_op="Validation" from_port="averagable 1" to_port="result 3"/>
      <portSpacing port="source_input 1" spacing="0"/>
      <portSpacing port="source_input 2" spacing="0"/>
      <portSpacing port="sink_result 1" spacing="0"/>
      <portSpacing port="sink_result 2" spacing="0"/>
      <portSpacing port="sink_result 3" spacing="0"/>
      <portSpacing port="sink_result 4" spacing="0"/>
Should I open a ticket asking for a better error message, or I made an obvious mistake?
Thanks, gabor
« Last Edit: January 14, 2013, 01:50:14 PM by aborg » Logged
Marius Helf
Hero Member
Posts: 1805

« Reply #1 on: January 14, 2013, 10:48:47 AM »

Hi Gabor,

this is a combination of a bug and a misconfiguration. The bug is, that the performance operator should give you a decent and descriptive error message. We'll fix that.

The misconfiguration is that you are missing an Apply Model operator. Just add it before the performance operator and your process will run fine.

Best regards,

Please add [SOLVED] to the topic title when your problem has been solved! (do so by editing the first post in the thread and modifying the title)
Please click here before posting.
Pages: [1]
Jump to: