Concatenate IVT from MERRA2 reanalysis #5072
-
Hello all, I am trying to concatenate MERRA2 files using iris, but I am having problems. Here is my code:
Python is returning: I believe the issue is about the dtype of the time coordinate. After type:
Python shows me that the dtype for time is int32. For older files, it was float64, and I was being able to concatenate. Please, I need to learn how I change the dtype from int32 to float64. I couldn't find an explanation in the iris user guide. Many thanks for your assistance. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hi @laisgfernandes. The values in a import numpy as np
my_coord = IVT.coord("time")
my_coord.points = my_coord.points.astype(np.float64) |
Beta Was this translation helpful? Give feedback.
Hi @laisgfernandes. The values in a
DimCoord
(DimCoord.points
) are a standard NumPyndarray
, so the correct way of changing type is to usendarray.astype()
on theDimCoord
'spoints
, e.g.: