Options

[SOLVED] WARNING: Join: Special attribute 'id' already exist, skipping!

tennenrishintennenrishin Member Posts: 177 Contributor II
edited November 2019 in Help
Hello all

My console is sometimes filled with the following warning message:
WARNING: Join: Special attribute 'id' already exist, skipping!

Can anyone explain to me what it means? In particular, what is it about the process below (for example) that is warning-worthy?
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<process version="5.2.008">
 <context>
   <input/>
   <output/>
   <macros/>
 </context>
 <operator activated="true" class="process" compatibility="5.2.008" expanded="true" name="Process">
   <process expanded="true" height="654" width="987">
     <operator activated="true" class="generate_data_user_specification" compatibility="5.2.008" expanded="true" height="60" name="Generate Data by User Specification" width="90" x="45" y="30">
       <list key="attribute_values">
         <parameter key="key" value="1"/>
         <parameter key="data" value="5"/>
       </list>
       <list key="set_additional_roles"/>
     </operator>
     <operator activated="true" class="set_role" compatibility="5.2.008" expanded="true" height="76" name="Set Role" width="90" x="179" y="30">
       <parameter key="name" value="key"/>
       <parameter key="target_role" value="id"/>
       <list key="set_additional_roles"/>
     </operator>
     <operator activated="true" class="generate_data_user_specification" compatibility="5.2.008" expanded="true" height="60" name="Generate Data by User Specification (2)" width="90" x="45" y="120">
       <list key="attribute_values">
         <parameter key="key" value="1"/>
         <parameter key="data2" value="6"/>
       </list>
       <list key="set_additional_roles"/>
     </operator>
     <operator activated="true" class="set_role" compatibility="5.2.008" expanded="true" height="76" name="Set Role (2)" width="90" x="179" y="120">
       <parameter key="name" value="key"/>
       <parameter key="target_role" value="id"/>
       <list key="set_additional_roles"/>
     </operator>
     <operator activated="true" class="join" compatibility="5.2.008" expanded="true" height="76" name="Join" width="90" x="301" y="75">
       <parameter key="join_type" value="left"/>
       <list key="key_attributes"/>
     </operator>
     <connect from_op="Generate Data by User Specification" from_port="output" to_op="Set Role" to_port="example set input"/>
     <connect from_op="Set Role" from_port="example set output" to_op="Join" to_port="left"/>
     <connect from_op="Generate Data by User Specification (2)" from_port="output" to_op="Set Role (2)" to_port="example set input"/>
     <connect from_op="Set Role (2)" from_port="example set output" to_op="Join" to_port="right"/>
     <connect from_op="Join" from_port="join" to_port="result 1"/>
     <portSpacing port="source_input 1" spacing="0"/>
     <portSpacing port="sink_result 1" spacing="0"/>
     <portSpacing port="sink_result 2" spacing="0"/>
   </process>
 </operator>
</process>
Thanks in advance
Isak
Tagged:

Answers

  • Options
    MariusHelfMariusHelf RapidMiner Certified Expert, Member Posts: 1,869 Unicorn
    Hi Isak,

    in this case this is a bug and the message can be ignored (it's only the message, nothing more).

    However, imagine you are joining to example sets by id, where each of them has a label. The problem then is, that the special roles must be unique, i.e. the final example set may contain only one label attribute. In that case, only the label from the first set is kept, whereas the label from the second example set will be dismissed. That's what the error message wants to say.

    But since you are joining by id anyway, you can safely ignore the message here.

    Best regards,
    Marius
  • Options
    tennenrishintennenrishin Member Posts: 177 Contributor II
    Thanks for the explanation, Marius!

    (I assume then there is no way currently to get rid of these messages without changing the overall process verbosity to below warning level.)
  • Options
    MariusHelfMariusHelf RapidMiner Certified Expert, Member Posts: 1,869 Unicorn
    No, unfortunately there's no possibility to do that.

    Best regards,
    Marius
  • Options
    tennenrishintennenrishin Member Posts: 177 Contributor II
    Marius wrote:
    in this case this is a bug and the message can be ignored...
    I know it's (almost) harmless, but it would be nice if this little bug could go away  :)

    Regards,
    Isak
  • Options
    MariusHelfMariusHelf RapidMiner Certified Expert, Member Posts: 1,869 Unicorn
    Hi Isak,

    I created a ticket for this issue, but since it is, as you already stated, a small thing, but a bit complicated since at the same time a lot of special cases must be considered, it probably won't get high priority.

    Best regards,
    Marius
  • Options
    tennenrishintennenrishin Member Posts: 177 Contributor II
    Pleeeease consider reconsidering the priority of this request ;D
    I have to wade through hundreds (if not thousands) of these messages every day in my console to find the meaningful messages between them.  :'(
  • Options
    Marco_BoeckMarco_Boeck Administrator, Moderator, Employee, Member, University Professor Posts: 1,995 RM Engineering
    Hi,

    I guess I'm in a hacky mood when I'm reading your threads, so you are in luck again (Refers to your other thread Accessing "last modified" metadata) 8)
    Disclaimer: The following code is a very dirty hack and should not be used! But I guess if you are having the problem of sifting through hundreds of these false warnings it will help you until the issue gets resolved.
    The solution is once again the Execute Script operator (this thing can be abused to no end ::) )
    Add the Execute script operator before your Join operator and put this in as the script paramter:

    import com.rapidminer.operator.Operator;
    import java.util.logging.Filter;
    import java.util.logging.LogRecord;
    import java.util.logging.Logger;


    Logger.getLogger(Operator.class.getName()).setFilter(new Filter() {

    @Override
    public boolean isLoggable(LogRecord record) {
    if (record.getMessage().contains("Special attribute 'id' already exist")) {
    return false;
    } else {
    return true;
    }
    }
    });

    return (input[0]);
    This will set a filter to the logger which will filter exactly all log entries which contain the phrase "Special attribute 'id' already exist". After your join operator you can place another execute script operator which will remove the filter again:

    import com.rapidminer.operator.Operator;
    import java.util.logging.Logger;


    Logger.getLogger(Operator.class.getName()).setFilter(null);

    return (input[0]);
    But as mentioned above, this is dirty and should not be done, but I guess in your case you might like it anyway ;)

    Regards,
    Marco
  • Options
    tennenrishintennenrishin Member Posts: 177 Contributor II
    :o
    Thank you!

    I didn't even realize what the Execute Script operator is. I think it lacked documentation when I once looked into it, so I've spent hours and hours ever since then writing "scripts" graphically in the Turing tarpit that is RM Macro + Process Control operators :-[
Sign In or Register to comment.