File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -315,7 +315,7 @@ def decompose_NWP(
315315 )
316316
317317 # Make a NetCDF file
318- output_date = f"{ analysis_time .astype (datetime .datetime ):%Y%m%d%H%M%S} "
318+ output_date = f"{ analysis_time .astype ('datetime64[us]' ). astype ( datetime .datetime ):%Y%m%d%H%M%S} "
319319 outfn = Path (output_path ) / f"cascade_{ NWP_model } _{ output_date } .nc"
320320 ncf = netCDF4 .Dataset (outfn , "w" , format = "NETCDF4" )
321321
@@ -411,7 +411,7 @@ def compute_store_nwp_motion(
411411 """
412412
413413 # Set the output file
414- output_date = f"{ analysis_time .astype (datetime .datetime ):%Y%m%d%H%M%S} "
414+ output_date = f"{ analysis_time .astype ('datetime64[us]' ). astype ( datetime .datetime ):%Y%m%d%H%M%S} "
415415 outfn = Path (output_path ) / f"motion_{ nwp_model } _{ output_date } .npy"
416416
417417 # Get the velocity field per time step
You can’t perform that action at this time.
0 commit comments