LCOV - code coverage report
Current view: top level - include - LayerOutput.h (source / functions) Hit Total Coverage
Test: lcov.info Lines: 3 3 100.0 %
Date: 2024-12-28 17:36:05 Functions: 2 2 100.0 %

          Line data    Source code
       1             : /**
       2             :  * @file LayerOutput.h
       3             :  * @author Damien Balima (www.dams-labs.net)
       4             :  * @brief Output layer
       5             :  * @date 2023-08-27
       6             :  *
       7             :  * @copyright Damien Balima (c) CC-BY-NC-SA-4.0 2023
       8             :  *
       9             :  */
      10             : #pragma once
      11             : #include "Layer.h"
      12             : #include "Neuron.h"
      13             : #include <algorithm>
      14             : #include <cstddef>
      15             : #include <execution>
      16             : #include <ranges>
      17             : #include <stdexcept>
      18             : #include <vector>
      19             : 
      20             : namespace sipai {
      21             : /**
      22             :  * @brief The OutputLayer class represents the output layer of a neural network.
      23             :  * It inherits from the Layer class and overrides its methods as necessary. This
      24             :  * layer is responsible for producing the final output of the network.
      25             :  */
      26             : class LayerOutput : public Layer {
      27             : public:
      28             :   LayerOutput() : Layer(LayerType::LayerOutput) {}
      29           8 :   LayerOutput(size_t size_x, size_t size_y)
      30           8 :       : Layer(LayerType::LayerOutput, size_x, size_y) {}
      31             : 
      32             :   void computeErrors(cv::Mat const &expectedValues);
      33             : 
      34          61 :   cv::Mat getOutputValues() const { return values; }
      35             : };
      36             : } // namespace sipai

Generated by: LCOV version 1.16