Index TableOfContents

Summary

GPL is bad and we're going to replace GSL.

Stub library located at: /usr/pubsw/packages/gsl/stub/include/

See also NumericalRecipesReplacement

Freesurfer files using GSL

GSL Function Stack Trace

GSL Types and Functions Used

Possible Replacements

Steps for Replacement

  1. Create wrapper file (gsl_wrapper.c in /utils, and gsl_wrapper.h in /include) to wrap existing gsl functions with replacement routines (example: create new routine called 'cdf_flat_Q' which wraps 'gsl_cdf_flat_Q'). The basis for this wrapper file can be taken from the /usr/pubsw/packages/gsl/stub directory,
  2. Create test file (utils/gsl_wrapper_test.c) containing tests of gsl function, as taken from the GSL source code (found at /usr/pubsw/packages/gsl/current/src/gsl-1.6.tar.gz, where each sub-package has its own test.c file).
  3. Change all freesurfer code to call the wrapper functions instead of the gsl functions directly. Commit the gsl wrappers, gsl test files, and code changes to CVS dev. Essentially, no code has changed, so freesurfer should behave exactly the same. This is the baseline. Tag it as 'pre_gsl_replacement', so that its possible to revert to that code line.
  4. The GSL code is basically of two types: the matrix/vector stuff, and the statistic stuff. First, replace the matrix/vector stuff with the VNL equivalent that is already being used to replace the Numerical Recipes (NRC) stuff. Once this change-over is made, run test_recon-all to compare recon-all results before and after the change. Commit changes to CVS dev.
  5. Now the tough part: identify suitable equivalents to the GSL statistics stuff that we use (gsl_cdf_ etc.), and replace. Run units tests (the test code take from the orignal GSL code), run system tests (test_recon-all script), and commit to CVS.
  6. Run recon-all on the buckner40, and manually check results.