Skip to content

Commit 2b7c32e

Browse files
jakob-rja-thomas
authored andcommitted
rename all multicrit to multiobj (#282)
* rename all multicrit to multiobj
1 parent dcf3f70 commit 2b7c32e

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

70 files changed

+259
-260
lines changed

DESCRIPTION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ Package: mlrMBO
22
Title: Model-Based Optimization for mlr
33
Description: A framework for the (sequential) model-based parameter
44
optimization. It offers methods to optimize numeric or discrete influence
5-
parameters of non-linear black-box single- or multiobjective target
5+
parameters of non-linear black-box single- or multi-objective target
66
functions like an industrial simulator or a time-consuming algorithm using
77
cheap surrogate models.
88
Authors@R: c(

NAMESPACE

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,15 +9,15 @@ S3method(predictLearner,MultiFidWrapper)
99
S3method(predictLearner,regr.kmforrester)
1010
S3method(print,MBOControl)
1111
S3method(print,MBOExampleRun)
12-
S3method(print,MBOExampleRunMultiCrit)
12+
S3method(print,MBOExampleRunMultiObj)
1313
S3method(print,MBOMultiObjResult)
1414
S3method(print,MBOResult)
1515
S3method(renderExampleRunPlot,MBOExampleRun)
16-
S3method(renderExampleRunPlot,MBOExampleRunMultiCrit)
16+
S3method(renderExampleRunPlot,MBOExampleRunMultiObj)
1717
S3method(trainLearner,MultiFidWrapper)
1818
S3method(trainLearner,regr.kmforrester)
1919
export(exampleRun)
20-
export(exampleRunMultiCrit)
20+
export(exampleRunMultiObj)
2121
export(getGlobalOpt)
2222
export(getSupportedInfillCritFunctions)
2323
export(getSupportedInfillOptFunctions)
@@ -32,8 +32,8 @@ export(plotEAF)
3232
export(plotExampleRun)
3333
export(renderExampleRunPlot)
3434
export(setMBOControlInfill)
35-
export(setMBOControlMultiCrit)
3635
export(setMBOControlMultiFid)
36+
export(setMBOControlMultiObj)
3737
export(setMBOControlMultiPoint)
3838
export(setMBOControlTermination)
3939
export(trafoLog)

R/OptProblem.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,9 +75,9 @@ setOptProblemAllPossibleWeights = function(opt.problem, all.possible.weights) {
7575

7676
getOptProblemAllPossibleWeights = function(opt.problem) {
7777
control = getOptProblemControl(opt.problem)
78-
if (is.null(opt.problem$all.possible.weights) && control$n.objectives > 1L && control$multicrit.method == "parego") {
78+
if (is.null(opt.problem$all.possible.weights) && control$n.objectives > 1L && control$multiobj.method == "parego") {
7979
# calculate all possible weight vectors and save them
80-
all.possible.weights = combWithSum(control$multicrit.parego.s, control$n.objectives) / control$multicrit.parego.s
80+
all.possible.weights = combWithSum(control$multiobj.parego.s, control$n.objectives) / control$multiobj.parego.s
8181
# rearrange them a bit - we want to have the margin weights on top of the matrix
8282
# tricky: all margin weights have maximal variance
8383
vars = apply(all.possible.weights, 1, var)

R/OptState_getter.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ getOptStateShouldSave = function(opt.state) {
8080
}
8181

8282
# @param unify [\code{logical(1)}]
83-
# Defines if in the case of multicriterial optimization we shoud try to make
83+
# Defines if in the case of multi-objective optimization we shoud try to make
8484
# the output similar to the result of the normal optimization.
8585
getOptStateFinalPoints = function(opt.state, unify = FALSE) {
8686
opt.problem = getOptStateOptProblem(opt.state)

R/checkStuff.R

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,15 @@ checkStuff = function(fun, par.set, design, learner, control) {
2323
getNumberOfObjectives(fun), control$n.objectives)
2424
}
2525

26-
# at the moment we do not support noisy multicriteria optimization
26+
# at the moment we do not support noisy multi-objective optimization
2727
if (getNumberOfObjectives(fun) > 1L && isNoisy(fun)) {
2828
stopf("Optimization of noisy multi-objective functions not supported in the moment.")
2929
}
3030

31-
# final.method and final.evals have no effect on multicriteria optimization
31+
# final.method and final.evals have no effect on multi-objective optimization
3232
if (getNumberOfObjectives(fun) > 1L &&
3333
(control$final.method != "best.true.y" || control$final.evals > 0L)) {
34-
stop("Setting of final.method and final.evals for multicriteria optimization not supported at the moment.")
34+
stop("Setting of final.method and final.evals for multi-objective optimization not supported at the moment.")
3535
}
3636

3737
# general parameter and learner checks
@@ -50,7 +50,7 @@ checkStuff = function(fun, par.set, design, learner, control) {
5050
if (hasRequires(par.set) && !hasLearnerProperties(learner, "missings"))
5151
stopf("The 'par.set' has dependent parameters, which will lead to missing values in X-space during modeling, but learner '%s' does not support handling of missing values (property 'missing')!", learner$id)
5252

53-
# general infill stuff (relavant for single objective and parEGO)
53+
# general infill stuff (relavant for single-objective and parEGO)
5454
if (control$infill.crit %in% c("se", "ei", "aei", "cb", "dib") && learner$predict.type != "se") {
5555
stopf("For infill criterion '%s' predict.type of learner %s must be set to 'se'!%s",
5656
control$infill.crit, learner$id,
@@ -90,7 +90,7 @@ checkStuff = function(fun, par.set, design, learner, control) {
9090
control$store.model.at = coalesce(control$store.model.at, control$iters + 1)
9191
control$resample.at = coalesce(control$resample.at, integer(0))
9292

93-
# single objective
93+
# single-objective
9494
if (control$n.objectives == 1L) {
9595
if (control$propose.points == 1L) { # single point
9696
} else { # multi point
@@ -112,17 +112,17 @@ checkStuff = function(fun, par.set, design, learner, control) {
112112
}
113113
}
114114

115-
# multicrit stuff
115+
# multi-objective stuff
116116
if (control$n.objectives > 1L) {
117-
if (control$multicrit.method == "dib") {
117+
if (control$multiobj.method == "dib") {
118118
if (control$infill.crit != "dib")
119-
stopf("For multicrit 'dib' infil.crit must be set to 'dib'!")
119+
stopf("For multi-objective 'dib' infil.crit must be set to 'dib'!")
120120
} else {
121121
if (control$infill.crit == "dib")
122-
stopf("For infill.crit 'dib', multicrit method 'dib' is needed!")
122+
stopf("For infill.crit 'dib', multi-objective method 'dib' is needed!")
123123
}
124-
if (control$multicrit.method == "mspot" && control$infill.opt != "nsga2")
125-
stopf("For multicrit 'mspot' infil.opt must be set to 'nsga2'!")
124+
if (control$multiobj.method == "mspot" && control$infill.opt != "nsga2")
125+
stopf("For multi-objective 'mspot' infil.opt must be set to 'nsga2'!")
126126
}
127127

128128
# multifidelity stuff

R/doc_error_handling.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
#'
77
#' The target function could
88
#' \itemize{
9-
#' \item{1}{The target function returns NA(s) or NaN(s) (plural for the multicrit case).}
9+
#' \item{1}{The target function returns NA(s) or NaN(s) (plural for the multi-objective case).}
1010
#' \item{2}{The target function stops with an error.}
1111
#' \item{3}{The target function does not return at all (infinite or very long execution time).}
1212
#' \item{4}{The target function crashes the whole R process.}

R/doc_mbo_parallel.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@
1616
#' }
1717
#' Details regarding the latter:
1818
#' \describe{
19-
#' \item{Singlecrit MBO with LCB multipoint}{Parallel optimization of LCBs for the lambda-values.}
20-
#' \item{Multicrit MBO with ParEGO}{Parallel optimization of scalarization functions.}
19+
#' \item{single-objective MBO with LCB multipoint}{Parallel optimization of LCBs for the lambda-values.}
20+
#' \item{Multi-objective MBO with ParEGO}{Parallel optimization of scalarization functions.}
2121
#' }
2222
#'
2323
#' @name mbo_parallel

R/evalProposedPoints.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# @param opt.state
55
# @param prop: result of proposePoints
66
# @return [\code{numeric} | \code{matrix}] Numeric vector of y-vals or matrix
7-
# (for multi-criteria problems).
7+
# (for multi-objective problems).
88
#
99
# gets the getExtras, converts point data.frame to a list, repairs points out-of-bounds
1010
# then call evalTargetFun

R/evalTargetFun.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# @param xs: list of list of points to evaluate
55
# @param extras: list of extra stuff from getExtras, list of list of entries. same length as xs.
66
# @return [\code{numeric} | \code{matrix}] Numeric vector of y-vals or matrix
7-
# (for multi-criteria problems).
7+
# (for multi-objective problems).
88
#
99
# Does this:
1010
# 1) trafo X points

R/exampleRun.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ exampleRun = function(fun, design = NULL, learner = NULL, control,
5555
global.opt = NA_real_
5656

5757
if (control$n.objectives != 1L)
58-
stopf("exampleRun can only be applied for single objective functions, but you have %i objectives! Use 'exampleRunMultiCrit'!",
58+
stopf("exampleRun can only be applied for single-objective functions, but you have %i objectives! Use 'exampleRunMultiObj'!",
5959
control$n.objectives)
6060
if (n.params >= 3L)
6161
stopf("exampleRun can only be applied for functions with at most 2 dimensions, but you have %iD", n.params)

0 commit comments

Comments
 (0)