How to save Tree Ensemble Model to PMML?

How can I save a Model generated by Tree Ensemble Model to disk? I use the Tree ensemble model extraction which create as many rows as there are trees. Howeve the "Table to PMML Ensemble" Node now expects a column with a double value containing the weight of the model.

Given the Tree ensemble nodes description:

The output model describes an ensemble of decision tree models and is applied in the corresponding predictor node using a simply majority vote.

I assume each model ahs exactly the same weight? And if true is it correct to then use that PMML model with the PMML Ensemble predictor?

EDIT:

OK the "Table to PMML Ensemble" needs a double column so you can configure it but in the actually node the weight is optional and you can just select "majority vote" like the Tree ensemble predictor uses. I propose to fix this node so that it auto-configures it self this way if no double-value column is available.

Is there another way to export such a Tree Ensemble Model? I ask this because the PMML Ensemble predictor constantly fails: Execute failed: Java heap space. And I can't give more memory. Also it's very slow compared to the Tree ensemble predictor.

 

 

 

 

Hi Beginner,

About the table to pmml ensemble node. You're right this is a bug in the configuration panel, I will fix it.

 

However about your initial question: It would be

Tree Ensemble Learner -> Tree Ensemble Model Extract -> Table to PMML Ensemble and afterwards you can use the PMML Writer to write the PMML to disk.

Alternatively you can directly write the model with the Model Writer.

 

Does this help?

Cheers Iris