Skip to content

Commit

Permalink
Add short form parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
PINTO0309 committed Sep 9, 2022
1 parent 1183d20 commit fa20d70
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 10 deletions.
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,30 +24,30 @@ $ pip install -U onnx \
https://github.com/PINTO0309/simple-onnx-processing-tools#docker

## 2. CLI Usage
```bash
```
$ soc4onnx -h
usage:
soc4onnx [-h]
--input_onnx_file_path INPUT_ONNX_FILE_PATH
--output_onnx_file_path OUTPUT_ONNX_FILE_PATH
--opset OPSET
[--non_verbose]
-if INPUT_ONNX_FILE_PATH
-of OUTPUT_ONNX_FILE_PATH
-os OPSET
[-n]
optional arguments:
-h, --help
show this help message and exit
--input_onnx_file_path INPUT_ONNX_FILE_PATH
-if INPUT_ONNX_FILE_PATH, --input_onnx_file_path INPUT_ONNX_FILE_PATH
Input onnx file path.
--output_onnx_file_path OUTPUT_ONNX_FILE_PATH
-of OUTPUT_ONNX_FILE_PATH, --output_onnx_file_path OUTPUT_ONNX_FILE_PATH
Output onnx file path.
--opset OPSET
-os OPSET, --opset OPSET
opset number to be changed. e.g. --opset 11
--non_verbose
-n, --non_verbose
Do not show all information logs. Only error logs are displayed.
```

Expand Down
2 changes: 1 addition & 1 deletion soc4onnx/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
from soc4onnx.onnx_opset_change import change, main

__version__ = '1.0.1'
__version__ = '1.0.2'
4 changes: 4 additions & 0 deletions soc4onnx/onnx_opset_change.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,18 +118,21 @@ def change(
def main():
parser = ArgumentParser()
parser.add_argument(
'-if',
'--input_onnx_file_path',
type=str,
required=True,
help='Input onnx file path.'
)
parser.add_argument(
'-of',
'--output_onnx_file_path',
type=str,
required=True,
help='Output onnx file path.'
)
parser.add_argument(
'-os',
'--opset',
type=int,
required=True,
Expand All @@ -138,6 +141,7 @@ def main():
'e.g. --opset 11'
)
parser.add_argument(
'-n',
'--non_verbose',
action='store_true',
help='Do not show all information logs. Only error logs are displayed.'
Expand Down

0 comments on commit fa20d70

Please sign in to comment.