Skip to content

Commit 03455f3

Browse files
authored
Fix cardinality of output_dtypes in apply_gufunc (#738)
1 parent 2c04fda commit 03455f3

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

cubed/core/gufunc.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,13 @@ def apply_gufunc(
5151
"Multiple outputs are not yet supported, see https://github.com/cubed-dev/cubed/issues/69"
5252
)
5353

54+
if (
55+
nout is None
56+
and isinstance(output_dtypes, (tuple, list))
57+
and len(output_dtypes) == 1
58+
):
59+
output_dtypes = output_dtypes[0]
60+
5461
# Vectorize function, if required
5562
if vectorize:
5663
otypes = output_dtypes

0 commit comments

Comments
 (0)