[ENH]: Implement a NaN policy for onthefly.read_transform #429

Merged
fraimondo merged 5 commits from enh/read_transform_nan into main 2025-07-22 11:05:08 +00:00
fraimondo commented 2025-02-24 16:00:25 +00:00 (Migrated from github.com)
  • description of feature/fix
  • tests added/passed
  • add an entry for the latest changes

This PR implements a policy to handle NaN values before calling the respective transformation function in read_transform.

Current options are:

  • bypass: do nothing, pass NaNs.
  • drop_element: skip elements with at least one NaN value
  • drop_rows: skip rows with at least one NaN value
  • drop_symmetric: skip rows and columns symmetrically, keeping the matrix squared.
- [x] description of feature/fix - [x] tests added/passed - [x] add an entry for the latest changes This PR implements a policy to handle NaN values before calling the respective transformation function in `read_transform`. Current options are: * `bypass`: do nothing, pass NaNs. * `drop_element`: skip elements with at least one NaN value * `drop_rows`: skip rows with at least one NaN value * `drop_symmetric`: skip rows and columns symmetrically, keeping the matrix squared.
codecov[bot] commented 2025-02-24 16:41:11 +00:00 (Migrated from github.com)

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 91.30%. Comparing base (d3fe3e6) to head (93205f3).
Report is 6 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #429      +/-   ##
==========================================
+ Coverage   91.26%   91.30%   +0.03%     
==========================================
  Files         135      135              
  Lines        5566     5588      +22     
  Branches      905      910       +5     
==========================================
+ Hits         5080     5102      +22     
  Misses        313      313              
  Partials      173      173              
Flag Coverage Δ
junifer 91.30% <100.00%> (+0.03%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
junifer/onthefly/read_transform.py 100.00% <100.00%> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
## [Codecov](https://app.codecov.io/gh/juaml/junifer/pull/429?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=juaml) Report All modified and coverable lines are covered by tests :white_check_mark: > Project coverage is 91.30%. Comparing base [(`d3fe3e6`)](https://app.codecov.io/gh/juaml/junifer/commit/d3fe3e6f33f3621bff2e7eea8d7c5f3bf144670e?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=juaml) to head [(`93205f3`)](https://app.codecov.io/gh/juaml/junifer/commit/93205f3011ea554e9e7db63e2ce3ec733283875a?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=juaml). > Report is 6 commits behind head on main. <details><summary>Additional details and impacted files</summary> [![Impacted file tree graph](https://app.codecov.io/gh/juaml/junifer/pull/429/graphs/tree.svg?width=650&height=150&src=pr&token=5H21JuZXMw&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=juaml)](https://app.codecov.io/gh/juaml/junifer/pull/429?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=juaml) ```diff @@ Coverage Diff @@ ## main #429 +/- ## ========================================== + Coverage 91.26% 91.30% +0.03% ========================================== Files 135 135 Lines 5566 5588 +22 Branches 905 910 +5 ========================================== + Hits 5080 5102 +22 Misses 313 313 Partials 173 173 ``` | [Flag](https://app.codecov.io/gh/juaml/junifer/pull/429/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=juaml) | Coverage Δ | | |---|---|---| | [junifer](https://app.codecov.io/gh/juaml/junifer/pull/429/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=juaml) | `91.30% <100.00%> (+0.03%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=juaml#carryforward-flags-in-the-pull-request-comment) to find out more. | [Files with missing lines](https://app.codecov.io/gh/juaml/junifer/pull/429?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=juaml) | Coverage Δ | | |---|---|---| | [junifer/onthefly/read\_transform.py](https://app.codecov.io/gh/juaml/junifer/pull/429?src=pr&el=tree&filepath=junifer%2Fonthefly%2Fread_transform.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=juaml#diff-anVuaWZlci9vbnRoZWZseS9yZWFkX3RyYW5zZm9ybS5weQ==) | `100.00% <100.00%> (ø)` | | </details> <details><summary> :rocket: New features to boost your workflow: </summary> - :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems. </details>
github-actions[bot] commented 2025-02-24 16:44:35 +00:00 (Migrated from github.com)
PR Preview Action v1.6.2
Preview removed because the pull request was closed.
2025-07-22 11:45 UTC
[PR Preview Action](https://github.com/rossjrw/pr-preview-action) v1.6.2 :---: Preview removed because the pull request was closed. 2025-07-22 11:45 UTC <!-- Sticky Pull Request Commentpr-preview -->
synchon (Migrated from github.com) approved these changes 2025-07-22 09:28:24 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
juaml/junifer!429
No description provided.