Skip to content

Simple scripts to generate a NetCDF file from an xyz .txt file.

Notifications You must be signed in to change notification settings

cpjordan/text_to_NetCDF

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

text_to_NetCDF

Interpolation of unstructured xyz data (e.g. bathymetry) in .txt or .csv format to a structured grid. in .nc format. Subsequent generation of boundary (concave hull - alphashapes) to create a mask for clipping resultant gridded data.

  1. Run 'txt_to_npy.py' - requires input file.
  2. Run 'npy_to_nc_UTM.py' - requires input file and choice of interpolation method, resolution and espg (keep to UTM and change to WGS84 via QGIS).
  3. If non-rectangular boundaries required, run the boundary generation file to generate a more precise outline. use the 'test_files/bounds_vis.py' to visualise the shapefiles over the gridded data to help reduce the number of data points if using a large data set.

Written originally for a very large data set of 100m+ points where the resolution was being reduced and hence nearest neighbour interpolation used.

About

Simple scripts to generate a NetCDF file from an xyz .txt file.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages