-
Notifications
You must be signed in to change notification settings - Fork 174
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
Made encoders probeable from ensembles #1167
Conversation
Thank you for the PR! I added a commit to rename the probed attribute to @bmorcos You need to sign Contributor Assignment Agreement (instructions are under that link) before we can merge this PR.
|
LGTM. Although the history is a bit messy, but I guess we'll leave that up to the maintainers to fix on merge? |
@tbekolay this has been ready to merge for a while. Any chance of getting it merged soon? |
@@ -411,6 +412,8 @@ def test_voja_encoders(Simulator, nl_nodirect, rng, seed): | |||
assert np.allclose( | |||
sim.data[p_enc][tend, :n_change] / encoder_scale[:n_change], | |||
learned_vector, atol=0.01) | |||
# Check that encoders probed from ensemble euqal encoders probed from voja |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo (euqal) -- will fix in merge, noting here so I don't forget
ens = nengo.Ensemble(n_neurons=10, dimensions=2, radius=1.5) | ||
p_enc = nengo.Probe(ens, 'scaled_encoders') | ||
|
||
with nengo.Simulator(model) as sim: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In the future, use the Simulator
pytest fixture here rather than instantiating nengo.Simulator
directly. You can see how this is done in other tests in this file, like test_dts
. I'll fix this for now though :)
Encoders can still be probed via learning rule.
100476a
to
e1b4601
Compare
Merged, congrats to @bmorcos on your first merged PR! 😃 🌈 |
Motivation and context:
Feature request from #1117
Interactions with other PRs:
Change also implemented in #553 commit 4a572c3
How has this been tested?
Updated
test_probe.py
andtest_learning_rule.py
How long should this take to review?
Types of changes:
Checklist: