Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Add template to prepare quantum states of molecules using the excitation operations #1383
Add template to prepare quantum states of molecules using the excitation operations #1383
Changes from 32 commits
6cbfbe9
1f08079
29a38ad
7ee1c3f
d171b07
d5a672b
ebf688c
4b388c7
0982ae8
15cd191
33f5208
d5609bf
a8428f8
901536a
d4ff316
acb89c7
4523ebb
eb9b7ba
3326044
42358a8
00f576d
99daea1
b1604dd
20ed330
2e22598
39b236c
c1f24d0
f618d6a
eb1d909
3ad3935
270764e
4082bb3
548af4c
768f7a3
824758d
132b638
7798409
4a07399
74b4a57
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
I somehow like the name :)
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.
It's still a matter of taste, but we are trying to keep the checks to an absolute minimum, because they are used in every qnode call...
My thinking is that we should check tensor dimensions (since this is an annoying error to see), and things that are theoretically tricky. So if this check is something a user with a look at the docs can get right, maybe we should delete it?
Non-blocking comment though
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.
Good point. My concern in removing this check is that the user may want to call this template without passing
singles
anddoubles
. In this case, the template will not raise an error, will only prepare the HF state and numbers will come out (even though the state the user is preparing is trivial). I vote to keep it :-).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.
I didn't know that
not a
evaluates to True ifa=None
, interesting!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.
Nice! I need to get used to using
qml.math