Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Assistance with Converting ERA5 & WRF Model Simulated Wind Fields to WW3 Input Format #1256

Open
CHARANJULURI opened this issue Jun 21, 2024 · 3 comments
Labels
bug Something isn't working

Comments

@CHARANJULURI
Copy link

Dear WW3 Community,

I hope this message finds you well. My name is Charan Kumar, and I am reaching out to seek your assistance with a technical issue I am currently facing.

I am working on a project that involves running the WaveWatch III (WW3) model using real forcing fields from ERA5 and WRF model-simulated wind data. I have the wind fields in .nc (NetCDF) format and need to convert them into a compatible format for .ww3 specifically for use with the ww3_prnc pre-processing tool.

Despite my efforts, I have encountered errors when directly importing the wind files in .nc format into WW3. Therefore, I am seeking guidance or tools that could facilitate this conversion process.

Error Details:
image

[(base) [las@localhost work]$ ./ww3_prnc

             *** WAVEWATCH III  Input pre-processing ***
           ===============================================

Grid name : NIO

Description of inputs

   Input type        : winds
   Format type       : long.-lat. grid
      Field conserves velocity.
   Start time        : 2020/05/10 00:00:00 UTC
   Stop time         : 2020/05/10 03:00:00 UTC

       File name         : ./input/May-2020-Wind.nc
       Dimension along x : longitude
       Dimension along y : latitude
       Field component 1 : u10
       Field component 2 : v10

*** WAVEWATCH III ERROR IN W3PRNC :
LATITUDE VALUES MUST BE REVERSED
EXAMPLE: ncpdq -h -O -a -lat file.nc

(base) [las@localhost work]$ ncpdq -h -O -a -lat input/May-2020-Wind.nc
bash: ncpdq: command not found...]

Request:
Could you please provide any available codes, software, or guidance on how to successfully convert the wind fields from .nc format to the required wind.ww3 format for use with ww3_prnc?

Your assistance in resolving this issue would be greatly appreciated.
Thank you for your time and attention to this matter.

Yours faithfully,
J. Charan Kumar

@CHARANJULURI CHARANJULURI added the bug Something isn't working label Jun 21, 2024
@aliabdolali
Copy link
Contributor

you need cdo package to do ncpdq -h -O -a -lat input/May-2020-Wind.nc

@CHARANJULURI
Copy link
Author

Thank you for addressing my issue, sir. I am currently facing difficulties in using the cdo package. If there are any alternative sources or codes available to convert the .nc file to .ww3 format or directly incorporate it into the ww3 model, I would greatly appreciate any assistance in this matter.

@CarstenHansen
Copy link
Contributor

@aliabdolali is pointing out that you encounter a bash shell error because you have no path to the NCO program ncpdq. An installation guidance for the NCO package is given here: https://nco.sourceforge.net/#bld . An alternative is the cdo program, which has an operator -invertlat that can do the same conversion of the latitude order in the netCDF file for ww3_prnc. I find the CDO package very useful for this kind of work - maybe you could try harder to obtain a new installation?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants