Closed HiaHong closed 9 months ago
预处理决定了最终输入给模型的数据大小,默认情况下是640,640. 如若你是1280, 1280,那么需要修改预处理参数,可使用如下方式
model = fd.vision.detection.YOLOv5()
model.preprocessor.size = [1280, 1280]
C++部署 CPU版本的 yolov5face imgsize在哪改啊,没找到图像预处理的源码/(ㄒoㄒ)/~~
@lhh753159 试试如下代码
auto model = fastdeploy::vision::facedet::YOLOv5Face(model_file, "", option);
model.size = {width, height};
此ISSUE由于一年未更新,将会关闭处理,如有需要,可再次更新打开。
[FastDeploy][INFO]: Successfully found CUDA ToolKit from system PATH env -> C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.6\bin [INFO] fastdeploy/runtime.cc(528)::fastdeploy::Runtime::Init Runtime initialized with Backend::OPENVINO in Device::CPU. Traceback (most recent call last): File "d:/AHONG_Space/AHONG/mytools/rcnnOKgpu copy.py", line 40, in <module> result = model.predict(img_array) File "D:\anaconda3\envs\paddleX\lib\site-packages\fastdeploy\vision\detection\contrib\yolov5.py", line 154, in predict return self._model.predict(input_image) RuntimeError: Can't set input blob with name: images, because model input (shape={1,3,1280,1280}) and blob (shape=(1.3.640.640)) are incompatible
默认640就可以正常运行