chadhazlett / KBAL

Kernel Balancing project
10 stars 7 forks source link

Add early stopping criteria (enabled by default) + add docs for OSX #37

Closed akravetz closed 2 months ago

akravetz commented 2 months ago

This PR has two main changes:

  1. Add an "early stopping" criteria. When optimizing the number of dimensions based on the bias bound, we stop if the last 20 rounds have not achieved a minimum better than the best known. This can have a substantial impact on performance when using higher dimensional input data. Anecdotally, folks have found that the optimization generally hits a minimum then increases as dimensionality increases. I settled on 20 rounds just based on empiric evidence (having run these types of study across a couple different data sets). Happy to have feedback here. Alternatively, we could make this a parameter w/ a default value of 20.
  2. For OSX, I found that using the Accelerate vecLib BLAS implementation can create a 5-10x speed up for OSX users. I've added instructions in README.Rmd on how to switch to this BLAS library

I added myself as a contributor in the DESCRIPTION file, but lmk if you'd prefer it somewhere else!

chadhazlett commented 2 months ago

Thank you!