LCOV - code coverage report
Current view: top level - problems - RepresentationProblem.cpp (source / functions) Hit Total Coverage
Test: test_coverage.info.cleaned Lines: 0 13 0.0 %
Date: 2022-08-04 03:43:28 Functions: 0 10 0.0 %

          Line data    Source code
       1             : #include "RepresentationProblem.h"
       2             : 
       3             : namespace elsa
       4             : {
       5             : 
       6             :     template <typename data_t>
       7           0 :     RepresentationProblem<data_t>::RepresentationProblem(const Dictionary<data_t>& D,
       8             :                                                          const DataContainer<data_t>& y)
       9           0 :         : Problem<data_t>{L2NormPow2<data_t>{LinearResidual<data_t>{D, y}}}, _signal(y)
      10             :     {
      11           0 :         _dict = std::unique_ptr<Dictionary<data_t>>{
      12           0 :             static_cast<Dictionary<data_t>*>(D.clone().release())};
      13           0 :     }
      14             : 
      15             :     template <typename data_t>
      16           0 :     const Dictionary<data_t>& RepresentationProblem<data_t>::getDictionary() const
      17             :     {
      18           0 :         return *_dict;
      19             :     }
      20             : 
      21             :     template <typename data_t>
      22           0 :     const DataContainer<data_t>& RepresentationProblem<data_t>::getSignal() const
      23             :     {
      24           0 :         return _signal;
      25             :     }
      26             : 
      27             :     template <typename data_t>
      28           0 :     void RepresentationProblem<data_t>::getGradientImpl(DataContainer<data_t>&)
      29             :     {
      30           0 :         throw LogicError(
      31             :             "RepresentationProblem::getGradient: Objective function is not differentiable");
      32             :     }
      33             : 
      34             :     template <typename data_t>
      35           0 :     RepresentationProblem<data_t>* RepresentationProblem<data_t>::cloneImpl() const
      36             :     {
      37           0 :         return new RepresentationProblem(*_dict, _signal);
      38             :     }
      39             : 
      40             :     // ------------------------------------------
      41             :     // explicit template instantiation
      42             :     template class RepresentationProblem<float>;
      43             :     template class RepresentationProblem<double>;
      44             : 
      45             : } // namespace elsa

Generated by: LCOV version 1.14