Skip to content

Conversation

@thuytr18
Copy link
Collaborator

This pull request introduces a new feature to Quanti-gin that calculates the fidelity between the states and the true ground states.
Two new methods were added:

  • get_ground_state: calculates the ground state to a given molecule
  • calculate_fidelity: computes the fidelity between two states

thuytr18 and others added 30 commits March 21, 2025 16:58
@thuytr18 thuytr18 requested a review from nylser March 21, 2025 16:22
Copy link
Owner

@nylser nylser left a comment

Choose a reason for hiding this comment

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

Just one small change in the warning, otherwise it looks good

Co-authored-by: Korbinian Stein <[email protected]>
@thuytr18 thuytr18 requested a review from nylser March 26, 2025 16:50
@nylser nylser merged commit e1f886f into nylser:main Mar 26, 2025
1 check passed
nylser added a commit that referenced this pull request Mar 26, 2025
nylser pushed a commit that referenced this pull request Mar 26, 2025
* added TODO and a method for calculating the fidelity

* feat: added library to calculate ground state

* added hamiltonian and circuit to OptimizationResult

* added ground state and fidelity flag to Job class

* hamiltonian, circuit is None for FCI

* hamiltonian, circuit is returned for spa

* fidelity method to calculate fidelity between states

* add parameter for fidelity in generate jobs

* ground state method

* updated execute job for calculating optimized ground state

* added parameter ground state and calculate fidelity to job

* changed create result to get extra column for fidelity

* changed create result to get extra column for fidelity

* added fidelity as argument

* Changed ground state Hamiltonian to hardcore boson hamiltonian

* saved normal circuit

* changed ground state hamiltonian

* used Circuit to calculate optimized state

* deleted Hamiltonian

* deleted Hamiltonian

* add test and deleted unnecessary code

* add molecule parameter to OptimizationResult

* deleted ground_state parameter in Job

* OptimizationResult returns molecule too

* made get_ground_state a class method

* deleted ground_state parameter from Job

* added molecule from optimization result and some comments

* feat: optimize fidelity code for degenerated states

* chore: organize imports

* added warning if num_of_atoms greater than 8

* chore: optimized code and deleted commits

* chore: fix formatting

* chore: changed warning
@nylser nylser mentioned this pull request Mar 26, 2025
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