LightGBM에서 plot_tree()에서 에러가 나서, 해당 트리 모형을 수기로 그리는 것 이외에는 별다른 방법이 없다.
아래가 찾고 찾아서 만든 트리 모델 정보 가져오는 코드를 설명해주는 사이트이다. 아래 코드에서 clf.booster_trees_to_dataframe() 는 작동하지 않는다.
Is there a way to get tree data as a list with the LightGBM Classifier
In random forest type models, there is usually an attribute like "estimators" which returns all the tree split as a list of lists. I can't seem find something similar with lightgbm. The c...
stackoverflow.com
반응형
'Python, PySpark' 카테고리의 다른 글
파이썬에서 문자/숫자 컬럼 구분해서 missing값 처리 (0) | 2022.08.30 |
---|---|
파이썬에서 JSON 인코딩 자료를 Text로 변환 (0) | 2022.08.23 |
Python dataframe 조건별로 날짜 변환 (0) | 2022.06.17 |
Python loop로 객체 삭제 (0) | 2022.05.13 |
뱅크샐러드 과제물 작성 : 2021/11/16 (0) | 2021.11.16 |