Skip to content

Commit

Permalink
[Feature] Support unroll with MMDDP in darts algorithm (#210)
Browse files Browse the repository at this point in the history
* support unroll in darts

* fix bugs in optimizer; add docstring

* update darts algorithm [untested]

* modify autograd.grad to optim_wrapper.backward

* add amp in train.py; support constructor

* rename mmcls.data to mmcls.structures

* modify darts algo to support apex [not done]

* fix code spell in diff_mutable_module

* modify optim_context of dartsddp

* add testcase for dartsddp

* fix bugs of apex in dartsddp

* standardized the unittest of darts

* adapt new data_preprocessor

* fix ut bugs

* remove unness code

Co-authored-by: gaoyang07 <1546308416@qq.com>
  • Loading branch information
pprp and gaoyang07 authored Oct 14, 2022
1 parent 0409adc commit dd51ab8
Show file tree
Hide file tree
Showing 6 changed files with 612 additions and 54 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,11 @@
_delete_=True,
constructor='mmrazor.SeparateOptimWrapperConstructor',
architecture=dict(
type='OptimWrapper',
optimizer=dict(type='SGD', lr=0.025, momentum=0.9, weight_decay=3e-4),
clip_grad=dict(max_norm=5, norm_type=2)),
mutator=dict(optimizer=dict(type='Adam', lr=3e-4, weight_decay=1e-3)))
mutator=dict(
type='OptimWrapper',
optimizer=dict(type='Adam', lr=3e-4, weight_decay=1e-3)))

find_unused_parameter = False
Loading

0 comments on commit dd51ab8

Please sign in to comment.