Skip to content

Commit

Permalink
Add ASV for datatree.from_dict (pydata#9459)
Browse files Browse the repository at this point in the history
  • Loading branch information
Illviljan authored and hollymandel committed Sep 23, 2024
1 parent 82456a7 commit dd7a9a5
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions asv_bench/benchmarks/datatree.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import xarray as xr
from xarray.core.datatree import DataTree


class Datatree:
def setup(self):
run1 = DataTree.from_dict({"run1": xr.Dataset({"a": 1})})
self.d = {"run1": run1}

def time_from_dict(self):
DataTree.from_dict(self.d)

0 comments on commit dd7a9a5

Please sign in to comment.