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

Plugging new parametrization inside instrumentation and optimization #391

Merged
merged 150 commits into from
Jan 17, 2020

Conversation

jrapin
Copy link
Contributor

@jrapin jrapin commented Dec 19, 2019

Types of changes

  • Docs change / refactoring / dependency upgrade
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Motivation and Context / Related issue

How Has This Been Tested (if it applies)

FYI: this is expected to land after January 8th

This plugs parametrization as created in #323
To do so, the new Instrumentation is extended with old Variable methods, and the old Variable inherits from Instrumentation  and overrides the new methods. 

This is not expected to change anything for you, but some printed information may change, and deprecation warnings will appear for some methods (Eg.: set_cheap_constraint_checker -> register_cheap_constraint with a slightly different API). Some probably unused functions will disappear (get_description) making the changes breaking anyway. At this point you will be able to use new Parameter classes, but their initialization may be inaccurate so it will not be advised in some cases (you would get a user warning). Also, because of the compatibility, we expect optimizers to be about 25% slower in this version. The optimizer will still only take an Instrumentation (new version) as input for its initialization.

Checklist

  • The documentation is up-to-date with the changes I made.
  • I have read the CONTRIBUTING document and completed the CLA (see CONTRIBUTING).
  • All tests passed, and additional code has been covered with new tests.

@jrapin jrapin changed the base branch from instrumentation_v3 to master December 30, 2019 21:06
docs/parametrization.md Outdated Show resolved Hide resolved
@jrapin
Copy link
Contributor Author

jrapin commented Jan 6, 2020

For the record:
Locally pytest nevergrad/optimization has gone up from 45s to 70s. Next PR will hopefully revert the change, which is due to the need of keeping both compatibilities.

@jrapin jrapin merged commit f083cc7 into master Jan 17, 2020
@jrapin jrapin deleted the variable_as_instrumentation branch January 20, 2020 15:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed Do not delete this pull request or issue due to inactivity. Difficulty: High Priority: Critical Status: Review needed Type: Breaking changes Breaking changes to the API, to be notified in changelogs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants