dsgibbons / shap

A game theoretic approach to explain the output of any machine learning model.
https://shap-community.readthedocs.io/en/latest/
MIT License
25 stars 5 forks source link

chore: make convert_color ruff compliant and add test #96

Closed dsgibbons closed 1 year ago

dsgibbons commented 1 year ago

Following on from #54, this PR provides fixes for future ruff rules BLE001 (blanket exception catching) and S110 (try-except-pass). This PR also provides a test case to illustrate the purpose of convert_color. This test is probably a bit redundant, but good for extending coverage at least.

codecov[bot] commented 1 year ago

Codecov Report

Merging #96 (d60a06b) into master (14c76da) will increase coverage by 0.06%. The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master      #96      +/-   ##
==========================================
+ Coverage   53.58%   53.65%   +0.06%     
==========================================
  Files          90       90              
  Lines       12982    12981       -1     
==========================================
+ Hits         6957     6965       +8     
+ Misses       6025     6016       -9     
Impacted Files Coverage Δ
shap/plots/_utils.py 18.66% <100.00%> (+5.42%) :arrow_up:

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more