Tom O'Brien
Tom O'Brien
To get this codebase up to standard, we need to add type hints. At the very least, perhaps we should start insisting that all new code has type hints added,...
PR #632 has cleaned up most of operator_utils, but the hermitian conjugation routines remain there. I'd like to refactor them into SymbolicOperator/PolynomialTensor - perhaps as an op.hc() or op.herm() routine...
Currently, we only allow the index of a SymbolicOperator to be a single number. In some cases (e.g. conversion to a sparse matrix or to a PolynomialTensor) this is required,...
The current codebase is a bit of a mess w.r.t. imports - we have a fair few near-circular imports that are just hacked away and reappear during refactoring. I'm not...
The Hermitian conjugation function is currently sitting in operator_utils.py where it's really hard to find, and it also has hardcoded functionality for each subclass of each operator. It should probably...
So I just saw the seeding behaviour in _study.py, e.g. at: https://github.com/quantumlib/OpenFermion-Cirq/blob/d2f5a871bb5aea1e53d280c0a0e4be999b0c8d9d/openfermioncirq/variational/study.py#L365 the offending statement being the line: >> seeds[i] if seeds is not None else numpy.random.randint(2**16) The issue with...
Changes the multi_measurement_histogram function to use pandas tools instead of a list comprehension. Testing in https://drive.google.com/file/d/1-EyfUCwBfiZ1sM1ELlX5_rp4O3Rl3uPK/view?usp=sharing shows a 100x speed improvement even for a small system (100k shots, 1 key).