@@ -386,7 +386,7 @@ def test_equal(name):
386
386
def test_unequal(name):
387
387
df, df2 = pairs[name]
388
388
return df.equals(df2)
389
-
389
+
390
390
float_df = DataFrame(np.random.randn(1000, 1000))
391
391
object_df = DataFrame([['foo']*1000]*1000)
392
392
nonunique_cols = object_df.copy()
@@ -434,11 +434,21 @@ def test_unequal(name):
434
434
# frame shift speedup issue-5609
435
435
436
436
setup = common_setup + """
437
- df = pd.DataFrame(np.random.rand(10000,500))
437
+ df = DataFrame(np.random.rand(10000,500))
438
+ # note: df._data.blocks are f_contigous
438
439
"""
439
440
frame_shift_axis0 = Benchmark ('df.shift(1,axis=0)' , setup ,
440
- name = 'frame_shift_axis_0' ,
441
441
start_date = datetime (2014 ,1 ,1 ))
442
442
frame_shift_axis1 = Benchmark ('df.shift(1,axis=1)' , setup ,
443
- name = 'frame_shift_axis_1' ,
444
- start_date = datetime (2014 ,1 ,1 ))
443
+ start_date = datetime (2014 ,1 ,1 ))
444
+
445
+ #
446
+ setup = common_setup + """
447
+ df = DataFrame(np.random.rand(10000,500))
448
+ df = df.consolidate()
449
+ # note: df._data.blocks are c_contigous
450
+ """
451
+ frame_shift_c_order_axis0 = Benchmark ('df.shift(1,axis=0)' , setup ,
452
+ start_date = datetime (2014 ,1 ,1 ))
453
+ frame_shift_c_order_axis1 = Benchmark ('df.shift(1,axis=1)' , setup ,
454
+ start_date = datetime (2014 ,1 ,1 ))
0 commit comments