Skip to content
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

Defining the new Backend API classes #764

Draft
wants to merge 23 commits into
base: develop
Choose a base branch
from
Draft

Conversation

HGSilveri
Copy link
Collaborator

@HGSilveri HGSilveri commented Nov 19, 2024

  • Introduces the Results class and make Result a subclass of it in backwards compatible way
  • Defines the State and Operator ABCs
  • Updates BackendConfig and defines EmulationConfig
  • Defines the EmulatorBackend ABC
  • Defines the Callback and Observable ABCs
  • Defines the default observables

To do:

  • Define QutipState to have an example
  • Idem for QutipOperator
  • Solve relevant TODOs
  • Write UTs

)

if default_evaluation_times != "Full":
eval_times_arr = np.array(default_evaluation_times, dtype=float)

Choose a reason for hiding this comment

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

why is this a np.array but below you use AbstractArray?

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 mean for interaction_matrix? I use AbstractArray because I expect people might want to differentiate against it

"""
pass

def infer_one_state(self) -> Eigenstate:

Choose a reason for hiding this comment

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

why do we not simply throw an error if the eigenbasis is not predefined? No backend would know how to simulate it anyway.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I'm not sure I get what you mean. Do you mean in the case that the eigenstates don't match one of these sets we would just throw an error right away?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants