Specify layer types for Caffe FP32->FP16 weights converter

This commit is contained in:
Dmitry Kurtaev
2017-10-30 15:39:19 +03:00
parent 7b0d2d189f
commit e1ebc4e991
2 changed files with 18 additions and 3 deletions
+5 -1
View File
@@ -726,13 +726,17 @@ CV__DNN_EXPERIMENTAL_NS_BEGIN
* @param src Path to origin model from Caffe framework contains single
* precision floating point weights (usually has `.caffemodel` extension).
* @param dst Path to destination model with updated weights.
* @param layersTypes Set of layers types which parameters will be converted.
* By default, converts only Convolutional and Fully-Connected layers'
* weights.
*
* @note Shrinked model has no origin float32 weights so it can't be used
* in origin Caffe framework anymore. However the structure of data
* is taken from NVidia's Caffe fork: https://github.com/NVIDIA/caffe.
* So the resulting model may be used there.
*/
CV_EXPORTS_W void shrinkCaffeModel(const String& src, const String& dst);
CV_EXPORTS_W void shrinkCaffeModel(const String& src, const String& dst,
const std::vector<String>& layersTypes = std::vector<String>());
/** @brief Performs non maximum suppression given boxes and corresponding scores.