Testing Xray on weather forecast model data


In [4]:
import xray
import datetime
import matplotlib.pyplot as plt
import numpy as np
import pandas as pd
%matplotlib inline

In [5]:
URL = 'http://thredds.ucar.edu/thredds/dodsC/grib/NCEP/GFS/Global_0p5deg/Best'

In [6]:
ds = xray.open_dataset(URL)

In [7]:
ds


Out[7]:
<xray.Dataset>
Dimensions:                                                                     (altitude_above_msl: 3, depth_below_surface_layer: 4, depth_below_surface_layer_bounds_1: 2, height_above_ground: 1, height_above_ground1: 2, height_above_ground2: 1, height_above_ground3: 3, height_above_ground4: 3, height_above_ground_layer: 1, height_above_ground_layer1: 1, height_above_ground_layer1_bounds_1: 2, height_above_ground_layer_bounds_1: 2, isobaric: 12, isobaric1: 1, isobaric2: 21, isobaric3: 26, lat: 361, lon: 720, potential_vorticity_surface: 2, pressure_difference_layer: 1, pressure_difference_layer1: 1, pressure_difference_layer1_bounds_1: 2, pressure_difference_layer2: 2, pressure_difference_layer2_bounds_1: 2, pressure_difference_layer_bounds_1: 2, sigma: 1, sigma_layer: 4, sigma_layer_bounds_1: 2, time: 205, time1: 204, time2: 204, time2_bounds_1: 2)
Coordinates:
  * lat                                                                         (lat) float32 90.0 ...
  * lon                                                                         (lon) float32 0.0 ...
  * time                                                                        (time) datetime64[ns] 2015-08-21 ...
    reftime                                                                     (time) datetime64[ns] ...
  * time1                                                                       (time1) datetime64[ns] 2015-08-21T03:00:00 ...
    reftime1                                                                    (time1) datetime64[ns] ...
  * time2                                                                       (time2) datetime64[ns] 2015-08-21T03:00:00 ...
    reftime2                                                                    (time2) datetime64[ns] ...
  * depth_below_surface_layer                                                   (depth_below_surface_layer) float32 0.05 ...
  * isobaric                                                                    (isobaric) float32 1000.0 ...
  * height_above_ground_layer                                                   (height_above_ground_layer) float32 1500.0 ...
  * height_above_ground                                                         (height_above_ground) float32 2.0 ...
  * potential_vorticity_surface                                                 (potential_vorticity_surface) float32 -2e-06 ...
  * pressure_difference_layer                                                   (pressure_difference_layer) float32 1500.0 ...
  * isobaric1                                                                   (isobaric1) float32 50000.0 ...
  * height_above_ground1                                                        (height_above_ground1) float32 2.0 ...
  * height_above_ground2                                                        (height_above_ground2) float32 80.0 ...
  * isobaric2                                                                   (isobaric2) float32 10000.0 ...
  * sigma                                                                       (sigma) float32 0.995 ...
  * altitude_above_msl                                                          (altitude_above_msl) float32 1829.0 ...
  * height_above_ground3                                                        (height_above_ground3) float32 10.0 ...
  * height_above_ground_layer1                                                  (height_above_ground_layer1) float32 3000.0 ...
  * pressure_difference_layer1                                                  (pressure_difference_layer1) float32 12750.0 ...
  * isobaric3                                                                   (isobaric3) float32 1000.0 ...
  * sigma_layer                                                                 (sigma_layer) float32 0.58 ...
  * pressure_difference_layer2                                                  (pressure_difference_layer2) float32 9000.0 ...
  * height_above_ground4                                                        (height_above_ground4) float32 2.0 ...
  * depth_below_surface_layer_bounds_1                                          (depth_below_surface_layer_bounds_1) int64 0 ...
  * height_above_ground_layer1_bounds_1                                         (height_above_ground_layer1_bounds_1) int64 0 ...
  * height_above_ground_layer_bounds_1                                          (height_above_ground_layer_bounds_1) int64 0 ...
  * pressure_difference_layer1_bounds_1                                         (pressure_difference_layer1_bounds_1) int64 0 ...
  * pressure_difference_layer2_bounds_1                                         (pressure_difference_layer2_bounds_1) int64 0 ...
  * pressure_difference_layer_bounds_1                                          (pressure_difference_layer_bounds_1) int64 0 ...
  * sigma_layer_bounds_1                                                        (sigma_layer_bounds_1) int64 0 ...
  * time2_bounds_1                                                              (time2_bounds_1) int64 0 ...
