Skip to content

Commit

Permalink
Add ASV for datatree.from_dict (#9459)
Browse files Browse the repository at this point in the history
  • Loading branch information
Illviljan authored Sep 9, 2024
1 parent 9a19d11 commit 0af1979
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 0af1979

Please sign in to comment.