Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

run test_balancing_learner for all strategies#218

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
basnijholt wants to merge1 commit intomain
base:main
Choose a base branch
Loading
fromtest_balancing_learner_all_strategies

Conversation

@basnijholt
Copy link
Member

@basnijholtbasnijholt commentedSep 18, 2019
edited
Loading

@python-adaptive/core this reveals a regression in theLearnerND.

Should we merge this already (without a fix)?

also: @JornHoofwijk

@basnijholt
Copy link
MemberAuthor

Something broke in between these two commits tolearnerND.py
image

However, when I reverse the exact changes fromca8b1d5 in that state of the repo, it is still broken.

So seemingly it is not the code inside theLearnerND that causes the error.

@basnijholt
Copy link
MemberAuthor

basnijholt commentedSep 18, 2019
edited
Loading

test.py

#!/usr/bin/env python3importsysfromfunctoolsimportpartialimportadaptivef=lambdax:x[0]learner=adaptive.BalancingLearner(    [adaptive.LearnerND(f,bounds=[(-1,1), (-1,1)])],strategy="loss")try:# fails in masteradaptive.runner.simple(learner,goal=lambdal:l.learners[0].npoints>20)except:sys.exit(1)sys.exit(0)

using the power ofgit bisect:

export PYTHONWARNINGS="ignore"git bisect start ca8b1d5f70ca7fc05a2c8fddf813894a19fc3595 3f617442acdff18fcf4c2aceb725f7a93f0827c9git bisect run ./test.py
running ./test.pyBisecting: 4 revisions left to test after this (roughly 2 steps)[c233ceb9daecd7eaa32232551e2b3c5472ede815] change while loop to normal looprunning ./test.pyBisecting: 2 revisions left to test after this (roughly 1 step)[07f24b9ee02c72d811726c8dc76bd92ccd18b41e] add a test to ask for 0 pointsrunning ./test.pyBisecting: 0 revisions left to test after this (roughly 1 step)[dc846e1513f7d28dcd5dd3fa9d1d7622a1b56222] add missing tell_pendingrunning ./test.pyBisecting: 0 revisions left to test after this (roughly 0 steps)[fa616ef3537ac954138f2bf7fbc20cb1159e5ea3] fix asking for 0 pointsrunning ./test.pydc846e1513f7d28dcd5dd3fa9d1d7622a1b56222 is the first bad commitcommit dc846e1513f7d28dcd5dd3fa9d1d7622a1b56222Author: Bas Nijholt <basnijholt@gmail.com>Date:   Sun Mar 17 17:10:55 2019 +0100    add missing tell_pending

Sodc846e1 is the culprit introduced in#160.

@jbweston
Copy link
Contributor

We should probably add the test, but we can probably wait until#220 is merged, because that will replace LearnerND anyway.

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

3 participants

@basnijholt@jbweston

[8]ページ先頭

©2009-2025 Movatter.jp