yoloX-yoloV5-onnx-matlab
yoloX-yoloV5-onnx-matlab copied to clipboard
Problems with using own onnx
Dear Sir, I have a problem using my own onnx file. The code works fine with your model:
model = 'yolov5s_DL.onnx';
customYoloV5FcnName = 'yolov5fcn';
inputSize = [640,640];
throushHold = 0.3;
nmsThroushHold = 0.4;
outs = cell(3,1);
classesNames = categorical(readlines("coco.names"));
colors = randi(255,length(classesNames),3);
params = importONNXFunction(model,customYoloV5FcnName);
But if i use my own onnx file, exported to [480 640] I get the follwing results:
model = 'yolov5s_480_640.onnx';
customYoloV5FcnName = 'yolov5fcn';
inputSize = [480,640];
throushHold = 0.3;
nmsThroushHold = 0.4;
outs = cell(3,1);
classesNames = categorical(readlines("coco.names"));
colors = randi(255,length(classesNames),3);
params = importONNXFunction(model,customYoloV5FcnName);
Do you have an idea wether this is due to my onnx export or the Matlab implementation?
Are there factors that I have to note in my onnx export?
I also changed the subfunction, but it still works with the standart yolov5.
inputSizeX = 480; %(640 for standart)
inputSizeY = 640;
scaledX = inputSizeX./oriWidth;
scaledY = inputSizeY./oriHight;
kind regards
Hello, I also had a similar problem, after using my own trained model, a bunch of wrong recognition boxes appeared. Do you have a solution to this problem?