Skip to content

Commit

Permalink
add ASVs
Browse files Browse the repository at this point in the history
  • Loading branch information
topper-123 committed Sep 19, 2020
1 parent 5d1dd81 commit 256ad70
Showing 1 changed file with 12 additions and 5 deletions.
17 changes: 12 additions & 5 deletions asv_bench/benchmarks/strings.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,20 @@ class Construction:
param_names = ["dtype"]

def setup(self, dtype):
self.data = tm.rands_array(nchars=10 ** 5, size=10)
self.series_arr = tm.rands_array(nchars=10, size=10 ** 5)
self.frame_arr = self.series_arr.reshape((50_000, 2)).copy()

def time_construction(self, dtype):
Series(self.data, dtype=dtype)
def time_series_construction(self, dtype):
Series(self.series_arr, dtype=dtype)

def peakmem_construction(self, dtype):
Series(self.data, dtype=dtype)
def peakmem_series_construction(self, dtype):
Series(self.series_arr, dtype=dtype)

def time_frame_construction(self, dtype):
DataFrame(self.frame_arr, dtype=dtype)

def peakmem_frame_construction(self, dtype):
DataFrame(self.frame_arr, dtype=dtype)


class Methods:
Expand Down

0 comments on commit 256ad70

Please sign in to comment.