Data variables:
    LatLon_Projection                                                           int32 ...
    time2_bounds                                                                (time2, time2_bounds_1) datetime64[ns] ...
    depth_below_surface_layer_bounds                                            (depth_below_surface_layer, depth_below_surface_layer_bounds_1) float32 ...
    height_above_ground_layer_bounds                                            (height_above_ground_layer, height_above_ground_layer_bounds_1) float32 ...
    pressure_difference_layer_bounds                                            (pressure_difference_layer, pressure_difference_layer_bounds_1) float32 ...
    height_above_ground_layer1_bounds                                           (height_above_ground_layer1, height_above_ground_layer1_bounds_1) float32 ...
    pressure_difference_layer1_bounds                                           (pressure_difference_layer1, pressure_difference_layer1_bounds_1) float32 ...
    sigma_layer_bounds                                                          (sigma_layer, sigma_layer_bounds_1) float32 ...
    pressure_difference_layer2_bounds                                           (pressure_difference_layer2, pressure_difference_layer2_bounds_1) float32 ...
    Total_ozone_entire_atmosphere_single_layer                                  (time, lat, lon) float64 ...
    Ozone_Mixing_Ratio_isobaric                                                 (time, isobaric, lat, lon) float64 ...
    Momentum_flux_u-component_surface_Mixed_intervals_Average                   (time2, lat, lon) float64 ...
    Momentum_flux_v-component_surface_Mixed_intervals_Average                   (time2, lat, lon) float64 ...
    Surface_Lifted_Index_surface                                                (time, lat, lon) float64 ...
    Downward_Short-Wave_Radiation_Flux_surface_Mixed_intervals_Average          (time2, lat, lon) float64 ...
    Downward_Long-Wave_Radp_Flux_surface_Mixed_intervals_Average                (time2, lat, lon) float64 ...
    Pressure_middle_cloud_bottom_Mixed_intervals_Average                        (time2, lat, lon) float64 ...
    Pressure_middle_cloud_top_Mixed_intervals_Average                           (time2, lat, lon) float64 ...
    Pressure_convective_cloud_bottom                                            (time1, lat, lon) float64 ...
    Pressure_convective_cloud_top                                               (time1, lat, lon) float64 ...
    Pressure_low_cloud_bottom_Mixed_intervals_Average                           (time2, lat, lon) float64 ...
    Pressure_low_cloud_top_Mixed_intervals_Average                              (time2, lat, lon) float64 ...
    Ventilation_Rate_planetary_boundary                                         (time, lat, lon) float64 ...
    Pressure_high_cloud_top_Mixed_intervals_Average                             (time2, lat, lon) float64 ...
    Vertical_Speed_Shear_potential_vorticity_surface                            (time, potential_vorticity_surface, lat, lon) float64 ...
    Pressure_high_cloud_bottom_Mixed_intervals_Average                          (time2, lat, lon) float64 ...
    MSLP_Eta_model_reduction_msl                                                (time, lat, lon) float64 ...
    Vertical_Speed_Shear_tropopause                                             (time, lat, lon) float64 ...
    Wind_speed_gust_surface                                                     (time, lat, lon) float64 ...
    Pressure_of_level_from_which_parcel_was_lifted_pressure_difference_layer    (time, pressure_difference_layer1, lat, lon) float64 ...
    Temperature_middle_cloud_top_Mixed_intervals_Average                        (time2, lat, lon) float64 ...
    Temperature_high_cloud_top_Mixed_intervals_Average                          (time2, lat, lon) float64 ...
    Temperature_low_cloud_top_Mixed_intervals_Average                           (time2, lat, lon) float64 ...
    Categorical_Rain_surface_Mixed_intervals_Average                            (time2, lat, lon) float64 ...
    Potential_Evaporation_Rate_surface                                          (time1, lat, lon) float64 ...
    Volumetric_Soil_Moisture_Content_depth_below_surface_layer                  (time, depth_below_surface_layer, lat, lon) float64 ...
    Ice_cover_surface                                                           (time, lat, lon) float64 ...
    Land_cover_0__sea_1__land_surface                                           (time, lat, lon) float64 ...
    Pressure_surface                                                            (time, lat, lon) float64 ...
    Specific_humidity_pressure_difference_layer                                 (time, pressure_difference_layer, lat, lon) float64 ...
    Temperature_surface                                                         (time, lat, lon) float64 ...
    Temperature_pressure_difference_layer                                       (time, pressure_difference_layer, lat, lon) float64 ...
    Albedo_surface_Mixed_intervals_Average                                      (time2, lat, lon) float64 ...
    Relative_humidity_sigma_layer                                               (time, sigma_layer, lat, lon) float64 ...
    Relative_humidity_pressure_difference_layer                                 (time, pressure_difference_layer, lat, lon) float64 ...
    Haines_Index_surface                                                        (time, lat, lon) float64 ...
    Soil_temperature_depth_below_surface_layer                                  (time, depth_below_surface_layer, lat, lon) float64 ...
    u-component_of_wind_pressure_difference_layer                               (time, pressure_difference_layer, lat, lon) float64 ...
    v-component_of_wind_pressure_difference_layer                               (time, pressure_difference_layer, lat, lon) float64 ...
    Geopotential_height_surface                                                 (time, lat, lon) float64 ...
    Water_runoff_surface_Mixed_intervals_Accumulation                           (time2, lat, lon) float64 ...
    Convective_available_potential_energy_surface                               (time, lat, lon) float64 ...
    Convective_available_potential_energy_pressure_difference_layer             (time, pressure_difference_layer2, lat, lon) float64 ...
    Convective_inhibition_pressure_difference_layer                             (time, pressure_difference_layer2, lat, lon) float64 ...
    Convective_inhibition_surface                                               (time, lat, lon) float64 ...
    Precipitation_rate_surface_Mixed_intervals_Average                          (time2, lat, lon) float64 ...
    Storm_relative_helicity_height_above_ground_layer                           (time, height_above_ground_layer, lat, lon) float64 ...
    Total_precipitation_surface_Mixed_intervals_Accumulation                    (time2, lat, lon) float64 ...
    Convective_precipitation_surface_Mixed_intervals_Accumulation               (time2, lat, lon) float64 ...
    Latent_heat_net_flux_surface_Mixed_intervals_Average                        (time2, lat, lon) float64 ...
    Sensible_heat_net_flux_surface_Mixed_intervals_Average                      (time2, lat, lon) float64 ...
    Snow_depth_surface                                                          (time, lat, lon) float64 ...
    Water_equivalent_of_accumulated_snow_depth_surface                          (time, lat, lon) float64 ...
    Total_cloud_cover_high_cloud_Mixed_intervals_Average                        (time2, lat, lon) float64 ...
    Total_cloud_cover_convective_cloud                                          (time1, lat, lon) float64 ...
    Total_cloud_cover_middle_cloud_Mixed_intervals_Average                      (time2, lat, lon) float64 ...
    Total_cloud_cover_boundary_layer_cloud_Mixed_intervals_Average              (time2, lat, lon) float64 ...
    Total_cloud_cover_low_cloud_Mixed_intervals_Average                         (time2, lat, lon) float64 ...
    Cloud_Work_Function_entire_atmosphere_single_layer_Mixed_intervals_Average  (time2, lat, lon) float64 ...
    Sunshine_Duration_surface                                                   (time, lat, lon) float64 ...
    Best_4_layer_Lifted_Index_surface                                           (time, lat, lon) float64 ...
    Upward_Short-Wave_Radiation_Flux_atmosphere_top_Mixed_intervals_Average     (time2, lat, lon) float64 ...
    Upward_Short-Wave_Radiation_Flux_surface_Mixed_intervals_Average            (time2, lat, lon) float64 ...
    Upward_Long-Wave_Radp_Flux_atmosphere_top_Mixed_intervals_Average           (time2, lat, lon) float64 ...
    Upward_Long-Wave_Radp_Flux_surface_Mixed_intervals_Average                  (time2, lat, lon) float64 ...
    5-Wave_Geopotential_Height_isobaric                                         (time, isobaric1, lat, lon) float64 ...
    Relative_humidity_entire_atmosphere_single_layer                            (time, lat, lon) float64 ...
    Relative_humidity_highest_tropospheric_freezing                             (time, lat, lon) float64 ...
    Categorical_Freezing_Rain_surface_Mixed_intervals_Average                   (time2, lat, lon) float64 ...
    Ground_Heat_Flux_surface_Mixed_intervals_Average                            (time2, lat, lon) float64 ...
    Wilting_Point_surface                                                       (time, lat, lon) float64 ...
    Per_cent_frozen_precipitation_surface                                       (time, lat, lon) float64 ...
    Temperature_isobaric                                                        (time, isobaric3, lat, lon) float64 ...
    Relative_humidity_isobaric                                                  (time, isobaric3, lat, lon) float64 ...
    Relative_humidity_zeroDegC_isotherm                                         (time, lat, lon) float64 ...
    u-component_of_wind_isobaric                                                (time, isobaric3, lat, lon) float64 ...
    v-component_of_wind_isobaric                                                (time, isobaric3, lat, lon) float64 ...
    Geopotential_height_isobaric                                                (time, isobaric3, lat, lon) float64 ...
    Geopotential_height_zeroDegC_isotherm                                       (time, lat, lon) float64 ...
    U-Component_Storm_Motion_height_above_ground_layer                          (time, height_above_ground_layer1, lat, lon) float64 ...
    Zonal_Flux_of_Gravity_Wave_Stress_surface_Mixed_intervals_Average           (time2, lat, lon) float64 ...
    u-component_of_wind_planetary_boundary                                      (time, lat, lon) float64 ...
    Categorical_Ice_Pellets_surface_Mixed_intervals_Average                     (time2, lat, lon) float64 ...
    Vertical_velocity_pressure_isobaric                                         (time, isobaric2, lat, lon) float64 ...
    Absolute_vorticity_isobaric                                                 (time, isobaric3, lat, lon) float64 ...
    Pressure_reduced_to_MSL_msl                                                 (time, lat, lon) float64 ...
    Cloud_mixing_ratio_isobaric                                                 (time, isobaric2, lat, lon) float64 ...
    Pressure_maximum_wind                                                       (time, lat, lon) float64 ...
    Temperature_altitude_above_msl                                              (time, altitude_above_msl, lat, lon) float64 ...
    Temperature_maximum_wind                                                    (time, lat, lon) float64 ...
    u-component_of_wind_altitude_above_msl                                      (time, altitude_above_msl, lat, lon) float64 ...
    u-component_of_wind_maximum_wind                                            (time, lat, lon) float64 ...
    ICAO_Standard_Atmosphere_Reference_Height_maximum_wind                      (time, lat, lon) float64 ...
    v-component_of_wind_maximum_wind                                            (time, lat, lon) float64 ...
    v-component_of_wind_altitude_above_msl                                      (time, altitude_above_msl, lat, lon) float64 ...
    Apparent_temperature_height_above_ground                                    (time, height_above_ground, lat, lon) float64 ...
    Geopotential_height_maximum_wind                                            (time, lat, lon) float64 ...
    V-Component_Storm_Motion_height_above_ground_layer                          (time, height_above_ground_layer1, lat, lon) float64 ...
    Meridional_Flux_of_Gravity_Wave_Stress_surface_Mixed_intervals_Average      (time2, lat, lon) float64 ...
    Field_Capacity_surface                                                      (time, lat, lon) float64 ...
    v-component_of_wind_planetary_boundary                                      (time, lat, lon) float64 ...
    Precipitable_water_entire_atmosphere_single_layer                           (time, lat, lon) float64 ...
    Categorical_Snow_surface_Mixed_intervals_Average                            (time2, lat, lon) float64 ...
    Pressure_height_above_ground                                                (time, height_above_ground2, lat, lon) float64 ...
    Pressure_tropopause                                                         (time, lat, lon) float64 ...
    Specific_humidity_height_above_ground                                       (time, height_above_ground1, lat, lon) float64 ...
    Temperature_height_above_ground                                             (time, height_above_ground4, lat, lon) float64 ...
    Temperature_tropopause                                                      (time, lat, lon) float64 ...
    Relative_humidity_height_above_ground                                       (time, height_above_ground, lat, lon) float64 ...
    u-component_of_wind_height_above_ground                                     (time, height_above_ground3, lat, lon) float64 ...
    u-component_of_wind_tropopause                                              (time, lat, lon) float64 ...
    ICAO_Standard_Atmosphere_Reference_Height_tropopause                        (time, lat, lon) float64 ...
    v-component_of_wind_height_above_ground                                     (time, height_above_ground3, lat, lon) float64 ...
    v-component_of_wind_tropopause                                              (time, lat, lon) float64 ...
    Maximum_temperature_height_above_ground_Mixed_intervals_Maximum             (time2, height_above_ground, lat, lon) float64 ...
    Geopotential_height_tropopause                                              (time, lat, lon) float64 ...
    Minimum_temperature_height_above_ground_Mixed_intervals_Minimum             (time2, height_above_ground, lat, lon) float64 ...
    Dewpoint_temperature_height_above_ground                                    (time, height_above_ground, lat, lon) float64 ...
    Temperature_sigma                                                           (time, sigma, lat, lon) float64 ...
    Relative_humidity_sigma                                                     (time, sigma, lat, lon) float64 ...
    Potential_temperature_sigma                                                 (time, sigma, lat, lon) float64 ...
    u-component_of_wind_sigma                                                   (time, sigma, lat, lon) float64 ...
    v-component_of_wind_sigma                                                   (time, sigma, lat, lon) float64 ...
    Planetary_Boundary_Layer_Height_surface                                     (time, lat, lon) float64 ...
    Convective_Precipitation_Rate_surface_Mixed_intervals_Average               (time2, lat, lon) float64 ...
    Vertical_velocity_pressure_sigma                                            (time, sigma, lat, lon) float64 ...
    Total_cloud_cover_entire_atmosphere_Mixed_intervals_Average                 (time2, lat, lon) float64 ...
    Geopotential_height_highest_tropospheric_freezing                           (time, lat, lon) float64 ...
    Cloud_water_entire_atmosphere_single_layer                                  (time, lat, lon) float64 ...
    Pressure_potential_vorticity_surface                                        (time, potential_vorticity_surface, lat, lon) float64 ...
    Temperature_potential_vorticity_surface                                     (time, potential_vorticity_surface, lat, lon) float64 ...
    u-component_of_wind_potential_vorticity_surface                             (time, potential_vorticity_surface, lat, lon) float64 ...
    v-component_of_wind_potential_vorticity_surface                             (time, potential_vorticity_surface, lat, lon) float64 ...
    Geopotential_height_potential_vorticity_surface                             (time, potential_vorticity_surface, lat, lon) float64 ...
