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

Issue with OBSGRID and CSV-based Observation Nudging (Using Python to Convert Format)

cloud37

New member
Hello WRF community,

I'm currently running WRF+WPS successfully, and now trying to apply observation nudging using FDDA.
I would like to ingest ground-based observation data stored in .csv format (see example in Fig. 1) into WRF using obsgrid.exe, without using obsproc.exe.


Fig. 1: Observation data – original .csv format
(Figure shows weather station data such as temperature, pressure, wind direction/speed, etc.)
1744088891298.png


Fig. (1) observation data - .csv format

To achieve this, I wrote a Python script (convert_csv_to_obsgrid.py, attached below) to convert the .csv files into the required format for obsgrid.exe.

The third attachment (obs_input:2025-03-04_12) is an example of the converted observation input file.
However, when I run obsgrid.exe, I encounter errors such as error.

I would like to ask the following:
  1. Is it acceptable to use a custom Python script (instead of obsproc.exe) to generate the observation input file for obsgrid.exe?
    Are there any essential preprocessing steps that only obsproc.exe performs?
  2. What is the exact input file format required by obsgrid.exe?
    Is there an official specification or example for the observation input (e.g., required lines, variable codes, units, order)?
Any guidance would be greatly appreciated. Thank you in advance!

Current Setup​

  • WRF version: 4.6.1
  • OBSGRID version: 3.7
  • FDDA and observation nudging enabled in namelist.input
  • I'm generating hourly obs_input:* files with obsgrid.exe using custom-processed .csv observations
  • I’ve attached:
    • Sample Python script used for conversion
    • Sample input file (obs_input:2025-03-04_12)
    • Log output from obsgrid.exe
 

Attachments

  • convert_csv_to_obsgrid_405.txt
    2.3 KB · Views: 0
  • obs_input:2025-03-04_12.txt
    64.7 KB · Views: 0
  • error_log.txt
    46 KB · Views: 0
Top