When the number of features exceeds 20, the MambularRegressor will throw the following error. How can this be resolved?
KeyError Traceback (most recent call last)
in <cell line: 0>()
18 # print("y_train 类型:", type(y_train))
19 # print("y_train 形状:", y_train.shape)
---> 20 model.fit(X_train, y_train, max_epochs=10)
21 preds = model.predict(X_test)
22 print(model.evaluate(X_test, y_test))
21 frames
/usr/local/lib/python3.11/dist-packages/pretab/transformers/ple/tree_to_code.py in recurse(node, depth, parent)
50 else:
51 k = k + 1
---> 52 my_list.append(pathto[parent])
53 # print(k,')',pathto[parent], tree_.value[node])