Attributes:
    Originating_or_generating_Center: US National Weather Service, National Centres for Environmental Prediction (NCEP)
    Originating_or_generating_Subcenter: 0
    GRIB_table_version: 2,1
    Type_of_generating_process: Forecast
    Analysis_or_forecast_generating_process_identifier_defined_by_originating_centre: Analysis from GFS (Global Forecast System)
    file_format: GRIB-2
    Conventions: CF-1.6
    history: Read using CDM IOSP GribCollection v3
    featureType: GRID
    _CoordSysBuilder: ucar.nc2.dataset.conv.CF1Convention

In [8]:
# select lat,lon region of interest
# note: slice(20.5,55.0) fails
dsloc = ds.sel(lon=slice(230.5,300.0),lat=slice(55.0,20.5))

In [9]:
# select closest data to time of interest
#date = datetime.datetime(2015,7,15,3,0,0)
date = datetime.datetime.now()
ds_snapshot = dsloc.sel(time=date,time1=date,time2=date,method='nearest')

In [10]:
ds.data_vars


Out[10]:
Data variables:
    LatLon_Projection                                                           int32 ...
    time2_bounds                                                                (time2, time2_bounds_1) datetime64[ns] ...
    depth_below_surface_layer_bounds                                            (depth_below_surface_layer, depth_below_surface_layer_bounds_1) float32 ...
    height_above_ground_layer_bounds                                            (height_above_ground_layer, height_above_ground_layer_bounds_1) float32 ...
    pressure_difference_layer_bounds                                            (pressure_difference_layer, pressure_difference_layer_bounds_1) float32 ...
    height_above_ground_layer1_bounds                                           (height_above_ground_layer1, height_above_ground_layer1_bounds_1) float32 ...
    pressure_difference_layer1_bounds                                           (pressure_difference_layer1, pressure_difference_layer1_bounds_1) float32 ...
    sigma_layer_bounds                                                          (sigma_layer, sigma_layer_bounds_1) float32 ...
    pressure_difference_layer2_bounds                                           (pressure_difference_layer2, pressure_difference_layer2_bounds_1) float32 ...
    Total_ozone_entire_atmosphere_single_layer                                  (time, lat, lon) float64 ...
    Ozone_Mixing_Ratio_isobaric                                                 (time, isobaric, lat, lon) float64 ...
    Momentum_flux_u-component_surface_Mixed_intervals_Average                   (time2, lat, lon) float64 ...
    Momentum_flux_v-component_surface_Mixed_intervals_Average                   (time2, lat, lon) float64 ...
    Surface_Lifted_Index_surface                                                (time, lat, lon) float64 ...
    Downward_Short-Wave_Radiation_Flux_surface_Mixed_intervals_Average          (time2, lat, lon) float64 ...
    Downward_Long-Wave_Radp_Flux_surface_Mixed_intervals_Average                (time2, lat, lon) float64 ...
    Pressure_middle_cloud_bottom_Mixed_intervals_Average                        (time2, lat, lon) float64 ...
    Pressure_middle_cloud_top_Mixed_intervals_Average                           (time2, lat, lon) float64 ...
    Pressure_convective_cloud_bottom                                            (time1, lat, lon) float64 ...
    Pressure_convective_cloud_top                                               (time1, lat, lon) float64 ...
    Pressure_low_cloud_bottom_Mixed_intervals_Average                           (time2, lat, lon) float64 ...
    Pressure_low_cloud_top_Mixed_intervals_Average                              (time2, lat, lon) float64 ...
    Ventilation_Rate_planetary_boundary                                         (time, lat, lon) float64 ...
    Pressure_high_cloud_top_Mixed_intervals_Average                             (time2, lat, lon) float64 ...
    Vertical_Speed_Shear_potential_vorticity_surface                            (time, potential_vorticity_surface, lat, lon) float64 ...
    Pressure_high_cloud_bottom_Mixed_intervals_Average                          (time2, lat, lon) float64 ...
    MSLP_Eta_model_reduction_msl                                                (time, lat, lon) float64 ...
    Vertical_Speed_Shear_tropopause                                             (time, lat, lon) float64 ...
    Wind_speed_gust_surface                                                     (time, lat, lon) float64 ...
    Pressure_of_level_from_which_parcel_was_lifted_pressure_difference_layer    (time, pressure_difference_layer1, lat, lon) float64 ...
    Temperature_middle_cloud_top_Mixed_intervals_Average                        (time2, lat, lon) float64 ...
    Temperature_high_cloud_top_Mixed_intervals_Average                          (time2, lat, lon) float64 ...
    Temperature_low_cloud_top_Mixed_intervals_Average                           (time2, lat, lon) float64 ...
    Categorical_Rain_surface_Mixed_intervals_Average                            (time2, lat, lon) float64 ...
    Potential_Evaporation_Rate_surface                                          (time1, lat, lon) float64 ...
    Volumetric_Soil_Moisture_Content_depth_below_surface_layer                  (time, depth_below_surface_layer, lat, lon) float64 ...
    Ice_cover_surface                                                           (time, lat, lon) float64 ...
    Land_cover_0__sea_1__land_surface                                           (time, lat, lon) float64 ...
    Pressure_surface                                                            (time, lat, lon) float64 ...
    Specific_humidity_pressure_difference_layer                                 (time, pressure_difference_layer, lat, lon) float64 ...
    Temperature_surface                                                         (time, lat, lon) float64 ...
    Temperature_pressure_difference_layer                                       (time, pressure_difference_layer, lat, lon) float64 ...
    Albedo_surface_Mixed_intervals_Average                                      (time2, lat, lon) float64 ...
    Relative_humidity_sigma_layer                                               (time, sigma_layer, lat, lon) float64 ...
    Relative_humidity_pressure_difference_layer                                 (time, pressure_difference_layer, lat, lon) float64 ...
    Haines_Index_surface                                                        (time, lat, lon) float64 ...
    Soil_temperature_depth_below_surface_layer                                  (time, depth_below_surface_layer, lat, lon) float64 ...
    u-component_of_wind_pressure_difference_layer                               (time, pressure_difference_layer, lat, lon) float64 ...
    v-component_of_wind_pressure_difference_layer                               (time, pressure_difference_layer, lat, lon) float64 ...
    Geopotential_height_surface                                                 (time, lat, lon) float64 ...
    Water_runoff_surface_Mixed_intervals_Accumulation                           (time2, lat, lon) float64 ...
    Convective_available_potential_energy_surface                               (time, lat, lon) float64 ...
    Convective_available_potential_energy_pressure_difference_layer             (time, pressure_difference_layer2, lat, lon) float64 ...
    Convective_inhibition_pressure_difference_layer                             (time, pressure_difference_layer2, lat, lon) float64 ...
    Convective_inhibition_surface                                               (time, lat, lon) float64 ...
    Precipitation_rate_surface_Mixed_intervals_Average                          (time2, lat, lon) float64 ...
    Storm_relative_helicity_height_above_ground_layer                           (time, height_above_ground_layer, lat, lon) float64 ...
    Total_precipitation_surface_Mixed_intervals_Accumulation                    (time2, lat, lon) float64 ...
    Convective_precipitation_surface_Mixed_intervals_Accumulation               (time2, lat, lon) float64 ...
    Latent_heat_net_flux_surface_Mixed_intervals_Average                        (time2, lat, lon) float64 ...
    Sensible_heat_net_flux_surface_Mixed_intervals_Average                      (time2, lat, lon) float64 ...
    Snow_depth_surface                                                          (time, lat, lon) float64 ...
    Water_equivalent_of_accumulated_snow_depth_surface                          (time, lat, lon) float64 ...
    Total_cloud_cover_high_cloud_Mixed_intervals_Average                        (time2, lat, lon) float64 ...
    Total_cloud_cover_convective_cloud                                          (time1, lat, lon) float64 ...
    Total_cloud_cover_middle_cloud_Mixed_intervals_Average                      (time2, lat, lon) float64 ...
    Total_cloud_cover_boundary_layer_cloud_Mixed_intervals_Average              (time2, lat, lon) float64 ...
    Total_cloud_cover_low_cloud_Mixed_intervals_Average                         (time2, lat, lon) float64 ...
    Cloud_Work_Function_entire_atmosphere_single_layer_Mixed_intervals_Average  (time2, lat, lon) float64 ...
    Sunshine_Duration_surface                                                   (time, lat, lon) float64 ...
    Best_4_layer_Lifted_Index_surface                                           (time, lat, lon) float64 ...
    Upward_Short-Wave_Radiation_Flux_atmosphere_top_Mixed_intervals_Average     (time2, lat, lon) float64 ...
    Upward_Short-Wave_Radiation_Flux_surface_Mixed_intervals_Average            (time2, lat, lon) float64 ...
    Upward_Long-Wave_Radp_Flux_atmosphere_top_Mixed_intervals_Average           (time2, lat, lon) float64 ...
    Upward_Long-Wave_Radp_Flux_surface_Mixed_intervals_Average                  (time2, lat, lon) float64 ...
    5-Wave_Geopotential_Height_isobaric                                         (time, isobaric1, lat, lon) float64 ...
    Relative_humidity_entire_atmosphere_single_layer                            (time, lat, lon) float64 ...
    Relative_humidity_highest_tropospheric_freezing                             (time, lat, lon) float64 ...
    Categorical_Freezing_Rain_surface_Mixed_intervals_Average                   (time2, lat, lon) float64 ...
    Ground_Heat_Flux_surface_Mixed_intervals_Average                            (time2, lat, lon) float64 ...
    Wilting_Point_surface                                                       (time, lat, lon) float64 ...
    Per_cent_frozen_precipitation_surface                                       (time, lat, lon) float64 ...
    Temperature_isobaric                                                        (time, isobaric3, lat, lon) float64 ...
    Relative_humidity_isobaric                                                  (time, isobaric3, lat, lon) float64 ...
    Relative_humidity_zeroDegC_isotherm                                         (time, lat, lon) float64 ...
    u-component_of_wind_isobaric                                                (time, isobaric3, lat, lon) float64 ...
    v-component_of_wind_isobaric                                                (time, isobaric3, lat, lon) float64 ...
    Geopotential_height_isobaric                                                (time, isobaric3, lat, lon) float64 ...
    Geopotential_height_zeroDegC_isotherm                                       (time, lat, lon) float64 ...
    U-Component_Storm_Motion_height_above_ground_layer                          (time, height_above_ground_layer1, lat, lon) float64 ...
    Zonal_Flux_of_Gravity_Wave_Stress_surface_Mixed_intervals_Average           (time2, lat, lon) float64 ...
    u-component_of_wind_planetary_boundary                                      (time, lat, lon) float64 ...
    Categorical_Ice_Pellets_surface_Mixed_intervals_Average                     (time2, lat, lon) float64 ...
    Vertical_velocity_pressure_isobaric                                         (time, isobaric2, lat, lon) float64 ...
    Absolute_vorticity_isobaric                                                 (time, isobaric3, lat, lon) float64 ...
    Pressure_reduced_to_MSL_msl                                                 (time, lat, lon) float64 ...
    Cloud_mixing_ratio_isobaric                                                 (time, isobaric2, lat, lon) float64 ...
    Pressure_maximum_wind                                                       (time, lat, lon) float64 ...
    Temperature_altitude_above_msl                                              (time, altitude_above_msl, lat, lon) float64 ...
    Temperature_maximum_wind                                                    (time, lat, lon) float64 ...
    u-component_of_wind_altitude_above_msl                                      (time, altitude_above_msl, lat, lon) float64 ...
    u-component_of_wind_maximum_wind                                            (time, lat, lon) float64 ...
    ICAO_Standard_Atmosphere_Reference_Height_maximum_wind                      (time, lat, lon) float64 ...
    v-component_of_wind_maximum_wind                                            (time, lat, lon) float64 ...
    v-component_of_wind_altitude_above_msl                                      (time, altitude_above_msl, lat, lon) float64 ...
    Apparent_temperature_height_above_ground                                    (time, height_above_ground, lat, lon) float64 ...
    Geopotential_height_maximum_wind                                            (time, lat, lon) float64 ...
    V-Component_Storm_Motion_height_above_ground_layer                          (time, height_above_ground_layer1, lat, lon) float64 ...
    Meridional_Flux_of_Gravity_Wave_Stress_surface_Mixed_intervals_Average      (time2, lat, lon) float64 ...
    Field_Capacity_surface                                                      (time, lat, lon) float64 ...
    v-component_of_wind_planetary_boundary                                      (time, lat, lon) float64 ...
    Precipitable_water_entire_atmosphere_single_layer                           (time, lat, lon) float64 ...
    Categorical_Snow_surface_Mixed_intervals_Average                            (time2, lat, lon) float64 ...
    Pressure_height_above_ground                                                (time, height_above_ground2, lat, lon) float64 ...
    Pressure_tropopause                                                         (time, lat, lon) float64 ...
    Specific_humidity_height_above_ground                                       (time, height_above_ground1, lat, lon) float64 ...
    Temperature_height_above_ground                                             (time, height_above_ground4, lat, lon) float64 ...
    Temperature_tropopause                                                      (time, lat, lon) float64 ...
    Relative_humidity_height_above_ground                                       (time, height_above_ground, lat, lon) float64 ...
    u-component_of_wind_height_above_ground                                     (time, height_above_ground3, lat, lon) float64 ...
    u-component_of_wind_tropopause                                              (time, lat, lon) float64 ...
    ICAO_Standard_Atmosphere_Reference_Height_tropopause                        (time, lat, lon) float64 ...
    v-component_of_wind_height_above_ground                                     (time, height_above_ground3, lat, lon) float64 ...
    v-component_of_wind_tropopause                                              (time, lat, lon) float64 ...
    Maximum_temperature_height_above_ground_Mixed_intervals_Maximum             (time2, height_above_ground, lat, lon) float64 ...
    Geopotential_height_tropopause                                              (time, lat, lon) float64 ...
    Minimum_temperature_height_above_ground_Mixed_intervals_Minimum             (time2, height_above_ground, lat, lon) float64 ...
    Dewpoint_temperature_height_above_ground                                    (time, height_above_ground, lat, lon) float64 ...
    Temperature_sigma                                                           (time, sigma, lat, lon) float64 ...
    Relative_humidity_sigma                                                     (time, sigma, lat, lon) float64 ...
    Potential_temperature_sigma                                                 (time, sigma, lat, lon) float64 ...
    u-component_of_wind_sigma                                                   (time, sigma, lat, lon) float64 ...
    v-component_of_wind_sigma                                                   (time, sigma, lat, lon) float64 ...
    Planetary_Boundary_Layer_Height_surface                                     (time, lat, lon) float64 ...
    Convective_Precipitation_Rate_surface_Mixed_intervals_Average               (time2, lat, lon) float64 ...
    Vertical_velocity_pressure_sigma                                            (time, sigma, lat, lon) float64 ...
    Total_cloud_cover_entire_atmosphere_Mixed_intervals_Average                 (time2, lat, lon) float64 ...
    Geopotential_height_highest_tropospheric_freezing                           (time, lat, lon) float64 ...
    Cloud_water_entire_atmosphere_single_layer                                  (time, lat, lon) float64 ...
    Pressure_potential_vorticity_surface                                        (time, potential_vorticity_surface, lat, lon) float64 ...
    Temperature_potential_vorticity_surface                                     (time, potential_vorticity_surface, lat, lon) float64 ...
    u-component_of_wind_potential_vorticity_surface                             (time, potential_vorticity_surface, lat, lon) float64 ...
    v-component_of_wind_potential_vorticity_surface                             (time, potential_vorticity_surface, lat, lon) float64 ...
    Geopotential_height_potential_vorticity_surface                             (time, potential_vorticity_surface, lat, lon) float64 ...

