forked from open-mmlab/mmpose
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Feature] Support New config type (open-mmlab#2463)
- Loading branch information
Showing
35 changed files
with
1,133 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
# Copyright (c) OpenMMLab. All rights reserved. | ||
from mmengine.hooks import (CheckpointHook, DistSamplerSeedHook, IterTimerHook, | ||
LoggerHook, ParamSchedulerHook, SyncBuffersHook) | ||
from mmengine.runner import LogProcessor | ||
from mmengine.visualization import LocalVisBackend | ||
|
||
from mmpose.engine.hooks import PoseVisualizationHook | ||
from mmpose.visualization import PoseLocalVisualizer | ||
|
||
default_scope = None | ||
|
||
# hooks | ||
default_hooks = dict( | ||
timer=dict(type=IterTimerHook), | ||
logger=dict(type=LoggerHook, interval=50), | ||
param_scheduler=dict(type=ParamSchedulerHook), | ||
checkpoint=dict(type=CheckpointHook, interval=10), | ||
sampler_seed=dict(type=DistSamplerSeedHook), | ||
visualization=dict(type=PoseVisualizationHook, enable=False), | ||
) | ||
|
||
# custom hooks | ||
custom_hooks = [ | ||
# Synchronize model buffers such as running_mean and running_var in BN | ||
# at the end of each epoch | ||
dict(type=SyncBuffersHook) | ||
] | ||
|
||
# multi-processing backend | ||
env_cfg = dict( | ||
cudnn_benchmark=False, | ||
mp_cfg=dict(mp_start_method='fork', opencv_num_threads=0), | ||
dist_cfg=dict(backend='nccl'), | ||
) | ||
|
||
# visualizer | ||
vis_backends = [dict(type=LocalVisBackend)] | ||
visualizer = dict( | ||
type=PoseLocalVisualizer, vis_backends=vis_backends, name='visualizer') | ||
|
||
# logger | ||
log_processor = dict( | ||
type=LogProcessor, window_size=50, by_epoch=True, num_digits=6) | ||
log_level = 'INFO' | ||
load_from = None | ||
resume = False | ||
|
||
# file I/O backend | ||
backend_args = dict(backend='local') | ||
|
||
# training/validation/testing progress | ||
train_cfg = dict(by_epoch=True) | ||
val_cfg = dict() | ||
test_cfg = dict() |
Oops, something went wrong.