SENT MAIL OPERATOR

Alexandros_Tzekas51Alexandros_Tzekas51 Member Posts: 27 Contributor I
Let's say i have a dataset that contains temperatures, pressures, etc and I want to use the operator "Sent Mail" so that below a minimum value and above a maximum value of temperature it would send me a message to alert me. Could anyone tell me how exactly I should use this particular operator in this example (parameters, other operators etc)?

Best Answers

Answers

  • sgenzersgenzer Administrator, Moderator, Employee, RapidMiner Certified Analyst, Community Manager, Member Posts: 1,959  Community Manager
    edited December 2018
    hi @Alexandros_Tzekas51 so just build whatever process you want so that the result is the ExampleSet you wish to email to yourself. Then use the very handy "ExampleSet to HTML" operator in the Converter extension to convert to HTML. Then you can use Send Mail. Something like this:

    <?xml version="1.0" encoding="UTF-8"?><process version="9.1.000">
      <context>
        <input/>
        <output/>
        <macros/>
      </context>
      <operator activated="true" class="process" compatibility="9.1.000" expanded="true" name="Process">
        <parameter key="logverbosity" value="init"/>
        <parameter key="random_seed" value="2001"/>
        <parameter key="send_mail" value="never"/>
        <parameter key="notification_email" value=""/>
        <parameter key="process_duration_for_mail" value="30"/>
        <parameter key="encoding" value="SYSTEM"/>
        <process expanded="true">
          <operator activated="true" class="generate_data" compatibility="9.1.000" expanded="true" height="68" name="Generate Data" width="90" x="45" y="85">
            <parameter key="target_function" value="random"/>
            <parameter key="number_examples" value="100"/>
            <parameter key="number_of_attributes" value="5"/>
            <parameter key="attributes_lower_bound" value="-10.0"/>
            <parameter key="attributes_upper_bound" value="10.0"/>
            <parameter key="gaussian_standard_deviation" value="10.0"/>
            <parameter key="largest_radius" value="10.0"/>
            <parameter key="use_local_random_seed" value="false"/>
            <parameter key="local_random_seed" value="1992"/>
            <parameter key="datamanagement" value="double_array"/>
            <parameter key="data_management" value="auto"/>
          </operator>
          <operator activated="true" class="converters:example_set_2_html" compatibility="0.4.001" expanded="true" height="82" name="ExampleSet to HTML" width="90" x="179" y="85">
            <parameter key="macro" value="htmlMacro"/>
            <parameter key="Use a limit on Digits" value="false"/>
            <parameter key="Number of Digits" value="3"/>
            <parameter key="HTML class name for the table" value="rapidminer-table"/>
          </operator>
          <operator activated="true" class="send_mail" compatibility="9.1.000" expanded="true" height="68" name="Send Mail" width="90" x="313" y="85">
            <parameter key="to" value="[email protected]"/>
            <parameter key="subject" value="My ExampleSet"/>
            <parameter key="use_html" value="true"/>
            <parameter key="body_html" value="&lt;html&gt;&#10;&#9;&lt;head&gt;&#10;&#9;&#9;&lt;title&gt;RapidMiner Mail Message&lt;/title&gt;&#10;&#9;&lt;/head&gt;&#10;&#9;&lt;body&gt;&#10;&#9;&#9;&lt;p&gt;%{htmlMacro}&#10;&#9;&#9;&lt;/p&gt;&#10;&#9;&lt;/body&gt;&#10;&lt;/html&gt;&#10;"/>
            <list key="headers"/>
            <parameter key="ignore_errors" value="false"/>
          </operator>
          <connect from_op="Generate Data" from_port="output" to_op="ExampleSet to HTML" to_port="example set input"/>
          <portSpacing port="source_input 1" spacing="0"/>
          <portSpacing port="sink_result 1" spacing="0"/>
        </process>
      </operator>
    </process>

    Scott
  • Alexandros_Tzekas51Alexandros_Tzekas51 Member Posts: 27 Contributor I
    i can't see anything....
  • sgenzersgenzer Administrator, Moderator, Employee, RapidMiner Certified Analyst, Community Manager, Member Posts: 1,959  Community Manager
    ok sorry I used the spoiler tag to hide/show but clearly that's not working on your browser. Try again.
  • Alexandros_Tzekas51Alexandros_Tzekas51 Member Posts: 27 Contributor I
    Ok, now i see!
  • Alexandros_Tzekas51Alexandros_Tzekas51 Member Posts: 27 Contributor I
    I wiil try that and i will reply to you soon.
  • Alexandros_Tzekas51Alexandros_Tzekas51 Member Posts: 27 Contributor I
    didn't work! It says:

    "Cannot send mail to '[email protected]'. Couldn't connect to host, port: localhost, 25;"
  • sgenzersgenzer Administrator, Moderator, Employee, RapidMiner Certified Analyst, Community Manager, Member Posts: 1,959  Community Manager
    yes ok. Did you set up your mail preferences?



    Scott
  • Alexandros_Tzekas51Alexandros_Tzekas51 Member Posts: 27 Contributor I
    Good Morning my Brothers!
    I have a Big Problem here! I have a gmail so my SMTP Settings should be configured like this:
    • server address: smtp.gmail.com
    • adress: [email protected]
    • pass: MyPassword
    • port: 465 (i checked it)
    But it didn't work! So i created 3 other emails: yahoo, mail and hotmail. I figured out that the only thing that changes is the server address which is smtp.mail.yahoo.com for yahoo, smtp.mail.com for mail and smtp.live.com for hotmail.
    I used them all but it was a failure...!

    You have any idea what is going wrong?



  • Edin_KlapicEdin_Klapic Moderator, Employee, RMResearcher, Member Posts: 243  RM Data Scientist
    Did you set the Authentication type? Maybe StartTLS is necessary.
    At least for gmail I know that you need to enable not trusted Apps (see https://support.google.com/accounts/answer/6010255?hl=en) in your account settings.
    Let me know how this works :)
    Happy Mining,
    Edin



    sgenzer
  • Alexandros_Tzekas51Alexandros_Tzekas51 Member Posts: 27 Contributor I
    Nothing!
  • Alexandros_Tzekas51Alexandros_Tzekas51 Member Posts: 27 Contributor I
    Guys, please i really really need some answers on these questions cause i have to start my experiment. I have only 2 weeks to get my results!
Sign In or Register to comment.