Sklearn: Is there any way to debug Pipelines?

后端 未结 2 564
甜味超标
甜味超标 2021-01-01 22:26

I have created some pipelines for classification task and I want to check out what information is being present/stored at each stage (e.g. text_stats, ngram_tfidf). How coul

2条回答
  •  轮回少年
    2021-01-01 23:12

    You can traverse your Pipeline() tree using steps and named_steps attributes. The former is a list of tuples ('step_name', Step()) while the latter gives you a dictionary constructed from this list

    FeatureUnion() content could be explored the same way using transformer_list attribute

提交回复
热议问题