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

PSMList: Use np.fromiter when using a string as accessor (e.g. psm_list["peptidoform"]) #102

Merged
merged 3 commits into from
Nov 19, 2024

Conversation

RalfG
Copy link
Member

@RalfG RalfG commented Oct 23, 2024

Changed

  • When returning a PSM property across the full PSMList (e.g. psm_list["peptidoform"]), np.fromiter is now used instead of np.array. This fixes an issue where if all peptidoforms have the same length, a 3D array of parsed sequences (amino acids and modifications) was be returned instead of an array of Peptidoform object. However, this does mean that all resulting arrays will have the object dtype instead of the previously coerced dtypes. This might lead to issues downstream.

RalfG added 2 commits October 23, 2024 16:24
…f amino acids and modifications if all peptidoforms have the same length
@RalfG RalfG added the enhancement Improvement of an existing feature label Oct 23, 2024
Copy link

codecov bot commented Oct 23, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 67.66%. Comparing base (b0fb411) to head (0d47b14).
Report is 29 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #102      +/-   ##
==========================================
+ Coverage   67.63%   67.66%   +0.03%     
==========================================
  Files          27       27              
  Lines        2629     2626       -3     
==========================================
- Hits         1778     1777       -1     
+ Misses        851      849       -2     
Flag Coverage Δ
unittests 67.66% <100.00%> (+0.03%) ⬆️

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

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


🚨 Try these New Features:

@RalfG RalfG requested a review from paretje November 5, 2024 13:08
@RalfG RalfG added this to the v1.2.0 milestone Nov 18, 2024
@RalfG RalfG merged commit 22c7d7e into main Nov 19, 2024
7 checks passed
@RalfG RalfG deleted the fix/from-iter branch November 19, 2024 17:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Improvement of an existing feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant