Skip to content

Commit

Permalink
Merge pull request #204 from dstansby/cdf-testing
Browse files Browse the repository at this point in the history
Improve xarray testing
  • Loading branch information
dstansby committed May 26, 2023
2 parents ae214f6 + b4cd51d commit 3e52a8d
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 338 deletions.
2 changes: 1 addition & 1 deletion cdflib/cdf_to_xarray.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def _convert_cdf_time_types(data, atts: Dict[str, AttData], properties: VDRInfo,
# If nothing, ALL CDF_EPOCH16 types are converted to CDF_EPOCH, because xarray can't handle int64s
"""

data = np.atleast_1d(data)
data = np.atleast_1d(np.squeeze(data))

if to_datetime and to_unixtime:
print("Cannot convert to both unixtime and datetime. Continuing with conversion to unixtime.")
Expand Down

0 comments on commit 3e52a8d

Please sign in to comment.