Spaces:
Runtime error
Runtime error
Download cpp_engine/src/vision_pyramid.hpp from Ypeng12/E-commerce-platform: direct link, hf CLI and curl.
- Browser
- Download file 915 Bytes
-
https://huggingface.co/spaces/Ypeng12/E-commerce-platform/resolve/main/cpp_engine/src/vision_pyramid.hpp
- Command line
-
hf download hf://spaces/Ypeng12/E-commerce-platform/cpp_engine/src/vision_pyramid.hpp
-
curl -L -o vision_pyramid.hpp https://huggingface.co/spaces/Ypeng12/E-commerce-platform/resolve/main/cpp_engine/src/vision_pyramid.hpp
915 Bytes
| struct VisionResult { | |
| double composite_score; | |
| double latency_ms; | |
| double phash_score; | |
| double dhash_score; | |
| double sift_score; | |
| int kp1_count; | |
| int kp2_count; | |
| int matches_count; | |
| double ssim_score; | |
| double delta_e; | |
| std::string verdict; | |
| std::string engine_type; | |
| }; | |
| // AVX2 Vectorized Math Utilities | |
| float simd_avx2_l2_distance_sq(const float* a, const float* b, size_t size); | |
| float simd_avx2_dot_product(const float* a, const float* b, size_t size); | |
| class VisionPyramidEngine { | |
| public: | |
| VisionPyramidEngine(); | |
| ~VisionPyramidEngine(); | |
| VisionResult match_images(const std::string& image_path_a, const std::string& image_path_b); | |
| std::string to_json(const VisionResult& result); | |
| }; | |