API: preprocessing.encoding
skyulf.preprocessing.encoding
Encoding nodes package.
Split from a single 832-LOC module into per-encoder files
_common.py — shared helpers (detect_categorical_columns, _exclude_target_column, …) one_hot.py — OneHotEncoder ordinal.py — OrdinalEncoder label.py — LabelEncoder target.py — TargetEncoder hash.py — HashEncoder dummy.py — DummyEncoder woe.py — WOEEncoder (Weight-of-Evidence / Information Value)
All public names are re-exported here so existing imports such as
from skyulf.preprocessing.encoding import OneHotEncoderCalculator
continue to work unchanged.
TargetEncoderCalculator
Bases: BaseCalculator
Source code in skyulf-core/skyulf/preprocessing/encoding/target.py
298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 | |
fit_transform_train(df, config)
Fit sklearn TargetEncoder and cross-fit the pipeline training rows.
Source code in skyulf-core/skyulf/preprocessing/encoding/target.py
322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 | |
WOEEncoderCalculator
Bases: BaseCalculator
Source code in skyulf-core/skyulf/preprocessing/encoding/woe.py
308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 | |
fit_transform_train(df, config)
Fit the full-data WOE artifact and cross-fit the training rows.
Source code in skyulf-core/skyulf/preprocessing/encoding/woe.py
335 336 337 338 339 340 341 342 343 344 345 346 347 348 | |