ggirelli / radiantkit

A Python3 Radial Image Analysis Toolkit
https://ggirelli.github.io/radiantkit/
MIT License
3 stars 4 forks source link

Argparser to Click switch #204

Open ggirelli opened 3 years ago

sourcery-ai[bot] commented 2 years ago

Sourcery Code Quality Report

✅  Merging this PR will increase code quality in the affected files by 0.96%.

Quality metrics Before After Change
Complexity 2.79 ⭐ 2.74 ⭐ -0.05 👍
Method Length 46.53 ⭐ 43.53 ⭐ -3.00 👍
Working memory 7.85 🙂 7.78 🙂 -0.07 👍
Quality 76.08% 77.04% 0.96% 👍
Other metrics Before After Change
Lines 6073 4692 -1381
Changed files Quality Before Quality After Quality Change
radiantkit/init.py 88.33% ⭐ 96.01% ⭐ 7.68% 👍
radiantkit/argtools.py 91.62% ⭐ 91.62% ⭐ 0.00%
radiantkit/channel.py 85.31% ⭐ 85.56% ⭐ 0.25% 👍
radiantkit/const.py 93.86% ⭐ 87.69% ⭐ -6.17% 👎
radiantkit/conversion.py 84.15% ⭐ 83.05% ⭐ -1.10% 👎
radiantkit/deconvolution.py 70.13% 🙂 72.46% 🙂 2.33% 👍
radiantkit/distance.py 83.94% ⭐ 83.94% ⭐ 0.00%
radiantkit/image.py 79.00% ⭐ 79.17% ⭐ 0.17% 👍
radiantkit/io.py 76.78% ⭐ 76.78% ⭐ 0.00%
radiantkit/output.py 89.16% ⭐ 89.40% ⭐ 0.24% 👍
radiantkit/particle.py 81.48% ⭐ 81.78% ⭐ 0.30% 👍
radiantkit/path.py 78.59% ⭐ 78.89% ⭐ 0.30% 👍
radiantkit/plot.py 53.33% 🙂 53.33% 🙂 0.00%
radiantkit/report.py 77.30% ⭐ 77.56% ⭐ 0.26% 👍
radiantkit/segmentation.py 83.43% ⭐ 83.43% ⭐ 0.00%
radiantkit/selection.py 91.84% ⭐ 91.84% ⭐ 0.00%
radiantkit/series.py 69.96% 🙂 69.93% 🙂 -0.03% 👎
radiantkit/stat.py 73.05% 🙂 73.29% 🙂 0.24% 👍
radiantkit/string.py 79.71% ⭐ 81.15% ⭐ 1.44% 👍
radiantkit/scripts/init.py 83.05% ⭐ 80.00% ⭐ -3.05% 👎
radiantkit/scripts/radiant.py 71.89% 🙂 94.61% ⭐ 22.72% 👍
radiantkit/scripts/report.py 78.80% ⭐ 94.05% ⭐ 15.25% 👍

Here are some functions in these files that still need a tune-up:

File Function Complexity Length Working Memory Quality Recommendation
radiantkit/plot.py ProfileMultiCondition.__make_panel 9 🙂 210 ⛔ 25 ⛔ 34.41% 😞 Try splitting into smaller methods. Extract out complex expressions
radiantkit/series.py SeriesList.get_particle_single_px_stats 9 🙂 242 ⛔ 16 ⛔ 37.91% 😞 Try splitting into smaller methods. Extract out complex expressions
radiantkit/plot.py ProfileMultiConditionNorm.__make_panel 9 🙂 160 😞 21 ⛔ 40.25% 😞 Try splitting into smaller methods. Extract out complex expressions
radiantkit/plot.py ProfileSingleCondition.__make_scatter_trace 1 ⭐ 240 ⛔ 21 ⛔ 41.95% 😞 Try splitting into smaller methods. Extract out complex expressions
radiantkit/plot.py ProfileMultiCondition.__make_scatter_trace 1 ⭐ 250 ⛔ 20 ⛔ 42.00% 😞 Try splitting into smaller methods. Extract out complex expressions

Legend and Explanation

The emojis denote the absolute quality of the code:

The 👍 and 👎 indicate whether the quality has improved or gotten worse with this pull request.


Please see our documentation here for details on how these metrics are calculated.

We are actively working on this report - lots more documentation and extra metrics to come!

Help us improve this quality report!