|
@@ -1039,6 +1039,7 @@ class GMRDataProcessor(SNMRDataProcessor):
|
1039
|
1039
|
(float)(self.DATADICT["nPulseMoments"] * len(self.DATADICT[pulse]["chan"])))
|
1040
|
1040
|
self.progressTrigger.emit(percent)
|
1041
|
1041
|
ichan += 1
|
|
1042
|
+ self.DATADICT[pulse]["TIMES"] = self.DATADICT[pulse]["TIMES"][clip::]
|
1042
|
1043
|
|
1043
|
1044
|
self.DATADICT["CA"] = CA
|
1044
|
1045
|
self.DATADICT["IP"] = IP
|
|
@@ -1067,10 +1068,11 @@ class GMRDataProcessor(SNMRDataProcessor):
|
1067
|
1068
|
axes = canvas.fig.axes
|
1068
|
1069
|
mmaxr = 0.
|
1069
|
1070
|
mmaxi = 0.
|
1070
|
|
- if clip > 0:
|
1071
|
|
- time_sp = 1e3 * (self.DATADICT[pulse]["TIMES"][clip-1::] - self.DATADICT[pulse]["PULSE_TIMES"][-1] )
|
1072
|
|
- else:
|
1073
|
|
- time_sp = 1e3 * (self.DATADICT[pulse]["TIMES"] - self.DATADICT[pulse]["PULSE_TIMES"][-1] )
|
|
1071
|
+ #if clip > 0:
|
|
1072
|
+ # time_sp = 1e3 * (self.DATADICT[pulse]["TIMES"][clip-1::] - self.DATADICT[pulse]["PULSE_TIMES"][-1] )
|
|
1073
|
+ #else:
|
|
1074
|
+ # time_sp = 1e3 * (self.DATADICT[pulse]["TIMES"] - self.DATADICT[pulse]["PULSE_TIMES"][-1] )
|
|
1075
|
+ time_sp = 1e3 * (self.DATADICT[pulse]["TIMES"] - self.DATADICT[pulse]["PULSE_TIMES"][-1] )
|
1074
|
1076
|
|
1075
|
1077
|
QQ = np.average(self.DATADICT[pulse]["Q"], axis=1 )
|
1076
|
1078
|
|
|
@@ -1257,10 +1259,11 @@ class GMRDataProcessor(SNMRDataProcessor):
|
1257
|
1259
|
if self.GATED[chan]["isum"][it] < 8:
|
1258
|
1260
|
XS[ii, it] = self.sigma[pulse][chan]
|
1259
|
1261
|
else:
|
1260
|
|
-
|
1261
|
1262
|
if it == 0:
|
1262
|
|
- X = self.bootstrap_resample( np.concatenate( (self.GATED[chan]["NR"][:,it], self.GATED[chan]["NR"][:,it+1], \
|
1263
|
|
- self.GATED[chan]["NR"][:,it+2], self.GATED[chan]["NR"][:,it+3] ) ), n=nt )
|
|
1263
|
+ X = self.bootstrap_resample( np.concatenate( (self.GATED[chan]["NR"][:,it], \
|
|
1264
|
+ self.GATED[chan]["NR"][:,it+1], \
|
|
1265
|
+ self.GATED[chan]["NR"][:,it+2], \
|
|
1266
|
+ self.GATED[chan]["NR"][:,it+3] ) ), n=nt )
|
1264
|
1267
|
elif it == 1:
|
1265
|
1268
|
X = self.bootstrap_resample( np.concatenate( (self.GATED[chan]["NR"][:,it-1], self.GATED[chan]["NR"][:,it], \
|
1266
|
1269
|
self.GATED[chan]["NR"][:,it+1], self.GATED[chan]["NR"][:,it+2] ) ), n=nt )
|
|
@@ -1282,7 +1285,8 @@ class GMRDataProcessor(SNMRDataProcessor):
|
1282
|
1285
|
|
1283
|
1286
|
canvas.reAxH2( len(self.DATADICT[ self.DATADICT["PULSES"][0] ]["chan"] ), False, False)
|
1284
|
1287
|
axes = canvas.fig.axes
|
1285
|
|
- cmap = cmocean.cm.balance_r
|
|
1288
|
+ #cmap = cmocean.cm.balance_r
|
|
1289
|
+ dcmap = cmocean.cm.curl_r #"seismic_r" #cmocean.cm.balance_r #"RdBu" #YlGn" # "coolwarm_r" # diverging
|
1286
|
1290
|
|
1287
|
1291
|
# Calculate maximum for plotting...TODO move into loop above
|
1288
|
1292
|
vmax1 = 0
|
|
@@ -1308,14 +1312,14 @@ class GMRDataProcessor(SNMRDataProcessor):
|
1308
|
1312
|
ax2 = axes[2*ichan+1]
|
1309
|
1313
|
|
1310
|
1314
|
if phase == 0:
|
1311
|
|
- im1 = ax1.pcolormesh(self.GATED[chan]["GTT"], self.GATED[chan]["QQ"], self.GATED[chan]["RE"], cmap=cmap, vmin=-vmax1, vmax=vmax1)
|
1312
|
|
- im2 = ax2.pcolormesh(self.GATED[chan]["GTT"], self.GATED[chan]["QQ"], self.GATED[chan]["IM"], cmap=cmap, vmin=-vmax2, vmax=vmax2)
|
|
1315
|
+ im1 = ax1.pcolormesh(self.GATED[chan]["GTT"], self.GATED[chan]["QQ"], self.GATED[chan]["RE"], cmap=dcmap, vmin=-vmax1, vmax=vmax1)
|
|
1316
|
+ im2 = ax2.pcolormesh(self.GATED[chan]["GTT"], self.GATED[chan]["QQ"], self.GATED[chan]["IM"], cmap=dcmap, vmin=-vmax2, vmax=vmax2)
|
1313
|
1317
|
elif phase == 1:
|
1314
|
|
- im1 = ax1.pcolormesh(self.GATED[chan]["GTT"], self.GATED[chan]["QQ"], self.GATED[chan]["CA"], cmap=cmap, vmin=-vmax1, vmax=vmax1)
|
1315
|
|
- im2 = ax2.pcolormesh(self.GATED[chan]["GTT"], self.GATED[chan]["QQ"], self.GATED[chan]["IP"], cmap=cmocean.cm.balance, vmin=-vmax2, vmax=vmax2)
|
|
1318
|
+ im1 = ax1.pcolormesh(self.GATED[chan]["GTT"], self.GATED[chan]["QQ"], self.GATED[chan]["CA"], cmap=dcmap, vmin=-vmax1, vmax=vmax1)
|
|
1319
|
+ im2 = ax2.pcolormesh(self.GATED[chan]["GTT"], self.GATED[chan]["QQ"], self.GATED[chan]["IP"], cmap=cmocean.cm.delta, vmin=-vmax2, vmax=vmax2)
|
1316
|
1320
|
#im2 = ax2.pcolormesh(self.GATED[chan]["GTT"], self.GATED[chan]["QQ"], self.GATED[chan]["IP"], cmap=cmocean.cm.phase, vmin=-vmax2, vmax=vmax2)
|
1317
|
1321
|
elif phase == 2:
|
1318
|
|
- im1 = ax1.pcolormesh(self.GATED[chan]["GTT"], self.GATED[chan]["QQ"], self.GATED[chan]["CA"], cmap=cmap, vmin=-vmax1, vmax=vmax1)
|
|
1322
|
+ im1 = ax1.pcolormesh(self.GATED[chan]["GTT"], self.GATED[chan]["QQ"], self.GATED[chan]["CA"], cmap=dcmap, vmin=-vmax1, vmax=vmax1)
|
1319
|
1323
|
XS = self.bootstrap_sigma(pulse, chan)
|
1320
|
1324
|
#im2 = ax2.pcolormesh(self.GATED[chan]["GTT"], self.GATED[chan]["QQ"], self.GATED[chan]["NR"], cmap=cmap, vmin=-vmax2, vmax=vmax2)
|
1321
|
1325
|
# bootstrap resample
|
|
@@ -1358,7 +1362,6 @@ class GMRDataProcessor(SNMRDataProcessor):
|
1358
|
1362
|
if phase != 2:
|
1359
|
1363
|
im2.set_edgecolor('face')
|
1360
|
1364
|
|
1361
|
|
-
|
1362
|
1365
|
plt.setp(ax1.get_xticklabels(), visible=False)
|
1363
|
1366
|
|
1364
|
1367
|
ax1.set_ylim( np.min(self.GATED[chan]["QQ"]), np.max(self.GATED[chan]["QQ"]) )
|
|
@@ -1379,15 +1382,15 @@ class GMRDataProcessor(SNMRDataProcessor):
|
1379
|
1382
|
#formatter = matplotlib.ticker.LogFormatter(10, labelOnlyBase=False)
|
1380
|
1383
|
formatter = matplotlib.ticker.FuncFormatter(lambda x, pos: str((round(x,1))))
|
1381
|
1384
|
|
|
1385
|
+ ax1.set_xscale('log')
|
|
1386
|
+ ax2.set_xscale('log')
|
|
1387
|
+
|
1382
|
1388
|
ax1.yaxis.set_major_formatter(formatter) #matplotlib.ticker.FormatStrFormatter('%d.1'))
|
1383
|
1389
|
ax2.yaxis.set_major_formatter(formatter) #matplotlib.ticker.FormatStrFormatter('%d.1'))
|
1384
|
1390
|
|
1385
|
1391
|
ax1.xaxis.set_major_formatter(formatter) #matplotlib.ticker.FormatStrFormatter('%d.1'))
|
1386
|
1392
|
ax2.xaxis.set_major_formatter(formatter) #matplotlib.ticker.FormatStrFormatter('%d.1'))
|
1387
|
1393
|
|
1388
|
|
- ax1.set_xscale('log')
|
1389
|
|
- ax2.set_xscale('log')
|
1390
|
|
-
|
1391
|
1394
|
if ichan == 0:
|
1392
|
1395
|
ax1.set_ylabel(r"$q$ ( $\mathrm{A}\cdot\mathrm{s}$)", fontsize=8)
|
1393
|
1396
|
if phase == 2:
|
|
@@ -1410,8 +1413,8 @@ class GMRDataProcessor(SNMRDataProcessor):
|
1410
|
1413
|
cb1 = canvas.fig.colorbar(im1, ax=axes[0::2], format='%1.0e', orientation='horizontal', shrink=.35, aspect=30)
|
1411
|
1414
|
cb1.ax.tick_params(axis='both', which='major', labelsize=8)
|
1412
|
1415
|
cb1.set_label("$\mathcal{V}_N$ (nV)", fontsize=8)
|
1413
|
|
- cb1.locator = tick_locator
|
1414
|
|
- cb1.update_ticks()
|
|
1416
|
+ #cb1.locator = tick_locator
|
|
1417
|
+ #cb1.update_ticks()
|
1415
|
1418
|
|
1416
|
1419
|
if phase != 2:
|
1417
|
1420
|
cb2 = canvas.fig.colorbar(im2, ax=axes[1::2], format='%1.0e', orientation='horizontal', shrink=.35, aspect=30, pad=.2)
|