• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

CSMMLab / KiT-RT / #95

28 May 2025 02:06AM UTC coverage: 46.655% (-11.1%) from 57.728%
#95

push

travis-ci

web-flow
Release 2025 (#44)

* New neural models (#30)

* extend kitrt script

* added new neural models

* extend to m3 models

* added M3_2D models

* added M2 and M4 models

* configure ml optimizer for high order models

* added configuration for high order models

* add option for rotation postprcessing in neural networks. remove unneccessary python scripts

* started rotational symmetric postprocessing

* added rotational invariance postprocessing for m2 and m1 models

* fix post merge bugs

* created hohlraum mesh

* add hohlraum tes case

* add hohlraum test case

* add hohlraum cfg filees

* fixed hohlraum testcase

* add hohlraum cfg files

* changed hohlraum cfg

* changed hohlraum testcase to isotropic inflow source boundary condition

* added ghost cell bonudary for hohlraum testcase

* update readme and linesource mesh creator

* added proper scaling for linesource reference solution

* regularized newton debugging

* Data generator with reduced objective functional (#33)

* added reduced optimizer for sampling

* remove old debugging comments

* mesh acceleration (#38)

* added new ansatz (#36)

* added new ansatz

* debug new ansatz

* branch should be abandoned here

* debug new ansatz

* fix scaling error new ansatz

* fix config errors

* temporarily fixed dynamic ansatz rotation bug

* fix inheritance error for new ansatz

* mesh acceleration

* add structured hohlraum

* Mesh acc (#41)

* mesh acceleration

* added floor value for starmap moment methods

* enable accelleration

* delete minimum value starmap

* Update README.md

* Spherical harmonics nn (#40)

* added new ansatz

* debug new ansatz

* branch should be abandoned here

* debug new ansatz

* fix scaling error new ansatz

* fix config errors

* temporarily fixed dynamic ansatz rotation bug

* fix inheritance error for new ansatz

* mesh acceleration

* add structured hohlraum

* added sph... (continued)

767 of 3019 new or added lines in 51 files covered. (25.41%)

131 existing lines in 8 files now uncovered.

4422 of 9478 relevant lines covered (46.66%)

57163.05 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/optimizers/reducedpartregularizednewtonoptimizer.cpp
1
/*!
2
 * @file reducedpartregularizednewtonoptimizer.cpp
3
 * @brief class for solving the minimal entropy optimization problem using a partly regularized (order zero moment is not regularized) newton
4
 * optimizer with line search.
5
 * @author S. Schotthöfer
6
 */
7

8
#include "optimizers/reducedpartregularizednewtonoptimizer.hpp"
9
#include "common/config.hpp"
10
#include "entropies/entropybase.hpp"
11
#include "quadratures/quadraturebase.hpp"
12
#include "toolboxes/errormessages.hpp"
13
#include "toolboxes/textprocessingtoolbox.hpp"
14

15
ReducedPartRegularizedNewtonOptimizer::ReducedPartRegularizedNewtonOptimizer( Config* settings ) : ReducedNewtonOptimizer( settings ) {
×
16
    _gamma = settings->GetRegularizerGamma();    // Regularization parameter (to be included in settings)
×
17
}
18

19
ReducedPartRegularizedNewtonOptimizer::~ReducedPartRegularizedNewtonOptimizer() {}
×
20

×
NEW
21
double ReducedPartRegularizedNewtonOptimizer::ComputeObjFunc( const Vector& alpha, const Vector& sol, const VectorVector& moments ) {
×
22
    double result = ReducedNewtonOptimizer::ComputeObjFunc( alpha, sol, moments );    // Calls non regularized objective function
23
    for( unsigned idx_sys = 0; idx_sys < alpha.size(); idx_sys++ ) {
×
24
        result += 0.5 * _gamma * alpha[idx_sys] * alpha[idx_sys];    // Add regularizer norm(_alpha^r)^2
×
25
    }
×
26
    return result;
×
27
}
28

×
29
void ReducedPartRegularizedNewtonOptimizer::ComputeGradient( const Vector& alpha, const Vector& sol, const VectorVector& moments, Vector& grad ) {
30
    ReducedNewtonOptimizer::ComputeGradient( alpha, sol, moments, grad );    // compute unregularized gradients
31
    for( unsigned idx_sys = 0; idx_sys < alpha.size(); idx_sys++ ) {
×
32
        grad[idx_sys] += _gamma * alpha[idx_sys];    // Add regularizer _alpha^r
×
33
    }
×
34
}
×
35

36
void ReducedPartRegularizedNewtonOptimizer::ComputeHessian(const Vector& alpha, const VectorVector& moments, Matrix& hessian ) {
37
    ReducedNewtonOptimizer::ComputeHessian( alpha, moments, hessian );    // compute unregularized hessian)
38
    for( unsigned idx_sys = 0; idx_sys < alpha.size(); idx_sys++ ) {
×
39
        hessian( idx_sys, idx_sys ) += _gamma;    // Add block identity matrix with regularizer
×
40
    }
×
41
}
×
42

43
void ReducedPartRegularizedNewtonOptimizer::ReconstructMoments( Vector& sol, const Vector& alpha, const VectorVector& moments ) {
44
    ReducedNewtonOptimizer::ReconstructMoments( sol, alpha, moments );
45
    for( unsigned idx_sys = 0; idx_sys < alpha.size(); idx_sys++ ) {
×
46
        sol[idx_sys] += _gamma * alpha[idx_sys];    // Add regularizer _alpha^r
×
47
    }
×
48
}
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc