You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
FairModel — PyTorch nn.Module with differentiable fairness layer (cvxpylayers) enforcing hard per-batch constraints during training
FairModel.wrap() — wrap any existing nn.Module with fairness constraints; prediction bounds inferred automatically via dry-run forward pass
FairTrainer — high-level training loop with early stopping, LR scheduling, checkpoint save/load, and per-epoch fairness gap tracking
Three built-in fairness metrics: MeanPredictionParity ('mean_pred'), MeanResidualFairness ('mean_residual'), EqualizedOdds ('equalized_odds')
FairnessMetric abstract base class for custom affine fairness constraints
validate_metric() — pre-training DPP compliance check for custom metrics
create_stratified_dataloaders() — stratified batching that maintains constant group ratios per batch, accepting both numpy arrays and torch tensors
Online primal-dual inference algorithm for small-batch / streaming deployment with sample-weighted average violation guarantee (converges to ≤ ε as T → ∞)