MCPcopy
hub / github.com/pydata/xarray / setup

Method setup

asv_bench/benchmarks/repr.py:65–67  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

63 # display a memory-saving pandas.RangeIndex shouldn't trigger memory
64 # expensive conversion into a numpy array
65 def setup(self):
66 index = xr.indexes.PandasIndex(pd.RangeIndex(1_000_000), "x")
67 self.ds = xr.Dataset(coords=xr.Coordinates.from_xindex(index))
68
69 def time_repr(self):
70 repr(self.ds.x)

Callers

nothing calls this directly

Calls 1

from_xindexMethod · 0.80

Tested by

no test coverage detected