Git Product home page Git Product logo

ermig1979 / simd Goto Github PK

View Code? Open in Web Editor NEW
2.0K 115.0 403.0 38.59 MB

C++ image processing and machine learning library with using of SIMD: SSE, AVX, AVX-512, AMX for x86/x64, VMX(Altivec) and VSX(Power7) for PowerPC, NEON for ARM.

Home Page: http://ermig1979.github.io/Simd

License: MIT License

Shell 0.02% C++ 99.13% C 0.07% CMake 0.08% Batchfile 0.04% Dockerfile 0.01% Makefile 0.01% Python 0.66%
simd avx neon image-processing altivec c-plus-plus vsx simd-library arm powerpc

simd's People

Contributors

adela0814 avatar alexanderkomarov avatar anmikh avatar arsmasiuk avatar ccnut avatar ddaletski avatar dmitryfedorov1991 avatar edi61 avatar ermig1979 avatar facug91 avatar fspindle avatar hungmingwu avatar j-stafford avatar jopknoppers avatar levwi avatar ngzhian avatar pozdneev avatar robinvanemden avatar rysavyjan avatar s-trinh avatar sergeydobrodey avatar teor292 avatar thesharpowl avatar unsignedvoid avatar usertest1 avatar vianney avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

simd's Issues

FaceDetection

1 hello author,I test your FaceDetection example
640*480 image,i use your xml,speed is 6-8ms;
detection.Init(image.Size(), 1.16, cv::Size(60,60),cv::Size(450,450));
i use my xml ,speed is 1-2ms;
your work is great,perfect.
2 But, I test my plate detect
detection.Init(image.Size(), 1.16, cv::Size(60,60),cv::Size(450,450));
speed is 1-2ms
and detection.Init(image.Size(), 1.16, cv::Size(80,20),cv::Size(520,130));
speed is 16-20ms
so i think that Your algorithm is faster for squares, but rectangles don't support it very well

How to show detection results using OPENCV

Hi,
Thanks for your project. I use example code to detect face, the code save result on disk. I don't know how to input image form camera and show result on screen based on OPENCV. Could you tell me how to do that. Thank you.

ResizeBilinearGray for NEON

Hi! There are ResizeBilinearGray optimization functions for SSSE3, AVX2 and AVX512, but not for NEON. So, I created such function for NEON and test it, but separately from Simd (unfortunately, I do not have the opportunity to test it together with the library on the ARM now). It seems like it works. Please, test it and add to repo.
SimdNeonResizeBilinear.txt

Fail to compile using HaarDetector from Example

Hello, when I try to use SIMD with the HaarClassifier I receive following error:
Does anyone know what is the reason for this? Thanks

CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Free(void*)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Detection<Simd::Allocator>::Load(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdDetection.hpp:220: undefined reference to `SimdDetectionLoadA'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdDetection.hpp:226: undefined reference to `SimdDetectionInfo'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Free(void*)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Free(void*)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Align(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:96: undefined reference to `SimdAlign'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Align(void*, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:115: undefined reference to `SimdAlign'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Free(void*)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Align(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:96: undefined reference to `SimdAlign'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Align(void*, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:115: undefined reference to `SimdAlign'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Free(void*)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Align(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:96: undefined reference to `SimdAlign'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Align(void*, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:115: undefined reference to `SimdAlign'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Free(void*)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Align(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:96: undefined reference to `SimdAlign'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Align(void*, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:115: undefined reference to `SimdAlign'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Free(void*)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Align(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:96: undefined reference to `SimdAlign'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Align(void*, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:115: undefined reference to `SimdAlign'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Free(void*)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Align(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:96: undefined reference to `SimdAlign'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Align(void*, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:115: undefined reference to `SimdAlign'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Free(void*)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Align(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:96: undefined reference to `SimdAlign'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Align(void*, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:115: undefined reference to `SimdAlign'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Detection<Simd::Allocator>::InitLevels(double, Simd::Point<long> const&, Simd::Point<long> const&, Simd::View<Simd::Allocator> const&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdDetection.hpp:438: undefined reference to `SimdDetectionInit'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdDetection.hpp:445: undefined reference to `SimdDetectionHaarDetect32fi'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdDetection.hpp:445: undefined reference to `SimdDetectionHaarDetect32fp'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdDetection.hpp:449: undefined reference to `SimdDetectionLbpDetect16ii'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdDetection.hpp:449: undefined reference to `SimdDetectionLbpDetect16ip'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdDetection.hpp:451: undefined reference to `SimdDetectionLbpDetect32fi'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdDetection.hpp:451: undefined reference to `SimdDetectionLbpDetect32fp'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::Fill<Simd::Allocator>(Simd::View<Simd::Allocator>&, unsigned char)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:1469: undefined reference to `SimdFill'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::Copy<Simd::Allocator, Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:1156: undefined reference to `SimdCopy'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::ResizeBilinear<Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:2517: undefined reference to `SimdResizeBilinear'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::Binarization<Simd::Allocator>(Simd::View<Simd::Allocator> const&, unsigned char, unsigned char, unsigned char, Simd::View<Simd::Allocator>&, SimdCompareType)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:910: undefined reference to `SimdBinarization'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::SegmentationShrinkRegion<Simd::Allocator>(Simd::View<Simd::Allocator> const&, unsigned char, Simd::Rectangle<long>&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:2617: undefined reference to `SimdSegmentationShrinkRegion'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Free(void*)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Align(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:96: undefined reference to `SimdAlign'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Align(void*, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:115: undefined reference to `SimdAlign'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::Copy<Simd::Allocator, Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:1156: undefined reference to `SimdCopy'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::GrayToBgra<Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&, unsigned char)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:1595: undefined reference to `SimdGrayToBgra'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::GrayToBgr<Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:1574: undefined reference to `SimdGrayToBgr'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::BgrToBgra<Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&, unsigned char)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:722: undefined reference to `SimdBgrToBgra'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::BgrToGray<Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:765: undefined reference to `SimdBgrToGray'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::BgraToBgr<Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:584: undefined reference to `SimdBgraToBgr'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::BgraToGray<Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:604: undefined reference to `SimdBgraToGray'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Free(void*)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::Copy<Simd::Allocator, Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:1156: undefined reference to `SimdCopy'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::ResizeBilinear<Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:2517: undefined reference to `SimdResizeBilinear'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::NormalizeHistogram<Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:1718: undefined reference to `SimdNormalizeHistogram'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::Copy<Simd::Allocator, Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:1156: undefined reference to `SimdCopy'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::ResizeBilinear<Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:2517: undefined reference to `SimdResizeBilinear'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Free(void*)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::Fill<Simd::Allocator>(Simd::View<Simd::Allocator>&, unsigned char)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:1469: undefined reference to `SimdFill'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::Fill<Simd::Allocator>(Simd::View<Simd::Allocator>&, unsigned char)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:1469: undefined reference to `SimdFill'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Free(void*)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::OperationBinary8u<Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&, SimdOperationBinary8uType)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:2296: undefined reference to `SimdOperationBinary8u'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Free(void*)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Alignment()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:131: undefined reference to `SimdAlignment'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Allocate(unsigned long, unsigned long)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:59: undefined reference to `SimdAllocate'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::Fill<Simd::Allocator>(Simd::View<Simd::Allocator>&, unsigned char)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:1469: undefined reference to `SimdFill'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Detection<Simd::Allocator>::Hid::Detect(Simd::View<Simd::Allocator> const&, Simd::Rectangle<long> const&, Simd::View<Simd::Allocator>&, unsigned long, bool)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdDetection.hpp:344: undefined reference to `SimdDetectionPrepare'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Free(void*)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Detection<Simd::Allocator>::Level::~Level()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdDetection.hpp:378: undefined reference to `SimdDetectionFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Allocator<unsigned char>::Free(void*)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: undefined reference to `SimdFree'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o:/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdAllocator.hpp:77: more undefined references to `SimdFree' follow
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::Integral<Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&, Simd::View<Simd::Allocator>&, Simd::View<Simd::Allocator>&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:1856: undefined reference to `SimdIntegral'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::Integral<Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&, Simd::View<Simd::Allocator>&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:1831: undefined reference to `SimdIntegral'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `void Simd::Integral<Simd::Allocator>(Simd::View<Simd::Allocator> const&, Simd::View<Simd::Allocator>&)':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdLib.hpp:1807: undefined reference to `SimdIntegral'
CMakeFiles/face_sdk_cpp.dir/main.cpp.o: In function `Simd::Detection<Simd::Allocator>::~Detection()':
/home/user1/CLionProjects/face_sdk_cpp/Simd/SimdDetection.hpp:205: undefined reference to `SimdDetectionFree'
collect2: error: ld returned 1 exit status
CMakeFiles/face_sdk_cpp.dir/build.make:112: recipe for target 'face_sdk_cpp' failed
make[3]: *** [face_sdk_cpp] Error 1
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/face_sdk_cpp.dir/all' failed
make[2]: *** [CMakeFiles/face_sdk_cpp.dir/all] Error 2
CMakeFiles/Makefile2:79: recipe for target 'CMakeFiles/face_sdk_cpp.dir/rule' failed
make[1]: *** [CMakeFiles/face_sdk_cpp.dir/rule] Error 2
Makefile:118: recipe for target 'face_sdk_cpp' failed
make: *** [face_sdk_cpp] Error 2

Compilation error for SimdDetection

Compiling code using SimdDetection raises the following two errors for SimdDetection.hpp:

../simd/src/Simd/SimdDetection.hpp:178:41: error: ‘INT_MAX’ was not declared in this scope
const Size & sizeMax = Size(INT_MAX, INT_MAX), const View & roi = View(), ptrdiff_t threadNumber = -1)
^~~~~~~
../simd/src/Simd/SimdDetection.hpp:178:50: error: ‘INT_MAX’ was not declared in this scope
const Size & sizeMax = Size(INT_MAX, INT_MAX), const View & roi = View(), ptrdiff_t threadNumber = -1)
^~~~~~~

This can be solved by
#include <limits.h>

in SimdDetection.hpp

Cannot show the result

I have use the example in Simd::Detection ,input an image ,The code is working properly,But the final test images were not shown.I want to know how to show it? thankyou!

assert(0) in View = operator

Hi. There is = operator in View class, and I think there is a bug with assert:
template <template<class> class A> SIMD_INLINE View<A> & View<A>::operator = (const View<A> & view)
{
if (this != &view)
{
if (_owner && data)
{
Allocator::Free(data);
assert(0); // <= here, it's stop application
}
.....
}

Crash in AddConvolution

When do convolution on a very small image (e.g., 2x2) by using "SimdNeuralConvolutionForward", the following function will crash due to out-of-range memory access.

template <bool align, size_t kernelX, size_t kernelY> void AddConvolution(const float * src, size_t srcWidth, size_t srcHeight, size_t srcDepth, const float * weight, float * dst, size_t dstWidth, size_t dstHeight, size_t dstDepth)

The possible reason may be "col" < 0 and then "pdst + col" point to an illegal area. Could you give some suggestions?

if (dstWidth - alignedWidth) {
size_t col = dstWidth - F;
__m128 _dst = Load(pdst + col);
_dst = _mm_add_ps(_dst, _mm_and_ps(tailMask, Convolution<kernelX, kernelY>::template Forward(psrc + col, srcWidth, _weight)));
Store(pdst + col, _dst);
}

NEON: Bayer to bgr

Hello,
is it possible to add NEON version of BayerToBGR conversion?

Regards

Build errors. ARM native build.

Linux(Debian Wheezy), gcc/g++ -4.7, using cmake:
[...]
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp: In instantiation of ‘void Simd::Neon::AlphaBlender<align, 3u>::operator()(const uint8_t_, uint8_t_, uint8x16_t) [with bool align = true; uint8_t = unsigned char; uint8x16_t = vector(16) builtin_neon_uqi]’:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:125:21: required from ‘void Simd::Neon::AlphaBlending(const uint8_t
, size_t, size_t, size_t, const uint8_t
, size_t, uint8_t
, size_t) [with bool align = true; unsigned int channelCount = 3u; uint8_t = unsigned char; size_t = unsigned int]’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:153:13: required from ‘void Simd::Neon::AlphaBlending(const uint8_t
, size_t, size_t, size_t, size_t, const uint8_t_, size_t, uint8_t_, size_t) [with bool align = true; uint8_t = unsigned char; size_t = unsigned int]’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:164:104: required from here
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:98:5: error: no matching function for call to ‘AlphaBlending(const uint8_t_, uint8_t_, )’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:98:5: note: candidates are:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:38:42: note: template void Simd::Neon::AlphaBlending(const uint8_t_, uint8_t_, uint8x8x2_t)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:38:42: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:98:5: note: cannot convert ‘{vtbl1_u8(_alpha.uint8x8x2_t::val[0], ((uint8x8_t)Simd::Neon::K8_TBL1_3_0)), vtbl1_u8(alpha.uint8x8x2_t::val[0], ((uint8x8_t)Simd::Neon::K8_TBL1_3_1))}’ (type ‘’) to type ‘uint8x8x2_t’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:47:51: note: template uint8x8_t Simd::Neon::AlphaBlending(const uint8x16_t&, const uint8x16_t&, const uint8x16_t&, const uint8x16_t&)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:47:51: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:98:5: note: cannot convert ‘src’ (type ‘const uint8_t* {aka const unsigned char
}’) to type ‘const uint8x16_t& {aka const __vector(16) builtin_neon_uqi&}’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:56:48: note: template void Simd::Neon::AlphaBlending(const uint8_t
, uint8_t
, const uint8x16_t&)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:56:48: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:98:5: note: cannot convert ‘{vtbl1_u8(_alpha.uint8x8x2_t::val[0], ((uint8x8_t)Simd::Neon::K8_TBL1_3_0)), vtbl1_u8(_alpha.uint8x8x2_t::val[0], ((uint8x8_t)Simd::Neon::K8_TBL1_3_1))}’ (type ‘’) to type ‘const uint8x16_t& {aka const vector(16) builtin_neon_uqi&}’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:99:5: error: no matching function for call to ‘AlphaBlending(const uint8_t
, uint8_t
, )’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:99:5: note: candidates are:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:38:42: note: template void Simd::Neon::AlphaBlending(const uint8_t
, uint8_t
, uint8x8x2_t)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:38:42: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:99:5: note: cannot convert ‘{vtbl1_u8(alpha.uint8x8x2_t::val[0], ((uint8x8_t)Simd::Neon::K8_TBL1_3_2)), vtbl1_u8(alpha.uint8x8x2_t::val[1], ((uint8x8_t)Simd::Neon::K8_TBL1_3_0))}’ (type ‘’) to type ‘uint8x8x2_t’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:47:51: note: template uint8x8_t Simd::Neon::AlphaBlending(const uint8x16_t&, const uint8x16_t&, const uint8x16_t&, const uint8x16_t&)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:47:51: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:99:5: note: cannot convert ‘(src + 16u)’ (type ‘const uint8_t
{aka const unsigned char
}’) to type ‘const uint8x16_t& {aka const __vector(16) builtin_neon_uqi&}’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:56:48: note: template void Simd::Neon::AlphaBlending(const uint8_t
, uint8_t
, const uint8x16_t&)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:56:48: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:99:5: note: cannot convert ‘{vtbl1_u8(_alpha.uint8x8x2_t::val[0], ((uint8x8_t)Simd::Neon::K8_TBL1_3_2)), vtbl1_u8(_alpha.uint8x8x2_t::val[1], ((uint8x8_t)Simd::Neon::K8_TBL1_3_0))}’ (type ‘’) to type ‘const uint8x16_t& {aka const vector(16) builtin_neon_uqi&}’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:100:5: error: no matching function for call to ‘AlphaBlending(const uint8_t
, uint8_t
, )’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:100:5: note: candidates are:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:38:42: note: template void Simd::Neon::AlphaBlending(const uint8_t
, uint8_t
, uint8x8x2_t)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:38:42: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:100:5: note: cannot convert ‘{vtbl1_u8(alpha.uint8x8x2_t::val[1], ((uint8x8_t)Simd::Neon::K8_TBL1_3_1)), vtbl1_u8(alpha.uint8x8x2_t::val[1], ((uint8x8_t)Simd::Neon::K8_TBL1_3_2))}’ (type ‘’) to type ‘uint8x8x2_t’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:47:51: note: template uint8x8_t Simd::Neon::AlphaBlending(const uint8x16_t&, const uint8x16_t&, const uint8x16_t&, const uint8x16_t&)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:47:51: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:100:5: note: cannot convert ‘(src + 32u)’ (type ‘const uint8_t
{aka const unsigned char
}’) to type ‘const uint8x16_t& {aka const vector(16) builtin_neon_uqi&}’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:56:48: note: template void Simd::Neon::AlphaBlending(const uint8_t
, uint8_t
, const uint8x16_t&)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:56:48: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:100:5: note: cannot convert ‘{vtbl1_u8(alpha.uint8x8x2_t::val[1], ((uint8x8_t)Simd::Neon::K8_TBL1_3_1)), vtbl1_u8(alpha.uint8x8x2_t::val[1], ((uint8x8_t)Simd::Neon::K8_TBL1_3_2))}’ (type ‘’) to type ‘const uint8x16_t& {aka const vector(16) builtin_neon_uqi&}’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp: In instantiation of ‘void Simd::Neon::AlphaBlender<align, 3u>::operator()(const uint8_t
, uint8_t
, uint8x16_t) [with bool align = false; uint8_t = unsigned char; uint8x16_t = vector(16) builtin_neon_uqi]’:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:130:21: required from ‘void Simd::Neon::AlphaBlending(const uint8_t
, size_t, size_t, size_t, const uint8_t
, size_t, uint8_t
, size_t) [with bool align = true; unsigned int channelCount = 3u; uint8_t = unsigned char; size_t = unsigned int]’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:153:13: required from ‘void Simd::Neon::AlphaBlending(const uint8_t
, size_t, size_t, size_t, size_t, const uint8_t
, size_t, uint8_t
, size_t) [with bool align = true; uint8_t = unsigned char; size_t = unsigned int]’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:164:104: required from here
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:98:5: error: no matching function for call to ‘AlphaBlending(const uint8_t, uint8_t, )’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:98:5: note: candidates are:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:38:42: note: template void Simd::Neon::AlphaBlending(const uint8_t, uint8_t, uint8x8x2_t)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:38:42: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:98:5: note: cannot convert ‘{vtbl1_u8(alpha.uint8x8x2_t::val[0], ((uint8x8_t)Simd::Neon::K8_TBL1_3_0)), vtbl1_u8(alpha.uint8x8x2_t::val[0], ((uint8x8_t)Simd::Neon::K8_TBL1_3_1))}’ (type ‘’) to type ‘uint8x8x2_t’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:47:51: note: template uint8x8_t Simd::Neon::AlphaBlending(const uint8x16_t&, const uint8x16_t&, const uint8x16_t&, const uint8x16_t&)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:47:51: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:98:5: note: cannot convert ‘src’ (type ‘const uint8_t
{aka const unsigned char
}’) to type ‘const uint8x16_t& {aka const __vector(16) builtin_neon_uqi&}’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:56:48: note: template void Simd::Neon::AlphaBlending(const uint8_t
, uint8_t
, const uint8x16_t&)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:56:48: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:98:5: note: cannot convert ‘{vtbl1_u8(_alpha.uint8x8x2_t::val[0], ((uint8x8_t)Simd::Neon::K8_TBL1_3_0)), vtbl1_u8(_alpha.uint8x8x2_t::val[0], ((uint8x8_t)Simd::Neon::K8_TBL1_3_1))}’ (type ‘’) to type ‘const uint8x16_t& {aka const vector(16) builtin_neon_uqi&}’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:99:5: error: no matching function for call to ‘AlphaBlending(const uint8_t
, uint8_t
, )’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:99:5: note: candidates are:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:38:42: note: template void Simd::Neon::AlphaBlending(const uint8_t
, uint8_t
, uint8x8x2_t)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:38:42: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:99:5: note: cannot convert ‘{vtbl1_u8(alpha.uint8x8x2_t::val[0], ((uint8x8_t)Simd::Neon::K8_TBL1_3_2)), vtbl1_u8(alpha.uint8x8x2_t::val[1], ((uint8x8_t)Simd::Neon::K8_TBL1_3_0))}’ (type ‘’) to type ‘uint8x8x2_t’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:47:51: note: template uint8x8_t Simd::Neon::AlphaBlending(const uint8x16_t&, const uint8x16_t&, const uint8x16_t&, const uint8x16_t&)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:47:51: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:99:5: note: cannot convert ‘(src + 16u)’ (type ‘const uint8_t
{aka const unsigned char
}’) to type ‘const uint8x16_t& {aka const __vector(16) builtin_neon_uqi&}’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:56:48: note: template void Simd::Neon::AlphaBlending(const uint8_t
, uint8_t
, const uint8x16_t&)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:56:48: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:99:5: note: cannot convert ‘{vtbl1_u8(_alpha.uint8x8x2_t::val[0], ((uint8x8_t)Simd::Neon::K8_TBL1_3_2)), vtbl1_u8(_alpha.uint8x8x2_t::val[1], ((uint8x8_t)Simd::Neon::K8_TBL1_3_0))}’ (type ‘’) to type ‘const uint8x16_t& {aka const vector(16) builtin_neon_uqi&}’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:100:5: error: no matching function for call to ‘AlphaBlending(const uint8_t
, uint8_t
, )’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:100:5: note: candidates are:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:38:42: note: template void Simd::Neon::AlphaBlending(const uint8_t
, uint8_t
, uint8x8x2_t)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:38:42: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:100:5: note: cannot convert ‘{vtbl1_u8(alpha.uint8x8x2_t::val[1], ((uint8x8_t)Simd::Neon::K8_TBL1_3_1)), vtbl1_u8(alpha.uint8x8x2_t::val[1], ((uint8x8_t)Simd::Neon::K8_TBL1_3_2))}’ (type ‘’) to type ‘uint8x8x2_t’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:47:51: note: template uint8x8_t Simd::Neon::AlphaBlending(const uint8x16_t&, const uint8x16_t&, const uint8x16_t&, const uint8x16_t&)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:47:51: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:100:5: note: cannot convert ‘(src + 32u)’ (type ‘const uint8_t
{aka const unsigned char
}’) to type ‘const uint8x16_t& {aka const __vector(16) builtin_neon_uqi&}’
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:56:48: note: template void Simd::Neon::AlphaBlending(const uint8_t
, uint8_t
, const uint8x16_t&)
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:56:48: note: template argument deduction/substitution failed:
/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp:100:5: note: cannot convert ‘{vtbl1_u8(_alpha.uint8x8x2_t::val[1], ((uint8x8_t)Simd::Neon::K8_TBL1_3_1)), vtbl1_u8(alpha.uint8x8x2_t::val[1], ((uint8x8_t)Simd::Neon::K8_TBL1_3_2))}’ (type ‘’) to type ‘const uint8x16_t& {aka const __vector(16) __builtin_neon_uqi&}’
make[2]: *
* [CMakeFiles/SimdNeon.dir/root/Simd/src/Simd/SimdNeonAlphaBlending.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [CMakeFiles/SimdNeon.dir/all] Error 2
make: *** [all] Error 2

How to compile the library as a shared object file (.so)

I am not well-versed into the compilation process with cmake/make and the current process gives a list of Object files (.o) i.e.

git clone https://github.com/ermig1979/Simd.git
cd Simd/prj/cmake/
cmake . -DTOOLCHAIN="" -DTARGET="" -DCMAKE_BUILD_TYPE="Release"
make

What should be done to link all these object files into one shared object .so file?
Thanks in advance

Avx perfomance degradation compared to SSE

Hi. I test some neural network with AVX2, AVX and SSE instructions and found that AVX is less perfomance than even SSE. I think this is a problem or maybe AVX is meaningless for neural network (or my type of neural network).

Rotate image

Hi,
how can i rotate image with Simd?
Thanks.!

internal compiler error: in subreg_get_info while compiling on Raspbian

[ 41%] Building CXX object CMakeFiles/Simd.dir/home/pi/simd/src/Simd/SimdNeonBgrToBgra.cpp.o
/home/pi/simd/src/Simd/SimdNeonBgrToBgra.cpp: In function ‘void Simd::Neon::BgrToBgra(const uint8_t*, size_t, size_t, size_t, uint8_t*, size_t, uint8_t)’:
/home/pi/simd/src/Simd/SimdNeonBgrToBgra.cpp:69:9: internal compiler error: in subreg_get_info, at rtlanal.c:3679
}
^
Please submit a full bug report,
with preprocessed source if appropriate.
See file:///usr/share/doc/gcc-6/README.Bugs for instructions.
CMakeFiles/Simd.dir/build.make:1766: recipe for target 'CMakeFiles/Simd.dir/home/pi/simd/src/Simd/SimdNeonBgrToBgra.cpp.o' failed
make[2]: *** [CMakeFiles/Simd.dir/home/pi/simd/src/Simd/SimdNeonBgrToBgra.cpp.o] Error 1
CMakeFiles/Makefile2:104: recipe for target 'CMakeFiles/Simd.dir/all' failed
make[1]: *** [CMakeFiles/Simd.dir/all] Error 2
Makefile:83: recipe for target 'all' failed
make: *** [all] Error 2

Any idea how to solve that? I'm using latest Raspbian Stretch Lite and new Raspberry-Pi 3 B Plus.

Thanks,

Image size for detection

It appears that the number of pixels in each direction must be a multiple of 16 for the detection to find e.g. faces using the included Haar cascade for frontal faces. When the image dimensions are not multiple of 16, there is no error reported, but the detection algorithm does not find any faces.

Python wrapper

Hello, I'd like to use your library from Python, what would be the best way to achieve that ?

Build fails: no member named 'DrawFilledRectangle' in namespace 'Simd'

In file included from /usr/ports/graphics/simd/work/Simd-cb13960/src/Test/TestFont.cpp:28:
/usr/ports/graphics/simd/work/Simd-cb13960/prj/cmake/../../src/Simd/SimdFont.hpp:199:19: error: no member named 'DrawFilledRectangle' in namespace 'Simd'
            Simd::DrawFilledRectangle(region, Rect(region.Size()), background);
            ~~~~~~^

clang-4.0.0, rev. cb13960

aarch64 is not support NEON

Build type: Release
Target: aarch64
Library: STATIC
Toolchain: /usr/bin/c++
ID: GNU
Version: 5.4.0
Try to estimate SVN revision:
Subversion is not installed!
Last project version '4.1.64' is equal to current version '4.1.64'.
File '../../src/Simd/SimdVersion.h' is already exist.
Skip updating of '../../src/Simd/SimdVersion.h' file.
-- Configuring done
-- Generating done

I use haar cascade detection for simd, a times slower than the speed of opencv.

CmakeList.txt exist this:

elseif((CMAKE_SYSTEM_PROCESSOR MATCHES "arm") OR (CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64"))

    if(CMAKE_SYSTEM_PROCESSOR MATCHES "arm")
        set(CXX_NEON_FLAG "-mfpu=neon -mfpu=neon-fp16 -mfp16-format=ieee")
    else()
        set(CXX_NEON_FLAG "")
    endif()

Failed to compile the FaceDetect example

While trying to compile the example facedetect.cpp i get the following errors:

g++ -std=c++11 face.cpp -I../simd/src
/tmp/ccsGhz9i.o: In function main': face.cpp:(.text+0x47c): undefined reference to SimdAlignment'
face.cpp:(.text+0x4d8): undefined reference to SimdFree' face.cpp:(.text+0x63c): undefined reference to SimdAlign'
face.cpp:(.text+0x678): undefined reference to SimdAlign' face.cpp:(.text+0x6c4): undefined reference to SimdAllocate'
face.cpp:(.text+0x938): undefined reference to SimdFree' face.cpp:(.text+0x2cac): undefined reference to SimdFree'
face.cpp:(.text+0x2d1c): undefined reference to SimdFree' face.cpp:(.text+0x2db4): undefined reference to SimdFree'
/tmp/ccsGhz9i.o: In function Simd::Detection<Simd::Allocator>::~Detection()': face.cpp:(.text._ZN4Simd9DetectionINS_9AllocatorEED2Ev[_ZN4Simd9DetectionINS_9AllocatorEED5Ev]+0x38): undefined reference to SimdDetectionFree'
/tmp/ccsGhz9i.o: In function Simd::Detection<Simd::Allocator>::Load(std::string const&, int)': face.cpp:(.text._ZN4Simd9DetectionINS_9AllocatorEE4LoadERKSsi[_ZN4Simd9DetectionINS_9AllocatorEE4LoadERKSsi]+0x28): undefined reference to SimdDetectionLoadA'
face.cpp:(.text._ZN4Simd9DetectionINS_9AllocatorEE4LoadERKSsi[_ZN4Simd9DetectionINS_9AllocatorEE4LoadERKSsi]+0x78): undefined reference to SimdDetectionInfo' /tmp/ccsGhz9i.o: In function Simd::DetectionSimd::Allocator::Detect(Simd::ViewSimd::Allocator const&, std::vector<Simd::DetectionSimd::Allocator::Object, std::allocator<Simd::DetectionSimd::Allocator::Object> >&, int, double, bool, std::vector<Simd::Rectangle, std::allocator<Simd::Rectangle > > const&)':

Any advice?
Thanks,
Mark

Make failed on Mac OS 13.10

I ran the command
cmake . -DTOOLCHAIN="" -DTARGET=""
make

error:

clang: error: unknown argument: '-fabi-version=4'

Memory leak

I think there are memory leaks in cascade classifier module.

build issue

I can't compile it because there are no file SimdVersion.h.
I have message "fatal error: Simd/SimdVersion.h: No such file or directory #include "Simd/SimdVersion.h"

Conan package

Hello,
Do you know about Conan?
Conan is modern dependency manager for C++. And will be great if your library will be available via package manager for other developers.

Here you can find example, how you can create package for the library.

If you have any questions, just ask :-)

MinGW64 compatibility

Trying to build with GCC for Windows (MinGW64) via cmake makes cmake quit due to unknown Plattform (Platform/MINGW64_NT-10.0).
This is my toolchain of choise. Would it be possible to get it running?
CopyOfCMakeCache.txt

Can't compile with GCC 4.8.4 (Ubuntu 14.04 LTS)

$ gcc -v
gcc version 4.8.4 (Ubuntu 4.8.4-2ubuntu1~14.04.3)

Output:

In file included from /home/homm/Code/pillow-perf/simd/src/Test/TestContour.cpp:312:0:
/home/homm/Code/pillow-perf/simd/prj/cmake/../../src/Simd/SimdContour.hpp: In member function ‘void Simd::ContourDetector<A>::ContourAnchors(int, int)’:
/home/homm/Code/pillow-perf/simd/prj/cmake/../../src/Simd/SimdContour.hpp:176:51: error: expected primary-expression before ‘>’ token
                 const uint8_t * a = &_a.At<uint8_t>(0, row);
                                                   ^
/home/homm/Code/pillow-perf/simd/prj/cmake/../../src/Simd/SimdContour.hpp:180:50: error: expected primary-expression before ‘(’ token
                         _anchors.push_back(Anchor(Point(col, row), _m.At<int16_t>(col, row) / 2));
                                                  ^
/home/homm/Code/pillow-perf/simd/prj/cmake/../../src/Simd/SimdContour.hpp:180:81: error: expected primary-expression before ‘>’ token
                         _anchors.push_back(Anchor(Point(col, row), _m.At<int16_t>(col, row) / 2));
                                                                                 ^
/home/homm/Code/pillow-perf/simd/prj/cmake/../../src/Simd/SimdContour.hpp: In member function ‘void Simd::ContourDetector<A>::SmartRoute(Simd::ContourDetector<A>::Contours&, Simd::ContourDetector<A>::Contour&, ptrdiff_t, ptrdiff_t, size_t, uint16_t, Simd::ContourDetector<A>::Direction)’:
/home/homm/Code/pillow-perf/simd/prj/cmake/../../src/Simd/SimdContour.hpp:215:38: error: expected primary-expression before ‘>’ token
                     if (_e.At<uint8_t>(x, y) == 0)
                                      ^
/home/homm/Code/pillow-perf/simd/prj/cmake/../../src/Simd/SimdContour.hpp:217:38: error: expected primary-expression before ‘>’ token
                         _e.At<uint8_t>(x, y) = 255;
                                      ^
/home/homm/Code/pillow-perf/simd/prj/cmake/../../src/Simd/SimdContour.hpp:238:38: error: expected primary-expression before ‘>’ token
                     if (_e.At<uint8_t>(x, y) != 0)
                                      ^

And so on

Scale buffer pixel

Hello,

I have a buffer of pixels (BGRA) of a 1920x1080 image. The length is 192010804.
I would like to scale this buffer to 1280x720.
How to do this using Simd library ? I don't find any sample or documentation.

Thank you !

Error on compiling windows

Hello,

I'm trying to compile Simd library as static on visual studio 2017.
I get an error :VCEnd exited with code 9009

I uncommented the #define SIMD_STATIC and I selected staticLib on General Configuration. It's for a C++ Project.

I opened the projet from the directory /prj/vs2017w.

Can you please tell me what I did wrong ? Thanks a lot !

Scale image from path

Hello,

I would like to scale an image (.jpg or .png) from path.
How to do it using Simd library ?

Thanks

Clang Errors

CLANGCOMPILE : fatal error : error in backend: Cannot select: intrinsic %llvm.arm.neon.vcvtfp2hf;
clang.exe : error : clang frontend command failed with exit code 70 (use -v to see invocation)

fail to compile src/Test/TestImageMatcher.cpp with clang

Building with clang on macOS, the library seems to compile fine (with 78f1db8), but this test fails to compile:

[ 90%] Building CXX object CMakeFiles/Test.dir/Users/me/Development/Simd/src/Test/TestImageMatcher.cpp.o
/Users/me/Development/Simd/src/Test/TestImageMatcher.cpp:150:18: error: no matching function for call to 'Compare'
        result = Compare(is0, is1, 0, true, 0, "D1");
                 ^~~~~~~
/Users/me/Development/Simd/prj/cmake/../../src/Test/TestUtils.h:57:10: note: candidate function not viable: no known conversion from 'Indexes' (aka 'vector<unsigned long>') to 'const uint32_t *'
      (aka 'const unsigned int *') for 1st argument
    bool Compare(const Histogram a, const Histogram b,
         ^
/Users/me/Development/Simd/prj/cmake/../../src/Test/TestUtils.h:60:10: note: candidate function not viable: no known conversion from 'vector<size_t>' to 'const vector<uint32_t>' for 1st argument
    bool Compare(const Sums & a, const Sums & b,
         ^
/Users/me/Development/Simd/prj/cmake/../../src/Test/TestUtils.h:63:10: note: candidate function not viable: no known conversion from 'vector<size_t>' to 'const vector<uint64_t>' for 1st argument
    bool Compare(const Sums64 & a, const Sums64 & b,
         ^
/Users/me/Development/Simd/prj/cmake/../../src/Test/TestUtils.h:53:10: note: candidate function not viable: no known conversion from 'Indexes' (aka 'vector<unsigned long>') to 'const View'
      (aka 'const View<Simd::Allocator>') for 1st argument
    bool Compare(const View & a, const View & b,
         ^
/Users/me/Development/Simd/prj/cmake/../../src/Test/TestUtils.h:74:10: note: candidate function not viable: no known conversion from 'Indexes' (aka 'vector<unsigned long>') to 'const View'
      (aka 'const View<Simd::Allocator>') for 1st argument
    bool Compare(const View & a, const View & b, float relativeDifferenceMax = EPS, bool printError = false,
         ^
/Users/me/Development/Simd/prj/cmake/../../src/Test/TestUtils.h:68:10: note: candidate function not viable: no known conversion from 'vector<size_t>' to 'const vector<float>' for 1st argument
    bool Compare(const Buffer32f & a, const Buffer32f & b, float relativeDifferenceMax = EPS,
         ^
/Users/me/Development/Simd/prj/cmake/../../src/Test/TestUtils.h:77:10: note: candidate function not viable: requires at most 5 arguments, but 6 were provided
    bool Compare(const float & a, const float & b, float relativeDifferenceMax = EPS, bool printError = false,
         ^
/Users/me/Development/Simd/prj/cmake/../../src/Test/TestUtils.h:66:10: note: candidate function not viable: requires at most 3 arguments, but 6 were provided
    bool Compare(const Rect & a, const Rect & b, bool printError = false);
         ^
/Users/me/Development/Simd/src/Test/TestImageMatcher.cpp:152:18: error: no matching function for call to 'Compare'
        result = Compare(is1, is2, 0, true, 0, "D3");
                 ^~~~~~~
/Users/me/Development/Simd/prj/cmake/../../src/Test/TestUtils.h:57:10: note: candidate function not viable: no known conversion from 'Indexes' (aka 'vector<unsigned long>') to 'const uint32_t *'
      (aka 'const unsigned int *') for 1st argument
    bool Compare(const Histogram a, const Histogram b,
         ^
/Users/me/Development/Simd/prj/cmake/../../src/Test/TestUtils.h:60:10: note: candidate function not viable: no known conversion from 'vector<size_t>' to 'const vector<uint32_t>' for 1st argument
    bool Compare(const Sums & a, const Sums & b,
         ^
/Users/me/Development/Simd/prj/cmake/../../src/Test/TestUtils.h:63:10: note: candidate function not viable: no known conversion from 'vector<size_t>' to 'const vector<uint64_t>' for 1st argument
    bool Compare(const Sums64 & a, const Sums64 & b,
         ^
/Users/me/Development/Simd/prj/cmake/../../src/Test/TestUtils.h:53:10: note: candidate function not viable: no known conversion from 'Indexes' (aka 'vector<unsigned long>') to 'const View'
      (aka 'const View<Simd::Allocator>') for 1st argument
    bool Compare(const View & a, const View & b,
         ^
/Users/me/Development/Simd/prj/cmake/../../src/Test/TestUtils.h:74:10: note: candidate function not viable: no known conversion from 'Indexes' (aka 'vector<unsigned long>') to 'const View'
      (aka 'const View<Simd::Allocator>') for 1st argument
    bool Compare(const View & a, const View & b, float relativeDifferenceMax = EPS, bool printError = false,
         ^
/Users/me/Development/Simd/prj/cmake/../../src/Test/TestUtils.h:68:10: note: candidate function not viable: no known conversion from 'vector<size_t>' to 'const vector<float>' for 1st argument
    bool Compare(const Buffer32f & a, const Buffer32f & b, float relativeDifferenceMax = EPS,
         ^
/Users/me/Development/Simd/prj/cmake/../../src/Test/TestUtils.h:77:10: note: candidate function not viable: requires at most 5 arguments, but 6 were provided
    bool Compare(const float & a, const float & b, float relativeDifferenceMax = EPS, bool printError = false,
         ^
/Users/me/Development/Simd/prj/cmake/../../src/Test/TestUtils.h:66:10: note: candidate function not viable: requires at most 3 arguments, but 6 were provided
    bool Compare(const Rect & a, const Rect & b, bool printError = false);
         ^
2 errors generated.
make[2]: *** [CMakeFiles/Test.dir/Users/me/Development/Simd/src/Test/TestImageMatcher.cpp.o] Error 1
make[1]: *** [CMakeFiles/Test.dir/all] Error 2
make: *** [all] Error 2

Ubuntu14.04 Compilation Error

../../src/Simd/SimdFont.hpp: In member function ‘bool Simd::Font::Draw(Simd::Font::View&, const String&, const Simd::ViewSimd::Allocator::Position&, const Color&, const Color&) const’:
/Simd/prj/cmake/../../src/Simd/SimdFont.hpp:199:13: error: ‘DrawFilledRectangle’ is not a member of ‘Simd’
Simd::DrawFilledRectangle(region, Rect(region.Size()), background);
^
make[2]: *** [CMakeFiles/Test.dir/home/keti/KETI/Simd/src/Test/TestFont.cpp.o] Error 1
make[1]: *** [CMakeFiles/Test.dir/all] Error 2
make: *** [all] Error 2

please let me know how to compile.

I used these steps to compile as mentioned.

cd ./prj/cmake
cmake . -DTOOLCHAIN="" -DTARGET=""
make

can't compile with vc2015

hi, this is the error message:
simd\simdavx1ann.cpp(258): error C2719: 'dst': formal parameter with requested alignment of 32 won't be aligned
simd\simdsse1ann.cpp(244): error C2719: 'dst': formal parameter with requested alignment of 16 won't be aligned

ValueSum and SquareSum at once

Hi. There is a function of the sum of the pixels and the square of the sum of the pixels in your library. But in some problems (for example, to calculate variance), both the first and second functions are used.
So, for greater perfomance it is logical to make a function that considers both the sum and the square of the sum of pixels. I union this functions in other one for AVX2, SSE2 and base realization. Can you add it to repo and add other realizations?

valSq.txt

How to build on Ubuntu 14.04?

What I have done:
1: cd build
2: cmake ../prj/cmake
-- The C compiler identification is GNU 4.8.4
-- The CXX compiler identification is GNU 4.8.4
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMAKE_BUILD_TYPE variable is not defined. Set CMAKE_BUILD_TYPE = 'Release'.
Using crossplatform toolchain '' for '' platform.
CMAKE_SYSTEM_PROCESSOR =
-- Configuring done
-- Generating done
-- Build files have been written to: /home/houzy/Simd/build
3: make (No output)
What is the correct way to build this repo? Thanks.

simd::nural

Hi @ermig1979,

I am using LBP face detection in arm based environment and its speed is awesome :).

do you have any example code for hog feature extraction for face detection/recognition and examples for neural module?

Can't build using clang

Error building Simd with clang.
I got a following error during build: clang: error: unknown argument: '-fabi-version=4'

Tried clang versions 3, 5, and 6.
Building with CMake.

Different falls when using small scaleFactor

Hello.
I experience some strange memory problems when running Simd::Detection<Simd::Allocator>::Detect method when cascade was initialized with scaleFactor = 1.01. It ends with SIGABRT or SIGBUS.
Compiler is GCC 7.1.1 x86_64, with all extensions. It also reproducible using Visual Studio 2013 (looks like problem is in Base::DetectionFree)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.