--json
Applicability
Product |
Supported |
|---|---|
√ |
|
√ |
|
√ |
|
√ |
|
√ |
Description
Sets the directory (including the file name) of the JSON file converted from an offline model, an original model file, or a dumped GE graph.
The JSON file converted from an offline model also records the versions of the infrastructure software such as ATC and OPP as well as the ATC commands used during model conversion.
See Also
- To convert an offline model into a JSON file:
- To convert an original model into a JSON file:
Use this option in conjunction with --mode = 1, --om, and --framework.
If the original model uses the MindSpore framework, that is, --framework is set to 1, conversion to JSON files is not supported.
- To convert a GE dump graph into a JSON file:
Use this option in conjunction with --mode = 5 and --om.
Only the dumped ge_proto*.txt file can be converted into a JSON file.
Argument
Argument: Directory (including the file name) of the JSON file.
Format: The directory (including the file name) can contain letters, digits, underscores (_), hyphens (-), periods (.), and Chinese characters.
Suggestions and Benefits
None
Example
- To convert an offline model into a JSON file:
--mode=1 --om=$HOME/module/out/tf_resnet50.om --json=$HOME/module/out/tf_resnet50.json
- To convert an original model into a JSON file:
--mode=1 --om=$HOME/module/resnet50_tensorflow*.pb --json=$HOME/module/out/tf_resnet50.json --framework=3
- To convert a GE dump graph into a JSON file:
--mode=5 --om=$HOME/module/ge_proto_00000000_PreRunBegin.txt --json=$HOME/module/out/ge_proto.json
Dependencies and Restrictions
None