Return a value from nested dicts by any path in the given keys tuple.

    Parameters
    ---------
    key_tuple : tuple
        Describe all possible paths for extraction.
    dict_obj : dict
        The outer-most dict to extract from.

    Returns
    -------
    value : object
        The extracted value, if exists. Otherwise, raises KeyError.

    Example:
    --------
    >>> dict_obj = {'a': {'b': 7}}
    >>> get_alternative_nested_val(('a', ('b', 'c')), dict_obj)
    7

def get_alternative_nested_val(key_tuple, dict_obj):
    """Return a value from nested dicts by any path in the given keys tuple.

    Parameters
    ---------
    key_tuple : tuple
        Describe all possible paths for extraction.
    dict_obj : dict
        The outer-most dict to extract from.

    Returns
    -------
    value : object
        The extracted value, if exists. Otherwise, raises KeyError.

    Example:
    --------
    >>> dict_obj = {'a': {'b': 7}}
    >>> get_alternative_nested_val(('a', ('b', 'c')), dict_obj)
    7
    """
    # print('key_tuple: {}'.format(key_tuple))
    # print('dict_obj: {}'.format(dict_obj))
    top_keys = key_tuple[0] if isinstance(key_tuple[0], (list, tuple)) else [
        key_tuple[0]]
    for key in top_keys:
        try:
            if len(key_tuple) < 2:
                return dict_obj[key]
            return get_alternative_nested_val(key_tuple[1:], dict_obj[key])
        except (KeyError, TypeError, IndexError):
            pass
    raise KeyError