-
Notifications
You must be signed in to change notification settings - Fork 59
Miscellaneous Bugfixes for 0.9.14 #640
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
Fix a bug in the conversion from unitary model members to error generator ones present in the new SPAM conversion logic. All that was needed here was to change the space for the to_dense calls so they were consistent. Additionally adds a docstring to convert_members_inplace and set_default_gauge_group for the explicit model class. For set_default_gauge_group I have also changed the default behavior for the set_default_gauge_group function. Previously this would default to the TrivialGaugeGroup for all or most of the valid lindblad types. But in this case the unitary group is a better (though imperfect for edge cases) choice.
Partial patch for gauge optimization when using the statevec evotype that arises from difference in minimal reps for gauge group elements and operations.
There is an incompatibility between the statevec evotype and the representations used in gauge optimization. For now turn off gauge optimization on the GST tests which use the term forward simulator. Doing this most straightforwardly required adding a new option for the GST driver function.
Fix a bug in deserializing models saved before the recent changes to allow saving fogi stores.
Patch the diamond distance reportable function to account for a change to the return call signature for the diamond distance when returning the value of the SDP solution.
Some recent changes resulted in serialization using legacy json and msgpack serialization protocols breaking. This functionality has been deprecated for over two years, and so spending energy patching this doesn't make sense. Rather, this is as good a time as any to finally expire this deprecation.
Cleans up additional reference to the now expired legacy json and msgpack serialization protocols.
Add in casting logic to set_errorgen_coefficients when the input lindblad dictionary has label types which do not match the object being updated. Also add handling for edge case where the update dictionary is empty.
Change the default for run_long_sequence_gst's gauge optimization to use stdgaugeopt
Update the default gauge optimization settings of run_long_sequence_gst_base to match the non base counterpart.
Fix a small logic bug that meant certain dictionary values weren't be retained properly.
Minor patches to address some unbound variable name and related errors in color box plots, and some of type mismatches in the workspace tables.
Regenerate reference files for test_packages module to account for recent changes.
Update gauge optimization labels to account for recent default gauge optimization suite change. Turn off gauge optimization for model types which do not properly support it.
We're encountering CI issues with this field, and some googling indicates this is because there have been some changes to the conventions for this and not all versions of the build utilities (like setuptools) support these changes across all versions yet.
@coreyostrove I've triggered a CI build that runs the tests for beta and master, changed to target this branch: https://github.com/sandialabs/pyGSTi/actions/runs/17054858542 If those tests pass then I'll approve. Makes more sense to go this route than have me review the individual changes. |
Smx = s.transform_matrix; Si = s.transform_matrix_inverse | ||
Tinv = _np.linalg.inv(self.factorops[0].to_dense("minimal")) | ||
trans_eLT = _np.dot(Si, _np.dot(self.to_dense("minimal"), Smx)) | ||
Tinv = _np.linalg.inv(self.factorops[0].to_dense("HilbertSchmidt")) |
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.
Why are we limiting this hack for state_space.dim <= 16
?
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.
Presumably just because it is expensive to perform the dense operations required with 3 or more qubits, but is faster than whatever other code path is used for 2Q and 3Q. This is incidentally not the biggest problem with this function at the moment, though. See #620 for more on that.
Revert changes from when I was debugging.
Something changed in some package which is producing np float objects which didn't have serialization logic in nameddict. Add a cast to standard python float.
Numpy 2.3 expired this deprecation for tostring.
The beta tests on the runners caught a couple extra issues that I didn't get locally. One was an expired deprecation of the |
Relaunched the beta tests with those extra patches (still need to fix the cython environment variable). |
See if we can figure out why it is that the workflow is triggering the ubuntu and macos branch on windows.
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.
The CI tests that still fail are due to how we're executing a command on Windows. I'm fine with merging as-is.
Awesome, thanks! I'm going to keep plugging away at getting the workflow corrected for the no cython build on this branch and will merge it in once those are running correctly. |
This reverts commit 41dde39.
This reverts commit e89ca79.
Realistically we probably don't need to run against all OS combinations to achieve the coverage goals of this particular build. Save on some resources.
…nto bugfixes-914
Previous attempt was still running partial workflows on windows and macos.
And remove a couple unused imports from fogistore.py
Strip newlines and carriage returns from output before doing error checking.
Lower the maximum depth of the fisher information computation with instruments in unit test. Also a miscellaneous workflow change.
Fix a bug related to a mismatch between current behavior of DataSet.gate_labels and target model labels.
This PR consists of miscellaneous bug fixes and patches in preparation of the 0.9.14 release which were being caught by tests within the
test_packages
submodule (which are run against pushes to beta and master). Here is a brief summary:convert_members_inplace
andset_default_gauge_group_for_member_type
methods of theExplicitModel
class.set_default_gauge_group_for_member_type
for error generator parameterized models. Previously this was configured to set the default gauge group for such models to theTrivialGaugeGroup
. Now we set this to be theUnitaryGaugeGroup
, as one would more likely expect.pygsti.report.reportables
related to a recent change in the return signature for thediamonddist
function inoptools
.NicelySerializable
interface) and msgpack. We formally deprecated this functionality just over two years and had these marked for removal, so any users who might've been using this have been getting warnings for some time. Rather than invest any time fixing this, it makes more sense to finally expire these deprecations.run_long_sequence_gst
andrun_long_sequence_gst_base
. At the same time the default gauge optimization suite used for these functions has been switched to 'stdgaugeopt'. This brings these functions in line with their OOP-based counterpartGateSetTomography
which has used this gauge optimization suite as the default for a while.set_errorgen_coefficients
method ofComposedOp
to add handling for the cases where the update dictionary is empty, or has keys which do not match theElementaryErrorgenLabel
type of the modelmember.test_packages
have been regenerated to account for recent default setting changes.With these updates we have the tests on beta now passing (at least when run locally on my system, TBD on runners).