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

πŸ’š:bug::snake: Fix bug for 0 passing predictions #341

Merged
merged 6 commits into from
Aug 24, 2023
Merged

Conversation

evanroyrees
Copy link
Collaborator

πŸ’šβ¬†οΈ Pin scikit-learn to >=1.3
🐍🎨 Replace conda commands with mamba in Makefile
πŸ”₯⬇️ Remove hdbscan (now available in scikit-learn >= 1.3)

HDBSCAN has been failing in pytests and this seems to be an artifact of hdbscan being integrated into scikit-learn.

Some of these issues have cropped up in the past few weeks (scikit-learn-contrib/hdbscan#600).

scikit-learn is now pinned to >=1.3 as this is the earliest release of HDBSCAN being available via sklearn.cluster.HDBSCAN

The run_hdscan function has now been updated according to the API that was adopted in the sklearn library.

PR checklist

  • This comment contains a description of changes (with reason).
  • If you've fixed a bug or added code that should be tested, add tests!
  • Have you followed the pipeline conventions in the contribution docs

πŸ’šβ¬†οΈ Pin scikit-learn to >=1.3
:snake::art: Replace conda commands with mamba in Makefile
:fire::arrow_down: Remove hdbscan (now available in scikit-learn >= 1.3)
@evanroyrees evanroyrees added bug Something isn't working python Python related issues/code continuous integration Relating to continuously updating Autometa integrations labels Aug 23, 2023
@evanroyrees evanroyrees requested a review from Sidduppal August 23, 2023 18:54
@evanroyrees evanroyrees linked an issue Aug 23, 2023 that may be closed by this pull request
@codecov
Copy link

codecov bot commented Aug 23, 2023

Codecov Report

Patch coverage: 30.66% and project coverage change: -0.29% ⚠️

Comparison is base (6637426) 27.59% compared to head (bc34fae) 27.31%.
Report is 46 commits behind head on dev.

Additional details and impacted files
@@            Coverage Diff             @@
##              dev     #341      +/-   ##
==========================================
- Coverage   27.59%   27.31%   -0.29%     
==========================================
  Files          45       50       +5     
  Lines        5349     5730     +381     
==========================================
+ Hits         1476     1565      +89     
- Misses       3873     4165     +292     
Flag Coverage Ξ”
unittests 27.31% <30.66%> (-0.29%) ⬇️

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

Files Changed Coverage Ξ”
autometa/binning/large_data_mode.py 0.00% <0.00%> (ΓΈ)
autometa/config/databases.py 0.00% <0.00%> (ΓΈ)
autometa/config/utilities.py 25.00% <ΓΈ> (ΓΈ)
autometa/validation/benchmark.py 0.00% <0.00%> (ΓΈ)
autometa/validation/cami.py 0.00% <0.00%> (ΓΈ)
autometa/taxonomy/majority_vote.py 13.53% <11.53%> (+0.83%) ⬆️
autometa/binning/summary.py 41.48% <18.18%> (-0.38%) ⬇️
autometa/taxonomy/lca.py 9.37% <19.04%> (+0.57%) ⬆️
autometa/taxonomy/gtdb.py 21.01% <21.01%> (ΓΈ)
autometa/common/utilities.py 23.35% <37.50%> (+0.65%) ⬆️
... and 11 more

β˜” View full report in Codecov by Sentry.
πŸ“’ Have feedback on the report? Share it here.

Copy link
Member

@chasemc chasemc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems like the test coverage for the code is good so assuming the tests are good then the changes are fine and seem to fix the builds. Should get another pair of eyes to look but seems good

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code is fine. Going to need to search and replace mamba/conda in the Docs though

@chasemc
Copy link
Member

chasemc commented Aug 23, 2023

May need to look at hdbscan in tests
e.g.

Copy link
Collaborator

@Sidduppal Sidduppal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, minor comments:

  • What happens if the user has conda but not mamba? I created an environment without mamba and the installation was using (PYTHON_INTERPRETER) -m pip install -q virtualenv virtualenvwrapper. So maybe specify in the docs or somewhere to install mamba if the user needs the advantage conda offers.
  • On the environment with mamba the installation worked well πŸ‘πŸΌ
  • As @chasemc mentioned, update the docs telling user to use mamba and change scikit-learn in tests/environment.yml
  • I didn't try running clustering using hdbscan but I assume it should work as the tests are passing.

πŸ”₯ Remove virtualenv commands from Makefile
resolves #331
@evanroyrees evanroyrees merged commit 04b2926 into dev Aug 24, 2023
@evanroyrees evanroyrees deleted the issue-327 branch August 24, 2023 21:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working continuous integration Relating to continuously updating Autometa integrations python Python related issues/code
Projects
None yet
3 participants