Closed evaham1 closed 3 weeks ago
Updating perf()
functions to use BPPARAM
As MCVfold.spls()
is also used by perf()
, which is a generic function that acts as a dispatcher for following functions depending on the class of the input object:
perf.mixo_pls()
perf.mixo_spls()
perf.mixo_plsda()
perf.mixo_splsda()
perf.sgccda()
perf.mint.plsda()
perf.mint.splsda()
✅ Updated these functions to make sure they all use BPPARAM
and pass this to bplapply
rather than lapply
✅ Added tests for these functions running in serial and parallel and with and without progress bar.
Updating the parallel running of
tune()
functions to use theBPPARAM
arg✅
tune.spca()
- was already parallelised usingBPPARAM
when run independently, but this wasn't working in thetune
wrapper so made sureBPPARAM
is passed through wrapper to function ✅tune.spls()
- was already parallelised usingBPPARAM
but did not pass this on totune.spls1
when this was called, now fixed ✅tune.splsda()
- was parallelised using old-tylecpu
andparallel
arguments. Updated this toBPPARAM
which feeds into internal functionMCVfold.spls()
.perf()
also makes use of this internal function so updated it to reflect the fact theMCVfold.spls()
takesBPPARAM
arg now instead ofcpu
. ✅tune.block.splsda()
- was already parallelised usingBPPARAM
but was not in tune wrapper function so added to wrapper and added testing ✅tune.spls.level()
- added parallelisation usingBPPARAM
independently and throughtune()
wrapper✅ Added unit testing for all the tune functions above to make sure they:
set.seed()
before running function AND setBPPARAM = SerialParam(RNGseed = 123)
tune()
wrapper function ✅ Worked on making unit tests fast and not print out lots of statements by adjusting params and nesting tests together (if unit tests take too long coverage github action runs for 6 hours and then times out)