本文整理汇总了Python中pyview.lib.datacube.Datacube.parameters()["ramseyFit"]方法的典型用法代码示例。如果您正苦于以下问题:Python Datacube.parameters()["ramseyFit"]方法的具体用法?Python Datacube.parameters()["ramseyFit"]怎么用?Python Datacube.parameters()["ramseyFit"]使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类pyview.lib.datacube.Datacube
的用法示例。
在下文中一共展示了Datacube.parameters()["ramseyFit"]方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: callback
# 需要导入模块: from pyview.lib.datacube import Datacube [as 别名]
# 或者: from pyview.lib.datacube.Datacube import parameters()["ramseyFit"] [as 别名]
if callback != None:
callback(duration)
acqiris.bifurcationMap(ntimes = averaging)
data.set(duration = duration)
data.set(**acqiris.Psw())
data.commit()
except:
traceback.print_exc()
finally:
if amplitude != 0:
qubit.popState()
(params,rsquare) = fitRamseyFrequency(data,variable,f_offset=f_offset)
if rsquare > 0.5:
qubit.parameters()["pulses.ramsey.t_pi"] = params[1]/2.0
data.setName(data.name()+" - f_r = %g MHz - T_2 = %g ns" % ((1.0/params[1])*1000,params[2]))
data.parameters()["ramseyFit"] = params
f_correct = 1.0/params[1]-abs(f_offset)
if correctFrequency and amplitude == 0 and f_correct < 0.05:
print "Correcting qubit frequency by %g MHz" % (f_correct*1000)
if 01 == transition or 02 == transition:
qubit.parameters()["frequencies.f01"]-=f_correct
elif 12 == transition:
qubit.parameters()["frequencies.f12"]-=f_correct
else:
print "Ramsey fit is not good, resetting parameters..."
qubit.parameters()["pulses.ramsey.t_pi"] = None
if saveData:
data.savetxt()
return data