senwu / emmental

A deep learning framework for building multimodal multi-task learning systems.
https://emmental.readthedocs.io
MIT License
109 stars 18 forks source link

Refactor the import and support checkpoint optimizer and lr_scheduler state #93

Closed senwu closed 3 years ago

senwu commented 3 years ago

Description of the problems or issues

The current Emmental cannot checkpoint optimizer and lr_scheduler state.

Description of the proposed changes

Support checkpoint optimizer and lr_scheduler state

Checklist

codecov[bot] commented 3 years ago

Codecov Report

Merging #93 (22231cb) into master (06657d8) will decrease coverage by 1.85%. The diff coverage is 71.27%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #93      +/-   ##
==========================================
- Coverage   88.09%   86.24%   -1.86%     
==========================================
  Files          38       39       +1     
  Lines        1798     1883      +85     
  Branches      389      406      +17     
==========================================
+ Hits         1584     1624      +40     
- Misses        108      147      +39     
- Partials      106      112       +6     
Flag Coverage Δ
unittests 86.24% <71.27%> (-1.86%) :arrow_down:

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

Impacted Files Coverage Δ
setup.py 0.00% <ø> (ø)
src/emmental/logging/logging_manager.py 86.53% <30.00%> (-13.47%) :arrow_down:
src/emmental/learner.py 70.27% <50.00%> (-5.80%) :arrow_down:
src/emmental/utils/seed.py 82.60% <82.60%> (ø)
src/emmental/model.py 82.58% <93.10%> (+0.15%) :arrow_up:
src/emmental/__init__.py 100.00% <100.00%> (ø)
src/emmental/_version.py 100.00% <100.00%> (ø)
src/emmental/logging/checkpointer.py 88.57% <100.00%> (+0.33%) :arrow_up:
src/emmental/meta.py 79.31% <100.00%> (-0.69%) :arrow_down:
src/emmental/metrics/accuracy_f1.py 100.00% <100.00%> (ø)
... and 8 more