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

Parameter defaults update #48

Merged
merged 3 commits into from
Jul 2, 2024
Merged

Conversation

venaturum
Copy link
Member

Addresses #47

I have just dumped all parameters into the JSON, whose value is not an empty string, including ones that are not useful for gurobi-logtools, such as Tune*.

Perhaps a bit overkill, but from what I can tell it won't hurt, and makes life easier.

@venaturum venaturum requested a review from simonbowly July 1, 2024 09:34
Copy link
Member

@simonbowly simonbowly left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me!

Does generate-defaults.py still work?

@venaturum
Copy link
Member Author

Does generate-defaults.py still work?

God damn it 😂

@venaturum
Copy link
Member Author

What's the rationale behind excluding parameters with inf defaults?

@simonbowly
Copy link
Member

What's the rationale behind excluding parameters with inf defaults?

I can't quite recall. At one point I was using comparison with defaults to generate a run name automatically e.g. 1002-Method1-Presolve0-modelname. Maybe having infinite defaults resulted in some odd behaviour there? Feel free to change it

@venaturum
Copy link
Member Author

I'll test it out and see how it goes

@venaturum
Copy link
Member Author

If you're referring to the functionality provided by python -m gurobi_logtools --write-to-dir ... then I think this is ok.

I tested this with two logs, one with TimeLimit=15, and the other with defaults (so TimeLimit=inf). The "Infinity" values are default so they're never picked up as a changed parameter and the resulting log names were:

1102-TimeLimit15-glass4-0.log
1102-glass4-0.log

Is there a chance I've missed something?

Assuming this works ok, I'll modify generate_defaults.py to allow infinite valued parameters then regenerate the new json files with the script.

@simonbowly
Copy link
Member

Sounds good, not sure what I was thinking there. Makes sense to have the infinite defaults included as well.

@venaturum venaturum merged commit 1583c07 into Gurobi:master Jul 2, 2024
6 checks passed
@venaturum venaturum deleted the v11_param_defaults branch July 2, 2024 14:18
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

Successfully merging this pull request may close these issues.

2 participants