Skip to content

Loop cleanup and scikit-learn style parameters #146

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

Open
wants to merge 2 commits into
base: john-development
Choose a base branch
from

Conversation

john-halloran
Copy link

No description provided.

@john-halloran john-halloran changed the base branch from main to john-development April 26, 2025 23:08
Copy link

Warning! No news item is found for this PR. If this is a user-facing change/feature/fix,
please add a news item by copying the format from news/TEMPLATE.rst.
For best practices, please visit
https://billingegroup.github.io/scikit-package/frequently-asked-questions.html#billinge-group-standards.

Copy link

codecov bot commented Apr 26, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Please upload report for BASE (john-development@156511e). Learn more about missing BASE report.

Additional details and impacted files
@@                 Coverage Diff                 @@
##             john-development     #146   +/-   ##
===================================================
  Coverage                    ?   91.96%           
===================================================
  Files                       ?        7           
  Lines                       ?      112           
  Branches                    ?        0           
===================================================
  Hits                        ?      103           
  Misses                      ?        9           
  Partials                    ?        0           
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@sbillinge
Copy link
Contributor

@john-halloran I am not paying close attention to this. Could you maybe share what you want me to do? Give feedback? Merge ? Some words about the intent of the PR would be helpful. The title is good and makes sense, but is a bit vague as this seems to be the goal of a much larger refactor than will happen only a single PR

@john-halloran
Copy link
Author

Yes, of course. The goal of this PR is to move the sNMF implementation away from the original, specific style into one that is more general and better aligned with scikit-learn. It is not a full alignment with scikit-learn, of course, but it does do the following:

  • We no longer use any dependencies other than those scikit-learn uses (all optimization moved to scipy)
  • More steps are handled off-the-shelf instead of explicitly coded
  • We no longer iterate in a bespoke order (Ran confirmed this was only done for minor, performance reasons)
  • "tol" is a user parameter just like in scikit-learn, as is "max_iter" and "components"
    We can discuss more when we meet soon, but my hope was that you'd just merge for now unless you have critical feedback. This is the build I'm planning to use for my final project as well.

@sbillinge
Copy link
Contributor

so a general comment is that this looks like at least four PRs are needed, not just one. As we move away from your massive (and beautifully executed) code translation job to more functional code, we want to move to very small granular PRs that only do one thing at a time.

@john-halloran
Copy link
Author

Understood. With that in mind for the future, do you think it's okay to merge this one, this once? If not, I'd be happy to go back and granulate the changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants