QuLab 2.10.10__cp313-cp313-win_amd64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- qulab/__init__.py +33 -0
- qulab/__main__.py +4 -0
- qulab/cli/__init__.py +0 -0
- qulab/cli/commands.py +30 -0
- qulab/cli/config.py +170 -0
- qulab/cli/decorators.py +28 -0
- qulab/dicttree.py +523 -0
- qulab/executor/__init__.py +5 -0
- qulab/executor/analyze.py +188 -0
- qulab/executor/cli.py +434 -0
- qulab/executor/load.py +563 -0
- qulab/executor/registry.py +185 -0
- qulab/executor/schedule.py +543 -0
- qulab/executor/storage.py +615 -0
- qulab/executor/template.py +259 -0
- qulab/executor/utils.py +194 -0
- qulab/expression.py +827 -0
- qulab/fun.cp313-win_amd64.pyd +0 -0
- qulab/monitor/__init__.py +1 -0
- qulab/monitor/__main__.py +8 -0
- qulab/monitor/config.py +41 -0
- qulab/monitor/dataset.py +77 -0
- qulab/monitor/event_queue.py +54 -0
- qulab/monitor/mainwindow.py +234 -0
- qulab/monitor/monitor.py +115 -0
- qulab/monitor/ploter.py +123 -0
- qulab/monitor/qt_compat.py +16 -0
- qulab/monitor/toolbar.py +265 -0
- qulab/scan/__init__.py +2 -0
- qulab/scan/curd.py +221 -0
- qulab/scan/models.py +554 -0
- qulab/scan/optimize.py +76 -0
- qulab/scan/query.py +387 -0
- qulab/scan/record.py +603 -0
- qulab/scan/scan.py +1166 -0
- qulab/scan/server.py +450 -0
- qulab/scan/space.py +213 -0
- qulab/scan/utils.py +234 -0
- qulab/storage/__init__.py +0 -0
- qulab/storage/__main__.py +51 -0
- qulab/storage/backend/__init__.py +0 -0
- qulab/storage/backend/redis.py +204 -0
- qulab/storage/base_dataset.py +352 -0
- qulab/storage/chunk.py +60 -0
- qulab/storage/dataset.py +127 -0
- qulab/storage/file.py +273 -0
- qulab/storage/models/__init__.py +22 -0
- qulab/storage/models/base.py +4 -0
- qulab/storage/models/config.py +28 -0
- qulab/storage/models/file.py +89 -0
- qulab/storage/models/ipy.py +58 -0
- qulab/storage/models/models.py +88 -0
- qulab/storage/models/record.py +161 -0
- qulab/storage/models/report.py +22 -0
- qulab/storage/models/tag.py +93 -0
- qulab/storage/storage.py +95 -0
- qulab/sys/__init__.py +2 -0
- qulab/sys/chat.py +688 -0
- qulab/sys/device/__init__.py +3 -0
- qulab/sys/device/basedevice.py +255 -0
- qulab/sys/device/loader.py +86 -0
- qulab/sys/device/utils.py +79 -0
- qulab/sys/drivers/FakeInstrument.py +68 -0
- qulab/sys/drivers/__init__.py +0 -0
- qulab/sys/ipy_events.py +125 -0
- qulab/sys/net/__init__.py +0 -0
- qulab/sys/net/bencoder.py +205 -0
- qulab/sys/net/cli.py +169 -0
- qulab/sys/net/dhcp.py +543 -0
- qulab/sys/net/dhcpd.py +176 -0
- qulab/sys/net/kad.py +1142 -0
- qulab/sys/net/kcp.py +192 -0
- qulab/sys/net/nginx.py +194 -0
- qulab/sys/progress.py +190 -0
- qulab/sys/rpc/__init__.py +0 -0
- qulab/sys/rpc/client.py +0 -0
- qulab/sys/rpc/exceptions.py +96 -0
- qulab/sys/rpc/msgpack.py +1052 -0
- qulab/sys/rpc/msgpack.pyi +41 -0
- qulab/sys/rpc/router.py +35 -0
- qulab/sys/rpc/rpc.py +412 -0
- qulab/sys/rpc/serialize.py +139 -0
- qulab/sys/rpc/server.py +29 -0
- qulab/sys/rpc/socket.py +29 -0
- qulab/sys/rpc/utils.py +25 -0
- qulab/sys/rpc/worker.py +0 -0
- qulab/sys/rpc/zmq_socket.py +227 -0
- qulab/tools/__init__.py +0 -0
- qulab/tools/connection_helper.py +39 -0
- qulab/typing.py +2 -0
- qulab/utils.py +95 -0
- qulab/version.py +1 -0
- qulab/visualization/__init__.py +188 -0
- qulab/visualization/__main__.py +71 -0
- qulab/visualization/_autoplot.py +464 -0
- qulab/visualization/plot_circ.py +319 -0
- qulab/visualization/plot_layout.py +408 -0
- qulab/visualization/plot_seq.py +242 -0
- qulab/visualization/qdat.py +152 -0
- qulab/visualization/rot3d.py +23 -0
- qulab/visualization/widgets.py +86 -0
- qulab-2.10.10.dist-info/METADATA +110 -0
- qulab-2.10.10.dist-info/RECORD +107 -0
- qulab-2.10.10.dist-info/WHEEL +5 -0
- qulab-2.10.10.dist-info/entry_points.txt +2 -0
- qulab-2.10.10.dist-info/licenses/LICENSE +21 -0
- qulab-2.10.10.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,152 @@
|
|
|
1
|
+
"""
|
|
2
|
+
This module provides the visualization of the qdat file.
|
|
3
|
+
"""
|
|
4
|
+
import logging
|
|
5
|
+
import math
|
|
6
|
+
import re
|
|
7
|
+
from functools import reduce
|
|
8
|
+
|
|
9
|
+
import matplotlib.pyplot as plt
|
|
10
|
+
import numpy as np
|
|
11
|
+
from matplotlib import cm
|
|
12
|
+
|
|
13
|
+
log = logging.getLogger(__name__)
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
def draw(record_dict, fig=None, transpose=True, remove=True):
|
|
17
|
+
"""Draw a 2D or 3D plot from a record dict.
|
|
18
|
+
|
|
19
|
+
Args:
|
|
20
|
+
record_dict (dict): The record dict.
|
|
21
|
+
fig (matplotlib.figure.Figure): The figure to draw on.
|
|
22
|
+
transpose (bool): Whether to transpose the data.
|
|
23
|
+
"""
|
|
24
|
+
dim = record_dict['info']['dim']
|
|
25
|
+
zshape = record_dict['info']['zshape']
|
|
26
|
+
zsize = reduce(lambda a, b: a * b, zshape, 1)
|
|
27
|
+
|
|
28
|
+
axis_label = np.asarray(record_dict['info'].get('axis_label',
|
|
29
|
+
[])).flatten()
|
|
30
|
+
z_label = np.asarray(record_dict['info'].get('z_label', [])).flatten()
|
|
31
|
+
axis_unit = np.asarray(record_dict['info'].get('axis_unit', [])).flatten()
|
|
32
|
+
z_unit = np.asarray(record_dict['info'].get('z_unit', [])).flatten()
|
|
33
|
+
|
|
34
|
+
fig = plt.figure() if fig is None else fig
|
|
35
|
+
if zsize < 4:
|
|
36
|
+
plot_shape = (1, zsize)
|
|
37
|
+
else:
|
|
38
|
+
n = int(np.sqrt(zsize))
|
|
39
|
+
plot_shape = (math.ceil(zsize / n), n)
|
|
40
|
+
if dim < 3 and zsize < 100:
|
|
41
|
+
figsize = plot_shape[1] * 8, plot_shape[0] * 6
|
|
42
|
+
fig.set_size_inches(*figsize)
|
|
43
|
+
axes = fig.subplots(*plot_shape)
|
|
44
|
+
axes = np.array(axes).flatten()
|
|
45
|
+
else:
|
|
46
|
+
axes = []
|
|
47
|
+
|
|
48
|
+
cb_list = []
|
|
49
|
+
if dim == 1 and zsize < 101:
|
|
50
|
+
for i in range(zsize):
|
|
51
|
+
title = record_dict[
|
|
52
|
+
'name'] + f' {i}' if zsize > 1 else record_dict['name']
|
|
53
|
+
try:
|
|
54
|
+
xlabel = axis_label[0]
|
|
55
|
+
ylabel = z_label[0] if len(z_label) == 1 else z_label[i]
|
|
56
|
+
except:
|
|
57
|
+
xlabel, ylabel = 'X', 'Y'
|
|
58
|
+
try:
|
|
59
|
+
x_unit = axis_unit[0]
|
|
60
|
+
y_unit = z_unit[0] if len(z_unit) == 1 else z_unit[i]
|
|
61
|
+
except:
|
|
62
|
+
x_unit, y_unit = 'a.u.', 'a.u.'
|
|
63
|
+
axes[i].set_title(title)
|
|
64
|
+
axes[i].set_xlabel(f'{xlabel} ({x_unit})')
|
|
65
|
+
axes[i].set_ylabel(f'{ylabel} ({y_unit})')
|
|
66
|
+
elif dim == 2 and zsize < 101:
|
|
67
|
+
for i in range(zsize):
|
|
68
|
+
smp = cm.ScalarMappable(norm=None, cmap=None)
|
|
69
|
+
cb = fig.colorbar(smp, ax=axes[i]) # 默认色谱的colorbar
|
|
70
|
+
cb_list.append(cb)
|
|
71
|
+
try:
|
|
72
|
+
title = record_dict['name'] + \
|
|
73
|
+
f': {z_label[i]}' if zsize > 1 else record_dict['name']
|
|
74
|
+
except:
|
|
75
|
+
title = record_dict[
|
|
76
|
+
'name'] + f' {i}' if zsize > 1 else record_dict['name']
|
|
77
|
+
try:
|
|
78
|
+
xlabel, ylabel = axis_label[1], axis_label[0]
|
|
79
|
+
if transpose:
|
|
80
|
+
xlabel, ylabel = ylabel, xlabel
|
|
81
|
+
except:
|
|
82
|
+
xlabel, ylabel = 'X', 'Y'
|
|
83
|
+
try:
|
|
84
|
+
x_unit, y_unit = axis_unit[1], axis_unit[0]
|
|
85
|
+
if transpose:
|
|
86
|
+
x_unit, y_unit = y_unit, x_unit
|
|
87
|
+
except:
|
|
88
|
+
x_unit, y_unit = 'a.u.', 'a.u.'
|
|
89
|
+
axes[i].set_title(title)
|
|
90
|
+
axes[i].set_xlabel(f'{xlabel} ({x_unit})')
|
|
91
|
+
axes[i].set_ylabel(f'{ylabel} ({y_unit})')
|
|
92
|
+
else:
|
|
93
|
+
message1 = f'dim {dim} is too large (>2)! ' if dim > 2 else f'dim={dim}; '
|
|
94
|
+
message2 = f'zsize {zsize} is too large (>101)!' if zsize > 101 else f'zsize={zsize}'
|
|
95
|
+
log.warning('PASS: ' + message1 + message2)
|
|
96
|
+
#########################################################################################
|
|
97
|
+
try:
|
|
98
|
+
tags = [
|
|
99
|
+
tag.strip(r'\*')
|
|
100
|
+
for tag in record_dict['ParaSpace'].get('tags', [])
|
|
101
|
+
if re.match(r'\*', tag)
|
|
102
|
+
]
|
|
103
|
+
tag_text = ','.join(tags)
|
|
104
|
+
if tag_text:
|
|
105
|
+
axes[0].text(-0.1,
|
|
106
|
+
1.1,
|
|
107
|
+
'TAG: ' + tag_text,
|
|
108
|
+
horizontalalignment='left',
|
|
109
|
+
verticalalignment='bottom',
|
|
110
|
+
transform=axes[0].transAxes) # fig.transFigure)#
|
|
111
|
+
except:
|
|
112
|
+
pass
|
|
113
|
+
#########################################################################################
|
|
114
|
+
fig.tight_layout()
|
|
115
|
+
|
|
116
|
+
dim = record_dict['info']['dim']
|
|
117
|
+
zshape = record_dict['info']['zshape']
|
|
118
|
+
datashape = record_dict['info']['datashape']
|
|
119
|
+
zsize = reduce(lambda a, b: a * b, zshape, 1)
|
|
120
|
+
datashape_r = (*datashape[:dim], zsize)
|
|
121
|
+
|
|
122
|
+
if dim == 1 and zsize < 101:
|
|
123
|
+
x, z = record_dict['data']
|
|
124
|
+
z = z.reshape(datashape_r)
|
|
125
|
+
z = np.abs(z) if np.any(np.iscomplex(z)) else z.real
|
|
126
|
+
for i in range(zsize):
|
|
127
|
+
_ = [a.remove() for a in axes[i].get_lines()] if remove else []
|
|
128
|
+
axes[i].plot(x, z[:, i], 'C0')
|
|
129
|
+
axes[i].plot(x, z[:, i], 'C0.')
|
|
130
|
+
elif dim == 2 and zsize < 101:
|
|
131
|
+
x, y, z = record_dict['data']
|
|
132
|
+
x_step, y_step = x[1] - x[0], y[1] - y[0]
|
|
133
|
+
if transpose:
|
|
134
|
+
x, y = y, x
|
|
135
|
+
x_step, y_step = y_step, x_step
|
|
136
|
+
z = z.reshape(datashape_r)
|
|
137
|
+
z = np.abs(z) if np.any(np.iscomplex(z)) else z.real
|
|
138
|
+
for i in range(zsize):
|
|
139
|
+
_z = z[:, :, i]
|
|
140
|
+
_ = [a.remove() for a in axes[i].get_images()] if remove else []
|
|
141
|
+
if transpose:
|
|
142
|
+
_z = _z.T
|
|
143
|
+
im = axes[i].imshow(_z,
|
|
144
|
+
extent=(y[0] - y_step / 2, y[-1] + y_step / 2,
|
|
145
|
+
x[0] - x_step / 2, x[-1] + x_step / 2),
|
|
146
|
+
origin='lower',
|
|
147
|
+
aspect='auto')
|
|
148
|
+
cb_list[i].update_normal(im) # 更新对应的colorbar
|
|
149
|
+
else:
|
|
150
|
+
pass
|
|
151
|
+
|
|
152
|
+
return fig, axes
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import numpy as np
|
|
2
|
+
from scipy.linalg import expm
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
def _rot(theta, v):
|
|
6
|
+
x, y, z = np.asarray(v) / np.sqrt(np.sum(np.asarray(v)**2))
|
|
7
|
+
c, s = np.cos(theta), np.sin(theta)
|
|
8
|
+
|
|
9
|
+
return np.array([[
|
|
10
|
+
c + (1 - c) * x**2, (1 - c) * x * y - s * z, (1 - c) * x * z + s * y
|
|
11
|
+
], [(1 - c) * x * y + s * z, c + (1 - c) * y**2, (1 - c) * y * z - s * x],
|
|
12
|
+
[(1 - c) * x * z - s * y, (1 - c) * y * z + s * x,
|
|
13
|
+
c + (1 - c) * z**2]])
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
def rot_round(x, y, z, v=[0, 0, 1], theta=0, c=[0, 0, 0]):
|
|
17
|
+
ret = (np.array([x, y, z]).T - np.array(c)) @ _rot(theta, v) + np.array(c)
|
|
18
|
+
return ret.T
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
def projection(x, y, z, y0=1):
|
|
22
|
+
d = np.sqrt(x**2 + y**2 + z**2)
|
|
23
|
+
return x * y0 / y, z * y0 / y, d
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
import matplotlib.pyplot as plt
|
|
2
|
+
import numpy as np
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
class DataPicker():
|
|
6
|
+
|
|
7
|
+
def __init__(self, ax=None):
|
|
8
|
+
self.points_and_text = {}
|
|
9
|
+
self.points = None
|
|
10
|
+
self.hline = None
|
|
11
|
+
self.vline = None
|
|
12
|
+
self.text = None
|
|
13
|
+
if ax is None:
|
|
14
|
+
ax = plt.gca()
|
|
15
|
+
self.ax = ax
|
|
16
|
+
self.ax.figure.canvas.mpl_connect('button_press_event', self.on_click)
|
|
17
|
+
# self.ax.figure.canvas.mpl_connect('motion_notify_event', self.on_move)
|
|
18
|
+
self.ax.figure.canvas.mpl_connect('key_press_event', self.on_key_press)
|
|
19
|
+
self.mode = 'pick'
|
|
20
|
+
|
|
21
|
+
def on_key_press(self, event):
|
|
22
|
+
if event.key == 'a':
|
|
23
|
+
if self.mode != 'pick':
|
|
24
|
+
self.mode = 'pick'
|
|
25
|
+
else:
|
|
26
|
+
self.mode = 'default'
|
|
27
|
+
|
|
28
|
+
def on_move(self, event):
|
|
29
|
+
if event.inaxes is self.ax:
|
|
30
|
+
# self.hline = self.ax.axhline(y=np.nan, color='r', lw=1)
|
|
31
|
+
# self.vline = self.ax.axvline(x=np.nan, color='r', lw=1)
|
|
32
|
+
# self.text = self.ax.text(0, 0, '', verticalalignment='center')
|
|
33
|
+
self.hline.set_ydata(event.ydata)
|
|
34
|
+
self.vline.set_xdata(event.xdata)
|
|
35
|
+
self.text.set_position((event.xdata, event.ydata))
|
|
36
|
+
self.text.set_text(f'({event.xdata:.2f}, {event.ydata:.2f})')
|
|
37
|
+
self.ax.draw()
|
|
38
|
+
|
|
39
|
+
def on_click(self, event):
|
|
40
|
+
if self.mode != 'pick':
|
|
41
|
+
return
|
|
42
|
+
# 鼠标左键的button值为1
|
|
43
|
+
if event.button == 1 and event.inaxes is self.ax:
|
|
44
|
+
point = (event.xdata, event.ydata)
|
|
45
|
+
text = self.ax.text(point[0],
|
|
46
|
+
point[1],
|
|
47
|
+
f'({point[0]:.2f}, {point[1]:.2f})',
|
|
48
|
+
verticalalignment='center')
|
|
49
|
+
self.points_and_text[point] = text
|
|
50
|
+
x, y = self.get_xy()
|
|
51
|
+
if self.points is None:
|
|
52
|
+
self.points, = self.ax.plot(x, y, 'ro')
|
|
53
|
+
else:
|
|
54
|
+
self.points.set_data(x, y)
|
|
55
|
+
self.ax.draw()
|
|
56
|
+
|
|
57
|
+
elif event.button == 3 and event.inaxes is self.ax:
|
|
58
|
+
for point, text in list(self.points_and_text.items()):
|
|
59
|
+
point_xdisplay, point_ydisplay = self.ax.transData.transform_point(
|
|
60
|
+
point)
|
|
61
|
+
|
|
62
|
+
distance = np.sqrt((point_xdisplay - event.x)**2 +
|
|
63
|
+
(point_ydisplay - event.y)**2)
|
|
64
|
+
if distance < 10:
|
|
65
|
+
text.remove()
|
|
66
|
+
self.points_and_text.pop(point)
|
|
67
|
+
if self.points_and_text:
|
|
68
|
+
x, y = self.get_xy()
|
|
69
|
+
self.points.set_data(x, y)
|
|
70
|
+
else:
|
|
71
|
+
self.points.remove()
|
|
72
|
+
self.points = None
|
|
73
|
+
self.ax.draw()
|
|
74
|
+
break
|
|
75
|
+
|
|
76
|
+
def get_xy(self):
|
|
77
|
+
if self.points_and_text:
|
|
78
|
+
data = np.asarray(list(self.points_and_text.keys()))
|
|
79
|
+
x, y = data[:, 0], data[:, 1]
|
|
80
|
+
|
|
81
|
+
index = np.argsort(x)
|
|
82
|
+
x = np.asarray(x)[index]
|
|
83
|
+
y = np.asarray(y)[index]
|
|
84
|
+
return x, y
|
|
85
|
+
else:
|
|
86
|
+
return np.array([]), np.array([])
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: QuLab
|
|
3
|
+
Version: 2.10.10
|
|
4
|
+
Summary: contral instruments and manage data
|
|
5
|
+
Author-email: feihoo87 <feihoo87@gmail.com>
|
|
6
|
+
Maintainer-email: feihoo87 <feihoo87@gmail.com>
|
|
7
|
+
License: MIT
|
|
8
|
+
Project-URL: Homepage, https://github.com/feihoo87/QuLab
|
|
9
|
+
Project-URL: Bug Reports, https://github.com/feihoo87/QuLab/issues
|
|
10
|
+
Project-URL: Source, https://github.com/feihoo87/QuLab/
|
|
11
|
+
Keywords: experiment,laboratory
|
|
12
|
+
Classifier: Development Status :: 5 - Production/Stable
|
|
13
|
+
Classifier: Intended Audience :: Developers
|
|
14
|
+
Classifier: Intended Audience :: Science/Research
|
|
15
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
16
|
+
Classifier: Operating System :: Microsoft :: Windows
|
|
17
|
+
Classifier: Operating System :: POSIX :: Linux
|
|
18
|
+
Classifier: Operating System :: MacOS :: MacOS X
|
|
19
|
+
Classifier: Topic :: Scientific/Engineering :: Interface Engine/Protocol Translator
|
|
20
|
+
Classifier: Programming Language :: Python
|
|
21
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
22
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
23
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
24
|
+
Requires-Python: >=3.10
|
|
25
|
+
Description-Content-Type: text/markdown
|
|
26
|
+
License-File: LICENSE
|
|
27
|
+
Requires-Dist: blinker>=1.4
|
|
28
|
+
Requires-Dist: click>=7.1.2
|
|
29
|
+
Requires-Dist: dill>=0.3.6
|
|
30
|
+
Requires-Dist: GitPython>=3.1.14
|
|
31
|
+
Requires-Dist: ipython>=7.4.0
|
|
32
|
+
Requires-Dist: ipywidgets>=7.4.2
|
|
33
|
+
Requires-Dist: loguru>=0.7.2
|
|
34
|
+
Requires-Dist: matplotlib>=3.7.2
|
|
35
|
+
Requires-Dist: msgpack>=1.0.5
|
|
36
|
+
Requires-Dist: nevergrad>=1.0.2
|
|
37
|
+
Requires-Dist: numpy>=1.13.3
|
|
38
|
+
Requires-Dist: ply>=3.11
|
|
39
|
+
Requires-Dist: pyperclip>=1.8.2
|
|
40
|
+
Requires-Dist: pyzmq>=25.1.0
|
|
41
|
+
Requires-Dist: qlisp>=1.1.4
|
|
42
|
+
Requires-Dist: qlispc>=1.1.8
|
|
43
|
+
Requires-Dist: scipy>=1.0.0
|
|
44
|
+
Requires-Dist: scikit-optimize>=0.9.0
|
|
45
|
+
Requires-Dist: SQLAlchemy>=2.0.19
|
|
46
|
+
Requires-Dist: watchdog>=4.0.0
|
|
47
|
+
Requires-Dist: wath>=1.1.6
|
|
48
|
+
Requires-Dist: waveforms>=1.9.4
|
|
49
|
+
Provides-Extra: full
|
|
50
|
+
Requires-Dist: uvloop>=0.19.0; extra == "full"
|
|
51
|
+
Dynamic: license-file
|
|
52
|
+
|
|
53
|
+
# QuLab
|
|
54
|
+
[](https://travis-ci.org/feihoo87/QuLab)
|
|
55
|
+
[](https://coveralls.io/github/feihoo87/QuLab)
|
|
56
|
+
[](https://pyup.io/repos/github/feihoo87/QuLab/)
|
|
57
|
+
[](http://qulab.readthedocs.org)
|
|
58
|
+
[](https://badge.fury.io/py/QuLab)
|
|
59
|
+
[]()
|
|
60
|
+
[](https://doi.org/10.5281/zenodo.3352232)
|
|
61
|
+
|
|
62
|
+
**Documentation can be found at [qulab.readthedocs.org](https://qulab.readthedocs.org/).**
|
|
63
|
+
|
|
64
|
+
## Installation
|
|
65
|
+
We encourage installing QuLab via the pip tool (a python package manager):
|
|
66
|
+
```bash
|
|
67
|
+
python -m pip install QuLab
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
To install from the latest source, you need to clone the GitHub repository on your machine.
|
|
71
|
+
```bash
|
|
72
|
+
git clone https://github.com/feihoo87/QuLab.git
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
Then dependencies and QuLab can be installed in this way:
|
|
76
|
+
```bash
|
|
77
|
+
cd QuLab
|
|
78
|
+
python -m pip install -e .
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
## Usage
|
|
82
|
+
|
|
83
|
+
|
|
84
|
+
## Running Tests
|
|
85
|
+
To run tests:
|
|
86
|
+
|
|
87
|
+
```
|
|
88
|
+
python -m pip install -r requirements-dev.txt
|
|
89
|
+
python -m pytest
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
## Attribution
|
|
93
|
+
If you make use of this code, please consider citing the Zenodo DOI [](https://doi.org/10.5281/zenodo.3352232) as a software citation:
|
|
94
|
+
```
|
|
95
|
+
@misc{xu_huikai_2019_3352232,
|
|
96
|
+
author = {Xu, Huikai},
|
|
97
|
+
title = {QuLab},
|
|
98
|
+
month = aug,
|
|
99
|
+
year = 2019,
|
|
100
|
+
doi = {10.5281/zenodo.3352232},
|
|
101
|
+
url = {https://doi.org/10.5281/zenodo.3352232}
|
|
102
|
+
}
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
## Reporting Issues
|
|
106
|
+
Please report all issues [on github](https://github.com/feihoo87/QuLab/issues).
|
|
107
|
+
|
|
108
|
+
## License
|
|
109
|
+
|
|
110
|
+
[MIT](https://opensource.org/licenses/MIT)
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
qulab/__init__.py,sha256=SH37FtgS2bJcM5G5-BzwZ0EGK08vnv51YS450XENrv0,2060
|
|
2
|
+
qulab/__main__.py,sha256=FL4YsGZL1jEtmcPc5WbleArzhOHLMsWl7OH3O-1d1ss,72
|
|
3
|
+
qulab/dicttree.py,sha256=hYjVWjNYFmtzMWcIjIH6NJNDzpIW-g4TZbn2EBarpzg,14759
|
|
4
|
+
qulab/expression.py,sha256=XuB3Au582g5OhxprvKmZkF4ctvqBUsEVOpGAFzcS_uA,26578
|
|
5
|
+
qulab/fun.cp313-win_amd64.pyd,sha256=FQEQ-k304pYfjVnCtIPj-WRsW6j3hIdH1vrwLcVOAe8,31232
|
|
6
|
+
qulab/typing.py,sha256=PRtwbCHWY2ROKK8GHq4Bo8llXrIGo6xC73DrQf7S9os,71
|
|
7
|
+
qulab/utils.py,sha256=65N2Xj7kqRsQ4epoLNY6tL-i5ts6Wk8YuJYee3Te6zI,3077
|
|
8
|
+
qulab/version.py,sha256=iMPctba7Zmc8k76pU7WvVtu7ECCARmwVtsbglGDvCSg,23
|
|
9
|
+
qulab/cli/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
10
|
+
qulab/cli/commands.py,sha256=ZTs32yQjvwPIsFjXYWNr4KqEvly0NISIqyh--96qCAY,627
|
|
11
|
+
qulab/cli/config.py,sha256=c8AS35o_jMffL-qmwSpHrCo65sPone34JNxrrQbVyL0,5629
|
|
12
|
+
qulab/cli/decorators.py,sha256=mgAZiiaj2vZvsJEg70gxgB9TWkxR1nQSb2m-73RYHr0,649
|
|
13
|
+
qulab/executor/__init__.py,sha256=LosPzOMaljSZY1thy_Fxtbrgq7uubJszMABEB7oM7tU,101
|
|
14
|
+
qulab/executor/analyze.py,sha256=VoSthE2RTarY6Wj3QFKh4FqReMYL7djSAyuitgHs5K0,5837
|
|
15
|
+
qulab/executor/cli.py,sha256=bmuFPpPhHiRzTjIjhvlp2tQYp0jEwXSETILX8Nu2tLE,14901
|
|
16
|
+
qulab/executor/load.py,sha256=C5qepxC9QALMgfG_twxvGts6i0bCsnVg9lS05PXZZRM,20291
|
|
17
|
+
qulab/executor/registry.py,sha256=gym9F5FIDY5eV-cSCZsP99wC4l-6jkx9VMjJMaPOLaQ,4730
|
|
18
|
+
qulab/executor/schedule.py,sha256=7gAJFwj13j1niGjVa1fSzwOS22eNFEN1hdrN3dfTY6A,21410
|
|
19
|
+
qulab/executor/storage.py,sha256=8K73KGLAVgchJdtd4rKHXkr1CQOJORWH-Gi57w8IYsw,21081
|
|
20
|
+
qulab/executor/template.py,sha256=dKQM3IlADdTi9qp0fnOYjyycRNEl7KeSCBZhwbmP8bQ,10828
|
|
21
|
+
qulab/executor/utils.py,sha256=3OLRMBJu-1t78BeuZs4fv4jioEXnRNygaPnSoibzfgs,6405
|
|
22
|
+
qulab/monitor/__init__.py,sha256=xEVDkJF8issrsDeLqQmDsvtRmrf-UiViFcGTWuzdlFU,43
|
|
23
|
+
qulab/monitor/__main__.py,sha256=k2H1H5Zf9LLXTDLISJkbikLH-z0f1e5i5i6wXXYPOrE,105
|
|
24
|
+
qulab/monitor/config.py,sha256=y_5StMkdrbZO1ziyKBrvIkB7Jclp9RCPK1QbsOhCxnY,785
|
|
25
|
+
qulab/monitor/dataset.py,sha256=199kx7A08XKDnUN8MUZ7Cl4bWf52M0Mx7jrZLRyTwhw,2532
|
|
26
|
+
qulab/monitor/event_queue.py,sha256=0fj-iP4g6rKaxyom-bL-NoecwPe48V1LlVLoRuGgX_Q,1877
|
|
27
|
+
qulab/monitor/mainwindow.py,sha256=qqw7O9PTTrPjKgZAi7fS14S-fylTK9pzO1tAXtaNNAA,8033
|
|
28
|
+
qulab/monitor/monitor.py,sha256=yPgUG1_hNbqdFJWyMSepf5-Xayq9hOFdEq_o9pDLUrM,2912
|
|
29
|
+
qulab/monitor/ploter.py,sha256=dg7W28XTwEbBxHVtdPkFV135OQgoQwTi-NJCZQF-HYU,3724
|
|
30
|
+
qulab/monitor/qt_compat.py,sha256=Eq7zlA4_XstB92NhtAqebtWU_Btw4lcwFO30YxZ-TPE,804
|
|
31
|
+
qulab/monitor/toolbar.py,sha256=HxqG6ywKFyQJM2Q1s7SnhuzjbyeROczAZKwxztD1WJ8,8213
|
|
32
|
+
qulab/scan/__init__.py,sha256=ZUwe6GvaaEmelsvAwM6yTWF1DYG8klAFvya6nD_BGI4,89
|
|
33
|
+
qulab/scan/curd.py,sha256=m1MiW7Q_UActxpXor8n6PTck6A6O0_GRWHjVTJ3jBM4,7109
|
|
34
|
+
qulab/scan/models.py,sha256=LMMWNfty9T1CoO07pN1wloq6Gob7taeOxWTBJFjGXLI,18180
|
|
35
|
+
qulab/scan/optimize.py,sha256=zOR4Wp96bLarTSiPJ-cTAfT-V_MU-YEgB-XqYsBhS30,2637
|
|
36
|
+
qulab/scan/query.py,sha256=cyv72pYfnWIAHZHtlXYtkyC1BtsuOHD0AHkLEPVuqYQ,12641
|
|
37
|
+
qulab/scan/record.py,sha256=MVmxhIzwmOju7eWxJEWsqJZlVgrDeRXGMfNvXImj7Ms,21883
|
|
38
|
+
qulab/scan/scan.py,sha256=c9lWdcSS4O4JUhOpDkzn6mUQhwOK0ikvRtmIE9ExXzQ,40639
|
|
39
|
+
qulab/scan/server.py,sha256=lWDBnwYuVrSrDvTnrP-mAlDCkCNFpVDXZra3lfkpQ7s,17638
|
|
40
|
+
qulab/scan/space.py,sha256=t8caa_gKlnhaAIEksJyxINUTecOS7lMWAz1HDKlVcds,6909
|
|
41
|
+
qulab/scan/utils.py,sha256=yH8pvYoX9AvNkwWUGEh2MF2lHGzTsEQDgn2v2Xmlqhg,6523
|
|
42
|
+
qulab/storage/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
43
|
+
qulab/storage/__main__.py,sha256=6-EjN0waX1yfcMPJXqpIr9UlrIEsSCFApm5G-ZeaPMQ,1742
|
|
44
|
+
qulab/storage/base_dataset.py,sha256=28y3-OZrqJ52p5sbirEpUgjb7hqwLLpd38KU9DCkD24,12217
|
|
45
|
+
qulab/storage/chunk.py,sha256=gfj6EhQbaFbgzRdPZpMc2HV75RIQJ-iQeq_ULQp6g9E,1761
|
|
46
|
+
qulab/storage/dataset.py,sha256=mH5UTI3RbuWqsSnjvmVz1BJ_MoEyYFNhyDD-Ng1P6N8,4782
|
|
47
|
+
qulab/storage/file.py,sha256=HplZpmYu1onC_lb7QuZ5DMRiabW6GU_beaxkixY5KfQ,8616
|
|
48
|
+
qulab/storage/storage.py,sha256=Lb_MVORuwu3DZsXos0M18T10MGDlz4pGWsEseUAib5k,2656
|
|
49
|
+
qulab/storage/backend/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
50
|
+
qulab/storage/backend/redis.py,sha256=M6nsJc6dWMCjz57-EeCPcMpsuuyV6hUal2fcCr9D9a4,5406
|
|
51
|
+
qulab/storage/models/__init__.py,sha256=4eS_O6ErY8sMCgLt2wEhTHcPvi0ebJGo7smLbvo7YjU,608
|
|
52
|
+
qulab/storage/models/base.py,sha256=nImgJcUGdesnEAcPdF0YzT6td7jeod2CUDsVL7jQkCE,118
|
|
53
|
+
qulab/storage/models/config.py,sha256=I6g5m76ePkDJ9Tr2xB0SAJwDu6jupCQvu1XGIKTPj2g,717
|
|
54
|
+
qulab/storage/models/file.py,sha256=x8h8QbmkhJBZo2REjFFYYbR_SV5OWvZ6Ghpiy1SY2FE,2805
|
|
55
|
+
qulab/storage/models/ipy.py,sha256=ZjflbhUNNjPcRcrXvZung72Y8oGPHWZnJTMoa0x706U,1632
|
|
56
|
+
qulab/storage/models/models.py,sha256=h7nPI0uctftbxe8_cu3WkF59tKS4BuAIGCBmaHsuRBc,2967
|
|
57
|
+
qulab/storage/models/record.py,sha256=F5yu-Sf1aK9pkfCihb2AUU8b5HLlYZAUzrkUkBDpx_4,5131
|
|
58
|
+
qulab/storage/models/report.py,sha256=WO_hahL3VwWn3vn8tFZQ2ffYahV7RllIlAJPFmbVkdA,820
|
|
59
|
+
qulab/storage/models/tag.py,sha256=KPpiEm0SHI613-XLu3NBYE-qeIO9gwuKPw6se2obgPw,2432
|
|
60
|
+
qulab/sys/__init__.py,sha256=Z8_77Ddg3NpewBVx1BOeRWLs42QReZeiXllA2Y1pVJo,124
|
|
61
|
+
qulab/sys/chat.py,sha256=t7wSlREOQ_Ke0pO9bfpkik9wY1qeiTbRF1dial9IbII,23137
|
|
62
|
+
qulab/sys/ipy_events.py,sha256=rGjsApv58_Gwd_TH6ecPnyXK34_ZYZsaX8tk32ozLGY,3014
|
|
63
|
+
qulab/sys/progress.py,sha256=2iYskzRdOC2EM4wtbzm0u1kovjGrF_A0W1kCxbftyzE,5540
|
|
64
|
+
qulab/sys/device/__init__.py,sha256=ZZxPJ9_MHModvghQoZOSWjIdeo3vhg2TJETDdrwQvkU,152
|
|
65
|
+
qulab/sys/device/basedevice.py,sha256=mdKUzu0TpHIVMVQ4y7eADtlvGjFAjO-_NSEucLyVv3o,7450
|
|
66
|
+
qulab/sys/device/loader.py,sha256=RyUoykxGyfn-k22NWo-B06_AK_TMH8to4FzSkODLJHM,2583
|
|
67
|
+
qulab/sys/device/utils.py,sha256=5uqGOcaZlubCIw7gsknpB-tiFQyq8y6ebQxHcouQGUs,2393
|
|
68
|
+
qulab/sys/drivers/FakeInstrument.py,sha256=w5ItiveUppBoH2egZtfS6u7_heORA98iUdYeMjQkx8A,2474
|
|
69
|
+
qulab/sys/drivers/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
70
|
+
qulab/sys/net/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
71
|
+
qulab/sys/net/bencoder.py,sha256=tsMjTG-E_EQokfWrZgJvxO3dTGaM6NOVzPPKsify23A,5164
|
|
72
|
+
qulab/sys/net/cli.py,sha256=B3whPuhwBhlKiFvpdLK-FTv2EYE1U8tYWyUYNq9K5qs,5859
|
|
73
|
+
qulab/sys/net/dhcp.py,sha256=zKd4jQvSc8xYr7PcyR0tLlChpUYBb-WUr7-RzKBnClM,24052
|
|
74
|
+
qulab/sys/net/dhcpd.py,sha256=NB3lVTdk8xkwf4B-v9pOB0ylNj6SbYELGLSPgEQkOak,5498
|
|
75
|
+
qulab/sys/net/kad.py,sha256=uf9bNU2M3JLk6ZH04PDEdrChs4OOkHYoBHYodGIn_WE,40123
|
|
76
|
+
qulab/sys/net/kcp.py,sha256=NUDSkCXAneZoL-KDi_yGNfIdWycSCJRSpH0KL-tvpVQ,5952
|
|
77
|
+
qulab/sys/net/nginx.py,sha256=dRjkHTpGIGzf3lCsD1uyIsNwqjaE4lypK4aBuqZD3rc,5084
|
|
78
|
+
qulab/sys/rpc/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
79
|
+
qulab/sys/rpc/client.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
80
|
+
qulab/sys/rpc/exceptions.py,sha256=ZXfQYcF9MhUp4tvm7LI6h0jKbF8LUStEOfiW-keoGC0,2663
|
|
81
|
+
qulab/sys/rpc/msgpack.py,sha256=H2ujTA-6q41eQB-HBU0d_3LdGzWqL7EYQfDbPEfu4zQ,36378
|
|
82
|
+
qulab/sys/rpc/msgpack.pyi,sha256=P_tQdQ9L1-Zw6ZR07Eg3Yr-6AhmWCMLbEMFgr5JHke4,1314
|
|
83
|
+
qulab/sys/rpc/router.py,sha256=10iZv0kQQ0EvStn1Txog8QMq-PmZrucVNqtAD9WTqTg,976
|
|
84
|
+
qulab/sys/rpc/rpc.py,sha256=LVqOj7786kU8HrrF4ZVicIDp1aNkafyjBvhz9WJkDfE,12391
|
|
85
|
+
qulab/sys/rpc/serialize.py,sha256=tCrXmdDPw5CacCC2VoY0bbB4qeAGnvPh6UFwfXgVIoA,3494
|
|
86
|
+
qulab/sys/rpc/server.py,sha256=W3bPwe8um1IeR_3HLx-ad6iCcbeuUQcSg11Ze4w6DJg,742
|
|
87
|
+
qulab/sys/rpc/socket.py,sha256=W3bPwe8um1IeR_3HLx-ad6iCcbeuUQcSg11Ze4w6DJg,742
|
|
88
|
+
qulab/sys/rpc/utils.py,sha256=BurIcqh8CS-Hsk1dYP6IiefK4qHivaEqD9_rBY083SA,619
|
|
89
|
+
qulab/sys/rpc/worker.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
90
|
+
qulab/sys/rpc/zmq_socket.py,sha256=jFhcXJNONOl369uE1NkAvMkLl0oUP9q9Jwn_6SGY7k4,8814
|
|
91
|
+
qulab/tools/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
92
|
+
qulab/tools/connection_helper.py,sha256=-qZJcLsfueyHMihcbMp3HU3VRwz8zB0wnlosSjKp6R0,985
|
|
93
|
+
qulab/visualization/__init__.py,sha256=Bkt9AK5c45d6HFLlT-f8cIppywXziHtJqhDtVxOoKKo,6317
|
|
94
|
+
qulab/visualization/__main__.py,sha256=WduINFl21B-XMsi2rg2cVhIyU11hKKX3zOsjc56QLiQ,1710
|
|
95
|
+
qulab/visualization/_autoplot.py,sha256=gK3m5STiUigcQdJ3NzqD5jEITkPAsTsWMnmw6nUJfvE,14629
|
|
96
|
+
qulab/visualization/plot_circ.py,sha256=QBUWmoO_5lzYaOFi2RUISGba4jTQbWcGOe6OXECeW68,9078
|
|
97
|
+
qulab/visualization/plot_layout.py,sha256=E7hCheSGwuDCYVxM1VYsiLLXavsatKGXmtLlk7nQVcg,13943
|
|
98
|
+
qulab/visualization/plot_seq.py,sha256=Uo1-dB1YE9IN_A9tuaOs9ZG3S5dKDQ_l98iD2Wbxpp8,6993
|
|
99
|
+
qulab/visualization/qdat.py,sha256=HubXFu4nfcA7iUzghJGle1C86G6221hicLR0b-GqhKQ,5887
|
|
100
|
+
qulab/visualization/rot3d.py,sha256=jGHJcqj1lEWBUV-W4GUGONGacqjrYvuFoFCwPse5h1Y,757
|
|
101
|
+
qulab/visualization/widgets.py,sha256=HcYwdhDtLreJiYaZuN3LfofjJmZcLwjMfP5aasebgDo,3266
|
|
102
|
+
qulab-2.10.10.dist-info/licenses/LICENSE,sha256=b4NRQ-GFVpJMT7RuExW3NwhfbrYsX7AcdB7Gudok-fs,1086
|
|
103
|
+
qulab-2.10.10.dist-info/METADATA,sha256=FUoRWm7CqGTaxf9d8XGIPMKXgVCcPGSuVhnarI9jOwo,3948
|
|
104
|
+
qulab-2.10.10.dist-info/WHEEL,sha256=9h0gP8WIRUgefHU4Hsg223wEHJNWxV8x56YLXBJ4VCA,101
|
|
105
|
+
qulab-2.10.10.dist-info/entry_points.txt,sha256=b0v1GXOwmxY-nCCsPN_rHZZvY9CtTbWqrGj8u1m8yHo,45
|
|
106
|
+
qulab-2.10.10.dist-info/top_level.txt,sha256=3T886LbAsbvjonu_TDdmgxKYUn939BVTRPxPl9r4cEg,6
|
|
107
|
+
qulab-2.10.10.dist-info/RECORD,,
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2018 feihoo87
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
qulab
|