From e13e9184155488bf89168ba966cb848777f78a66 Mon Sep 17 00:00:00 2001 From: meggart Date: Thu, 28 Nov 2024 14:01:23 +0100 Subject: [PATCH] fix open_mfdataset for new axes --- src/DatasetAPI/Datasets.jl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/DatasetAPI/Datasets.jl b/src/DatasetAPI/Datasets.jl index 4977767e..0a56f5eb 100644 --- a/src/DatasetAPI/Datasets.jl +++ b/src/DatasetAPI/Datasets.jl @@ -8,8 +8,8 @@ using IntervalSets: Interval, (..) using CFTime: timedecode, timeencode, DateTimeNoLeap, DateTime360Day, DateTimeAllLeap using YAXArrayBase using YAXArrayBase: iscontdimval, add_var -using DiskArrayTools: CFDiskArray, ConcatDiskArray -using DiskArrays: DiskArrays, GridChunks +using DiskArrayTools: CFDiskArray, diskstack +using DiskArrays: DiskArrays, GridChunks, ConcatDiskArray using Glob: glob using DimensionalData: DimensionalData as DD @@ -341,7 +341,7 @@ function merge_new_axis(alldatasets, firstcube,var,mergedim) newdim = DD.rebuild(mergedim,1:length(alldatasets)) alldiskarrays = map(ds->ds.cubes[var].data,alldatasets).data newda = diskstack(alldiskarrays) - newdims = (DD.dim(firstcube)...,newdim) + newdims = (DD.dims(firstcube)...,newdim) YAXArray(newdims,newda,deepcopy(firstcube.properties)) end function merge_existing_axis(alldatasets,firstcube,var,mergedim)