|
登录后更精彩...O(∩_∩)O...
您需要 登录 才可以下载或查看,没有账号?立即注册
×
yolo如何导出.weights和.cfg
各位老师好,最近新接触一个opencv库中的函数cv::dnn::readnet()函数; 参数1是yolo训练好的模型.weights后缀文件,
参数2是超参数.cfg后缀的文件。
如何才能得到这2个后缀的文件呢(*.weigthts和*.cfg),或者其他的也行,因为yolov8训练好的都是*.pt和*.yaml配套。网上还可以发现能导出*.onnx,但是第二个参数怎么整呀?
如何导出一套来呢?只要能用上readnet函数就可以。
官网解释:
Python: | | cv.dnn.readNet( | model[, config[, framework]] | ) -> | retval | | cv.dnn.readNet( | framework, bufferModel[, bufferConfig] | ) -> | retval | Parameters[in] | model | Binary file contains trained weights. The following file extensions are expected for models from different frameworks: | [in] | config | Text file contains network configuration. It could be a file with the following extensions: | [in] | framework | Explicit framework name tag to determine a format. |
|
|