/
NNResultListener

NNResultListener

class NNResultListener { public: virtual void onDetectedError( std::shared_ptr<NNData> origData, int error) = 0; virtual void onDetected( std::shared_ptr<NNData> origData, std::shared_ptr<NNData> result) = 0; virtual void onDetected( std::shared_ptr<NNData> origData, std::vector<std::shared_ptr<NNData>> results) = 0; };

Introduction to the Class

Interface for listening to neural network processing results and errors.

This class defines a set of pure virtual methods that must be implemented by derived classes to handle different types of results and errors from neural network processing.

Introduction to the Class's Methods

  1. void onDetectedError(std::shared_ptr<NNData> origData, int error)

    • brief: Callback method invoked when an error is detected during neural network processing.

    • param

      • origData: The original data that was processed.

      • result: The error code indicating the type of error that occurred.

  2. void onDetected(std::shared_ptr<NNData> origData, std::shared_ptr<NNData> result)

    • brief: Callback method invoked when multiple results are detected from neural network processing.

    • param

      • origData: The original data that was processed.

      • result: The resulting data from the neural network processing.

  3. void onDetected(std::shared_ptr<NNData> origData, std::vector<std::shared_ptr<NNData>> results)

    • brief: Callback method invoked when multiple results are detected from neural network processing.

    • param

      • origData: The original data that was processed.

      • results: A vector containing multiple resulting data from the neural network processing.