-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Optimize ParamResolver.value_of #6341
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
Changes from all commits
e3d618b
cfe0a50
c7848c1
9a4037c
e3a7d61
abf9532
b4b3acf
440806d
68631ed
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -100,7 +100,7 @@ def test_sampler_multiple_jobs(): | |
results = sampler.sample( | ||
program=circuit, | ||
repetitions=4, | ||
params=[cirq.ParamResolver({x: '0.5'}), cirq.ParamResolver({x: '0.6'})], | ||
params=[cirq.ParamResolver({x: 0.5}), cirq.ParamResolver({x: 0.6})], | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This was coincidentally working before because the |
||
) | ||
pd.testing.assert_frame_equal( | ||
results, | ||
|
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.
Not sure why we decided to always return a symbol here even if resolving a string. My preference would be to return the given value unchanged if the resolver doesn't need to change it, but callers could rely on this behavior so we should be careful if we want to change it.