Open mpharrigan opened 4 years ago
Programs and jobs in Engine have labels which you should be able to set with less restrictions (also they are string string maps)
Because the sampler interface is rigid, we can't add it to the run sweep.
I guess we could add a mutable state on EngineSampler
for these job and program fields
sampler = engine.sampler(processor_id='mine', gate_set=my_gate_set)
sampler.set_program_id('mine')
sampler.run_sweep(my_circuit)
You'd need to set it each time, so maybe it would be
sampler.set_next_program_id('mine')
Other ways to do this?
What about having an optional label/program_id attribute on Circuit
?
A label on Circuit sounds good to me - we can use that in Circuit diagrams as well as in SubCircuits later. cc @95-martin-orion
Assigning to @wcourtney for triage. Should we allow tags on a circuit that get turned into program labels?
When using the
QuantumEngineSampler
object to run programs on Quantum Engine there is no way to tag programs/jobs with short metadata which allows one to scan active jobs from the web UI.If you use the
Engine
object, you can set theprogram_id
parameter which is helpful but comes with its own set of restrictions (restricted character set; limited to 64 chars). "Tags" has been suggested to me as a better solution for this.In any event, it would be nice if we could add an optional member variable to
cirq.Circuit
which contains either aprogram_id
or tag to be used byQuantumEngineSampler