Skip to content

Commit

Permalink
Update classification.py
Browse files Browse the repository at this point in the history
  • Loading branch information
RunningLeon authored Sep 4, 2023
1 parent 2e00fca commit 79451d8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion mmdeploy/codebase/mmpretrain/deploy/classification.py
Original file line number Diff line number Diff line change
Expand Up @@ -332,7 +332,8 @@ def get_postprocess(self, *args, **kwargs) -> Dict:
dict: Composed of the postprocess information.
"""
postprocess = self.model_cfg.model.head
if postprocess['type'] in ('EfficientFormerClsHead', 'StackedLinearClsHead'):
if postprocess['type'] in ('EfficientFormerClsHead',
'StackedLinearClsHead'):
postprocess['type'] = 'LinearClsHead'

if 'topk' not in postprocess:
Expand Down

0 comments on commit 79451d8

Please sign in to comment.