The Altair Community is migrating to a new platform to provide a better experience for you. In preparation for the migration, the Altair Community is on read-only mode from October 28 - November 6, 2024. Technical support via cases will continue to work as is. For any urgent requests from Students/Faculty members, please submit the form linked here
new developed operator not functioning
1. to develop a new operator, it is a must to have a input and output port?
2. when want to send the input object to the output port must use deliver() function? or it have others method to use?
3. " ExampleSet exampleSet = exampleSetInput.getData(); " what the ExampleSet class doing? it's a must to use it when I want to retrieve data/get data?
4. How to test the operator is working or not? I run the ant file already, when I use the new developed operator and run it, it's no response, I not sure is my function code got error or any others problem occurs .
I need a guide here. Thanks.
Best Regards,
Alan
2. when want to send the input object to the output port must use deliver() function? or it have others method to use?
3. " ExampleSet exampleSet = exampleSetInput.getData(); " what the ExampleSet class doing? it's a must to use it when I want to retrieve data/get data?
4. How to test the operator is working or not? I run the ant file already, when I use the new developed operator and run it, it's no response, I not sure is my function code got error or any others problem occurs .
I need a guide here. Thanks.
Best Regards,
Alan
Tagged:
0
Answers
the whitepaper How to Extend RapidMiner covers your questions pretty well.
Otherwise you might want to try and search this development forum and piece some code fragments that have been posted here together, that might help you as well.
4) Add RM as a project in Eclipse, add RM as a library project to your extension project, launch RM in debug mode and play around with your operator. You can then add breakpoints in your code and see what happens yourself.
Regards,
Marco
Best Regards,
Alan
1) yes input/output ports are a necessity - unless you are creating a special kind of operator to import data (for example see AbstractReader class) with no input port. The RapidMiner operator concept bases on an "execution flow" which basically sends your data through each operator in the chain in the given order. Even if your operator does nothing on the data, it needs to pass the data from an input port to an output port regardless.
2) It depends on what operator class you want to extend. For example, extending AbstractExampleSetProcessing class youwould simply need to do: This takes the input and delivers it at the output without doing anything.
3) See JavaDoc and whitepaper. However data is not always an ExampleSet, it could also be a Model or some other data. Most of the time you will deal with ExampleSets though I guess.
Regards,
Marco
private InputPort exampleSetInput = getInputPorts().createPort("example set");
private OutputPort exampleSetOutput = getOutputPorts().createPort("example set");
Employee a = new Employee();
ExampleSet ex = exampleSetInpu.getData();
a.printEmployee();
exampleSetOutput.deliver(ex);
Best Regards,
Alan
I don't quite understand what you're trying to achieve. Your operator class needs to extend the appropriate operator class (for example AbstractExampleSetProcessing), and then implement/overwrite the method that does the work, in the case of the AbstractExampleSetProcessing class it's the method as shown in my previous post. Also please note that creating a process programatically is of course possible but discouraged for beginners, as it is quite error prone and it is a lot easier to create the process (with your new operator) in the RapidMiner GUI and then just execute the whole process. See here how to do that.
Regards,
Marco
For example how to debug Numerical2DateOperator file ?
Regards,
Alan
as you would launch any other java program in debug mode. Use an IDE like Eclipse, add the RapidMiner_Unuk project via SourceForge SVN and then launch it in debug mode (RapidMinerGUI class contains the main() method you're looking for).
Regards,
Marco