In [11]:
ds.coords


Out[11]:
Coordinates:
  * lat                                  (lat) float32 90.0 89.5 89.0 88.5 ...
  * lon                                  (lon) float32 0.0 0.5 1.0 1.5 2.0 ...
  * time                                 (time) datetime64[ns] 2015-08-21 ...
    reftime                              (time) datetime64[ns] ...
  * time1                                (time1) datetime64[ns] 2015-08-21T03:00:00 ...
    reftime1                             (time1) datetime64[ns] ...
  * time2                                (time2) datetime64[ns] 2015-08-21T03:00:00 ...
    reftime2                             (time2) datetime64[ns] ...
  * depth_below_surface_layer            (depth_below_surface_layer) float32 0.05 ...
  * isobaric                             (isobaric) float32 1000.0 2000.0 ...
  * height_above_ground_layer            (height_above_ground_layer) float32 1500.0 ...
  * height_above_ground                  (height_above_ground) float32 2.0
  * potential_vorticity_surface          (potential_vorticity_surface) float32 -2e-06 ...
  * pressure_difference_layer            (pressure_difference_layer) float32 1500.0 ...
  * isobaric1                            (isobaric1) float32 50000.0
  * height_above_ground1                 (height_above_ground1) float32 2.0 80.0
  * height_above_ground2                 (height_above_ground2) float32 80.0
  * isobaric2                            (isobaric2) float32 10000.0 15000.0 ...
  * sigma                                (sigma) float32 0.995
  * altitude_above_msl                   (altitude_above_msl) float32 1829.0 ...
  * height_above_ground3                 (height_above_ground3) float32 10.0 ...
  * height_above_ground_layer1           (height_above_ground_layer1) float32 3000.0 ...
  * pressure_difference_layer1           (pressure_difference_layer1) float32 12750.0 ...
  * isobaric3                            (isobaric3) float32 1000.0 2000.0 ...
  * sigma_layer                          (sigma_layer) float32 0.58 0.665 ...
  * pressure_difference_layer2           (pressure_difference_layer2) float32 9000.0 ...
  * height_above_ground4                 (height_above_ground4) float32 2.0 ...
  * depth_below_surface_layer_bounds_1   (depth_below_surface_layer_bounds_1) int64 0 ...
  * height_above_ground_layer1_bounds_1  (height_above_ground_layer1_bounds_1) int64 0 ...
  * height_above_ground_layer_bounds_1   (height_above_ground_layer_bounds_1) int64 0 ...
  * pressure_difference_layer1_bounds_1  (pressure_difference_layer1_bounds_1) int64 0 ...
  * pressure_difference_layer2_bounds_1  (pressure_difference_layer2_bounds_1) int64 0 ...
  * pressure_difference_layer_bounds_1   (pressure_difference_layer_bounds_1) int64 0 ...
  * sigma_layer_bounds_1                 (sigma_layer_bounds_1) int64 0 1
  * time2_bounds_1                       (time2_bounds_1) int64 0 1

In [12]:
ds.attrs


Out[12]:
OrderedDict([(u'Originating_or_generating_Center', u'US National Weather Service, National Centres for Environmental Prediction (NCEP)'), (u'Originating_or_generating_Subcenter', u'0'), (u'GRIB_table_version', u'2,1'), (u'Type_of_generating_process', u'Forecast'), (u'Analysis_or_forecast_generating_process_identifier_defined_by_originating_centre', u'Analysis from GFS (Global Forecast System)'), (u'file_format', u'GRIB-2'), (u'Conventions', u'CF-1.6'), (u'history', u'Read using CDM IOSP GribCollection v3'), (u'featureType', u'GRID'), (u'_CoordSysBuilder', u'ucar.nc2.dataset.conv.CF1Convention')])

In [13]:
t = ds_snapshot['Temperature_surface']

In [14]:
t.shape


Out[14]:
(70, 140)

In [15]:
plt.pcolormesh(t.lon.data,t.lat.data,t.data)
plt.title(t.name+pd.Timestamp(t.time.values).strftime(': %Y-%m-%d  %H:%M:%S %Z %z'));



In [16]:
# time series closest to specified lon,lat location
ds_series = ds.sel(lon=250.,lat=33.,method='nearest')

In [17]:
# Select temperature and convert to Pandas Series
v_series = ds_series['Temperature_surface'].to_series()

