docstr: Get the location of a specific key in an index or model row labels
  
  Parameters
  ----------
  key : label
      The key for which to find the location if the underlying index is
      a DateIndex or is only being used as row labels, or a location if
      the underlying index is a RangeIndex or an NumericIndex.
  base_index : pd.Index, optional
      Optionally the base index to search. If None, the model's index is
      searched.
  
  Returns
  -------
  loc : int
      The location of the key
  index : pd.Index
      The index including the key; this is a copy of the original index
      unless the index had to be expanded to accommodate `key`.
  index_was_expanded : bool
      Whether or not the index was expanded to accommodate `key`.
  
  Notes
  -----
  This method expands on `_get_index_loc` by first trying the given
  base index (or the model's index if the base index was not given) and
  then falling back to try again with the model row labels as the base
  index.
docstr_tok: ["Get","the","location","of","a","specific","key","in","an","index","or","model","row","labels","Parameters","--","--","--","--","--","key",":","label","The","key","for","which","to","find","the","location","if","the","underlying","index","is","a","DateIndex","or","is","only","being","used","as","row","labels",",","or","a","location","if","the","underlying","index","is","a","RangeIndex","or","an","NumericIndex",".","base_index",":","pd.Index",",","optional","Optionally","the","base","index","to","search",".","If","None",",","the","model","'s","index","is","searched",".","Returns","--","--","--","-","loc",":","int","The","location","of","the","key","index",":","pd.Index","The","index","including","the","key",";","this","is","a","copy","of","the","original","index","unless","the","index","had","to","be","expanded","to","accommodate","`","key","`",".","index_was_expanded",":","bool","Whether","or","not","the","index","was","expanded","to","accommodate","`","key","`",".","Notes","--","--","-","This","method","expands","on","`","_get_index_loc","`","by","first","trying","the","given","base","index","(","or","the","model","'s","index","if","the","base","index","was","not","given",")","and","then","falling","back","to","try","again","with","the","model","row","labels","as","the","base","index","."]
code: def _get_index_label_loc(self, key, base_index=None):
      """
      Get the location of a specific key in an index or model row labels
  
      Parameters
      ----------
      key : label
          The key for which to find the location if the underlying index is
          a DateIndex or is only being used as row labels, or a location if
          the underlying index is a RangeIndex or an NumericIndex.
      base_index : pd.Index, optional
          Optionally the base index to search. If None, the model's index is
          searched.
  
      Returns
      -------
      loc : int
          The location of the key
      index : pd.Index
          The index including the key; this is a copy of the original index
          unless the index had to be expanded to accommodate `key`.
      index_was_expanded : bool
          Whether or not the index was expanded to accommodate `key`.
  
      Notes
      -----
      This method expands on `_get_index_loc` by first trying the given
      base index (or the model's index if the base index was not given) and
      then falling back to try again with the model row labels as the base
      index.
      """
      if base_index is None:
          base_index = self._index
      return get_index_label_loc(key, base_index, self.data.row_labels)
  
imports: from __future__ import annotations
  from statsmodels.compat.pandas import is_float_index, is_int_index, is_numeric_dtype
  import numbers
  import warnings
  import numpy
  from pandas import DatetimeIndex, Index, Period, PeriodIndex, RangeIndex, Series, Timestamp, date_range, period_range, to_datetime
  from pandas.tseries.frequencies import to_offset
  from statsmodels.base.data import PandasData
  import statsmodels.base.model
  import statsmodels.base.wrapper
  from statsmodels.tools.sm_exceptions import ValueWarning
label_desc: Use image node_id 4 for calling the TimeSeriesModel obj's underlying member method code with example usage: obj._get_index_label_loc(key, base_index) and returns: get_index_label_loc