mirror of
https://github.com/Ascend/ascend_community_projects.git
synced 2025-10-05 15:56:59 +08:00
update HelmetIdentification_V2/model/act-env.sh.
Signed-off-by: 叶生 <2930043128@qq.com>
This commit is contained in:
@@ -0,0 +1,14 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# This is used to convert onnx model file to .om model file.
|
||||||
|
export install_path=/usr/local/Ascend/ascend-toolkit/latest
|
||||||
|
export PATH=/usr/local/python3.9.2/bin:${install_path}/arm64-linux/atc/ccec_compiler/bin:${install_path}/arm64-linux/atc/bin:$PATH
|
||||||
|
export PYTHONPATH=${install_path}/arm64-linux/atc/python/site-packages:${install_path}/arm64-linux/atc/python/site-packages/auto_tune.egg/auto_tune:${install_path}/arm64-linux/atc/python/site-packages/schedule_search.egg
|
||||||
|
export LD_LIBRARY_PATH=${install_path}/arm64-linux/atc/lib64:$LD_LIBRARY_PATH
|
||||||
|
export ASCEND_OPP_PATH=${install_path}/opp
|
||||||
|
export Home="./path/"
|
||||||
|
# Home is set to the path where the model is located
|
||||||
|
|
||||||
|
# Execute, transform YOLOv5 model.
|
||||||
|
atc --model="${Home}"/YOLOv5_s.onnx --framework=5 --output="${Home}"/YOLOv5_s --insert_op_conf=./aipp_YOLOv5.config --input_format=NCHW --log=info --soc_version=Ascend310 --input_shape="images:1,3,640,640"
|
||||||
|
# --model is the path where onnx is located. --output is the path where the output of the converted model is located
|
Reference in New Issue
Block a user