In [18]:
v_series.plot(title=v_series.name);



In [19]:
ds_snapshot


Out[19]:
<xray.Dataset>
Dimensions:                                                                     (altitude_above_msl: 3, depth_below_surface_layer: 4, depth_below_surface_layer_bounds_1: 2, height_above_ground: 1, height_above_ground1: 2, height_above_ground2: 1, height_above_ground3: 3, height_above_ground4: 3, height_above_ground_layer: 1, height_above_ground_layer1: 1, height_above_ground_layer1_bounds_1: 2, height_above_ground_layer_bounds_1: 2, isobaric: 12, isobaric1: 1, isobaric2: 21, isobaric3: 26, lat: 70, lon: 140, potential_vorticity_surface: 2, pressure_difference_layer: 1, pressure_difference_layer1: 1, pressure_difference_layer1_bounds_1: 2, pressure_difference_layer2: 2, pressure_difference_layer2_bounds_1: 2, pressure_difference_layer_bounds_1: 2, sigma: 1, sigma_layer: 4, sigma_layer_bounds_1: 2, time2_bounds_1: 2)
Coordinates:
  * lat                                                                         (lat) float32 55.0 ...
  * lon                                                                         (lon) float32 230.5 ...
    time                                                                        datetime64[ns] 2015-09-04T06:00:00 ...
    reftime                                                                     datetime64[ns] 2015-09-04 ...
    time1                                                                       datetime64[ns] 2015-09-04T06:00:00 ...
    reftime1                                                                    datetime64[ns] 2015-09-04 ...
    time2                                                                       datetime64[ns] 2015-09-04T06:00:00 ...
    reftime2                                                                    datetime64[ns] 2015-09-04 ...
  * depth_below_surface_layer                                                   (depth_below_surface_layer) float32 0.05 ...
  * isobaric                                                                    (isobaric) float32 1000.0 ...
  * height_above_ground_layer                                                   (height_above_ground_layer) float32 1500.0 ...
  * height_above_ground                                                         (height_above_ground) float32 2.0 ...
  * potential_vorticity_surface                                                 (potential_vorticity_surface) float32 -2e-06 ...
  * pressure_difference_layer                                                   (pressure_difference_layer) float32 1500.0 ...
  * isobaric1                                                                   (isobaric1) float32 50000.0 ...
  * height_above_ground1                                                        (height_above_ground1) float32 2.0 ...
  * height_above_ground2                                                        (height_above_ground2) float32 80.0 ...
  * isobaric2                                                                   (isobaric2) float32 10000.0 ...
  * sigma                                                                       (sigma) float32 0.995 ...
  * altitude_above_msl                                                          (altitude_above_msl) float32 1829.0 ...
  * height_above_ground3                                                        (height_above_ground3) float32 10.0 ...
  * height_above_ground_layer1                                                  (height_above_ground_layer1) float32 3000.0 ...
  * pressure_difference_layer1                                                  (pressure_difference_layer1) float32 12750.0 ...
  * isobaric3                                                                   (isobaric3) float32 1000.0 ...
  * sigma_layer                                                                 (sigma_layer) float32 0.58 ...
  * pressure_difference_layer2                                                  (pressure_difference_layer2) float32 9000.0 ...
  * height_above_ground4                                                        (height_above_ground4) float32 2.0 ...
  * depth_below_surface_layer_bounds_1                                          (depth_below_surface_layer_bounds_1) int32 0 ...
  * height_above_ground_layer1_bounds_1                                         (height_above_ground_layer1_bounds_1) int32 0 ...
  * height_above_ground_layer_bounds_1                                          (height_above_ground_layer_bounds_1) int32 0 ...
  * pressure_difference_layer1_bounds_1                                         (pressure_difference_layer1_bounds_1) int32 0 ...
  * pressure_difference_layer2_bounds_1                                         (pressure_difference_layer2_bounds_1) int32 0 ...
  * pressure_difference_layer_bounds_1                                          (pressure_difference_layer_bounds_1) int32 0 ...
  * sigma_layer_bounds_1                                                        (sigma_layer_bounds_1) int32 0 ...
  * time2_bounds_1                                                              (time2_bounds_1) int32 0 ...
Data variables:
    LatLon_Projection                                                           int32 0 ...
    time2_bounds                                                                (time2_bounds_1) datetime64[ns] 2015-09-04 ...
    depth_below_surface_layer_bounds                                            (depth_below_surface_layer, depth_below_surface_layer_bounds_1) float32 0.0 ...
    height_above_ground_layer_bounds                                            (height_above_ground_layer, height_above_ground_layer_bounds_1) float32 3000.0 ...
    pressure_difference_layer_bounds                                            (pressure_difference_layer, pressure_difference_layer_bounds_1) float32 3000.0 ...
    height_above_ground_layer1_bounds                                           (height_above_ground_layer1, height_above_ground_layer1_bounds_1) float32 6000.0 ...
    pressure_difference_layer1_bounds                                           (pressure_difference_layer1, pressure_difference_layer1_bounds_1) float32 25500.0 ...
    sigma_layer_bounds                                                          (sigma_layer, sigma_layer_bounds_1) float32 0.44 ...
    pressure_difference_layer2_bounds                                           (pressure_difference_layer2, pressure_difference_layer2_bounds_1) float32 18000.0 ...
    Total_ozone_entire_atmosphere_single_layer                                  (lat, lon) float64 342.3 ...
    Ozone_Mixing_Ratio_isobaric                                                 (isobaric, lat, lon) float64 1.116e-05 ...
    Momentum_flux_u-component_surface_Mixed_intervals_Average                   (lat, lon) float64 0.034 ...
    Momentum_flux_v-component_surface_Mixed_intervals_Average                   (lat, lon) float64 0.013 ...
    Surface_Lifted_Index_surface                                                (lat, lon) float64 7.3 ...
    Downward_Short-Wave_Radiation_Flux_surface_Mixed_intervals_Average          (lat, lon) float64 121.0 ...
    Downward_Long-Wave_Radp_Flux_surface_Mixed_intervals_Average                (lat, lon) float64 261.0 ...
    Pressure_middle_cloud_bottom_Mixed_intervals_Average                        (lat, lon) float64 nan ...
    Pressure_middle_cloud_top_Mixed_intervals_Average                           (lat, lon) float64 nan ...
    Pressure_convective_cloud_bottom                                            (lat, lon) float64 nan ...
    Pressure_convective_cloud_top                                               (lat, lon) float64 nan ...
    Pressure_low_cloud_bottom_Mixed_intervals_Average                           (lat, lon) float64 nan ...
    Pressure_low_cloud_top_Mixed_intervals_Average                              (lat, lon) float64 nan ...
    Ventilation_Rate_planetary_boundary                                         (lat, lon) float64 0.0 ...
    Pressure_high_cloud_top_Mixed_intervals_Average                             (lat, lon) float64 nan ...
    Vertical_Speed_Shear_potential_vorticity_surface                            (potential_vorticity_surface, lat, lon) float64 nan ...
    Pressure_high_cloud_bottom_Mixed_intervals_Average                          (lat, lon) float64 nan ...
    MSLP_Eta_model_reduction_msl                                                (lat, lon) float64 1.019e+05 ...
    Vertical_Speed_Shear_tropopause                                             (lat, lon) float64 -0.0028 ...
    Wind_speed_gust_surface                                                     (lat, lon) float64 2.3 ...
    Pressure_of_level_from_which_parcel_was_lifted_pressure_difference_layer    (pressure_difference_layer1, lat, lon) float64 9.141e+04 ...
    Temperature_middle_cloud_top_Mixed_intervals_Average                        (lat, lon) float64 nan ...
    Temperature_high_cloud_top_Mixed_intervals_Average                          (lat, lon) float64 nan ...
    Temperature_low_cloud_top_Mixed_intervals_Average                           (lat, lon) float64 nan ...
    Categorical_Rain_surface_Mixed_intervals_Average                            (lat, lon) float64 0.0 ...
    Potential_Evaporation_Rate_surface                                          (lat, lon) float64 114.0 ...
    Volumetric_Soil_Moisture_Content_depth_below_surface_layer                  (depth_below_surface_layer, lat, lon) float64 0.282 ...
    Ice_cover_surface                                                           (lat, lon) float64 0.0 ...
    Land_cover_0__sea_1__land_surface                                           (lat, lon) float64 1.0 ...
    Pressure_surface                                                            (lat, lon) float64 9.426e+04 ...
    Specific_humidity_pressure_difference_layer                                 (pressure_difference_layer, lat, lon) float64 0.003812 ...
    Temperature_surface                                                         (lat, lon) float64 276.2 ...
    Temperature_pressure_difference_layer                                       (pressure_difference_layer, lat, lon) float64 282.9 ...
    Albedo_surface_Mixed_intervals_Average                                      (lat, lon) float64 25.6 ...
    Relative_humidity_sigma_layer                                               (sigma_layer, lat, lon) float64 45.0 ...
    Relative_humidity_pressure_difference_layer                                 (pressure_difference_layer, lat, lon) float64 47.0 ...
    Haines_Index_surface                                                        (lat, lon) float64 5.0 ...
    Soil_temperature_depth_below_surface_layer                                  (depth_below_surface_layer, lat, lon) float64 281.4 ...
    u-component_of_wind_pressure_difference_layer                               (pressure_difference_layer, lat, lon) float64 -2.37 ...
    v-component_of_wind_pressure_difference_layer                               (pressure_difference_layer, lat, lon) float64 -0.15 ...
    Geopotential_height_surface                                                 (lat, lon) float64 656.2 ...
    Water_runoff_surface_Mixed_intervals_Accumulation                           (lat, lon) float64 0.888 ...
    Convective_available_potential_energy_surface                               (lat, lon) float64 0.0 ...
    Convective_available_potential_energy_pressure_difference_layer             (pressure_difference_layer2, lat, lon) float64 0.0 ...
    Convective_inhibition_pressure_difference_layer                             (pressure_difference_layer2, lat, lon) float64 0.0 ...
    Convective_inhibition_surface                                               (lat, lon) float64 0.0 ...
    Precipitation_rate_surface_Mixed_intervals_Average                          (lat, lon) float64 0.0 ...
    Storm_relative_helicity_height_above_ground_layer                           (height_above_ground_layer, lat, lon) float64 53.0 ...
    Total_precipitation_surface_Mixed_intervals_Accumulation                    (lat, lon) float64 0.0 ...
    Convective_precipitation_surface_Mixed_intervals_Accumulation               (lat, lon) float64 0.0 ...
    Latent_heat_net_flux_surface_Mixed_intervals_Average                        (lat, lon) float64 33.0 ...
    Sensible_heat_net_flux_surface_Mixed_intervals_Average                      (lat, lon) float64 -10.0 ...
    Snow_depth_surface                                                          (lat, lon) float64 0.0 ...
    Water_equivalent_of_accumulated_snow_depth_surface                          (lat, lon) float64 0.0 ...
    Total_cloud_cover_high_cloud_Mixed_intervals_Average                        (lat, lon) float64 0.0 ...
    Total_cloud_cover_convective_cloud                                          (lat, lon) float64 0.0 ...
    Total_cloud_cover_middle_cloud_Mixed_intervals_Average                      (lat, lon) float64 0.0 ...
    Total_cloud_cover_boundary_layer_cloud_Mixed_intervals_Average              (lat, lon) float64 0.0 ...
    Total_cloud_cover_low_cloud_Mixed_intervals_Average                         (lat, lon) float64 0.0 ...
    Cloud_Work_Function_entire_atmosphere_single_layer_Mixed_intervals_Average  (lat, lon) float64 0.0 ...
    Sunshine_Duration_surface                                                   (lat, lon) float64 1.215e+04 ...
    Best_4_layer_Lifted_Index_surface                                           (lat, lon) float64 6.3 ...
    Upward_Short-Wave_Radiation_Flux_atmosphere_top_Mixed_intervals_Average     (lat, lon) float64 49.0 ...
    Upward_Short-Wave_Radiation_Flux_surface_Mixed_intervals_Average            (lat, lon) float64 31.0 ...
    Upward_Long-Wave_Radp_Flux_atmosphere_top_Mixed_intervals_Average           (lat, lon) float64 253.0 ...
    Upward_Long-Wave_Radp_Flux_surface_Mixed_intervals_Average                  (lat, lon) float64 349.0 ...
    5-Wave_Geopotential_Height_isobaric                                         (isobaric1, lat, lon) float64 5.662e+03 ...
    Relative_humidity_entire_atmosphere_single_layer                            (lat, lon) float64 22.0 ...
    Relative_humidity_highest_tropospheric_freezing                             (lat, lon) float64 60.0 ...
    Categorical_Freezing_Rain_surface_Mixed_intervals_Average                   (lat, lon) float64 0.0 ...
    Ground_Heat_Flux_surface_Mixed_intervals_Average                            (lat, lon) float64 13.0 ...
    Wilting_Point_surface                                                       (lat, lon) float64 0.0469 ...
    Per_cent_frozen_precipitation_surface                                       (lat, lon) float64 0.0 ...
    Temperature_isobaric                                                        (isobaric3, lat, lon) float64 230.6 ...
    Relative_humidity_isobaric                                                  (isobaric3, lat, lon) float64 0.09 ...
    Relative_humidity_zeroDegC_isotherm                                         (lat, lon) float64 60.0 ...
    u-component_of_wind_isobaric                                                (isobaric3, lat, lon) float64 -1.8 ...
    v-component_of_wind_isobaric                                                (isobaric3, lat, lon) float64 -3.5 ...
    Geopotential_height_isobaric                                                (isobaric3, lat, lon) float64 3.149e+04 ...
    Geopotential_height_zeroDegC_isotherm                                       (lat, lon) float64 1.986e+03 ...
    U-Component_Storm_Motion_height_above_ground_layer                          (height_above_ground_layer1, lat, lon) float64 -9.96 ...
    Zonal_Flux_of_Gravity_Wave_Stress_surface_Mixed_intervals_Average           (lat, lon) float64 -0.403 ...
    u-component_of_wind_planetary_boundary                                      (lat, lon) float64 -1.7 ...
    Categorical_Ice_Pellets_surface_Mixed_intervals_Average                     (lat, lon) float64 0.0 ...
    Vertical_velocity_pressure_isobaric                                         (isobaric2, lat, lon) float64 -0.02039 ...
    Absolute_vorticity_isobaric                                                 (isobaric3, lat, lon) float64 0.0001151 ...
    Pressure_reduced_to_MSL_msl                                                 (lat, lon) float64 1.02e+05 ...
    Cloud_mixing_ratio_isobaric                                                 (isobaric2, lat, lon) float64 0.0 ...
    Pressure_maximum_wind                                                       (lat, lon) float64 2.757e+04 ...
    Temperature_altitude_above_msl                                              (altitude_above_msl, lat, lon) float64 274.5 ...
    Temperature_maximum_wind                                                    (lat, lon) float64 226.4 ...
    u-component_of_wind_altitude_above_msl                                      (altitude_above_msl, lat, lon) float64 -1.49 ...
    u-component_of_wind_maximum_wind                                            (lat, lon) float64 7.0 ...
    ICAO_Standard_Atmosphere_Reference_Height_maximum_wind                      (lat, lon) float64 9.725e+03 ...
    v-component_of_wind_maximum_wind                                            (lat, lon) float64 -45.8 ...
    v-component_of_wind_altitude_above_msl                                      (altitude_above_msl, lat, lon) float64 -2.06 ...
    Apparent_temperature_height_above_ground                                    (height_above_ground, lat, lon) float64 276.3 ...
    Geopotential_height_maximum_wind                                            (lat, lon) float64 9.746e+03 ...
    V-Component_Storm_Motion_height_above_ground_layer                          (height_above_ground_layer1, lat, lon) float64 -4.59 ...
    Meridional_Flux_of_Gravity_Wave_Stress_surface_Mixed_intervals_Average      (lat, lon) float64 -0.735 ...
    Field_Capacity_surface                                                      (lat, lon) float64 0.2821 ...
    v-component_of_wind_planetary_boundary                                      (lat, lon) float64 0.1 ...
    Precipitable_water_entire_atmosphere_single_layer                           (lat, lon) float64 9.7 ...
    Categorical_Snow_surface_Mixed_intervals_Average                            (lat, lon) float64 0.0 ...
    Pressure_height_above_ground                                                (height_above_ground2, lat, lon) float64 9.336e+04 ...
    Pressure_tropopause                                                         (lat, lon) float64 2.416e+04 ...
    Specific_humidity_height_above_ground                                       (height_above_ground1, lat, lon) float64 0.00393 ...
    Temperature_height_above_ground                                             (height_above_ground4, lat, lon) float64 277.6 ...
    Temperature_tropopause                                                      (lat, lon) float64 223.1 ...
    Relative_humidity_height_above_ground                                       (height_above_ground, lat, lon) float64 70.7 ...
    u-component_of_wind_height_above_ground                                     (height_above_ground3, lat, lon) float64 -1.65 ...
    u-component_of_wind_tropopause                                              (lat, lon) float64 7.7 ...
    ICAO_Standard_Atmosphere_Reference_Height_tropopause                        (lat, lon) float64 1.058e+04 ...
    v-component_of_wind_height_above_ground                                     (height_above_ground3, lat, lon) float64 0.1 ...
    v-component_of_wind_tropopause                                              (lat, lon) float64 -43.8 ...
    Maximum_temperature_height_above_ground_Mixed_intervals_Maximum             (height_above_ground, lat, lon) float64 286.7 ...
    Geopotential_height_tropopause                                              (lat, lon) float64 1.061e+04 ...
    Minimum_temperature_height_above_ground_Mixed_intervals_Minimum             (height_above_ground, lat, lon) float64 277.6 ...
    Dewpoint_temperature_height_above_ground                                    (height_above_ground, lat, lon) float64 272.8 ...
    Temperature_sigma                                                           (sigma, lat, lon) float64 282.9 ...
    Relative_humidity_sigma                                                     (sigma, lat, lon) float64 48.0 ...
    Potential_temperature_sigma                                                 (sigma, lat, lon) float64 288.2 ...
    u-component_of_wind_sigma                                                   (sigma, lat, lon) float64 -2.36 ...
    v-component_of_wind_sigma                                                   (sigma, lat, lon) float64 0.09 ...
    Planetary_Boundary_Layer_Height_surface                                     (lat, lon) float64 22.04 ...
    Convective_Precipitation_Rate_surface_Mixed_intervals_Average               (lat, lon) float64 0.0 ...
    Vertical_velocity_pressure_sigma                                            (sigma, lat, lon) float64 2.222 ...
    Total_cloud_cover_entire_atmosphere_Mixed_intervals_Average                 (lat, lon) float64 1.0 ...
    Geopotential_height_highest_tropospheric_freezing                           (lat, lon) float64 1.986e+03 ...
    Cloud_water_entire_atmosphere_single_layer                                  (lat, lon) float64 0.0 ...
    Pressure_potential_vorticity_surface                                        (potential_vorticity_surface, lat, lon) float64 nan ...
    Temperature_potential_vorticity_surface                                     (potential_vorticity_surface, lat, lon) float64 nan ...
    u-component_of_wind_potential_vorticity_surface                             (potential_vorticity_surface, lat, lon) float64 nan ...
    v-component_of_wind_potential_vorticity_surface                             (potential_vorticity_surface, lat, lon) float64 nan ...
    Geopotential_height_potential_vorticity_surface                             (potential_vorticity_surface, lat, lon) float64 nan ...
Attributes:
    Originating_or_generating_Center: US National Weather Service, National Centres for Environmental Prediction (NCEP)
    Originating_or_generating_Subcenter: 0
    GRIB_table_version: 2,1
    Type_of_generating_process: Forecast
    Analysis_or_forecast_generating_process_identifier_defined_by_originating_centre: Analysis from GFS (Global Forecast System)
    file_format: GRIB-2
    Conventions: CF-1.6
    history: Read using CDM IOSP GribCollection v3
    featureType: GRID
    _CoordSysBuilder: ucar.nc2.dataset.conv.CF1Convention

In [20]:
#ds_snapshot.to_netcdf('ds_snapshot.nc')

In [ ]: