Advertisement
vishneva_olga

Untitled

Oct 31st, 2023
139
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.97 KB | None | 0 0
  1. preprocessor = ColumnTransformer([
  2.         ('num_scale', StandardScaler(), numerical_features)],
  3.         remainder='passthrough'
  4. )
  5.  
  6.  
  7. cbc_pipeline = Pipeline([
  8.         ('preprocessor', preprocessor),
  9.         ('classifier', CatBoostClassifier(random_state=STATE, cat_features=categorical_features, auto_class_weights='balanced', verbose=False))
  10. ])
  11.  
  12.  
  13. searcher = GridSearchCV(cbc_pipeline,
  14.                         param_grid={},
  15.                         scoring='f1',
  16.                         cv=2,
  17.                         n_jobs=-1,
  18.                         verbose=10)
  19.  
  20. cv_model = searcher.fit(X_train, y_train)
  21.  
  22.  
  23. # конец текста ошибки
  24.  
  25. File "/usr/local/lib/python3.10/dist-packages/catboost/core.py", line 277, in _get_features_indices
  26.     raise CatBoostError("features parameter contains string value '{}' but feature names "
  27. _catboost.CatBoostError: features parameter contains string value 'language' but feature names for a dataset are not specified
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement