Skip to content

Commit

Permalink
chore: bump version to v2.0.0rc2
Browse files Browse the repository at this point in the history
  • Loading branch information
Unbinilium authored Jul 14, 2023
1 parent d907922 commit 9404e45
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion edgelab/version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
__version__ = '2.0.0rc1'
__version__ = '2.0.0rc2'
short_version = __version__


Expand Down
2 changes: 1 addition & 1 deletion requirements/mmlab.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
mmcls>=1.0.0.rc6
mmcv>=2.0.0
mmdet>=3.0.0, <3.1.0 # mmyolo currently does not support mmdet 3.1.0
mmengine>=0.7.2
mmengine>=0.8.2
mmpose>=1.0.0

mmyolo@git+https://github.com/mjq2020/mmyolo
Empty file modified scripts/test_functional.sh
100644 → 100755
Empty file.
14 changes: 7 additions & 7 deletions tools/train.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,6 @@ def build_config(args):

def main():
from mmengine.analysis import get_model_complexity_info
from mmengine.device import get_device

args = parse_args()
args = verify_args(args)
Expand All @@ -193,15 +192,16 @@ def main():

runner = RUNNERS.build(cfg)

device = get_device()
dummy_inputs = torch.randn(*args.input_shape, device=device)
model = runner.model.to(device=device)
model = runner.model.to('cpu')
model.eval()

analysis_results = get_model_complexity_info(model=model, inputs=(dummy_inputs,))
analysis_results = get_model_complexity_info(model=model, input_shape=tuple(args.input_shape[1:]))

print('Model Flops:{}'.format(analysis_results['flops_str']))
print('Model Parameters:{}'.format(analysis_results['params_str']))
print('=' * 40)
print(f"{'Input Shape':^20}:{str(args.input_shape):^20}")
print(f"{'Model Flops':^20}:{analysis_results['flops_str']:^20}")
print(f"{'Model Parameters':^20}:{analysis_results['params_str']:^20}")
print('=' * 40)

runner.train()

Expand Down

0 comments on commit 9404e45

Please sign in to comment.