Skip to content

Tags: Quantco/glum

Tags

v3.4.1

Toggle v3.4.1's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Add test suite for backwards compatibility (#999)

* Add backwards compatibility tests.

* Save data to disk, save predictions as npy.

v3.4.0

Toggle v3.4.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Monotonic constraints (#996)

* Fix nightly test for sklearn ElasticNetCV n_alphas removal

sklearn 1.7 renamed the `n_alphas` parameter to `alphas` in
`ElasticNetCV`. Dynamically select the correct keyword to support
both old and new sklearn versions.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* fix

* Fix comment: don't assume sklearn removal version

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* implement monotonic constraints

* add explicit test between solvers and consolidate tests

* more consistent interface to standard irls solver

* pr comments; ci failure

* leave p2 in original form (sparse or 1D when there are no violations

* add changelog

* add to README [skip-ci]

* move constraint checks and resolution to single plac

* add comments back

* remvoe unnecessary branching

* sparce constraint matrix

* relax tol due to switch to sparse

* move validation of mono constr against Ab to hyperparameter validation

* test formula vs explicit A_ineq constraint path agreement

Renames test to test_monotonic_constraint_paths_agree and adds a formula-based
IRLS fit to verify internal constraint matrix building matches explicit A_ineq/b_ineq.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* cleanup

* cleanup

* validate edge case

* relax test tol slightly due to 8e-8 difference resulting from different paths via tabmat SplitMatrix vs. dense numpy array

* update changelog for release

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>

v3.3.0

Toggle v3.3.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Replace `hess="2-point"` with `hess=SR1()` in trust-constr solver (#993)

* use quasi newton gradient in trust-constr solver

* add changelog entry

* small test that constraint actually binds

* update changelog

* review

* update changelog for release

3.2.3

Toggle 3.2.3's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Update formula and french motor tutorials (#986)

* update formula and french motor tutorial

* fix

3.2.2

Toggle 3.2.2's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Fix inverse_derivative2 for cloglog (#988)

3.2.1

Toggle 3.2.1's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Partially reverse #975 (#984)

v3.2.0

Toggle v3.2.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
`GeneralizedLinearRegressorCV`: allow predicting with `alpha` or `alp…

…ha_index` and fix alpha path computation (#975)

* Add failing test for CV linear_predictor with alpha_index

coef_path_ in GeneralizedLinearRegressorCV has shape
(n_folds, n_l1_ratios, n_alphas, n_features) but the inherited
linear_predictor indexes it as if it were (n_alphas, n_features),
causing a broadcast error.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* Raise clear error for predict with alpha_index on CV estimator

GeneralizedLinearRegressorCV.coef_path_ has shape
(n_folds, n_l1_ratios, n_alphas, n_features), which is incompatible
with the base class linear_predictor that expects (n_alphas, n_features).
Override linear_predictor to raise a ValueError when alpha_index or
alpha is passed, directing users to use the default predict (best alpha
from the full-data refit).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* allow to predict with alpha_index

* fix trailing whitespace

* avoid breaking change

* Parametrize CV predict test over single and multiple l1_ratios

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* Simplify CV linear_predictor by normalizing alpha_index to a list early

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* Move alpha/alpha_index mutual exclusion check to top of linear_predictor

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* Move alpha_search guard out of _find_alpha_index into linear_predictor

The CV class no longer needs to override _find_alpha_index or set
alpha_search=True — it simply calls _find_alpha_index (which now
assumes _alphas exists) from its own linear_predictor override.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* docstrings

* combine shared logic

* move more logic into alpha path; type hints

* docstring

* fix scaling in setup of CV; fix solver name; add equivalence test

* wordings

* wordings, changelog

* reorganize linear predictor; wordings

* cosmetics

* more tiny cosmetics

* erroneous search and replace

* review comments

* adjust test to informative error message

* tiny wording

* wordings

* add comment on diagnostics

* correct type ifnore

* update changelog for release

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>

3.1.3

Toggle 3.1.3's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Prepare release 3.1.3 (#978)

* prepare release

* plural

3.1.2

Toggle 3.1.2's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Build wheels for linux-aarch64 (#903)

* Harmonize workflow triggers

* Build for linux-aarch64

* Build conda wheels as before

* Fix release date

Co-authored-by: Jan Tilly <jan.tilly@quantco.com>

---------

Co-authored-by: Jan Tilly <jan.tilly@quantco.com>

3.1.1

Toggle 3.1.1's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Prepare for releasing 3.1.1 (#900)

* Prepare for release

* Lint

* Use local version of house data

* Copy dataset for CI doctest