MCPcopy
hub / github.com/pandas-dev/pandas / setup

Method setup

asv_bench/benchmarks/sparse.py:183–187  ·  view source on GitHub ↗
(self, indices, allow_fill)

Source from the content-addressed store, hash-verified

181 param_names = ["indices", "allow_fill"]
182
183 def setup(self, indices, allow_fill):
184 N = 1_000_000
185 fill_value = 0.0
186 arr = make_array(N, 1e-5, fill_value, np.float64)
187 self.sp_arr = SparseArray(arr, fill_value=fill_value)
188
189 def time_take(self, indices, allow_fill):
190 self.sp_arr.take(indices, allow_fill=allow_fill)

Callers

nothing calls this directly

Calls 2

SparseArrayClass · 0.90
make_arrayFunction · 0.85

Tested by

no test coverage detected