Skip to content

skfolio/skfolio-cpcv-zero-purge

Rule skfolio-cpcv-zero-purge
Pack skfolio
Severity info
Fix none, edit by hand
Library versions skfolio 1.14.4 and later

skfolio defaults purged_size and embargo_size to zero. Overlapping observations or labels can cross a split boundary without a gap.

CombinatorialPurgedCV(n_folds=5, n_test_folds=2)
CombinatorialPurgedCV(n_folds=5, n_test_folds=2, purged_size=1, embargo_size=1)

In a 60-row run the first training split had 36 rows with no gap and 34 with both gaps set to one. Select the gap sizes for the overlap in your own data.

xpd prints this message with the issue. A name that starts with $ stands for code from your file.

Both skfolio combinatorial validation gaps are zero. If observations or labels overlap across a fold boundary, size purged_size and embargo_size for that overlap.

Browse the other rules of the skfolio pack.