Azure-docs: How to unwrap azure model and convert it to its original model?

Created on 25 Jun 2019  Â·  7Comments  Â·  Source: MicrosoftDocs/azure-docs

How to unwrap azure model and convert it to its original model?

For example, I fetch the best model which is XGBoostClassifier, but the type of model is automl.client.core.common.model_wrappers.PipelineWithYTransformations. Now I want to convert it to XGBoost object so that I can use xgboost.plot_importance to analyse the model.

image


Document Details

⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

Pri2 assigned-to-author corsubsvc machine-learninsvc product-question triaged

Most helpful comment

@yiikou you should be able to retrieve the estimator through automl_eclipse_2_0_xgboost.steps[-1][1] or as @marabout2015 mentioned through named steps automl_eclipse_2_0_xgboost.named_steps["XGBoostClassifier"]

The code would look like this:

model = automl_eclipse_2_0_xgboost.steps[-1][1]
xgboost.plot_importance(model)

All 7 comments

@yiikou Thank you for your feedback, we will investigate it and get back to you soon.

@nacharya1 Hi, from my end I don't think we can do this. Could you please help to check if there any plan from product end? Thank you very much.

@Sabina CartacioSabina.Cartacio@microsoft.com can you look into this please?

From: YutongTie-MSFT notifications@github.com
Sent: Monday, July 1, 2019 9:04 AM
To: MicrosoftDocs/azure-docs azure-docs@noreply.github.com
Cc: Nilesh Acharya nilesha@microsoft.com; Mention mention@noreply.github.com
Subject: Re: [MicrosoftDocs/azure-docs] How to unwrap azure model and convert it to its original model? (#33966)

@nacharya1https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnacharya1&data=02%7C01%7Cnilesha%40microsoft.com%7Ca009a68bf5244892b35908d6fe3dbbfe%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C636975938431780130&sdata=COx%2FNLPenyAwpEyexure2yuOnQ4MM7VryF5Aqj7WWJ8%3D&reserved=0 Hi, from my end I don't think we can do this. Could you please help to check if there any plan from product end? Thank you very much.

—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FMicrosoftDocs%2Fazure-docs%2Fissues%2F33966%3Femail_source%3Dnotifications%26email_token%3DAJ65JT2BLG5EQBPLVLT4YULP5ITHDA5CNFSM4H3LOD32YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODY6TFAQ%23issuecomment-507327106&data=02%7C01%7Cnilesha%40microsoft.com%7Ca009a68bf5244892b35908d6fe3dbbfe%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C636975938431790126&sdata=WbkCrTuoMF0q9o7y3Sw5AizkLC059NBIYwOi7JgXEfk%3D&reserved=0, or mute the threadhttps://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAJ65JT5PGCM6E7V2DGRCQQTP5ITHDANCNFSM4H3LOD3Q&data=02%7C01%7Cnilesha%40microsoft.com%7Ca009a68bf5244892b35908d6fe3dbbfe%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C636975938431790126&sdata=ouCD%2Bx7nf1MS8cOlNBN8%2FHaYqsqUpm9XGm1oNj7Gkmo%3D&reserved=0.

Hello @yiikou,

What do you see when you type:

automl_eclipse_2_0_xgboost.named_steps["XGBoostClassifier"].plot_importance()

Mario

hi @marabout2015 , it will cause error, since plot_importance is from the xgboost package.

@marabout2015 @cartacioS - any other guidance for @yiikou please?

@yiikou you should be able to retrieve the estimator through automl_eclipse_2_0_xgboost.steps[-1][1] or as @marabout2015 mentioned through named steps automl_eclipse_2_0_xgboost.named_steps["XGBoostClassifier"]

The code would look like this:

model = automl_eclipse_2_0_xgboost.steps[-1][1]
xgboost.plot_importance(model)
Was this page helpful?
0 / 5 - 0 ratings

Related issues

Favna picture Favna  Â·  3Comments

AronT-TLV picture AronT-TLV  Â·  3Comments

mrdfuse picture mrdfuse  Â·  3Comments

varma31 picture varma31  Â·  3Comments

JeffLoo-ong picture JeffLoo-ong  Â·  3Comments