You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

50 lines
1.0 KiB

8 years ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. #ifndef __DARKNET_DETECTOR_HEADER__
  2. #define __DARKNET_DETECTOR_HEADER__
  3. #include "../../../components/base/basicVideoAnalyzer.h"
  4. extern "C" {
  5. #include "../../../data/darknet/src/image.h"
  6. }
  7. using namespace cv;
  8. using namespace DN;
  9. class darknetDetector: public basicVideoAnalyzer {
  10. private:
  11. int m_iWidth;
  12. int m_iHeight;
  13. int m_iSST;
  14. int m_iCounterSST;
  15. int m_iWindow;
  16. int m_iCounterWindow;
  17. double m_dArea;
  18. bool m_bDilatePicture;
  19. Mat m_oMat;
  20. tContours m_vContours;
  21. tHierarhy m_vHierarchy;
  22. network m_oNeuralNetwork;
  23. char **m_vNames;
  24. struct DN_list *m_sOptions;
  25. //image **m_vAlphabet;
  26. layer m_lLastLayer;
  27. float m_fThresh;
  28. float m_fHier_Thresh;
  29. box *m_pBoxes;
  30. float **m_vProbs;
  31. float **m_vMasks;
  32. protected:
  33. virtual bool m_fImageAnalyzer( Mat &Picture );
  34. public:
  35. darknetDetector();
  36. ~darknetDetector();
  37. virtual void markup( Mat &Picture );
  38. void setParametersEx(int SST, int DetectionWindow);
  39. };
  40. #endif