Comments (5)
Thanks! I suspected this was the change required, but I'm not familiar enough with the code to be confident.
from pygsti.
I had the same issue. This is the error message I got when trying to create a model:
File c:\Users\k0426\anaconda3\envs\working_env_new\Lib\site-packages\pygsti\models\modelconstruction.py:1847, in create_cloud_crosstalk_model(processor_spec, custom_gates, depolarization_strengths, stochastic_error_probs, lindblad_error_coeffs, depolarization_parameterization, stochastic_parameterization, lindblad_parameterization, evotype, simulator, independent_gates, independent_spam, errcomp_type, implicit_idle_mode, basis, verbosity)
1713 """
1714 Create a n-qudit "cloud-crosstalk" model.
1715
(...)
1840 CloudNoiseModel
1841 """
1843 modelnoise = _build_modelnoise_from_args(depolarization_strengths, stochastic_error_probs, lindblad_error_coeffs,
1844 depolarization_parameterization, stochastic_parameterization,
1845 lindblad_parameterization, allow_nonlocal=True)
-> 1847 return _create_cloud_crosstalk_model(processor_spec, modelnoise, custom_gates, evotype,
1848 simulator, independent_gates, independent_spam, errcomp_type,
1849 implicit_idle_mode, basis, verbosity)
File c:\Users\k0426\anaconda3\envs\working_env_new\Lib\site-packages\pygsti\models\modelconstruction.py:1876, in _create_cloud_crosstalk_model(processor_spec, modelnoise, custom_gates, evotype, simulator, independent_gates, independent_spam, errcomp_type, implicit_idle_mode, basis, verbosity)
1873 printer = _VerbosityPrinter.create_printer(verbosity)
1875 #Create static ideal gates without any noise (we use modelnoise
further down)
-> 1876 gatedict = _setup_local_gates(processor_spec, evotype, None, custom_gates,
1877 ideal_gate_type=('static standard', 'static clifford', 'static unitary'),
1878 basis=basis)
1879 stencils = _collections.OrderedDict()
1881 # (Note: global idle is now processed with other processorspec gates)
1882
1883 # SPAM
File c:\Users\k0426\anaconda3\envs\working_env_new\Lib\site-packages\pygsti\models\modelconstruction.py:1475, in _setup_local_gates(processor_spec, evotype, modelnoise, custom_gates, ideal_gate_type, basis)
1473 ideal_gate = ideal_gates.get(name, None)
1474 if ideal_gate is None:
-> 1475 ideal_gate = _op.create_from_unitary_mx(U, ideal_gate_type, basis, stdname, evotype, state_space=None)
1476 ideal_gates[name] = ideal_gate
1477 noiseop = modelnoise.create_errormap(key, evotype, ideal_gate.state_space, target_labels=None)
File c:\Users\k0426\anaconda3\envs\working_env_new\Lib\site-packages\pygsti\modelmembers\operations_init_.py:59, in create_from_unitary_mx(unitary_mx, op_type, basis, stdname, evotype, state_space)
57 try:
58 if typ == 'static standard' and stdname is not None:
---> 59 op = StaticStandardOp(stdname, basis, evotype, state_space)
60 elif typ == 'static clifford':
61 op = StaticCliffordOp(U, None, basis, evotype, state_space)
File c:\Users\k0426\anaconda3\envs\working_env_new\Lib\site-packages\pygsti\modelmembers\operations\staticstdop.py:58, in StaticStandardOp.init(self, name, basis, evotype, state_space)
55 basis = _Basis.cast(basis, state_space.dim) # basis for Hilbert-Schmidt (superop) space
57 evotype = _Evotype.cast(evotype)
---> 58 rep = evotype.create_standard_rep(name, basis, state_space)
59 _LinearOperator.init(self, rep, evotype)
File c:\Users\k0426\anaconda3\envs\working_env_new\Lib\site-packages\pygsti\evotypes\evotype.py:136, in Evotype.create_standard_rep(self, standard_name, super_basis, state_space)
135 def create_standard_rep(self, standard_name, super_basis, state_space):
--> 136 return self.module.OpRepStandard(standard_name, super_basis, state_space)
File c:\Users\k0426\anaconda3\envs\working_env_new\Lib\site-packages\pygsti\evotypes\densitymx_slow\opreps.py:177, in OpRepStandard.init(self, name, basis, state_space)
174 state_space = _StateSpace.cast(state_space)
175 assert(superop.shape[0] == state_space.dim)
--> 177 super(OpRepStandard, self).init(superop, state_space)
TypeError: OpRepDenseSuperop.init() missing 1 required positional argument: 'state_space'
from pygsti.
Thanks for reporting this and for identifying a hole in our testing! This should be a quick fix, I'll have something on develop for you in the next day or so hopefully. We'll also add some tests in an environment without Cython
to ensure we catch things like this in the future.
from pygsti.
I believe this is a one-line fix. It will be merged into develop
shortly, and we are planning a hotfix release soon, but if you want to try the change locally and let me know if you run into other issues, you are certainly welcome to.
We go from:
to:
from pygsti.
Closing as this was merged into develop
with #439. The fixed-but-not-in-release
tag will remain until the 0.9.12.3 release, which will include this fix.
from pygsti.
Related Issues (20)
- Audit usage of linalg.inv
- Error gen projection basis must be Basis object HOT 1
- Method `parameter_labels()` returns an empty array HOT 1
- 1/2 Diamond Norm Errorbars
- Raw Estimates Errorbars for TPInstrument HOT 1
- CP Instruments & Instrument Error Generators
- QI Report Fixes & Additions
- Wildcard w/ QILGST
- Fisher Information w/ Experiment Designs Containing MCMs
- Explicit Model Construction from MCM-Containing Pspec
- Help with detecting crosstalk errors of simulated data
- Serialization Issue w/ Processor Spec Nonstd_Instruments HOT 1
- Numpy version dependency HOT 1
- Gswap cannot be used as a two-qubit standard native gate for two-qubit RB as CliffordCompilationRules taking too long
- Line label reordering during `Circuit` concatenation
- Generating Random Error Generators HOT 4
- Design pspec sslbl bug in modelpacks
- Serialization for ModelEstimateResults HOT 2
- Depolarizing SPAM in H-Only Models Silently Fails (and Discussion of How to Properly Regularize Reduced Models)
- Add cycle benchmarking with mid-circuit measurements
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pygsti.