File tree Expand file tree Collapse file tree 3 files changed +38
-0
lines changed Expand file tree Collapse file tree 3 files changed +38
-0
lines changed Original file line number Diff line number Diff line change @@ -324,3 +324,15 @@ def main():
324324
325325if __name__ == '__main__' :
326326 main ()
327+
328+ # Following strings of text style are from colorama package
329+ bright_style , reset_style = '\x1b [1m' , '\x1b [0m'
330+ red_text , blue_text = '\x1b [31m' , '\x1b [34m'
331+ white_background = '\x1b [107m'
332+
333+ msg = white_background + bright_style + red_text
334+ msg += 'DeprecationWarning: This tool will be deprecated in future. '
335+ msg += blue_text + 'Welcome to use the unified model deployment toolbox '
336+ msg += 'MMDeploy: https://github.com/open-mmlab/mmdeploy'
337+ msg += reset_style
338+ warnings .warn (msg )
Original file line number Diff line number Diff line change 22import argparse
33import os
44import os .path as osp
5+ import warnings
56from typing import Iterable , Optional , Union
67
78import matplotlib .pyplot as plt
@@ -274,3 +275,15 @@ def parse_args():
274275 dataset = args .dataset ,
275276 workspace_size = args .workspace_size ,
276277 verbose = args .verbose )
278+
279+ # Following strings of text style are from colorama package
280+ bright_style , reset_style = '\x1b [1m' , '\x1b [0m'
281+ red_text , blue_text = '\x1b [31m' , '\x1b [34m'
282+ white_background = '\x1b [107m'
283+
284+ msg = white_background + bright_style + red_text
285+ msg += 'DeprecationWarning: This tool will be deprecated in future. '
286+ msg += blue_text + 'Welcome to use the unified model deployment toolbox '
287+ msg += 'MMDeploy: https://github.com/open-mmlab/mmdeploy'
288+ msg += reset_style
289+ warnings .warn (msg )
Original file line number Diff line number Diff line change 11# Copyright (c) OpenMMLab. All rights reserved.
22import argparse
3+ import warnings
34from functools import partial
45
56import mmcv
@@ -390,3 +391,15 @@ def parse_args():
390391 output_file = args .output_file ,
391392 verify = args .verify ,
392393 dynamic_export = args .dynamic_export )
394+
395+ # Following strings of text style are from colorama package
396+ bright_style , reset_style = '\x1b [1m' , '\x1b [0m'
397+ red_text , blue_text = '\x1b [31m' , '\x1b [34m'
398+ white_background = '\x1b [107m'
399+
400+ msg = white_background + bright_style + red_text
401+ msg += 'DeprecationWarning: This tool will be deprecated in future. '
402+ msg += blue_text + 'Welcome to use the unified model deployment toolbox '
403+ msg += 'MMDeploy: https://github.com/open-mmlab/mmdeploy'
404+ msg += reset_style
405+ warnings .warn (msg )
You can’t perform that action at this time.
0 commit comments