HF RL Explorer

Task: Fix OneHotEncoder for Categorical Features with String Values

Task: Fix OneHotEncoder for Categorical Features with String Values: a task in Terminal-Lego-15k (Harbor dataset). Write a Python script that correctly applies one-hot encoding to specific categorical (string) columns in a mixed-type dataset using scikit-learn. The original approach using…

The task

Write a Python script that correctly applies one-hot encoding to specific categorical (string) columns in a mixed-type dataset using scikit-learn. The original approach using `preprocessing.OneHotEncoder(categorical_features=cat_features)` fails because `OneHotEncoder` in older versions cannot handle string values…

Part of PrimeIntellect/Terminal-Lego-15k.