code: def get_var_name(nc):
      
  
      non_variable_names = [
          'lat',
          'lat_bnds',
          'lon',
          'lon_bnds',
          'time',
          'latitude',
          'longitude',
          'bnds'
      ]
  
      _vars = set(nc.variables.keys())
      _vars.difference_update(set(non_variable_names))
      if len(_vars) == 1:
          return _vars.pop()
      return None
docs: Guesses the variable_name of an open NetCDF file