Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

4.x Constraint Tolerance Parameter Equivalent #120

Open
Arrowstar opened this issue Dec 28, 2022 · 8 comments
Open

4.x Constraint Tolerance Parameter Equivalent #120

Arrowstar opened this issue Dec 28, 2022 · 8 comments

Comments

@Arrowstar
Copy link

What are the NOMAD 4.x equivalent parameters to the 3.x parameters "h_min" and "h_norm"? I don't see anything that is roughly the same as these in the 4.x parameter list.

@ctribes
Copy link
Contributor

ctribes commented Jan 9, 2023

Parameters h_min and h_norm have not yet been transferred to Nomad 4. I increased the priority of this modif in the todo list.

@ctribes ctribes closed this as completed Jan 9, 2023
@ctribes
Copy link
Contributor

ctribes commented Jan 9, 2023

It is still possible to patch your version to get the equivalent of h_min and h_norm. Computation of H is done in the Eval class.

@ctribes ctribes reopened this Jan 9, 2023
@Arrowstar
Copy link
Author

It is still possible to patch your version to get the equivalent of h_min and h_norm. Computation of H is done in the Eval class.

Could you provide instructions on how I would go about this? Thank you!

@ctribes
Copy link
Contributor

ctribes commented Jan 9, 2023

In what follows, you can replace the NOMAD::Double::getEpsilon() with your value of H_MIN.

`bool NOMAD::Eval::isFeasible(NOMAD::ComputeType computeType) const
{

if (NOMAD::EvalStatusType::EVAL_OK != _evalStatus)

{

    throw NOMAD::Exception(__FILE__,__LINE__,"Eval::isFeasible: Needs status type EVAL_OK");

}

NOMAD::Double h = getH(computeType);

return (h.isDefined() && h.todouble() < NOMAD::Double::getEpsilon());

}`

In what follows, you can change how hTemp is computed

`NOMAD::Double NOMAD::Eval::computeHStandard() const
{

....

else if (NOMAD::BBOutputType::PB == bbOutputType)

        {

            hTemp = bboI * bboI;

        }

....`

@Arrowstar
Copy link
Author

Thank you for the code. I've taken a look and it looks like I'd have to substitute my own static value before compiling. Unfortunately I need my users to be able to specify this value themselves, so it looks like I need to wait for the h_min parameter to get implemented properly in NOMAD 4. I appreciate you increasing the priority of these two parameters. Thank you!

@Arrowstar
Copy link
Author

Did anything related to this get added in release 4.4?

@ctribes
Copy link
Contributor

ctribes commented Jan 10, 2024

Not yet.
I was passing through the issues today when I realized I did not do it.
I am currently looking how to do it.
I will push the modif into the master branch when done and will let you know.
It will make its way into v.4.4.1 after that.

@Arrowstar
Copy link
Author

Not yet. I was passing through the issues today when I realized I did not do it. I am currently looking how to do it. I will push the modif into the master branch when done and will let you know. It will make its way into v.4.4.1 after that.

That'll be fine, thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants