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

Bugfix: reset should set clear _computed #147

Merged
merged 3 commits into from
Mar 29, 2021

Conversation

maximsch2
Copy link
Contributor

Fixing a small bug - reset not clearing computed cache value.

Before submitting

  • Was this discussed/approved via a Github issue? (no need for typos and docs improvements)
  • Did you read the contributor guideline, Pull Request section?
  • Did you make sure to update the docs?
  • Did you write any new necessary tests?

Did you have fun?

Make sure you had fun coding 🙃

@codecov
Copy link

codecov bot commented Mar 29, 2021

Codecov Report

Merging #147 (9139356) into master (3d08235) will increase coverage by 0.00%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master     #147     +/-   ##
=========================================
  Coverage   96.76%   96.76%             
=========================================
  Files         156       78     -78     
  Lines        4824     2413   -2411     
=========================================
- Hits         4668     2335   -2333     
+ Misses        156       78     -78     
Flag Coverage Δ
Linux 79.27% <100.00%> (+<0.01%) ⬆️
Windows 79.27% <100.00%> (+<0.01%) ⬆️
cpu 96.76% <100.00%> (+<0.01%) ⬆️
gpu ?
macOS 96.76% <100.00%> (+<0.01%) ⬆️
pytest 96.76% <100.00%> (+<0.01%) ⬆️
python3.6 96.76% <100.00%> (+<0.01%) ⬆️
python3.8 96.76% <100.00%> (+<0.01%) ⬆️
python3.9 96.76% <100.00%> (+<0.01%) ⬆️
torch1.3.1 95.55% <100.00%> (+<0.01%) ⬆️
torch1.4.0 95.69% <100.00%> (+<0.01%) ⬆️
torch1.8.1 96.76% <100.00%> (+<0.01%) ⬆️

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

Impacted Files Coverage Δ
torchmetrics/metric.py 95.07% <100.00%> (+0.01%) ⬆️
__w/1/s/torchmetrics/retrieval/retrieval_metric.py
...s/torchmetrics/functional/classification/f_beta.py
...rics/functional/classification/hamming_distance.py
...1/s/torchmetrics/functional/retrieval/precision.py
__w/1/s/torchmetrics/regression/psnr.py
.../s/torchmetrics/classification/hamming_distance.py
.../1/s/torchmetrics/functional/classification/roc.py
...chmetrics/functional/classification/stat_scores.py
...1/s/torchmetrics/regression/mean_absolute_error.py
... and 69 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3d08235...9139356. Read the comment docs.

CHANGELOG.md Outdated Show resolved Hide resolved
@SkafteNicki SkafteNicki added ready bug / fix Something isn't working labels Mar 29, 2021
@maximsch2
Copy link
Contributor Author

While we are on this, should we reset _forward_cache as well?

@SkafteNicki
Copy link
Member

While we are on this, should we reset _forward_cache as well?

Fine by me :]

@Borda Borda merged commit 19b77cc into Lightning-AI:master Mar 29, 2021
@maximsch2 maximsch2 deleted the fix_reset branch March 29, 2021 21:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug / fix Something isn't working ready
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants