Download modules/objdetect/src/barcode_decoder/common/super_scale.hpp from tgollogly/test: direct link, hf CLI and curl.
- Browser
- Download file 1.06 kB
-
https://huggingface.co/tgollogly/test/resolve/main/modules/objdetect/src/barcode_decoder/common/super_scale.hpp
- Command line
-
hf download hf://tgollogly/test/modules/objdetect/src/barcode_decoder/common/super_scale.hpp
-
curl -L -o super_scale.hpp https://huggingface.co/tgollogly/test/resolve/main/modules/objdetect/src/barcode_decoder/common/super_scale.hpp
1.06 kB
| /// This file is part of OpenCV project. | |
| // It is subject to the license terms in the LICENSE file found in the top-level directory | |
| // of this distribution and at http://opencv.org/license.html. | |
| // | |
| // Tencent is pleased to support the open source community by making WeChat QRCode available. | |
| // Copyright (C) 2020 THL A29 Limited, a Tencent company. All rights reserved. | |
| namespace cv { | |
| namespace barcode { | |
| class SuperScale | |
| { | |
| public: | |
| SuperScale() = default; | |
| ~SuperScale() = default; | |
| int init(const std::string &proto_path, const std::string &model_path); | |
| void processImageScale(const Mat &src, Mat &dst, float scale, const bool &use_sr, int sr_max_size = 160); | |
| private: | |
| dnn::Net srnet_; | |
| bool net_loaded_ = false; | |
| int superResolutionScale(const cv::Mat &src, cv::Mat &dst); | |
| }; | |
| } // namespace barcode | |
| } // namespace cv | |