Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ENH] Penalty classes #55

Merged
merged 66 commits into from
Jan 4, 2025
Merged

[ENH] Penalty classes #55

merged 66 commits into from
Jan 4, 2025

Conversation

Tveten
Copy link
Collaborator

@Tveten Tveten commented Dec 18, 2024

  1. Adds the BasePenalty class. Only intended for internal usage.
  2. Changes all detector arguments penalty, penalty_scale or threshold_scale to penalty throughout.
  3. Adds convenience method for converting various types of inputs to different kinds of penalties.
  4. Adds a compose module with the PenalisedScore class. For now only used by CAPA and MVCAPA.

@Tveten Tveten added the enhancement New feature or request label Dec 18, 2024
@Tveten Tveten self-assigned this Dec 18, 2024
Copy link

codecov bot commented Dec 18, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 98.54%. Comparing base (498dac2) to head (2c546b6).
Report is 67 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #55      +/-   ##
==========================================
+ Coverage   97.50%   98.54%   +1.04%     
==========================================
  Files          40       49       +9     
  Lines        1680     1858     +178     
==========================================
+ Hits         1638     1831     +193     
+ Misses         42       27      -15     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Useful to have access to fitable object utilities like is_fitted and check_is_fitted
Enables different number of variables in base_values and input data to fit
The output is now 2d, but was 1d before
Other checks should ensure that the input will always be correct
The <= condition passes all tests, while < don't
It is inherited from BaseEstimator
None means fitting is required, and min_size == 1 will never require fitting
@Tveten Tveten merged commit c5b6e05 into main Jan 4, 2025
10 checks passed
@Tveten Tveten deleted the penalties branch January 4, 2025 20:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[ENH] Unify penalties/thresholds. Penalty classes?
1 participant