docstr: valid is a list of legal strings
docstr_tok: ["valid","is","a","list","of","legal","strings"]
code: def __init__(self, key, valid, ignorecase=False):
      "valid is a list of legal strings"
      self.key = key
      self.ignorecase = ignorecase
  
      def func(s):
          if ignorecase:
              return s.lower()
          else:
              return s
  
      self.valid = {func(k): k for k in valid}
  
imports: from __future__ import absolute_import, division, print_function
  import six
  from functools import reduce
  import operator
  import os
  import warnings
  import re
  from matplotlib import cbook, testing
  from matplotlib.cbook import mplDeprecation, deprecated, ls_mapper
  from matplotlib.fontconfig_pattern import parse_fontconfig_pattern
  from matplotlib.colors import is_color_like
  from cycler import Cycler, cycler
label_desc: Use image node_id 1 to create a new ValidateInStrings object from inherited base classes: object with example: obj = ValidateInStrings(key, valid, ignorecase)