Skip to content

9 implement dev tools and document usage #18

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

Merged
merged 10 commits into from
Nov 22, 2023

Conversation

elenbaasc
Copy link
Collaborator

No description provided.

@elenbaasc elenbaasc added the enhancement New feature or request label Nov 22, 2023
@elenbaasc elenbaasc requested a review from pablolh November 22, 2023 08:27
@elenbaasc elenbaasc linked an issue Nov 22, 2023 that may be closed by this pull request
@@ -5,7 +5,7 @@


# This should only be used for testing and on circuits with low number of qubits.
def getBigMatrix(semantic, qubitOperands, totalQubits):
def getBigMatrix(semantic: MultiQubitMatrixSemantic, qubitOperands, totalQubits):
Copy link

Choose a reason for hiding this comment

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

The correct type here is the parent class Semantic in the current code

Copy link

Choose a reason for hiding this comment

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

(see below isinstance)

Copy link
Collaborator Author

@elenbaasc elenbaasc Nov 22, 2023

Choose a reason for hiding this comment

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

Yes, makes sense!

Perhaps we should make Semantic an ABC then?

Copy link

Choose a reason for hiding this comment

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

It is indeed an ABC! I just only recently discovered that you can use this in Python with an extra module - it's not in the language by default I believe.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

You need to import the abc library indeed (https://docs.python.org/3/library/abc.html).

I was also thinking if it would be an idea to create ABCs for the various passes. And Users can then define new passes based on those interfaces. We have done a similar thing with NetSquid.

@elenbaasc elenbaasc merged commit 8e3c6e4 into master Nov 22, 2023
@elenbaasc elenbaasc deleted the 9-implement-dev-tools-and-document-usage branch April 9, 2024 08:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement dev-tools (and document usage)
2 participants