Minimising a black box function
I have a function with 8 inputs, which yields a single output. I do not know what the function does and so cannot use any derivative-based method to minimise said output.
Currently this is done by picking n random vectors, with some bounds for each input, obtaining an output value for each vector, and picking the lowest output from a vector of n.
I have been told to try Ant Colony Optimisation, however I struggle to see how I could implement that for a function with that many inputs.
Any ideas as to how to approach this problem in a better way than it is currently being done will be much appreciated.
The function itself takes a non-negligible time to run, so I am interested in ways to most efficiently (solving the function as low number of times as possible) find a minimum.
EDIT: The bounds for each of the 8 inputs are (0,1), but could conceivably be tightened a little bit.
EDIT 2: The function is actually a collection of processes, a simulation of sorts, it produces a number of outputs. I have those 8 inputs which I am trying to calibrate such that the outputs closely match the reality I am simulating. So I have 'observed' values for those outputs, and the simulated ones for each set of 8 inputs. That's how the 'loss' is defined: as distance from that fixed set of observed values.
I do not know limits, or whether it is differentiable.
optimization economics
New contributor
|
show 2 more comments
I have a function with 8 inputs, which yields a single output. I do not know what the function does and so cannot use any derivative-based method to minimise said output.
Currently this is done by picking n random vectors, with some bounds for each input, obtaining an output value for each vector, and picking the lowest output from a vector of n.
I have been told to try Ant Colony Optimisation, however I struggle to see how I could implement that for a function with that many inputs.
Any ideas as to how to approach this problem in a better way than it is currently being done will be much appreciated.
The function itself takes a non-negligible time to run, so I am interested in ways to most efficiently (solving the function as low number of times as possible) find a minimum.
EDIT: The bounds for each of the 8 inputs are (0,1), but could conceivably be tightened a little bit.
EDIT 2: The function is actually a collection of processes, a simulation of sorts, it produces a number of outputs. I have those 8 inputs which I am trying to calibrate such that the outputs closely match the reality I am simulating. So I have 'observed' values for those outputs, and the simulated ones for each set of 8 inputs. That's how the 'loss' is defined: as distance from that fixed set of observed values.
I do not know limits, or whether it is differentiable.
optimization economics
New contributor
What kind of mathematical soplution are you expecting? If I interpret right, you have a function $f:mathbb R^8tomathbb R$ with random outputs for each input, and you want to minimise $f$?
– YiFan
15 hours ago
I'm afraid I do not follow. What do you mean by random outputs for each input?
– MrKaplan
15 hours ago
My point being, we know nnothing about the function you just gave us. We don't even know that it is well-behaved (in the sense that it is continuous, differentiable, etc.), so what results, mathematically, do you think we can derive?
– YiFan
15 hours ago
Right, I also know relatively little about it. It is continuous. I know that it takes those 8 inputs and produces a single output in the form a 'loss', which is what I want to minimise.
– MrKaplan
15 hours ago
So it is continuous; is it differentiable? Bounded? Do you know any limits? You should put everything you know in the question, which will make the problem easier to answer. It would definitely help to put the context in which the function comes up as well; what "loss" does this function represent?
– YiFan
15 hours ago
|
show 2 more comments
I have a function with 8 inputs, which yields a single output. I do not know what the function does and so cannot use any derivative-based method to minimise said output.
Currently this is done by picking n random vectors, with some bounds for each input, obtaining an output value for each vector, and picking the lowest output from a vector of n.
I have been told to try Ant Colony Optimisation, however I struggle to see how I could implement that for a function with that many inputs.
Any ideas as to how to approach this problem in a better way than it is currently being done will be much appreciated.
The function itself takes a non-negligible time to run, so I am interested in ways to most efficiently (solving the function as low number of times as possible) find a minimum.
EDIT: The bounds for each of the 8 inputs are (0,1), but could conceivably be tightened a little bit.
EDIT 2: The function is actually a collection of processes, a simulation of sorts, it produces a number of outputs. I have those 8 inputs which I am trying to calibrate such that the outputs closely match the reality I am simulating. So I have 'observed' values for those outputs, and the simulated ones for each set of 8 inputs. That's how the 'loss' is defined: as distance from that fixed set of observed values.
I do not know limits, or whether it is differentiable.
optimization economics
New contributor
I have a function with 8 inputs, which yields a single output. I do not know what the function does and so cannot use any derivative-based method to minimise said output.
Currently this is done by picking n random vectors, with some bounds for each input, obtaining an output value for each vector, and picking the lowest output from a vector of n.
I have been told to try Ant Colony Optimisation, however I struggle to see how I could implement that for a function with that many inputs.
Any ideas as to how to approach this problem in a better way than it is currently being done will be much appreciated.
The function itself takes a non-negligible time to run, so I am interested in ways to most efficiently (solving the function as low number of times as possible) find a minimum.
EDIT: The bounds for each of the 8 inputs are (0,1), but could conceivably be tightened a little bit.
EDIT 2: The function is actually a collection of processes, a simulation of sorts, it produces a number of outputs. I have those 8 inputs which I am trying to calibrate such that the outputs closely match the reality I am simulating. So I have 'observed' values for those outputs, and the simulated ones for each set of 8 inputs. That's how the 'loss' is defined: as distance from that fixed set of observed values.
I do not know limits, or whether it is differentiable.
optimization economics
optimization economics
New contributor
New contributor
edited 15 hours ago
New contributor
asked 15 hours ago
MrKaplan
11
11
New contributor
New contributor
What kind of mathematical soplution are you expecting? If I interpret right, you have a function $f:mathbb R^8tomathbb R$ with random outputs for each input, and you want to minimise $f$?
– YiFan
15 hours ago
I'm afraid I do not follow. What do you mean by random outputs for each input?
– MrKaplan
15 hours ago
My point being, we know nnothing about the function you just gave us. We don't even know that it is well-behaved (in the sense that it is continuous, differentiable, etc.), so what results, mathematically, do you think we can derive?
– YiFan
15 hours ago
Right, I also know relatively little about it. It is continuous. I know that it takes those 8 inputs and produces a single output in the form a 'loss', which is what I want to minimise.
– MrKaplan
15 hours ago
So it is continuous; is it differentiable? Bounded? Do you know any limits? You should put everything you know in the question, which will make the problem easier to answer. It would definitely help to put the context in which the function comes up as well; what "loss" does this function represent?
– YiFan
15 hours ago
|
show 2 more comments
What kind of mathematical soplution are you expecting? If I interpret right, you have a function $f:mathbb R^8tomathbb R$ with random outputs for each input, and you want to minimise $f$?
– YiFan
15 hours ago
I'm afraid I do not follow. What do you mean by random outputs for each input?
– MrKaplan
15 hours ago
My point being, we know nnothing about the function you just gave us. We don't even know that it is well-behaved (in the sense that it is continuous, differentiable, etc.), so what results, mathematically, do you think we can derive?
– YiFan
15 hours ago
Right, I also know relatively little about it. It is continuous. I know that it takes those 8 inputs and produces a single output in the form a 'loss', which is what I want to minimise.
– MrKaplan
15 hours ago
So it is continuous; is it differentiable? Bounded? Do you know any limits? You should put everything you know in the question, which will make the problem easier to answer. It would definitely help to put the context in which the function comes up as well; what "loss" does this function represent?
– YiFan
15 hours ago
What kind of mathematical soplution are you expecting? If I interpret right, you have a function $f:mathbb R^8tomathbb R$ with random outputs for each input, and you want to minimise $f$?
– YiFan
15 hours ago
What kind of mathematical soplution are you expecting? If I interpret right, you have a function $f:mathbb R^8tomathbb R$ with random outputs for each input, and you want to minimise $f$?
– YiFan
15 hours ago
I'm afraid I do not follow. What do you mean by random outputs for each input?
– MrKaplan
15 hours ago
I'm afraid I do not follow. What do you mean by random outputs for each input?
– MrKaplan
15 hours ago
My point being, we know nnothing about the function you just gave us. We don't even know that it is well-behaved (in the sense that it is continuous, differentiable, etc.), so what results, mathematically, do you think we can derive?
– YiFan
15 hours ago
My point being, we know nnothing about the function you just gave us. We don't even know that it is well-behaved (in the sense that it is continuous, differentiable, etc.), so what results, mathematically, do you think we can derive?
– YiFan
15 hours ago
Right, I also know relatively little about it. It is continuous. I know that it takes those 8 inputs and produces a single output in the form a 'loss', which is what I want to minimise.
– MrKaplan
15 hours ago
Right, I also know relatively little about it. It is continuous. I know that it takes those 8 inputs and produces a single output in the form a 'loss', which is what I want to minimise.
– MrKaplan
15 hours ago
So it is continuous; is it differentiable? Bounded? Do you know any limits? You should put everything you know in the question, which will make the problem easier to answer. It would definitely help to put the context in which the function comes up as well; what "loss" does this function represent?
– YiFan
15 hours ago
So it is continuous; is it differentiable? Bounded? Do you know any limits? You should put everything you know in the question, which will make the problem easier to answer. It would definitely help to put the context in which the function comes up as well; what "loss" does this function represent?
– YiFan
15 hours ago
|
show 2 more comments
1 Answer
1
active
oldest
votes
A relatively simple way to optimize a continuous, non-differentiable function is Nelder-Mead simplex optimization (which, as the linked Wikipedia article comments, is "[n]ot to be confused with Dantzig's simplex algorithm for the problem of linear optimization"). Nelder-Mead has been implemented in many computational systems (e.g. optim(...,method="Nelder-Mead")
in R, scipy.optimize.minimize(..., method='Nelder-Mead')
in Python, etc. etc.; Numerical Recipes will give you versions in FORTRAN, C, and C++). It's also simple enough that you could implement it yourself if necessary. The simplex method works by constructing an $n$-dimensional simplex of evaluation points and then iteratively using simple heuristic rules (e.g. "find the worst point and establish a new trial point by reflecting through the opposing face of the simplex") to update until the simplex converges approximately to a point.
It's hard to say how many function evaluations would be required, but I would say you could expect on the order of dozens to hundreds of evaluations for a reasonably well-behaved 8-dimensional optimization problem.
It's not clear whether the (0,1) bounds on your inputs are hard constraints (i.e., are you pretty sure that the optimum is inside that space, or do you need to constrain the solution to that space)? If they are, things get a bit harder as most Nelder-Mead implementations don't allow for box constraints (i.e., independent upper/lower bounds on parameters). You can take a look at Powell's BOBYQA method, which might actually be a little more efficient than Nelder-Mead (although also more complex; FORTRAN implementations are available ...)
If you can guess that your function is differentiable (which seems like a good guess if the underlying simulation process is deterministic and doesn't contain sharp if/then switches), then you could also (in principle) compute gradients at each point by finite difference methods, i.e.
$$
frac{partial f(x_1,...,x_i,...,x_n)}{partial x_i} approx (1/delta) cdot left(f(x_1^*,...,x_i^*+delta,...,x_n^*) - f(x_1^*,...,x_i^*,...,x_n^*)right)
$$
for a $delta$ that is neither too small (roundoff/floating-point error) nor too big (approximation error). Then you can use any derivative-based method you like. In practice this isn't always worth it; the combination of cost and numerical error in the finite-difference computations means this method may be dominated by the derivative-free methods described above.
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
return StackExchange.using("mathjaxEditing", function () {
StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix) {
StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
});
});
}, "mathjax-editing");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "69"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
noCode: true, onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
MrKaplan is a new contributor. Be nice, and check out our Code of Conduct.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3061572%2fminimising-a-black-box-function%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
A relatively simple way to optimize a continuous, non-differentiable function is Nelder-Mead simplex optimization (which, as the linked Wikipedia article comments, is "[n]ot to be confused with Dantzig's simplex algorithm for the problem of linear optimization"). Nelder-Mead has been implemented in many computational systems (e.g. optim(...,method="Nelder-Mead")
in R, scipy.optimize.minimize(..., method='Nelder-Mead')
in Python, etc. etc.; Numerical Recipes will give you versions in FORTRAN, C, and C++). It's also simple enough that you could implement it yourself if necessary. The simplex method works by constructing an $n$-dimensional simplex of evaluation points and then iteratively using simple heuristic rules (e.g. "find the worst point and establish a new trial point by reflecting through the opposing face of the simplex") to update until the simplex converges approximately to a point.
It's hard to say how many function evaluations would be required, but I would say you could expect on the order of dozens to hundreds of evaluations for a reasonably well-behaved 8-dimensional optimization problem.
It's not clear whether the (0,1) bounds on your inputs are hard constraints (i.e., are you pretty sure that the optimum is inside that space, or do you need to constrain the solution to that space)? If they are, things get a bit harder as most Nelder-Mead implementations don't allow for box constraints (i.e., independent upper/lower bounds on parameters). You can take a look at Powell's BOBYQA method, which might actually be a little more efficient than Nelder-Mead (although also more complex; FORTRAN implementations are available ...)
If you can guess that your function is differentiable (which seems like a good guess if the underlying simulation process is deterministic and doesn't contain sharp if/then switches), then you could also (in principle) compute gradients at each point by finite difference methods, i.e.
$$
frac{partial f(x_1,...,x_i,...,x_n)}{partial x_i} approx (1/delta) cdot left(f(x_1^*,...,x_i^*+delta,...,x_n^*) - f(x_1^*,...,x_i^*,...,x_n^*)right)
$$
for a $delta$ that is neither too small (roundoff/floating-point error) nor too big (approximation error). Then you can use any derivative-based method you like. In practice this isn't always worth it; the combination of cost and numerical error in the finite-difference computations means this method may be dominated by the derivative-free methods described above.
add a comment |
A relatively simple way to optimize a continuous, non-differentiable function is Nelder-Mead simplex optimization (which, as the linked Wikipedia article comments, is "[n]ot to be confused with Dantzig's simplex algorithm for the problem of linear optimization"). Nelder-Mead has been implemented in many computational systems (e.g. optim(...,method="Nelder-Mead")
in R, scipy.optimize.minimize(..., method='Nelder-Mead')
in Python, etc. etc.; Numerical Recipes will give you versions in FORTRAN, C, and C++). It's also simple enough that you could implement it yourself if necessary. The simplex method works by constructing an $n$-dimensional simplex of evaluation points and then iteratively using simple heuristic rules (e.g. "find the worst point and establish a new trial point by reflecting through the opposing face of the simplex") to update until the simplex converges approximately to a point.
It's hard to say how many function evaluations would be required, but I would say you could expect on the order of dozens to hundreds of evaluations for a reasonably well-behaved 8-dimensional optimization problem.
It's not clear whether the (0,1) bounds on your inputs are hard constraints (i.e., are you pretty sure that the optimum is inside that space, or do you need to constrain the solution to that space)? If they are, things get a bit harder as most Nelder-Mead implementations don't allow for box constraints (i.e., independent upper/lower bounds on parameters). You can take a look at Powell's BOBYQA method, which might actually be a little more efficient than Nelder-Mead (although also more complex; FORTRAN implementations are available ...)
If you can guess that your function is differentiable (which seems like a good guess if the underlying simulation process is deterministic and doesn't contain sharp if/then switches), then you could also (in principle) compute gradients at each point by finite difference methods, i.e.
$$
frac{partial f(x_1,...,x_i,...,x_n)}{partial x_i} approx (1/delta) cdot left(f(x_1^*,...,x_i^*+delta,...,x_n^*) - f(x_1^*,...,x_i^*,...,x_n^*)right)
$$
for a $delta$ that is neither too small (roundoff/floating-point error) nor too big (approximation error). Then you can use any derivative-based method you like. In practice this isn't always worth it; the combination of cost and numerical error in the finite-difference computations means this method may be dominated by the derivative-free methods described above.
add a comment |
A relatively simple way to optimize a continuous, non-differentiable function is Nelder-Mead simplex optimization (which, as the linked Wikipedia article comments, is "[n]ot to be confused with Dantzig's simplex algorithm for the problem of linear optimization"). Nelder-Mead has been implemented in many computational systems (e.g. optim(...,method="Nelder-Mead")
in R, scipy.optimize.minimize(..., method='Nelder-Mead')
in Python, etc. etc.; Numerical Recipes will give you versions in FORTRAN, C, and C++). It's also simple enough that you could implement it yourself if necessary. The simplex method works by constructing an $n$-dimensional simplex of evaluation points and then iteratively using simple heuristic rules (e.g. "find the worst point and establish a new trial point by reflecting through the opposing face of the simplex") to update until the simplex converges approximately to a point.
It's hard to say how many function evaluations would be required, but I would say you could expect on the order of dozens to hundreds of evaluations for a reasonably well-behaved 8-dimensional optimization problem.
It's not clear whether the (0,1) bounds on your inputs are hard constraints (i.e., are you pretty sure that the optimum is inside that space, or do you need to constrain the solution to that space)? If they are, things get a bit harder as most Nelder-Mead implementations don't allow for box constraints (i.e., independent upper/lower bounds on parameters). You can take a look at Powell's BOBYQA method, which might actually be a little more efficient than Nelder-Mead (although also more complex; FORTRAN implementations are available ...)
If you can guess that your function is differentiable (which seems like a good guess if the underlying simulation process is deterministic and doesn't contain sharp if/then switches), then you could also (in principle) compute gradients at each point by finite difference methods, i.e.
$$
frac{partial f(x_1,...,x_i,...,x_n)}{partial x_i} approx (1/delta) cdot left(f(x_1^*,...,x_i^*+delta,...,x_n^*) - f(x_1^*,...,x_i^*,...,x_n^*)right)
$$
for a $delta$ that is neither too small (roundoff/floating-point error) nor too big (approximation error). Then you can use any derivative-based method you like. In practice this isn't always worth it; the combination of cost and numerical error in the finite-difference computations means this method may be dominated by the derivative-free methods described above.
A relatively simple way to optimize a continuous, non-differentiable function is Nelder-Mead simplex optimization (which, as the linked Wikipedia article comments, is "[n]ot to be confused with Dantzig's simplex algorithm for the problem of linear optimization"). Nelder-Mead has been implemented in many computational systems (e.g. optim(...,method="Nelder-Mead")
in R, scipy.optimize.minimize(..., method='Nelder-Mead')
in Python, etc. etc.; Numerical Recipes will give you versions in FORTRAN, C, and C++). It's also simple enough that you could implement it yourself if necessary. The simplex method works by constructing an $n$-dimensional simplex of evaluation points and then iteratively using simple heuristic rules (e.g. "find the worst point and establish a new trial point by reflecting through the opposing face of the simplex") to update until the simplex converges approximately to a point.
It's hard to say how many function evaluations would be required, but I would say you could expect on the order of dozens to hundreds of evaluations for a reasonably well-behaved 8-dimensional optimization problem.
It's not clear whether the (0,1) bounds on your inputs are hard constraints (i.e., are you pretty sure that the optimum is inside that space, or do you need to constrain the solution to that space)? If they are, things get a bit harder as most Nelder-Mead implementations don't allow for box constraints (i.e., independent upper/lower bounds on parameters). You can take a look at Powell's BOBYQA method, which might actually be a little more efficient than Nelder-Mead (although also more complex; FORTRAN implementations are available ...)
If you can guess that your function is differentiable (which seems like a good guess if the underlying simulation process is deterministic and doesn't contain sharp if/then switches), then you could also (in principle) compute gradients at each point by finite difference methods, i.e.
$$
frac{partial f(x_1,...,x_i,...,x_n)}{partial x_i} approx (1/delta) cdot left(f(x_1^*,...,x_i^*+delta,...,x_n^*) - f(x_1^*,...,x_i^*,...,x_n^*)right)
$$
for a $delta$ that is neither too small (roundoff/floating-point error) nor too big (approximation error). Then you can use any derivative-based method you like. In practice this isn't always worth it; the combination of cost and numerical error in the finite-difference computations means this method may be dominated by the derivative-free methods described above.
edited 7 hours ago
answered 12 hours ago
Ben Bolker
303210
303210
add a comment |
add a comment |
MrKaplan is a new contributor. Be nice, and check out our Code of Conduct.
MrKaplan is a new contributor. Be nice, and check out our Code of Conduct.
MrKaplan is a new contributor. Be nice, and check out our Code of Conduct.
MrKaplan is a new contributor. Be nice, and check out our Code of Conduct.
Thanks for contributing an answer to Mathematics Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
Use MathJax to format equations. MathJax reference.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3061572%2fminimising-a-black-box-function%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
What kind of mathematical soplution are you expecting? If I interpret right, you have a function $f:mathbb R^8tomathbb R$ with random outputs for each input, and you want to minimise $f$?
– YiFan
15 hours ago
I'm afraid I do not follow. What do you mean by random outputs for each input?
– MrKaplan
15 hours ago
My point being, we know nnothing about the function you just gave us. We don't even know that it is well-behaved (in the sense that it is continuous, differentiable, etc.), so what results, mathematically, do you think we can derive?
– YiFan
15 hours ago
Right, I also know relatively little about it. It is continuous. I know that it takes those 8 inputs and produces a single output in the form a 'loss', which is what I want to minimise.
– MrKaplan
15 hours ago
So it is continuous; is it differentiable? Bounded? Do you know any limits? You should put everything you know in the question, which will make the problem easier to answer. It would definitely help to put the context in which the function comes up as well; what "loss" does this function represent?
– YiFan
15 hours ago