test.dump_model¶
- test.dump_model(self, num_iteration=None, start_iteration=0, importance_type='split')¶
Dump Booster to JSON format.
- Parameters
num_iteration (int or None, optional (default=None)) – Index of the iteration that should be dumped. If None, if the best iteration exists, it is dumped; otherwise, all iterations are dumped. If <= 0, all iterations are dumped.
start_iteration (int, optional (default=0)) – Start index of the iteration that should be dumped.
importance_type (string, optional (default=”split”)) – What type of feature importance should be dumped. If “split”, result contains numbers of times the feature is used in a model. If “gain”, result contains total gains of splits which use the feature.
- Returns
json_repr (dict) – JSON format of Booster.