Skip to content

Commit

Permalink
BC
Browse files Browse the repository at this point in the history
  • Loading branch information
dreamerlin committed Jan 27, 2021
1 parent 9923cdf commit cbfbf82
Show file tree
Hide file tree
Showing 8 changed files with 14 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@
total_epochs = 20
checkpoint_config = dict(interval=1)
workflow = [('train', 1)]
evaluation = dict(interval=1, key_indicator='[email protected]')
evaluation = dict(interval=1, save_best='[email protected]')
log_config = dict(
interval=20, hooks=[
dict(type='TextLoggerHook'),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@
total_epochs = 20
checkpoint_config = dict(interval=1)
workflow = [('train', 1)]
evaluation = dict(interval=1, key_indicator='[email protected]')
evaluation = dict(interval=1, save_best='[email protected]')
log_config = dict(
interval=20, hooks=[
dict(type='TextLoggerHook'),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@
total_epochs = 20
checkpoint_config = dict(interval=1)
workflow = [('train', 1)]
evaluation = dict(interval=1, key_indicator='[email protected]')
evaluation = dict(interval=1, save_best='[email protected]')
log_config = dict(
interval=20, hooks=[
dict(type='TextLoggerHook'),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@
total_epochs = 20
checkpoint_config = dict(interval=1)
workflow = [('train', 1)]
evaluation = dict(interval=1, key_indicator='[email protected]')
evaluation = dict(interval=1, save_best='[email protected]')
log_config = dict(
interval=20, hooks=[
dict(type='TextLoggerHook'),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@
total_epochs = 20
checkpoint_config = dict(interval=1)
workflow = [('train', 1)]
evaluation = dict(interval=1, key_indicator='[email protected]')
evaluation = dict(interval=1, save_best='[email protected]')
log_config = dict(
interval=20, hooks=[
dict(type='TextLoggerHook'),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@
total_epochs = 20
checkpoint_config = dict(interval=1)
workflow = [('train', 1)]
evaluation = dict(interval=1, key_indicator='[email protected]')
evaluation = dict(interval=1, save_best='[email protected]')
log_config = dict(
interval=20, hooks=[
dict(type='TextLoggerHook'),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@
total_epochs = 20
checkpoint_config = dict(interval=1)
workflow = [('train', 1)]
evaluation = dict(interval=1, key_indicator='[email protected]')
evaluation = dict(interval=1, save_best='[email protected]')
log_config = dict(
interval=20, hooks=[
dict(type='TextLoggerHook'),
Expand Down
7 changes: 7 additions & 0 deletions mmaction/core/evaluation/eval_hooks.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,13 @@ def __init__(self,
save_best=None,
rule=None,
**eval_kwargs):
if 'key_indicator' in eval_kwargs:
raise RuntimeError(
'"key_indicator" is deprecated, '
'you need to use "save_best" instead. '
'See https://github.com/open-mmlab/mmaction2/pull/395 for more info' # noqa: E501
)

if not isinstance(dataloader, DataLoader):
raise TypeError(f'dataloader must be a pytorch DataLoader, '
f'but got {type(dataloader)}')
Expand Down

0 comments on commit cbfbf82

Please sign in to comment.