Skip to content

Commit

Permalink
Update power
Browse files Browse the repository at this point in the history
  • Loading branch information
phantomlsh committed Dec 16, 2024
1 parent abe4872 commit b921c30
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 6 deletions.
11 changes: 7 additions & 4 deletions docs/Tutorials/experiment.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,10 +107,13 @@ Use your pi pulse to plot the IQ scatter to see the readout visibility and fidel

```python
v["r_phase"] = 0
data = quick.experiment.IQScatter(var=v).run().data.T
c0, c1, visibility, Fg, Fe, fig = quick.iq_scatter(data[0] + 1j * data[1], data[2] + 1j * data[3])
v["r_phase"], v["r_threshold"] = quick.iq_rotation(c0, c1)
fig.show()
for _ in range(1): # iterate
data = quick.experiment.IQScatter(var=v).run().data.T
c0, c1, visibility, Fg, Fe, fig = quick.iq_scatter(data[0] + 1j * data[1], data[2] + 1j * data[3])
phase_delta, v["r_threshold"] = quick.iq_rotation(c0, c1)
v["r_phase"] += phase_delta
v["r_phase"] %= 360
plt.show()
```

You can also use the `DispersiveSpectroscopy` to find the best value for `v["r_freq"]`. See API References for details.
Expand Down
2 changes: 1 addition & 1 deletion quick/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.3.5
0.3.6
2 changes: 1 addition & 1 deletion quick/mercator.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ def parse(soccfg, cfg):
o["phase"] = cfg.get(f"p{p}_phase", list(np.zeros(len(o["freq"]))) if isinstance(o["freq"], listType) else 0)
o["idata"] = cfg.get(f"p{p}_idata", None)
o["qdata"] = cfg.get(f"p{p}_qdata", None)
if f"p{p}_power" in cfg:
if cfg.get(f"p{p}_power", None) is not None:
balun = cfg.get(f"p{p}_balun", 2)
o["gain"] = dbm2gain(cfg[f"p{p}_power"], o["freq"], c["g"][o["g"]]["nqz"], balun)
cfg[f"p{p}_gain"] = o["gain"] # write back computed gain
Expand Down

0 comments on commit b921c30

Please sign in to comment.