Skip to content

Commit

Permalink
trim trailing white spaces
Browse files Browse the repository at this point in the history
  • Loading branch information
schalkdaniel committed Jan 8, 2019
1 parent 9ddbc83 commit ecb93a8
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 13 deletions.
22 changes: 11 additions & 11 deletions R/AutoTuner.R
@@ -1,16 +1,16 @@
#' @title AutoTuner
#'
#' @description
#' The [AutoTuner] conducts tuning and sets the learners parameter configuration to the best parameters obtained by the tuning.
#'
#' The [AutoTuner] conducts tuning and sets the learners parameter configuration to the best parameters obtained by the tuning.
#'
#' Additionally, this class can be used to do nested resampling by passing an [AutoTuner] object to resample.
#'
#' @section Usage:
#' ```
#' # Construction
#' at = AutoTuner$new(learner, resampling, param_set, terminator,
#' at = AutoTuner$new(learner, resampling, param_set, terminator,
#' tuner, tuner_settings, ctrl = tune_control(), id = "autotuner")
#'
#'
#' # public fields
#' at$learner
#' ```
Expand All @@ -31,10 +31,10 @@
#' List with tuner settings (e.g. see `?TunerGridSearch`)
#'
#' @section Details:
#' * With `at$learner` the raw learner with the best parameter configuration can be accessed.
#' * With `at$learner` the raw learner with the best parameter configuration can be accessed.
#'
#' The interface is described in [Learner].
#'
#'
#' @name AutoTuner
#' @keywords internal
#' @family Learner
Expand All @@ -46,12 +46,12 @@
#' task$measures = measures
#' param_set = paradox::ParamSet$new(
#' params = list(paradox::ParamDbl$new("cp", lower = 0.001, upper = 0.1)))
#'
#'
#' terminator = TerminatorEvaluations$new(5)
#'
#' at = AutoTuner$new(learner, resampling, param_set, terminator, tuner = TunerGridSearch,
#'
#' at = AutoTuner$new(learner, resampling, param_set, terminator, tuner = TunerGridSearch,
#' tuner_settings = list(resolution = 10L))
#'
#'
#' at$train(task)
#' at$learner
NULL
Expand Down Expand Up @@ -102,7 +102,7 @@ AutoTuner = R6Class("AutoTuner", inherit = mlr3::Learner,

self$learner$param_vals = private$.tuner$tune_result()$param_vals
self$learner$train(task)

private$.is_trained = TRUE

return (invisible(self))
Expand Down
4 changes: 2 additions & 2 deletions vignettes/tuning-02-tuner.Rmd
Expand Up @@ -23,7 +23,7 @@ set.seed(123)

`mlr3tuning` is an extension of `mlr3` that includes tuning.

## Basis of Tuning
## Basis of Tuning

As mentioned in the `tuning-01-fitness-function` vignette, we have to initialize a `FitnessFunction` object to define the hyperparameter space as well as the evaluation technique that is used to estimate the generalization error:

Expand All @@ -49,7 +49,7 @@ terminator_eval = TerminatorEvaluations$new(5)
## Iterations

```{r}
terminator_eval = TerminatorEvaluations$new(5)
terminator_iters = TerminatorIterations$new(5)
```

## Basic Search Strategies
Expand Down

0 comments on commit ecb93a8

Please sign in to comment.