decision-forests
decision-forests copied to clipboard
Issue with Max_depth in tfdf
df_and_nn_model = tfdf.keras.GradientBoostedTreesModel(preprocessing=regmodel_wo_head,
task=tfdf.keras.Task.REGRESSION,
num_trees=500,
max_depth=2,
max_num_nodes=-1,
min_examples=5,
validation_ratio=0.2,
subsample=0.9,
early_stopping='MIN_LOSS_FINAL',
shrinkage=0.001)
and after
df_and_nn_model.compile(metrics=[tf.keras.metrics.RootMeanSquaredError()])
with sys_pipes():
df_and_nn_model.fit(train_dataset, validation_data=val_dataset)
[INFO kernel.cc:772] Configure learner
[FATAL hyper_parameters.cc:49] Already consumed hyper-parameter "max_depth".
This was working yesterday morning but i made updates on kaggle and it throws this exception, i have no idea what it means.
Hi,
Thanks for the bug report :).
The wrong error message is displayed. Instead, the message should read TensorFlow: INVALID_ARGUMENT: "max_num_nodes" is only available with "growing_strategy=BEST_FIRST_GLOBAL". [Op:SimpleMLModelTrainer].
Regarding the (correct) error message, you should remove the line max_num_nodes=-1 (or replace it with max_num_nodes=None).
Cleanup: This has been fixed a long time ago, closing.