Extension ABCs

The Python ABCs in skein_glm.penalties and skein_glm.datafits mirror the Rust traits in skein-core. Implement these to prototype new penalties / datafits in Python before porting to Rust.

See Extending: custom penalties and Extending: custom datafits for worked examples.

Penalty ABCs

class skein_glm.penalties.Penalty[source]

Bases: ABC

Separable scalar penalty p(β) = Σ_j w_j · ψ(β_j).

class skein_glm.penalties.GroupPenalty[source]

Bases: ABC

Block-separable penalty over a group partition.

Datafit ABC

class skein_glm.datafits.Datafit[source]

Bases: ABC