Scheduled Downtime
On Friday 21 April 2023 @ 5pm MT, this website will be down for maintenance and expected to return online the morning of 24 April 2023 at the latest

met_em files format

fipoucat

Member
I have a problem with my large number of met_em file with date format yyyy-mm-dd_hh_mn_ss while real exe looks for yyyy-mm-dd_hh:mn:ss.
How to set namelist.wps to force metgrid.exe to output files like met_em.d03.2012-01-15_03:00:00.nc and not met_em.d03.2012-01-15_03_00_00.nc.

Thanks
 
I have a problem with my large number of met_em file with date format yyyy-mm-dd_hh_mn_ss while real exe looks for yyyy-mm-dd_hh:mn:ss.
How to set namelist.wps to force metgrid.exe to output files like met_em.d03.2012-01-15_03:00:00.nc and not met_em.d03.2012-01-15_03_00_00.nc.

Thanks
This can happen if your files are on a non-Linux system. Try modifying the file name in bulk.
 
@fipoucat This command might help.

mv met_em.d03.2012-*-*_*:*:*.nc met_em.d03.2012-*-*_*_*_*.nc

Now before you run this on all your nc files copy and paste one nc file to a different folder and try that command and see if it changes the name to the proper name.

* In Linux or Unix allows for it to search any naming structure in the string. So it will search for any file that fits that format.

For example, the most commonly used special character is asterisk, * , meaning "zero or more characters". When you type a command like ls a* , the shell finds all filenames in the current directory starting with a and passes them to the ls command.
 
@haiqingsong, I notice I was writing to an ntfs disk within Linux, so you are right because after changing the met_em file are written correctly.
Thank you
 
Last edited:
Top