示例#1
0
 def test_dataframe_from_array2(self):
     vals = [float(i) for i in range(0,5)]
     key = Key("test",0)
     kv = KeyValueStore()
     d = Dataframe.from_array(key=key,kv=kv,size=5,array=vals,arr_type='F')
     self.assertEqual([vals], d.data)
示例#2
0
文件: demo.py 项目: destae/Milestones
 def producer(self):
     SZ = 100*100
     vals = [float(i) for i in range(0,SZ)]
     sum_vals = float(sum(vals))
     d = Dataframe.from_array(self.main, self.kv, SZ, vals, "F")
     s = Dataframe.from_scalar(self.check,self.kv,sum_vals, "F")
示例#3
0
 def test_dataframe_from_array(self):
     vals = [float(i) for i in range(0,500)]
     key = Key("test",0)
     kv = KeyValueStore()
     d = Dataframe.from_array(key=key,kv=kv, size=500,array=vals,arr_type='F')
     self.assertEqual(Schema(["F"],ncols=1,nrows=500), d.schema)