Skip to content

CR Hamiltonian tomo with group fit #718

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

Conversation

nkanazawa1989
Copy link
Collaborator

@nkanazawa1989 nkanazawa1989 commented Mar 7, 2022

Summary

This PR updates CrossResonanceHamiltonianAnalysis to perform fitting for curves with different control state separately. It has been a single multi-objective optimization though fit initial guesses for different control states are provided independently. This means we needed to test all O(N^2) init guesses (currently 225 loops) to find the best solution.

Now it uses group feature introduced in #715. With this update the number of loops is reduced from 225 to 2x15 which is much faster.

TODO: write reno

Details and comments

This is dependent on #715 thus should be merged after

This PR add new feature
- CurveAnalysis.curve_fit: this is class method, user can directly call fit function
- CompositeFitFunction: a function-like object for fitting

In addition unittest of curve analysis and class documentation are overhauled.

Following is deprecated
- CurveAnalysis.options.curve_fitter: This object is not serializable
The composite_func is no longer class attribute. It is converted into protected member and replaced with property method. This property method returns a copy of function to avoid conflict in the multithread execution. The parameter ordering is also fixed to match with original fit function signature.
@nkanazawa1989 nkanazawa1989 added the blocked Can't be worked on until another issue is resolved label Mar 7, 2022
@nkanazawa1989 nkanazawa1989 deleted the upgrade/cr_hamiltonian_with_group_fit branch October 27, 2022 06:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked Can't be worked on until another issue is resolved
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant