What's Changed
Bug Fixes & Compatibility
- SciPy compatibility: Replaced deprecated
scipy.sparse.csr.csr_matrixreferences withscipy.sparse.csr_matrixinDataset. - Pandas compatibility: Updated
auto_group_featuresto passobserved=Truetogroupbyfor categorical columns, explicitly cast feature series tofloat64, and use.to_numpy()to support mixed dtypes (including nullableInt64andboolcolumns). Set minimum version topandas>=0.24.0. - Auto-grouping 2-feature edge case: Handled scalar
spearmanroutput when auto-grouping exactly two features (e.g., alongsidefeature_groups).
Validation
- Minimum feature count check:
Datasetnow raises aValueErrorif fewer than 2 total features (includingfeature_groups) remain after auto-grouping, failing fast instead of erroring during importance computation.
Tests
- Added unit tests covering minimum feature validation and auto-grouping edge cases (correlated pairs with
feature_groups, single feature withfeature_groups, and mixed/nullable dtypes).