Default Avatar

Eric Wu

Eric Wu

About

Username
Eric Wu
Joined
Visits
254
Last Active
Roles
Member, ModeratorsAIModel

Comments

  • 建議可以先確認訓練過程中的log數據皆正常合理, 如果出現不合理的log數據, 可以根據log數據中的發現, 對相應的訓練參數做嘗試與修改(加大訓練數據, 修正數據, 加大epoch ... etc).
  • Hi Shih-Hsin Chen, 目前tool chain並沒有直接支援tensorflow.js的格式, 但我相信有許多第三方套件可以幫忙轉換你的tensorflow.js格式. 轉成onnx, tflite...etc 之後, 即可使用tool chain繼續.
  • @Jasmine 您提供的指令(compilerIpevaluator_720.sh) 與 圖片中的指令(fpAnalyserBatchCompile_720.py)貌似不太一樣, 您可能要在再確認一下. 我這邊嘗試使用 tftargetcut_v2_opt 做 fpAnalyserBatchCompile_720.py 與 compilerIpevaluator_720.sh 都可以正常執行. …
  • 關於 "該如何得知"輸出output node"為正確": 可以依照自己對這個模型的了解,以及接下來要做的事 (inference時, 沒轉出來的部分會需要以其他方式實現),  轉出來的model如果沒有你要的operator或與想像的不同(e.g. model size太小), 就是設定錯誤了…
  • @Jasmine 輸出output node時必須要設定正確, 除此之外, 這邊有一點tricky, 由於tensorflow輸出的model要做export時有時候會把常見的operator拆成奇怪的operator, 建議先把模型輸出的tflite後在做轉換會比較容易(tf官方有提供api做轉換, 且會處裡這些奇怪的opera…
  • Hi Jasmine, tensorflow 1.15.0應該可以使用 要找到node name, 用tensorboard可以, 或是直接印出來也可以:  https://stackoverflow.com/questions/36883949/in-tensorflow-get-the-names-of-all-the-tensors-in-a-graph
  • Hi Fred, 文章(https://www.kneron.com/forum/discussion/53/legacy-v0-12-example-keras-kl520-how-to-convert-and-compile-tiny-yolo-v3-from-github-project#latest) 是示範一個例子如何將github上的開源軟體中的pretrain model轉換成nef. 你在訓練時發生錯誤有可…
  • Hi Fred, 模型認不到物件可能原因有很多, bad training, input data, preprocess code,  postprocess code, quantization ... etc 建議先確認你的原始h5模型可以正確認出物件. 原始repository( keras-yolo3 )中應有對應的資源. 再驗證與onnx轉換正確可以正確認出物件.…
  • Hi 夏英杰, 我猜可能是環境中的onnx版本不正確. 請確認環境中onnx的版本, 目前主要使用onnx==1.6. https://github.com/kneron/ONNX_Convertor#introduction 新版本的onnx已經移除optimizer模組: https://github.com/onnx/onnx/releases/tag/v1.9.0
  • Hi mint, your onnx need some modification, https://www.kneron.com/forum/uploads/158/CXF0CTWTJ9A4.png Our kl520 could not support Transpose node, you need to remove it. Our toolchain need input shape and all feature map shape information, "?&q…
  • Hi 楊堯順, 方便提供下列項目: failed onnx model 可以重置toolchain問題的python script toolchain version 以利我們定位錯誤原因嗎? thanks.
  • https://www.kneron.com/forum/discussion/comment/301#Comment_301 Hi Raef Youssef, Yes, we train yolov5s and yolov5s_noupsample with focus layer(slice version). Only do convolution layer substitute when doing exporting to onnx for KL520.
  • Hi Raef Youssef, the "model_training" document is for the script in "/workspace/ai_training" (folder path in toolchain:v0.14.2). And, in order to port focus layer to kl520, we use a "conv" instead of those "slice…
  • Hi ChiYu, seems that your exported onnx is invalid, you can check your onnx with official onnx api as following: import onnx import onnx.shape_inference m = onnx.load('/data1/retina.onnx') onnx.checker.check_model(m) onnx.shape_inference.infer_s…
  • https://www.kneron.com/forum/discussion/comment/284#Comment_284 Hi Raef Youssef, Yes, you can use relu6, but you can't multiply it by variable x because kl520 can't support "MUL" operator. for removing the preprocessing layer, currently …
  • https://www.kneron.com/forum/discussion/comment/282#Comment_282 Hey Raef Youssef, Yes, KL520 support ReLU6 using Clip. Some operators in different deep learning framework have different name even though they have same behavior. And, onnx doesn't h…
  • Hi @Tim Gilmanov , What toolchain version you use? the converted onnx you provided seems not match to our latest toolchain (v0.14): yours: https://www.kneron.com/forum/uploads/685/PTKZEYV1K0IS.png expected: https://www.kneron.com/forum/uploads/50…
  • Hello 林韋銘: to learn the python api usage, you can check the python api document: http://doc.kn eron.com/docs/#toolchain/python_api/ chapter 3. Inferencer and the real world case(yolo) tutorial: http://doc.kneron.com/docs/#toolchain/yolo_e…
  • https://www.kneron.com/forum/discussion/comment/267#Comment_267 Hi Ellen, 看起來是在post_process (yolo_eval) 的部分出問題, 請問你有試過在keras可以成功inference嗎? 你更改了模型參數, 可能跟tutorial的設置的參數不符, 需要根據你的需求作修改. 建議先確認…
  • Hi Raef Youssef, there are several operators are not supported by kl520 in your yolo-v5, you can check the document (chapter 2.3 supported operators): http://doc.kneron.com/docs/#toolchain/manual/ if you want to port this yolo-v5 to kl520, you …
  • Hi Ellen, 你的model含有Lambda layer, 我們並不支援這個type的轉換, 必須想辦法拿掉這個layer. 修改source code是一個方法, 可以參考tutorial中step 5 (remove redundant layer): https://www.kneron.com/forum/discussion/53/legacy-v0-12-example-keras-kl520-how…
  • https://www.kneron.com/forum/discussion/85/tflite-model-migration Hi Raef Youssef, It's error comes from tflite intepreter while loading model, I guess there is a tensorflow version mismatch issue while convert tensorflow model to tflite model, Co…
  • https://www.kneron.com/forum/discussion/comment/232#Comment_232 Hi Raef Youssef, this is the issue comes from the changing of opset 9 to 11. when doing "torch.onnx.export" using opset_version=11, the torch give us the model with extra br…
  • Hi francisco soto, I saw there is "auto_pad" attribute in every convolution layer in the model you provided, https://www.kneron.com/forum/uploads/034/YSBBM29NUCD8.png I have some experience about a bug comes from onnx builtin function du…
  • https://www.kneron.com/forum/discussion/comment/209#Comment_209 Hi Ellen, train_weights_final.h5跟yolov3-tiny.weights是不同的東西, train_weights_final.h5是keras格式的weight file. 使用netron查看的話看起來像這樣: https://www.kneron.com/forum/uploads/…
  • Hi Phidias, Really thanks your post, we will fix this bug in next release.
  • https://www.kneron.com/forum/discussion/comment/200#Comment_200 Hi Ic.Wang, For the "/data1/images" I lost my calibration data in this case, so I do that again with the following dataset. It's still work. The dataset is picked from VOC 20…
  • Just want to share a tricky way to convert, In this case, I tried to downgrade the torch version to match the required ir version in kneron/toolchain:520_v0.12.0 ( onnx: 1.4.1 ir_version: 4), but, I got model loading issue with low torch version …
  • https://www.kneron.com/forum/discussion/comment/150#Comment_150 Hi @Raef Youssef, I found there is a mistake in the export_tiny.py, we have to change the anchor and classes information file: https://www.kneron.com/forum/uploads/615/5UQN38T7UQO2.png …
  • https://www.kneron.com/forum/discussion/comment/139#Comment_139 Hi @Raef Youssef , For the cpu node implementation, Sorry, I don't know the detail about this. Someone who know this part might reply this here. But for the upsampling layer, The up…