File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -422,7 +422,7 @@ def run(
422422 manual_input_data , dataset_trained_path
423423 )
424424
425- prepared_dataset , y_pred = _run_prediction_pipeline (
425+ _ , y_pred = _run_prediction_pipeline (
426426 task = task ,
427427 trained_model = trained_model ,
428428 train_dataset = train_dataset ,
@@ -460,9 +460,13 @@ def run(
460460 full_path = Path (path ) / folder_name
461461 full_path .mkdir (parents = True , exist_ok = True )
462462
463- # Add predictions to loaded dataset
463+ output_col = model_session .output_columns [0 ]
464+ base_columns = [
465+ col for col in loaded_dataset .column_names if col != output_col
466+ ]
467+ output_dataset = loaded_dataset .select_columns (base_columns )
464468 dataset_with_prediction = to_dashai_dataset (
465- prepared_dataset .add_column (model_session . output_columns [ 0 ] , y_pred )
469+ output_dataset .add_column (output_col , y_pred )
466470 )
467471
468472 # Filter schema from trained dataset
You can’t perform that action at this time.
0 commit comments