当前位置: 首页>>代码示例>>Python>>正文


Python CurveDB.params['coucou'+str(j)]方法代码示例

本文整理汇总了Python中pyinstruments.curvestore.models.CurveDB.params['coucou'+str(j)]方法的典型用法代码示例。如果您正苦于以下问题:Python CurveDB.params['coucou'+str(j)]方法的具体用法?Python CurveDB.params['coucou'+str(j)]怎么用?Python CurveDB.params['coucou'+str(j)]使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在pyinstruments.curvestore.models.CurveDB的用法示例。


在下文中一共展示了CurveDB.params['coucou'+str(j)]方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: test_save_params_only

# 需要导入模块: from pyinstruments.curvestore.models import CurveDB [as 别名]
# 或者: from pyinstruments.curvestore.models.CurveDB import params['coucou'+str(j)] [as 别名]
 def test_save_params_only(self):
     from curve import Curve
     models.PROFILE_SAVE = True
     curve = CurveDB()
     curve.set_data(pandas.Series([1,4,6]))
     curve.save()
     
     
     print_and_log("================================")
     
     for i in range(5):
         curve = CurveDB()
         curve.set_data(pandas.Series([1,4,6]))
         for j in range(100):
             curve.params['coucou' + str(j)] = i*j
         tic = time.time()
         curve.save_params()
         print_and_log("time for saving 100 parameters in db only, new curve each time: " + str(time.time() - tic))
     print_and_log("================================")
     for i in range(5):
         curve = CurveDB()
         curve.set_data(pandas.Series([1,4,6]))
         for j in range(100):
             curve.params['coucou' + str(j)] = i*j
         tic = time.time()
         curve.save()
         print_and_log("time for saving 1 curve with 100 parameters, new curve each time: " + str(time.time() - tic))
     models.PROFILE_SAVE = False
开发者ID:vsteinmetz,项目名称:pyinstruments,代码行数:30,代码来源:tests.py

示例2: test_delete

# 需要导入模块: from pyinstruments.curvestore.models import CurveDB [as 别名]
# 或者: from pyinstruments.curvestore.models.CurveDB import params['coucou'+str(j)] [as 别名]
 def test_delete(self):
     from curve import Curve
     curve = CurveDB()
     curve.set_data(pandas.Series([1,4,6]))
     curve.params["dummy"] = 24.5
     for j in range(100):
         curve.params['coucou' + str(j)] = j
     curve.save()
     tic = time.time()
     curve.delete()
     print_and_log("time for deleting one curve: ", time.time() - tic)
开发者ID:vsteinmetz,项目名称:pyinstruments,代码行数:13,代码来源:tests.py

示例3: range

# 需要导入模块: from pyinstruments.curvestore.models import CurveDB [as 别名]
# 或者: from pyinstruments.curvestore.models.CurveDB import params['coucou'+str(j)] [as 别名]
 def test_insert3(self):
     print_and_log("================================")
     
     for i in range(3):
         curve = CurveDB()
         curve.set_data(pandas.Series([1,4,6]))
         for j in range(100):
             curve.params['coucou' + str(j)] = i*j
         tic = time.time()
         curve.save()
         print_and_log("time for saving 1 curve with 100 parameters (new curve each time): " + str(time.time() - tic))
开发者ID:vsteinmetz,项目名称:pyinstruments,代码行数:13,代码来源:tests.py

示例4: test_save_curve_only

# 需要导入模块: from pyinstruments.curvestore.models import CurveDB [as 别名]
# 或者: from pyinstruments.curvestore.models.CurveDB import params['coucou'+str(j)] [as 别名]
 def test_save_curve_only(self):
     from curve import Curve
     curve = CurveDB()
     curve.set_data(pandas.Series([1,4,6]))
     curve.save()
     print_and_log("================================")
     for i in range(3):
         for j in range(100):
             curve.params['coucou' + str(j)] = i*j
         tic = time.time()
         Curve.save(curve, curve.get_full_filename())
         print_and_log("time for saving 1 curve with 100 parameters in h5: " + str(time.time() - tic))
开发者ID:vsteinmetz,项目名称:pyinstruments,代码行数:14,代码来源:tests.py

示例5: CurveDB

# 需要导入模块: from pyinstruments.curvestore.models import CurveDB [as 别名]
# 或者: from pyinstruments.curvestore.models.CurveDB import params['coucou'+str(j)] [as 别名]
 def test_insert2(self):
     print_and_log("================================")
     curve = CurveDB()
     curve.set_data(pandas.Series([1,4,6]))
     curve.save()
     
     for i in range(3):
         for j in range(100):
             curve.params['coucou' + str(j)] = i*j
         tic = time.time()
         curve.save()
         print_and_log("time for saving 1 curve with 100 parameters (always same curve, values changing): " + str(time.time() - tic))
开发者ID:vsteinmetz,项目名称:pyinstruments,代码行数:14,代码来源:tests.py

示例6: test_alter_params_only

# 需要导入模块: from pyinstruments.curvestore.models import CurveDB [as 别名]
# 或者: from pyinstruments.curvestore.models.CurveDB import params['coucou'+str(j)] [as 别名]
 def test_alter_params_only(self):
     from curve import Curve
     curve = CurveDB()
     curve.set_data(pandas.Series([1,4,6]))
     curve.params["dummy"] = 24.5
     for j in range(100):
         curve.params['coucou' + str(j)] = j
     curve.save()
     tic = time.time()
     curve.params["dummy"] = 25.5
     models.PROFILING = True
     curve.save_params()
     print_and_log("================================")
     print_and_log("time for altering just one value: ", time.time() - tic)
     models.PROFILING = False
开发者ID:vsteinmetz,项目名称:pyinstruments,代码行数:17,代码来源:tests.py

示例7: test_save_altered_curve

# 需要导入模块: from pyinstruments.curvestore.models import CurveDB [as 别名]
# 或者: from pyinstruments.curvestore.models.CurveDB import params['coucou'+str(j)] [as 别名]
 def test_save_altered_curve(self):
     from curve import Curve
     curve = CurveDB()
     curve.set_data(pandas.Series([1,4,6]))
     curve.save()
     
     
     print_and_log("================================")
     curve = CurveDB()
     curve.set_data(pandas.Series([1,4,6]))
     for i in range(5):
         for j in range(100):
             curve.params['coucou' + str(j)] = i*j
         tic = time.time()
         curve.save_params()
         print_and_log("time for saving 100 parameters in db only, same curve each time: " + str(time.time() - tic))
开发者ID:vsteinmetz,项目名称:pyinstruments,代码行数:18,代码来源:tests.py


注:本文中的pyinstruments.curvestore.models.CurveDB.params['coucou'+str(j)]方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。