RapidMiner 9.8 Beta is now available

Be one of the first to get your hands on the new features. More details and downloads here:

GET RAPIDMINER 9.8 BETA

Parallel execution of operators

Legacy UserLegacy User Member Posts: 0 Newbie
edited November 2018 in Help
Ok thanks.

Is it possible to apply operator in "parallel" ? I would like to filter input data that have RESULT A and RESULT B.
INPUT -> OPERATOR A -> RESULT A
INPUT -> OPERATOR B -> RESULT B

Operator seems to be chained in series:
INPUT -> OPERATOR A -> OPERATOR B -> RESULT C.

Answers

  • TobiasMalbrechtTobiasMalbrecht Moderator, Employee, Member Posts: 290  RM Product Management
    Hi,

    first of all: I hope you don't mind I put your questions in separate threads. That way, all users can easily recognize separate questions ...

    Regarding your problem, yes, in general operators in the operator tree are executed as a chain. However you can achieve a setting like the one you mentioned by using loops, e.g. by applying the [tt]ParameterIteration[/tt] operator.

    Here is an example process:

    <operator name="Root" class="Process" expanded="yes">
        <operator name="ExampleSetGenerator" class="ExampleSetGenerator">
            <parameter key="target_function" value="simple polynomial classification"/>
        </operator>
        <operator name="ParameterIteration" class="ParameterIteration" expanded="yes">
            <parameter key="keep_output" value="true"/>
            <list key="parameters">
              <parameter key="OperatorSelector.select_which" value="1,2"/>
            </list>
            <operator name="OperatorSelector" class="OperatorSelector" expanded="yes">
                <parameter key="select_which" value="2"/>
                <operator name="ExampleFilter" class="ExampleFilter">
                    <parameter key="condition_class" value="attribute_value_filter"/>
                    <parameter key="parameter_string" value="att1&gt;0"/>
                </operator>
                <operator name="ExampleFilter (2)" class="ExampleFilter">
                    <parameter key="condition_class" value="attribute_value_filter"/>
                    <parameter key="parameter_string" value="att1&lt;0"/>
                </operator>
            </operator>
        </operator>
    </operator>
    Hope that helps,
    regards,
    Tobias
  • Legacy UserLegacy User Member Posts: 0 Newbie
    Thanks, I've installed the lasted code from CVS and it works.
    However, I don't understand why you're using the following in OperatorSelector
    <parameter key="select_which" value="2"/>

    If I use:
    <parameter key="select_which" value="1"/>

    Then it works too. What's the meaning of this select_which ?
  • TobiasMalbrechtTobiasMalbrecht Moderator, Employee, Member Posts: 290  RM Product Management
    Hi,

    The thing is, that it does not matter what value is set in the OperatorSelector for the parameter [tt]select_which[/tt]. This is, because the process contains the operator [tt]ParameterIteration[/tt]. This operator iterates over parameters which you can specify. To select the first operator in the first iteration and the second operator in the second operator, you have to specify this in the [tt]ParameterIteration[/tt] operator parameters. Hence, the process XML contains the lines

            <list key="parameters">
              <parameter key="OperatorSelector.select_which" value="1,2"/>
            </list>
    which actually means exactly that the operator in the first iteration the value 1 is set for the parameter [tt]select_which[/tt], in the second iteration the value 2 is used for that parameter. The value you manually specify for the parameter [tt]select_which[/tt] in the operator [tt]OperatorSelector[/tt] is simply overwritten in that process.

    Hope that clarifies how it works!
    Regards,
    Tobias
Sign In or Register to comment.