I have a netCDF dataset and I did this:
nc = Dataset(nc_file, mode='r')
lat = nc.variables['latitude'][:] shape (452,)
lon = nc.variables['longitude'][:] shape (918,)
time = nc.variables['GMTime'][:] shape (1,10)
t2 = nc.variables['t2'][:] shape (1,452,918)
tp = nc.variables['tp'][:] shape (1,452,918)
sf = nc.variables['sf'][:] shape (1,452,918)
u10 = nc.variables['u10'][:] shape (1,452,918)
v10 = nc.variables['v10'][:] shape (1,452,918)
tcc = nc.variables['tcc'][:]
now I want to have a single list like:
new_data = [{lat =s.th,lon= s.th,t2 =s.th,..},lat =s.th,lon= s.th,t2 =s.th,..},...]
but I have no idea how should I do this. :(
thank you in advance for your help