Ignore:
Timestamp:
01/27/11 23:39:21 (9 years ago)
Author:
aivar
Message:

Parameter ordering problems. GrayNRCurveFitter was out of date.

Location:
trunk/projects/curve-fitter/src/main/java/loci/curvefitter
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/projects/curve-fitter/src/main/java/loci/curvefitter/GrayNRCurveFitter.java

    r7160 r7598  
    140140                // load once, on-demand 
    141141                s_library = (CLibrary) Native.loadLibrary("GrayNRCode", CLibrary.class); 
     142 
     143                System.out.println("s_library is " + s_library); 
    142144            } 
    143145            catch (UnsatisfiedLinkError e) { 
     
    170172            for (ICurveFitData data: dataArray) { 
    171173                // grab incoming parameters 
    172                 a.setValue(data.getParams()[0]); 
    173                 tau.setValue(data.getParams()[1]); 
    174                 z.setValue(data.getParams()[2]); 
     174                a.setValue(data.getParams()[2]); 
     175                tau.setValue(data.getParams()[3]); 
     176                z.setValue(data.getParams()[1]); 
    175177 
    176178                returnValue = s_library.RLD_fit( 
     
    191193 
    192194                // set outgoing parameters 
    193                 data.getParams()[0] = a.getValue(); 
    194                 data.getParams()[1] = tau.getValue(); 
    195                 data.getParams()[2] = z.getValue(); 
     195                data.getParams()[0] = chiSquare.getValue(); 
     196                data.getParams()[1] = z.getValue(); 
     197                data.getParams()[2] = a.getValue(); 
     198                data.getParams()[3] = tau.getValue(); 
     199 
    196200            } 
    197201        } 
     
    209213                        data.getParams(), 
    210214                        toIntArray(m_free), 
    211                         data.getParams().length, 
     215                        data.getParams().length - 1, 
    212216                        data.getYFitted(), 
    213217                        chiSquare, 
  • trunk/projects/curve-fitter/src/main/java/loci/curvefitter/SLIMCurveFitter.java

    r7596 r7598  
    148148                //TODO sort out the name s_library = (CLibrary) Native.loadLibrary("SLIMCurve", CLibrary.class); 
    149149               //TODO test with old code instead: s_library = (CLibrary) Native.loadLibrary("slim-curve-1.0-SNAPSHOT", CLibrary.class); 
    150                 s_library = (CLibrary) Native.loadLibrary("SLIMCurve_trimmed_down", CLibrary.class); 
     150                //TODO this was yet another version s_library = (CLibrary) Native.loadLibrary("SLIMCurve_trimmed_down", CLibrary.class); 
     151                s_library = (CLibrary) Native.loadLibrary("slim-curve-1.0-SNAPSHOT", CLibrary.class); 
    151152 
    152153                System.out.println("s_library is " + s_library); 
Note: See TracChangeset for help on using the changeset viewer.