IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 37811 for trunk/psLib


Ignore:
Timestamp:
Jan 11, 2015, 2:57:41 PM (12 years ago)
Author:
eugene
Message:

merge changes from ipp-20141224

Location:
trunk/psLib/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src/imageops/psImageMapFit.c

    r37721 r37811  
    286286    // fprintf (stderr, "Total: %f\n", Total);
    287287
     288    double MaxPivot = 0.0;
     289    for (int i = 0; i < Nx*Ny; i++) {
     290      MaxPivot = PS_MAX(MaxPivot, fabs(A->data.F32[i][i]));
     291      // fprintf (stderr, "piv, max: %f : %f\n", A->data.F32[i][i], MaxPivot);
     292    }
     293
    288294    // test for empty diagonal elements (unconstained cells), mark, and set pivots to 1.0
    289295    psVector *Empty = psVectorAlloc (Nx*Ny, PS_TYPE_S8);
    290296    psVectorInit (Empty, 0);
     297    double MinPivot = 0.025*MaxPivot;
    291298    for (int i = 0; i < Nx*Ny; i++) {
    292         if (A->data.F32[i][i] == 0.0) {
     299      if (fabs(A->data.F32[i][i]) < MinPivot) {
    293300            Empty->data.S8[i] = 1;
    294301            for (int j = 0; j < Nx*Ny; j++) {
  • trunk/psLib/src/math/psMinimizePolyFit.c

Note: See TracChangeset for help on using the changeset viewer.