Using yolov8-seg.onnx
provided by a forum user, and the following conversion command, I can get the correct result. I use the newer version of TRT-10.10, so this is not a problem.
/usr/src/tensorrt/bin/trtexec --fp16 --onnx=yolov8s-seg.onnx --saveEngine=yolov8s-seg.engine --minShapes=input:1x3x640x640 --optShapes=input:4x3x640x640 --maxShapes=input:4x3x640x640 --shapes=input:4x3x640x640