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

make the Runner work with unhashable points #268

Merged
merged 15 commits into from
Apr 24, 2020

Conversation

basnijholt
Copy link
Member

@basnijholt basnijholt commented Apr 16, 2020

Description

Enable the Runner to with with unhashable points.

Fixes #267.

Checklist

  • Fixed style issues using pre-commit run --all (first install using pip install pre-commit)
  • pytest passed

Type of change

Check relevant option(s).

  • 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 not work as expected)
  • This change requires a documentation update

@basnijholt basnijholt force-pushed the unhashable-runner-points branch 3 times, most recently from 7e96a7c to 8a0adf3 Compare April 16, 2020 18:11
@basnijholt basnijholt changed the title WIP: make the Runner work with unhashable points make the Runner work with unhashable points Apr 16, 2020
adaptive/runner.py Outdated Show resolved Hide resolved
adaptive/runner.py Outdated Show resolved Hide resolved
@codecov-io
Copy link

codecov-io commented Apr 17, 2020

Codecov Report

Merging #268 into master will decrease coverage by 0.17%.
The diff coverage is 50.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #268      +/-   ##
==========================================
- Coverage   79.52%   79.35%   -0.18%     
==========================================
  Files          32       32              
  Lines        4425     4446      +21     
  Branches      815      821       +6     
==========================================
+ Hits         3519     3528       +9     
- Misses        779      788       +9     
- Partials      127      130       +3     
Impacted Files Coverage Δ
adaptive/runner.py 64.58% <50.00%> (-1.71%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a0b22ff...62e9a41. Read the comment docs.

@jbweston
Copy link
Contributor

I've scheduled time later this morning (pacific time) to take a look at this.

Copy link
Contributor

@jbweston jbweston left a comment

Choose a reason for hiding this comment

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

Overall I agree with the approach, but I believe that we can make everything cleaner by only dealing with point IDs inside the runner itself. We only need to extract actual points at the interface between the runner and the outside world (when calling self.learner.ask and self._submit)

adaptive/runner.py Outdated Show resolved Hide resolved
adaptive/runner.py Outdated Show resolved Hide resolved
adaptive/runner.py Outdated Show resolved Hide resolved
adaptive/runner.py Outdated Show resolved Hide resolved
adaptive/runner.py Outdated Show resolved Hide resolved
adaptive/runner.py Outdated Show resolved Hide resolved
@basnijholt
Copy link
Member Author

@jbweston, thanks a lot for your review!

I've implemented all suggestions you've made 🎉

adaptive/runner.py Outdated Show resolved Hide resolved
Copy link
Contributor

@jbweston jbweston left a comment

Choose a reason for hiding this comment

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

LGTM! Nice work

@basnijholt basnijholt merged commit 5754320 into master Apr 24, 2020
basnijholt added a commit that referenced this pull request Apr 24, 2020
@basnijholt basnijholt mentioned this pull request May 19, 2020
@basnijholt basnijholt deleted the unhashable-runner-points branch May 20, 2020 08:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Make Runner work with unhashable points
4 participants