docs: def plot_map_basemap(fignum, lats, lons, Opts):
      """
      plot_map_basemap(fignum, lats,lons,Opts)
      makes a basemap with lats/lons
          requires working installation of Basemap
      Parameters:
      _______________
      fignum : matplotlib figure number
      lats : array or list of latitudes
      lons : array or list of longitudes
      Opts : dictionary of plotting options:
          Opts.keys=
              latmin : minimum latitude for plot
              latmax : maximum latitude for plot
              lonmin : minimum longitude for plot
              lonmax : maximum longitude
              lat_0 : central latitude
              lon_0 : central longitude
              proj : projection [basemap projections, e.g., moll=Mollweide, merc=Mercator, ortho=orthorhombic,
                  lcc=Lambert Conformal]
              sym : matplotlib symbol
              symsize : symbol size in pts
              edge : markeredgecolor
              pltgrid : plot the grid [1,0]
              res :  resolution [c,l,i,h] for crude, low, intermediate, high
              boundinglat : bounding latitude
              sym : matplotlib symbol for plotting
              symsize : matplotlib symbol size for plotting
              names : list of names for lats/lons (if empty, none will be plotted)
              pltgrd : if True, put on grid lines
              padlat : padding of latitudes
              padlon : padding of longitudes
              gridspace : grid line spacing
              details : dictionary with keys:
                  coasts : if True, plot coastlines
                  rivers : if True, plot rivers
                  states : if True, plot states
                  countries : if True, plot countries
                  ocean : if True, plot ocean
                  fancy : if True, plot etopo 20 grid
                      NB:  etopo must be installed
          if Opts keys not set :these are the defaults:
             Opts={'latmin':-90,'latmax':90,'lonmin':0,'lonmax':360,'lat_0':0,'lon_0':0,'proj':'moll','sym':'ro,'symsize':5,'pltgrid':1,'res':'c','boundinglat':0.,'padlon':0,'padlat':0,'gridspace':30,'details':all False,'edge':None}
  
      """
      if not has_basemap:
          print('-W- Basemap must be installed to run plot_map_basemap')
          return
      fig = plt.figure(num=fignum)
      rgba_land = (255, 255, 150, 255)
      rgba_ocean = (200, 250, 255, 255)
      ExMer = ['sinus', 'moll', 'lcc']
      # draw meridian labels on the bottom [left,right,top,bottom]
      mlabels = [0, 0, 0, 1]
      plabels = [1, 0, 0, 0]  # draw parallel labels on the left
      # set default Options
      Opts_defaults = {'latmin': -90, 'latmax': 90, 'lonmin': 0, 'lonmax': 360,
                       'lat_0': 0, 'lon_0': 0, 'proj': 'moll', 'sym': 'ro', 'symsize': 5,
                       'edge': None, 'pltgrid': 1, 'res': 'c', 'boundinglat': 0.,
                       'padlon': 0, 'padlat': 0, 'gridspace': 30,
                       'details': {'fancy': 0, 'coasts': 0, 'rivers': 0, 'states': 0, 'countries': 0, 'ocean': 0}}
      for key in Opts_defaults.keys():
          if key not in Opts.keys() and key != 'details':
              Opts[key] = Opts_defaults[key]
          if key == 'details':
              if key not in Opts.keys():
                  Opts[key] = Opts_defaults[key]
              for detail_key in Opts_defaults[key].keys():
                  if detail_key not in Opts[key].keys():
                      Opts[key][detail_key] = Opts_defaults[key][detail_key]
  
      if Opts['proj'] in ExMer:
          mlabels = [0, 0, 0, 0]
      if Opts['proj'] not in ExMer:
          m = Basemap(projection=Opts['proj'], lat_0=Opts['lat_0'],
                      lon_0=Opts['lon_0'], resolution=Opts['res'])
          plabels = [0, 0, 0, 0]
      else:
          m = Basemap(llcrnrlon=Opts['lonmin'], llcrnrlat=Opts['latmin'], urcrnrlat=Opts['latmax'], urcrnrlon=Opts['lonmax'],
                      projection=Opts['proj'], lat_0=Opts['lat_0'], lon_0=Opts['lon_0'], lat_ts=0., resolution=Opts['res'], boundinglat=Opts['boundinglat'])
      if 'details' in list(Opts.keys()):
          if Opts['details']['fancy'] == 1:
              from mpl_toolkits.basemap import basemap_datadir
              EDIR = basemap_datadir + "/"
              etopo = np.loadtxt(EDIR + 'etopo20data.gz')
              elons = np.loadtxt(EDIR + 'etopo20lons.gz')
              elats = np.loadtxt(EDIR + 'etopo20lats.gz')
              x, y = m(*np.meshgrid(elons, elats))
              cs = m.contourf(x, y, etopo, 30, cmap=color_map.jet)
          if Opts['details']['coasts'] == 1:
              m.drawcoastlines(color='k')
          if Opts['details']['rivers'] == 1:
              m.drawrivers(color='b')
          if Opts['details']['states'] == 1:
              m.drawstates(color='r')
          if Opts['details']['countries'] == 1:
              m.drawcountries(color='g')
          if Opts['details']['ocean'] == 1:
              try:
                  m.drawlsmask(land_color=rgba_land,
                               ocean_color=rgba_ocean, lsmask_lats=None)
              except TypeError:
                  # this is caused by basemap function: _readlsmask
                  # interacting with numpy
                  # (a float is provided, numpy wants an int).
                  # hopefully will be fixed eventually.
                  pass
      if Opts['pltgrid'] == 0.:
          circles = np.arange(Opts['latmin'], Opts['latmax'] + 15., 15.)
          meridians = np.arange(Opts['lonmin'], Opts['lonmax'] + 30., 30.)
      elif Opts['pltgrid'] > 0:
          if Opts['proj'] in ExMer or Opts['proj'] == 'lcc':
              circles = np.arange(-90, 180. +
                                  Opts['gridspace'], Opts['gridspace'])
              meridians = np.arange(0, 360., Opts['gridspace'])
          else:
              g = Opts['gridspace']
              latmin, lonmin = g * \
                  int(old_div(Opts['latmin'], g)), g * \
                  int(old_div(Opts['lonmin'], g))
              latmax, lonmax = g * \
                  int(old_div(Opts['latmax'], g)), g * \
                  int(old_div(Opts['lonmax'], g))
              # circles=np.arange(latmin-2.*Opts['padlat'],latmax+2.*Opts['padlat'],Opts['gridspace'])
              # meridians=np.arange(lonmin-2.*Opts['padlon'],lonmax+2.*Opts['padlon'],Opts['gridspace'])
              meridians = np.arange(0, 360, 30)
              circles = np.arange(-90, 90, 30)
      if Opts['pltgrid'] >= 0:
          # m.drawparallels(circles,color='black',labels=plabels)
          # m.drawmeridians(meridians,color='black',labels=mlabels)
          # skip the labels - they are ugly
          m.drawparallels(circles, color='black')
          # skip the labels - they are ugly
          m.drawmeridians(meridians, color='black')
          m.drawmapboundary()
      prn_name, symsize = 0, 5
      if 'names' in Opts.keys() and len(Opts['names']) > 0:
          names = Opts['names']
          if len(names) > 0:
              prn_name = 1
  #
      X, Y, T, k = [], [], [], 0
      if 'symsize' in list(Opts.keys()):
          symsize = Opts['symsize']
      if Opts['sym'][-1] != '-':  # just plot points
          X, Y = m(lons, lats)
          if prn_name == 1:
              for pt in range(len(lats)):
                  T.append(plt.text(X[pt] + 5000, Y[pt] - 5000, names[pt]))
          m.plot(X, Y, Opts['sym'], markersize=symsize,
                 markeredgecolor=Opts['edge'])
      else:  # for lines,  need to separate chunks using lat==100.
          chunk = 1
          while k < len(lats) - 1:
              if lats[k] <= 90:  # part of string
                  x, y = m(lons[k], lats[k])
                  if x < 1e20:
                      X.append(x)
                  if y < 1e20:
                      Y.append(y)  # exclude off the map points
                  if prn_name == 1:
                      T.append(plt.text(x + 5000, y - 5000, names[k]))
                  k += 1
              else:  # need to skip 100.0s and move to next chunk
                  # plot previous chunk
                  m.plot(X, Y, Opts['sym'], markersize=symsize,
                         markeredgecolor=Opts['edge'])
                  chunk += 1
                  while lats[k] > 90. and k < len(lats) - 1:
                      k += 1  # skip bad points
                  X, Y, T = [], [], []
          if len(X) > 0:
              m.plot(X, Y, Opts['sym'], markersize=symsize,
                     markeredgecolor=Opts['edge'])