Ë
    u™ãjÄ ã                  ó  — U d dl mZ d dlmZ d dlmZ d dlZd dlmZm	Z	m
Z
mZmZmZmZ d dlZd dlZd dlmZ d dlmZmZ d dlmZ d d	lmZ d d
lmZmZmZmZm Z m!Z! d dl"m#Z# d dl$m%Z% d dl&m'Z'm(Z(m)Z) d dl*m+Z+m,Z,m-Z-m.Z.m/Z/m0Z0m1Z1m2Z2m3Z3m4Z4 d dl5m6Z6 d dl7m8Z8m9Z9m:Z:m;Z;m<Z<m=Z=m>Z>m?Z? d dl@mAZAmBZBmCZCmDZD d dlEmFZFmGZGmHZHmIZImJZJ d dlKmLZM d dlNmOc mPZQ d dlRmSZTmUZUmVZVmWZW d dlXmYZYmZZZm[Z[m\Z\ d dl]m^Z^m_Z_ ered dl`maZambZb d dlcmdZdmeZemfZfmgZgmhZhmiZimjZj d dlkmlZlmmZm d dlnmoZo d dlpmqZq ereqehz  ebz  esz  df   Ztdeud<   ehebz  esz  etz  eretdf   z  Zvdeud<    ed ev¬!«      Zw esdd«      Zxd"Zy G d#„ d$«      Zz ez«       Z{d%e{_|         G d&„ d'«      Z} G d(„ d)e«      Z~ G d*„ d+e~«      Z G d,„ d-e~«      Z€ G d.„ d/e«      Z� G d0„ d1e�«      Z‚ G d2„ d3e�«      Zƒd4„ Z„dGd5„Z…dHd6„Z†dId7„Z‡dJd8„ZˆdKd9„Z‰d:„ ZŠdLd;„Z‹d<„ ZŒdHd=„Z�dHd>„ZŽdMd?„Z�dNd@„Z�dOdA„Z‘dPdB„Z’dQdC„Z“dDdEœ	 	 	 	 	 dRdF„Z”y)Sé    )Úannotations)Úabc)ÚsuppressN)ÚTYPE_CHECKINGÚAnyÚSelfÚ	TypeAliasÚTypeVarÚcastÚfinal)ÚNDFrameIndexerBase)Úis_np_dtypeÚitem_from_zerodim)ÚCHAINED_WARNING_DISABLED)ÚREF_COUNT_IDX)ÚAbstractMethodErrorÚChainedAssignmentErrorÚIndexingErrorÚInvalidIndexErrorÚLossySetitemErrorÚPandas4Warning)Ú_chained_assignment_msg)Úfind_stack_level)Úcan_hold_elementÚfloats_fit_integer_dtypeÚmaybe_downcast_to_dtype)
Ú"is_array_like_deprecate_non_pandasÚis_bool_dtypeÚis_hashableÚ
is_integerÚis_iteratorÚis_list_likeÚis_numeric_dtypeÚis_object_dtypeÚ	is_scalarÚis_sequence)Úconcat_compat)Ú
ArrowDtypeÚBaseMaskedDtypeÚDatetimeTZDtypeÚExtensionDtypeÚIntervalDtypeÚNumpyEADtypeÚPeriodDtypeÚSparseDtype)ÚABCDataFrameÚABCExtensionArrayÚABCIndexÚ	ABCSeries)Úarray_equivalentÚ+construct_1d_array_from_inferred_fill_valueÚis_valid_na_for_dtypeÚisnaÚna_value_for_dtype)Ú
algorithms)ÚarrayÚensure_wrapped_if_datetimelikeÚextract_arrayÚsanitize_array)Úcheck_array_indexerÚis_list_like_indexerÚis_scalar_indexerÚlength_of_indexer)ÚIndexÚ
MultiIndex)ÚHashableÚSequence)Ú	ArrayLikeÚAxisÚAxisIntÚDtypeObjÚScalarÚTÚnpt)Ú	DataFrameÚSeries)ÚExtensionArray)ÚIndexOpsMixin.r	   Ú_IndexSliceTupleÚ_IndexSliceUnionÚ_IndexSliceUnionT)Úboundz(indexer may only contain one '...' entryc                  ó   — e Zd ZdZdd„Zy)Ú_IndexSliceaí  
    Create an object to more easily perform multi-index slicing.

    ``IndexSlice`` is a convenience object that allows the use of natural
    slice syntax (``start:stop``) when selecting from a :class:`MultiIndex`,
    rather than requiring explicit ``slice()`` calls.

    See Also
    --------
    MultiIndex.remove_unused_levels : New MultiIndex with no unused levels.

    Notes
    -----
    See :ref:`Defined Levels <advanced.shown_levels>`
    for further info on slicing a MultiIndex.

    Examples
    --------
    >>> midx = pd.MultiIndex.from_product([["A0", "A1"], ["B0", "B1", "B2", "B3"]])
    >>> columns = ["foo", "bar"]
    >>> dfmi = pd.DataFrame(
    ...     np.arange(16).reshape((len(midx), len(columns))),
    ...     index=midx,
    ...     columns=columns,
    ... )

    Using the default slice command:

    >>> dfmi.loc[(slice(None), slice("B0", "B1")), :]
               foo  bar
        A0 B0    0    1
           B1    2    3
        A1 B0    8    9
           B1   10   11

    Using the IndexSlice class for a more intuitive command:

    >>> idx = pd.IndexSlice
    >>> dfmi.loc[idx[:, "B0":"B1"], :]
               foo  bar
        A0 B0    0    1
           B1    2    3
        A1 B0    8    9
           B1   10   11
    c                ó   — |S ©N© )ÚselfÚargs     ú_/var/www/html/python-recuperauto-other/env/lib/python3.12/site-packages/pandas/core/indexing.pyÚ__getitem__z_IndexSlice.__getitem__·   s   € Øˆ
ó    N)r[   rS   ÚreturnrS   )Ú__name__Ú
__module__Ú__qualname__Ú__doc__r]   rY   r^   r\   rV   rV   ˆ   s   „ ñ,ô\r^   rV   Úpandasc                  óX   — e Zd ZdZedd„«       Zedd„«       Zed	d„«       Zed
d„«       Zy)ÚIndexingMixinzH
    Mixin for adding .loc/.iloc/.at/.iat to Dataframes and Series.
    c                ó   — t        d| «      S )aÒ  
        Purely integer-location based indexing for selection by position.

        .. versionchanged:: 3.0

           Callables which return a tuple are deprecated as input.

        ``.iloc[]`` is primarily integer position based (from ``0`` to
        ``length-1`` of the axis), but may also be used with a boolean
        array.

        Allowed inputs are:

        - An integer, e.g. ``5``.
        - A list or array of integers, e.g. ``[4, 3, 0]``.
        - A slice object with ints, e.g. ``1:7``.
        - A boolean array.
        - A ``callable`` function with one argument (the calling Series or
          DataFrame) and that returns valid output for indexing (one of the above).
          This is useful in method chains, when you don't have a reference to the
          calling object, but would like to base your selection on
          some value.
        - A tuple of row and column indexes. The tuple elements consist of one of the
          above inputs, e.g. ``(0, 1)``.

        ``.iloc`` will raise ``IndexError`` if a requested indexer is
        out-of-bounds, except *slice* indexers which allow out-of-bounds
        indexing (this conforms with python/numpy *slice* semantics).

        See more at :ref:`Selection by Position <indexing.integer>`.

        See Also
        --------
        DataFrame.iat : Fast integer location scalar accessor.
        DataFrame.loc : Purely label-location based indexer for selection by label.
        Series.iloc : Purely integer-location based indexing for
                       selection by position.

        Examples
        --------
        >>> mydict = [
        ...     {"a": 1, "b": 2, "c": 3, "d": 4},
        ...     {"a": 100, "b": 200, "c": 300, "d": 400},
        ...     {"a": 1000, "b": 2000, "c": 3000, "d": 4000},
        ... ]
        >>> df = pd.DataFrame(mydict)
        >>> df
              a     b     c     d
        0     1     2     3     4
        1   100   200   300   400
        2  1000  2000  3000  4000

        **Indexing just the rows**

        With a scalar integer.

        >>> type(df.iloc[0])
        <class 'pandas.Series'>
        >>> df.iloc[0]
        a    1
        b    2
        c    3
        d    4
        Name: 0, dtype: int64

        With a list of integers.

        >>> df.iloc[[0]]
           a  b  c  d
        0  1  2  3  4
        >>> type(df.iloc[[0]])
        <class 'pandas.DataFrame'>

        >>> df.iloc[[0, 1]]
             a    b    c    d
        0    1    2    3    4
        1  100  200  300  400

        With a `slice` object.

        >>> df.iloc[:3]
              a     b     c     d
        0     1     2     3     4
        1   100   200   300   400
        2  1000  2000  3000  4000

        With a boolean mask the same length as the index.

        >>> df.iloc[[True, False, True]]
              a     b     c     d
        0     1     2     3     4
        2  1000  2000  3000  4000

        With a callable, useful in method chains. The `x` passed
        to the ``lambda`` is the DataFrame being sliced. This selects
        the rows whose index label even.

        >>> df.iloc[lambda x: x.index % 2 == 0]
              a     b     c     d
        0     1     2     3     4
        2  1000  2000  3000  4000

        **Indexing both axes**

        You can mix the indexer types for the index and columns. Use ``:`` to
        select the entire axis.

        With scalar integers.

        >>> df.iloc[0, 1]
        2

        With lists of integers.

        >>> df.iloc[[0, 2], [1, 3]]
              b     d
        0     2     4
        2  2000  4000

        With `slice` objects.

        >>> df.iloc[1:3, 0:3]
              a     b     c
        1   100   200   300
        2  1000  2000  3000

        With a boolean array whose length matches the columns.

        >>> df.iloc[:, [True, False, True, False]]
              a     c
        0     1     3
        1   100   300
        2  1000  3000

        With a callable function that expects the Series or DataFrame.

        >>> df.iloc[:, lambda df: [0, 2]]
              a     c
        0     1     3
        1   100   300
        2  1000  3000

        **Selecting along an explicit axis**

        ``.iloc`` can be called with an ``axis`` argument to apply a single
        indexer to that axis.

        >>> df.iloc(axis=0)[1]
        a    100
        b    200
        c    300
        d    400
        Name: 1, dtype: int64

        >>> df.iloc(axis=1)[1]
        0       2
        1     200
        2    2000
        Name: b, dtype: int64
        Úiloc)Ú_iLocIndexer©rZ   s    r\   rh   zIndexingMixin.ilocÄ   s   € ôD ˜F DÓ)Ð)r^   c                ó   — t        d| «      S )aî*  
        Access a group of rows and columns by label(s) or a boolean array.

        ``.loc[]`` is primarily label based, but may also be used with a
        boolean array.

        Allowed inputs are:

        - A single label, e.g. ``5`` or ``'a'``, (note that ``5`` is
          interpreted as a *label* of the index, and **never** as an
          integer position along the index).
        - A list or array of labels, e.g. ``['a', 'b', 'c']``.
        - A slice object with labels, e.g. ``'a':'f'``.

          .. warning:: Note that contrary to usual python slices, **both** the
              start and the stop are included

        - A boolean array of the same length as the axis being sliced,
          e.g. ``[True, False, True]``.
        - An alignable boolean Series. The index of the key will be aligned before
          masking.
        - An alignable Index. The Index of the returned selection will be the input.
        - A ``callable`` function with one argument (the calling Series or
          DataFrame) and that returns valid output for indexing (one of the above)

        See more at :ref:`Selection by Label <indexing.label>`.

        Raises
        ------
        KeyError
            If any items are not found.
        IndexingError
            If an indexed key is passed and its index is unalignable to the frame index.

        See Also
        --------
        DataFrame.at : Access a single value for a row/column label pair.
        DataFrame.iloc : Access group of rows and columns by integer position(s).
        DataFrame.xs : Returns a cross-section (row(s) or column(s)) from the
                       Series/DataFrame.
        Series.loc : Access group of values using labels.

        Examples
        --------
        **Getting values**

        >>> df = pd.DataFrame(
        ...     [[1, 2], [4, 5], [7, 8]],
        ...     index=["cobra", "viper", "sidewinder"],
        ...     columns=["max_speed", "shield"],
        ... )
        >>> df
                    max_speed  shield
        cobra               1       2
        viper               4       5
        sidewinder          7       8

        Single label. Note this returns the row as a Series.

        >>> df.loc["viper"]
        max_speed    4
        shield       5
        Name: viper, dtype: int64

        List of labels. Note using ``[[]]`` returns a DataFrame.

        >>> df.loc[["viper", "sidewinder"]]
                    max_speed  shield
        viper               4       5
        sidewinder          7       8

        Single label for row and column

        >>> df.loc["cobra", "shield"]
        2

        Slice with labels for row and single label for column. As mentioned
        above, note that both the start and stop of the slice are included.

        >>> df.loc["cobra":"viper", "max_speed"]
        cobra    1
        viper    4
        Name: max_speed, dtype: int64

        Boolean list with the same length as the row axis

        >>> df.loc[[False, False, True]]
                    max_speed  shield
        sidewinder          7       8

        Alignable boolean Series:

        >>> df.loc[
        ...     pd.Series([False, True, False], index=["viper", "sidewinder", "cobra"])
        ... ]
                             max_speed  shield
        sidewinder          7       8

        Conditional that returns a boolean Series

        >>> df.loc[df["shield"] > 6]
                    max_speed  shield
        sidewinder          7       8

        Conditional that returns a boolean Series with column labels specified

        >>> df.loc[df["shield"] > 6, ["max_speed"]]
                    max_speed
        sidewinder          7

        Multiple conditional using ``&`` that returns a boolean Series

        >>> df.loc[(df["max_speed"] > 1) & (df["shield"] < 8)]
                    max_speed  shield
        viper          4       5

        Multiple conditional using ``|`` that returns a boolean Series

        >>> df.loc[(df["max_speed"] > 4) | (df["shield"] < 5)]
                    max_speed  shield
        cobra               1       2
        sidewinder          7       8

        Please ensure that each condition is wrapped in parentheses ``()``.
        See the :ref:`user guide<indexing.boolean>`
        for more details and explanations of Boolean indexing.

        .. note::
            If you find yourself using 3 or more conditionals in ``.loc[]``,
            consider using :ref:`advanced indexing<advanced.advanced_hierarchical>`.

            See below for using ``.loc[]`` on MultiIndex DataFrames.

        Callable that returns a boolean Series

        >>> df.loc[lambda df: df["shield"] == 8]
                    max_speed  shield
        sidewinder          7       8

        **Selecting along an explicit axis**

        ``.loc`` can be called with an ``axis`` argument to apply a single
        indexer to that axis.

        >>> df.loc(axis=0)["viper"]
        max_speed    4
        shield       5
        Name: viper, dtype: int64

        >>> df.loc(axis=1)["shield"]
        cobra         2
        viper         5
        sidewinder    8
        Name: shield, dtype: int64

        **Setting values**

        Set value for all items matching the list of labels

        >>> df.loc[["viper", "sidewinder"], ["shield"]] = 50
        >>> df
                    max_speed  shield
        cobra               1       2
        viper               4      50
        sidewinder          7      50

        Set value for an entire row

        >>> df.loc["cobra"] = 10
        >>> df
                    max_speed  shield
        cobra              10      10
        viper               4      50
        sidewinder          7      50

        Set value for an entire column

        >>> df.loc[:, "max_speed"] = 30
        >>> df
                    max_speed  shield
        cobra              30      10
        viper              30      50
        sidewinder         30      50

        Set value for rows matching callable condition

        >>> df.loc[df["shield"] > 35] = 0
        >>> df
                    max_speed  shield
        cobra              30      10
        viper               0       0
        sidewinder          0       0

        Add value matching location

        >>> df.loc["viper", "shield"] += 5
        >>> df
                    max_speed  shield
        cobra              30      10
        viper               0       5
        sidewinder          0       0

        Setting using a ``Series`` or a ``DataFrame`` sets the values matching the
        index labels, not the index positions.

        >>> shuffled_df = df.loc[["viper", "cobra", "sidewinder"]]
        >>> df.loc[:] += shuffled_df
        >>> df
                    max_speed  shield
        cobra              60      20
        viper               0      10
        sidewinder          0       0

        **Getting values on a DataFrame with an index that has integer labels**

        Another example using integers for the index

        >>> df = pd.DataFrame(
        ...     [[1, 2], [4, 5], [7, 8]],
        ...     index=[7, 8, 9],
        ...     columns=["max_speed", "shield"],
        ... )
        >>> df
           max_speed  shield
        7          1       2
        8          4       5
        9          7       8

        Slice with integer labels for rows. As mentioned above, note that both
        the start and stop of the slice are included.

        >>> df.loc[7:9]
           max_speed  shield
        7          1       2
        8          4       5
        9          7       8

        **Getting values with a MultiIndex**

        A number of examples using a DataFrame with a MultiIndex

        >>> tuples = [
        ...     ("cobra", "mark i"),
        ...     ("cobra", "mark ii"),
        ...     ("sidewinder", "mark i"),
        ...     ("sidewinder", "mark ii"),
        ...     ("viper", "mark ii"),
        ...     ("viper", "mark iii"),
        ... ]
        >>> index = pd.MultiIndex.from_tuples(tuples)
        >>> values = [[12, 2], [0, 4], [10, 20], [1, 4], [7, 1], [16, 36]]
        >>> df = pd.DataFrame(values, columns=["max_speed", "shield"], index=index)
        >>> df
                             max_speed  shield
        cobra      mark i           12       2
                   mark ii           0       4
        sidewinder mark i           10      20
                   mark ii           1       4
        viper      mark ii           7       1
                   mark iii         16      36

        Single label. Note this returns a DataFrame with a single index.

        >>> df.loc["cobra"]
                 max_speed  shield
        mark i          12       2
        mark ii          0       4

        Single index tuple. Note this returns a Series.

        >>> df.loc[("cobra", "mark ii")]
        max_speed    0
        shield       4
        Name: (cobra, mark ii), dtype: int64

        Single label for row and column. Similar to passing in a tuple, this
        returns a Series.

        >>> df.loc["cobra", "mark i"]
        max_speed    12
        shield        2
        Name: (cobra, mark i), dtype: int64

        Single tuple. Note using ``[[]]`` returns a DataFrame.

        >>> df.loc[[("cobra", "mark ii")]]
                       max_speed  shield
        cobra mark ii          0       4

        Single tuple for the index with a single label for the column

        >>> df.loc[("cobra", "mark i"), "shield"]
        2

        Slice from index tuple to single label

        >>> df.loc[("cobra", "mark i") : "viper"]
                             max_speed  shield
        cobra      mark i           12       2
                   mark ii           0       4
        sidewinder mark i           10      20
                   mark ii           1       4
        viper      mark ii           7       1
                   mark iii         16      36

        Slice from index tuple to index tuple

        >>> df.loc[("cobra", "mark i") : ("viper", "mark ii")]
                            max_speed  shield
        cobra      mark i          12       2
                   mark ii          0       4
        sidewinder mark i          10      20
                   mark ii          1       4
        viper      mark ii          7       1

        Please see the :ref:`user guide<advanced.advanced_hierarchical>`
        for more details and explanations of advanced indexing.

        **Assignment with Series**

        When assigning a Series to .loc[row_indexer, col_indexer], pandas aligns
        the Series by index labels, not by order or position.

        Series assignment with .loc and index alignment:

        >>> df = pd.DataFrame({"A": [1, 2, 3]}, index=[0, 1, 2])
        >>> s = pd.Series([10, 20], index=[1, 0])  # Note reversed order
        >>> df.loc[:, "B"] = s  # Aligns by index, not order
        >>> df
           A   B
        0  1  20.0
        1  2  10.0
        2  3 NaN
        Úloc)Ú_LocIndexerrj   s    r\   rl   zIndexingMixin.loch  s   € ô`
 ˜5 $Ó'Ð'r^   c                ó   — t        d| «      S )a’  
        Access a single value for a row/column label pair.

        Similar to ``loc``, in that both provide label-based lookups. Use
        ``at`` if you only need to get or set a single value in a DataFrame
        or Series.

        Raises
        ------
        KeyError
            If getting a value and 'label' does not exist in a DataFrame or Series.

        ValueError
            If row/column label pair is not a tuple or if any label
            from the pair is not a scalar for DataFrame.
            If label is list-like (*excluding* NamedTuple) for Series.

        See Also
        --------
        DataFrame.at : Access a single value for a row/column pair by label.
        DataFrame.iat : Access a single value for a row/column pair by integer
            position.
        DataFrame.loc : Access a group of rows and columns by label(s).
        DataFrame.iloc : Access a group of rows and columns by integer
            position(s).
        Series.at : Access a single value by label.
        Series.iat : Access a single value by integer position.
        Series.loc : Access a group of rows by label(s).
        Series.iloc : Access a group of rows by integer position(s).

        Notes
        -----
        See :ref:`Fast scalar value getting and setting <indexing.basics.get_value>`
        for more details.

        Examples
        --------
        >>> df = pd.DataFrame(
        ...     [[0, 2, 3], [0, 4, 1], [10, 20, 30]],
        ...     index=[4, 5, 6],
        ...     columns=["A", "B", "C"],
        ... )
        >>> df
            A   B   C
        4   0   2   3
        5   0   4   1
        6  10  20  30

        Get value at specified row/column pair

        >>> df.at[4, "B"]
        2

        Set value at specified row/column pair

        >>> df.at[4, "B"] = 10
        >>> df.at[4, "B"]
        10

        Get value within a Series

        >>> df.loc[5].at["B"]
        4
        Úat)Ú
_AtIndexerrj   s    r\   ro   zIndexingMixin.atº  s   € ôD ˜$ Ó%Ð%r^   c                ó   — t        d| «      S )a†  
        Access a single value for a row/column pair by integer position.

        Similar to ``iloc``, in that both provide integer-based lookups. Use
        ``iat`` if you only need to get or set a single value in a DataFrame
        or Series.

        Raises
        ------
        IndexError
            When integer position is out of bounds.

        See Also
        --------
        DataFrame.at : Access a single value for a row/column label pair.
        DataFrame.loc : Access a group of rows and columns by label(s).
        DataFrame.iloc : Access a group of rows and columns by integer position(s).

        Examples
        --------
        >>> df = pd.DataFrame(
        ...     [[0, 2, 3], [0, 4, 1], [10, 20, 30]], columns=["A", "B", "C"]
        ... )
        >>> df
            A   B   C
        0   0   2   3
        1   0   4   1
        2  10  20  30

        Get value at specified row/column pair

        >>> df.iat[1, 2]
        1

        Set value at specified row/column pair

        >>> df.iat[1, 2] = 10
        >>> df.iat[1, 2]
        10

        Get value within a series

        >>> df.loc[0].iat[1]
        2
        Úiat)Ú_iAtIndexerrj   s    r\   rr   zIndexingMixin.iatþ  s   € ô^ ˜5 $Ó'Ð'r^   N)r_   ri   )r_   rm   )r_   rp   )r_   rs   )	r`   ra   rb   rc   Úpropertyrh   rl   ro   rr   rY   r^   r\   rf   rf   ¿   s`   „ ñð òa*ó ða*ðF òO(ó ðO(ðb
 òA&ó ðA&ðF ò.(ó ñ.(r^   rf   c                  ó~  — e Zd ZU ded<   dZded<   ded<   edd d„«       Zd	„ Zed
„ «       Zedd!d„«       Z	ed!d„«       Z
	 	 	 	 	 	 d"d„Zd#d„Zed$d„«       Zed%d„«       Zed&d„«       Zed%d„«       Zed%d„«       Zed'd„«       Zed'd„«       Zed'd„«       Zd(d„Zd)d„Zed„ «       Zd*d„Zd'd„Zd(d„Zd+d„Zed(d„«       Zy),Ú_LocationIndexerÚstrÚ_valid_typesNzAxisInt | NoneÚaxisÚboolÚ	_takeablec                ó    —  t        | «      | j                  | j                  «      }|�| j                  j                  |«      }n|}||_        |S rX   )ÚtypeÚnameÚobjÚ_get_axis_numberry   )rZ   ry   Únew_selfÚaxis_int_nones       r\   Ú__call__z_LocationIndexer.__call__7  sI   € ð ”4˜“:˜dŸi™i¨¯©Ó2ˆàÐØ ŸH™H×5Ñ5°dÓ;‰Mà ˆMØ%ˆŒØˆr^   c                óä  — | j                   dk(  r| j                  || j                  ¬«       t        |t        «      r|D ]  }t        |«       Œ | j                  �!t        | j                  | j                  |«      }| j                  j                  d«      }t        |t        «      rK| j                   dk7  r<t        |d¬«      r/t        t        t        «      5  |j                  |«      cddd«       S t        |t        «      r*t        t         «      5  | j#                  |«      cddd«       S t        |t$        «      rt'        |«      }| j)                  |d¬«      S # 1 sw Y   ŒqxY w# 1 sw Y   ŒCxY w)zR
        Convert a potentially-label-based key into a positional indexer.
        rl   ©ry   Nr   rh   F©Úallow_slice)r~   Ú_ensure_listlike_indexerry   Ú
isinstanceÚtupleÚcheck_dict_or_set_indexersÚ_tupleize_axis_indexerÚndimr   Ú	_get_axisrC   r   r   ÚKeyErrorr   Úget_locr   Ú_convert_tupleÚrangeÚlistÚ_convert_to_indexer)rZ   ÚkeyÚxÚaxs       r\   Ú_get_setitem_indexerz%_LocationIndexer._get_setitem_indexerC  s7  € ð �9‰9˜Òà×)Ñ)¨#°D·I±IÐ)Ô>ä�cœ5Ô!Øò .�Ü*¨1Õ-ð.ð �9‰9Ð Ü(¨¯©°D·I±I¸sÓCˆCà�X‰X×Ñ Ó"ˆô �rœ:Ô&Ø—	‘	˜VÒ#Ü˜C¨UÕ3äœ(Ô$5Ó6ñ 'à—z‘z #“÷'ñ 'ô �cœ5Ô!Üœ-Ó(ñ 0à×*Ñ*¨3Ó/÷0ñ 0ô �cœ5Ô!ä�s“)ˆCà×'Ñ'¨°!Ð'Ó4Ð4÷'ð 'ú÷
0ð 0ús   ÃEÄE&ÅE#Å&E/c                óî  — t        |t        «      �r¹t        |«      dk(  �rªt        |t        t        f«      �r“|\  }}|j
                  }t        j                  |«      �rht        |«      t        |«      k(  �rP|j                  «       d   }t        || j
                  dz
  «      rQ|dk(  rLt        |«      dk(  r|j                  dd }n&| j                  j                  j                  ||«      }||f}||fS t        |t        j                  «      r¹|j                  j                   dk(  r t        |«      dk(  r’|dk(  r.| j                  j                  j                  ||«      }||f}||fS |dk(  rZ|j"                  d   dk(  rHt        |«      dk(  r|j                  dd }n&| j                  j                  j%                  ||«      }||f}||fS t        j                  |«      r|j                  «       d   }||fS )a  
        If we have obj.iloc[mask] = series_or_frame and series_or_frame has the
        same length as obj, we treat this as obj.iloc[mask] = series_or_frame[mask],
        similar to Series.__setitem__.

        Note this is only for loc, not iloc.
        é   r   é   NÚi)r‰   rŠ   Úlenr3   r0   r�   ÚcomÚis_bool_indexerÚnonzeror@   rh   r   Ú_align_seriesÚnpÚndarrayÚdtypeÚkindÚshapeÚ_align_frame)rZ   ÚindexerÚvalueÚpiÚicolsr�   Únewkeys          r\   Ú_maybe_mask_setitem_valuez*_LocationIndexer._maybe_mask_setitem_valueh  s¿  € ô �w¤Õ&Ü�G“ Ó!Ü˜5¤9¬lÐ";Õ<à‰IˆB�Ø—:‘:ˆDÜ×"Ñ" 2Õ&¬3¨u«:¼¸R»Ó+@ØŸ™› a™�ä$ U¨D¯I©I¸©MÔ:¸tÀqºyä˜6“{ aÒ'Ø %§
¡
¨2¨A ™ð !%§¡§¡× ;Ñ ;¸GÀUÓ K˜Ø% u˜o�Gð0 ˜ˆ~Ðô+ ˜u¤b§j¡jÔ1ØŸ™×(Ñ(¨CÒ/Ü˜E›
 ašà˜q’yð !%§¡§¡× ;Ñ ;¸GÀUÓ K˜Ø#)¨5 /˜ð ˜ˆ~Ðð  š u§{¡{°1¡~¸Ò':Ü˜v›;¨!Ò+Ø$)§J¡J¨r° N™Eð %)§H¡H§M¡M×$>Ñ$>¸wÈÓ$N˜EØ#)¨5 /˜ð ˜ˆ~Ðô × Ñ  Ô)Ø—o‘oÓ'¨Ñ*ˆGà˜ˆ~Ðr^   c                ó2  — | j                   dk7  ryt        |t        «      rt        |«      dkD  r	|€d}||   }|dk(  �rZt        | j                  j
                  t        «      �s4t        |«      �r't        j                  |«      �st        d„ |D «       «      rý| j                  j
                  j                  |d¬«      }t        |d¬«      j                  | j                  j
                  d¬«      }t        |«      ra| j                  j
                  j                  |«      }| j                  j                  j!                  ||dd	d	¬
«      }|| j                  _        y| j                  j                  j#                  |dd	¬«      | j                  _        yyyyyy)a  
        Ensure that a list-like of column labels are all present by adding them if
        they do not already exist.

        Parameters
        ----------
        key : list-like of column labels
            Target labels.
        axis : key axis if known
        rš   Nr›   c              3  ó2   K  — | ]  }t        |«      –— Œ y ­wrX   )r   ©Ú.0Úks     r\   ú	<genexpr>z<_LocationIndexer._ensure_listlike_indexer.<locals>.<genexpr>º  s   è ø€ Ò0 q”K —NÑ0ùó   ‚F)Úsort©Úcopyr   T)r¨   ry   Ú
only_sliceÚuse_na_proxy)ry   r¸   )r�   r‰   rŠ   r�   r   ÚcolumnsrC   r?   rž   rŸ   ÚallÚunionrB   Ú
differenceÚget_indexerÚ_mgrÚreindex_indexerÚreindex_axis)rZ   r•   ry   ÚkeysÚdiffr¨   Únew_mgrs          r\   rˆ   z)_LocationIndexer._ensure_listlike_indexer�  s^  € ð �9‰9˜Š>Øä�cœ5Ô!¤c¨#£h°¢lð ˆ|Ø�Ø�d‘)ˆCð �A‹IÜ˜tŸx™x×/Ñ/´Õ<Ü$ SÕ)Ü×'Ñ'¨Õ,ÜÑ0¨CÔ0Ô0ð —8‘8×#Ñ#×)Ñ)¨#°EÐ)Ó:ˆDÜ˜ 5Ô)×4Ñ4°T·X±X×5EÑ5EÈEÐ4ÓRˆDä�4Œyð Ÿ(™(×*Ñ*×6Ñ6°tÓ<�ØŸ(™(Ÿ-™-×7Ñ7Ø '°¸dÐQUð 8ó �ð !(�—‘”Øà ŸH™HŸM™M×6Ñ6°tÀ!ÐPTÐ6ÓUˆD�H‰H�Mð+ 1ð -ð *ð =ð r^   c                ó¼  ‡ — t         sFt        j                  ‰ j                  «      t        k  r t        j                  t        t        d¬«       t        |«       t        |t        «      rd„ |D «       }t        ˆ fd„|D «       «      }n2t        j                  |‰ j                  «      }‰ j                  ||«      }‰ j                  j                  d   }‰ j!                  |«      }‰ j#                  |«       ‰ j                  j$                  dk(  r‰ j                  j&                  }d }n:‰ j                  j(                  j+                  «       }‰ j                  j,                  }‰ j.                  dk(  rt1        d‰ «      n‰ j                  j2                  }|j5                  ||‰ j.                  «       ‰ j                  j                  d   |k7  r‰ j7                  ||«       y y )	Nrš   ©Ú
stacklevelc              3  óL   K  — | ]  }t        |«      rt        |«      n|–— Œ y ­wrX   ©r!   r“   ©r±   r–   s     r\   r³   z/_LocationIndexer.__setitem__.<locals>.<genexpr>Û  ó   è ø€ ÒA¸œk¨!œn”4˜”7°!Ó3ÑAùó   ‚"$c              3  ó^   •K  — | ]$  }t        j                  |‰j                  «      –— Œ& y ­wrX   ©rž   Úapply_if_callabler   ©r±   r–   rZ   s     €r\   r³   z/_LocationIndexer.__setitem__.<locals>.<genexpr>Ü  ó"   øè ø€ ÒH¸qœ×-Ñ-¨a°·±×:ÑHùó   ƒ*-r   r›   rh   ri   )r   ÚsysÚgetrefcountr   r   ÚwarningsÚwarnr   r   r‹   r‰   rŠ   rž   rÏ   Ú_raise_callable_usager¦   r˜   Ú_has_valid_setitem_indexerr�   r¤   r¿   Ú
get_dtypesrº   r~   r   rh   Ú_setitem_with_indexerÚ_post_expansion_casting)	rZ   r•   r©   Úmaybe_callableÚ
orig_nrowsr¨   Úorig_dtype_infoÚorig_columnsrh   s	   `        r\   Ú__setitem__z_LocationIndexer.__setitem__Ñ  si  ø€ å'Ü�‰˜tŸx™xÓ(¬MÒ9Ü—‘Ü+Ô-CÐPQõô 	# 3Ô'Ü�cœ5Ô!ÙA¸SÔAˆCÜÓHÀCÔHÓH‰Cä ×2Ñ2°3¸¿¹ÓAˆNØ×,Ñ,¨S°.ÓAˆCð —X‘X—^‘^ AÑ&ˆ
Ø×+Ñ+¨CÓ0ˆØ×'Ñ'¨Ô,ð �8‰8�=‰=˜AÒØ"Ÿh™hŸn™nˆOØ‰Là"Ÿh™hŸm™m×6Ñ6Ó8ˆOØŸ8™8×+Ñ+ˆLð +/¯)©)°vÒ*=ŒD� Ô&À4Ç8Á8Ç=Á=ð 	ð 	×"Ñ" 7¨E°4·9±9Ô=à�8‰8�>‰>˜!Ñ 
Ò*Ø×(Ñ(¨¸,ÕGð +r^   c                óü  — | j                   j                  dk(  rÅt        |t        j                  «      rJ ‚|| j                   j
                  k7  r�t        g |¬«      }t        || j                   j                  «      }| j                   j                  || j                   j                  | j                   j                  ¬«      }|j                  | j                   _        y y t        |t        j                  «      sJ ‚|€J ‚|}| j                   j                  j                  «       }t        |«      t        |«      k(  r�||k7  }t        j                  |«      D ]r  }	||	   j                   dk(  rŒt        g ||	   ¬«      }t        || j                   j"                  d d …|	f   j                  «      }| j                   j%                  |	|«       Œt y |j&                  r¥| j                   j(                  j&                  r…t+        ||d¬«      D ]s  \  }
}| j                   |
   j
                  }||k7  sŒ%|j                   dk(  rŒ5t        g |¬«      }t        || j                   |
   j                  «      }|| j                   |
<   Œu y y )Nr›   ©r¤   ©Úindexr~   ÚVT©Ústrict)r   r�   r‰   r¢   r£   r¤   Úpd_arrayÚinfer_and_maybe_downcastÚ_valuesÚ_constructorrä   r~   r¿   rÙ   r�   Úflatnonzeror¥   rh   ÚisetitemÚ	is_uniquerº   Úzip)rZ   rÞ   rß   Úorig_arrÚnew_arrÚnew_serÚorig_dtypesÚ
new_dtypesÚchanged_dtypesÚidxÚcolÚ
orig_dtypeÚ	new_dtypes                r\   rÛ   z(_LocationIndexer._post_expansion_casting÷  s  € ð �8‰8�=‰=˜AÒÜ! /´2·:±:Ô>Ð>Ð>Ø $§(¡(§.¡.Ò0Ü# B¨oÔ>�Ü2°8¸T¿X¹X×=MÑ=MÓN�ØŸ(™(×/Ñ/Ø 4§8¡8§>¡>¸¿¹¿¹ð 0ó �ð !(§¡�—‘•ð 1ô ˜o¬r¯z©zÔ:Ð:Ð:ØÐ+Ð+Ð+Ø)ˆKØŸ™Ÿ™×1Ñ1Ó3ˆJÜ�;Ó¤3 z£?Ò2à!+¨{Ñ!:�ÜŸ>™>¨.Ó9ò 	4�CØ" 3Ñ'×,Ñ,°Ò3ð !Ü'¨°+¸cÑ2BÔC�HÜ6Ø  $§(¡(§-¡-²°3°Ñ"7×"?Ñ"?ó�Gð —H‘H×%Ñ% c¨7Õ3ñ	4ð ×'Ò'¨D¯H©H×,<Ñ,<×,FÒ,Fô (+¨<¸ÈTÔ'Rò 
0‘O�C˜Ø $§¡¨¡× 3Ñ 3�IØ  JÓ.Ø%Ÿ?™?¨cÒ1à$Ü#+¨B°jÔ#A˜Ü":Ø$ d§h¡h¨s¡m×&;Ñ&;ó#˜ð )0˜Ÿ™ šñ
0ð  r^   c                ó   — t        | «      ‚)áó  
        Ensure that key is valid for current indexer.

        Parameters
        ----------
        key : scalar, slice or list-like
            Key requested.
        axis : int
            Dimension on which the indexing is being made.

        Raises
        ------
        TypeError
            If the key (or some element of it) has wrong type.
        IndexError
            If the key (or some element of it) is out of bounds.
        KeyError
            If the key was not found.
        ©r   ©rZ   r•   ry   s      r\   Ú_validate_keyz_LocationIndexer._validate_key0  s   € ô( " $Ó'Ð'r^   c                ó  — t        d„ |D «       «      rl|j                  t        «      dkD  rt        t        «      ‚t        |«      | j                  k(  r-|j                  t        «      }g |d| ¢t        ‘||dz   d ¢­}|S |S )zt
        If a tuple key includes an Ellipsis, replace it with an appropriate
        number of null slices.
        c              3  ó,   K  — | ]  }|t         u –— Œ y ­wrX   )ÚEllipsisrÊ   s     r\   r³   z4_LocationIndexer._expand_ellipsis.<locals>.<genexpr>L  s   è ø€ Ò* ˆq”HŒ}Ñ*ùs   ‚r›   N)	ÚanyÚcountr  r   Ú_one_ellipsis_messager�   r�   rä   Ú_NS)rZ   Útuprœ   Únew_keys       r\   Ú_expand_ellipsisz!_LocationIndexer._expand_ellipsisF  s   € ô Ñ* cÔ*Ô*Ø�y‰yœÓ" QÒ&Ü#Ô$9Ó:Ð:ä�3‹x˜4Ÿ9™9Ò$ð —I‘IœhÓ'�Ø8˜C  ˜GÐ8¤SÐ8¨3¨q°1©u¨w¨<Ñ8�Ø�ð ˆ
r^   c                óì   — | j                  |«      }| j                  |«      }t        |«      D ]  \  }}	 | j                  ||«       Œ |S # t        $ r}t	        d| j
                  › d�«      |‚d}~ww xY w)zA
        Check the key for valid keys across my indexer.
        z'Location based indexing can only have [z] typesN)Ú_validate_key_lengthr  Ú	enumeraterþ   Ú
ValueErrorrx   )rZ   r•   rœ   r²   Úerrs        r\   Ú_validate_tuple_indexerz(_LocationIndexer._validate_tuple_indexer[  s�   € ð
 ×'Ñ'¨Ó,ˆØ×#Ñ# CÓ(ˆÜ˜c“Nò 	‰DˆAˆqðØ×"Ñ" 1 aÕ(ð	ð ˆ
øô	 ò Ü Ø=¸d×>OÑ>OÐ=PÐPWÐXóàðûðús   µAÁ	A3ÁA.Á.A3c                ó¢   ‡— t        d„ | j                  j                  D «       «      r(t        ˆfd„| j                  j                  D «       «      S y)ú6
        Returns
        -------
        bool
        c              3  ó<   K  — | ]  }t        |t        «      –— Œ y ­wrX   )r‰   rC   )r±   r—   s     r\   r³   z<_LocationIndexer._is_nested_tuple_indexer.<locals>.<genexpr>r  s   è ø€ ÒB¨bŒz˜"œj×)ÑBùó   ‚c              3  ó6   •K  — | ]  }t        ‰|«      –— Œ y ­wrX   )Úis_nested_tuple)r±   r—   r  s     €r\   r³   z<_LocationIndexer._is_nested_tuple_indexer.<locals>.<genexpr>s  s   øè ø€ ÒH°B” s¨B×/ÑHùó   ƒF)r  r   Úaxes©rZ   r  s    `r\   Ú_is_nested_tuple_indexerz)_LocationIndexer._is_nested_tuple_indexerk  s7   ø€ ô ÑB°D·H±H·M±MÔBÔBÜÓH¸$¿(¹(¿-¹-ÔHÓHÐHØr^   c                ó¢   — | j                  |«       t        |«      D ��cg c]  \  }}| j                  ||¬«      ‘Œ }}}t        |«      S c c}}w ©Nr…   )r
  r  r”   rŠ   )rZ   r•   rœ   r²   Úkeyidxs        r\   r‘   z_LocationIndexer._convert_tuplev  sM   € ð 	×!Ñ! #Ô&ÜBKÈCÃ.×Q¹$¸!¸Q�$×*Ñ*¨1°1Ð*Õ5ÐQˆÑQÜ�V‹}Ðùó Rs    Ac                ó¼   — t        |«      | j                  kD  rC|d   t        u r-|dd  }t        |v rt        t        «      ‚| j                  |«      S t        d«      ‚|S )Nr   r›   úToo many indexers)r�   r�   r  r   r  r
  ©rZ   r•   s     r\   r
  z%_LocationIndexer._validate_key_length}  s^   € äˆs‹8�d—i‘iÒØ�1‰vœÑ!à˜!˜"�g�Ü˜s‘?Ü'Ô(=Ó>Ð>Ø×0Ñ0°Ó5Ð5ÜÐ 3Ó4Ð4Øˆ
r^   c                ó   — | j                   }| j                  t        |«      z
  dz   }t        t	        |«      «      D ]o  \  }}| j                  |z
  |z
  }t        j                  |«      rŒ.t        || j                  «      j                  ||¬«      }|j                  | j                  k(  rŒoJ ‚ || j                   u r|j                  d¬«      }|S )z´
        Index with indexers that should return an object of the same dimension
        as self.obj.

        This is only called after a failed call to _getitem_lowerdim.
        r›   r…   F©Údeep)r   r�   r�   r  Úreversedrž   Úis_null_sliceÚgetattrr~   Ú_getitem_axisr·   )rZ   r  ÚretvalÚ	start_valrœ   r•   s         r\   Ú_getitem_tuple_same_dimz(_LocationIndexer._getitem_tuple_same_dim‰  sÀ   € ð —‘ˆà—Y‘Y¤ S£Ñ)¨QÑ.ˆ	Ü¤¨£Ó.ò 	,‰FˆAˆsØ—	‘	˜A‘ 	Ñ)ˆAÜ× Ñ  Ô%Øä˜V T§Y¡YÓ/×=Ñ=¸cÈÐ=ÓJˆFð —;‘; $§)¡)Ó+Ð+Ð+ð	,ð �T—X‘XÑð —[‘[ e�[Ó,ˆFàˆr^   c                ó   — | j                   �8| j                  j                  | j                   «      }| j                  ||¬«      S | j	                  |«      r| j                  |«      S | j                  j                  d«      }t        |t        «      rU| j                  dk7  rFt        d„ |D «       «      s4t        t        «      5  t        d| «      j                  |«      cd d d «       S | j                  |«      }t!        t#        t%        |«      dz
  dd«      t'        |«      d¬	«      D ]Ï  \  }}t)        |«      s(t+        |«      st        |t,        «      sŒ-t/        |«      sŒ9| j                  ||¬«      }|j0                  | j0                  k(  rg |d | ¢t2        ‘||dz   d  ¢­}n!|d | ||dz   d  z   }t%        |«      dk(  r|d   }t5        j6                  |«      r|c S t9        || j                  «      |   c S  t        d
«      ‚# 1 sw Y   �Œ&xY w)Nr…   r   rh   c              3  ó<   K  — | ]  }t        |t        «      –— Œ y ­wrX   ©r‰   ÚslicerÊ   s     r\   r³   z5_LocationIndexer._getitem_lowerdim.<locals>.<genexpr>·  s   è ø€ Ò:°œ
 1¤e×,Ñ:ùr  rm   r›   éÿÿÿÿTræ   znot applicable)ry   r   r€   r%  r  Ú_getitem_nested_tuplerŽ   r‰   rC   r~   r  r   r   r   Ú"_handle_lowerdim_multi_index_axis0r
  rï   r’   r�   r"  Úis_label_liker"   r,  Ú
need_slicer�   r  rž   r#  r$  )rZ   r  ry   Úax0rœ   r•   Úsectionr  s           r\   Ú_getitem_lowerdimz"_LocationIndexer._getitem_lowerdim¥  sù  € ð �9‰9Ð Ø—8‘8×,Ñ,¨T¯Y©YÓ7ˆDØ×%Ñ% c°Ð%Ó5Ð5ð ×(Ñ(¨Ô-Ø×-Ñ-¨cÓ2Ð2ð �h‰h× Ñ  Ó#ˆô �sœJÔ'Ø—	‘	˜VÒ#ÜÑ:°cÔ:Ô:ô œ-Ó(ñ YÜ˜M¨4Ó0×SÑSÐTWÓX÷Yñ Yð ×'Ñ'¨Ó,ˆô œ%¤ C£¨1¡¨b°"Ó5´xÀ³}ÈTÔRò  	<‰FˆAˆsä˜cÔ"Ü Ô$Ü˜s¤EÕ*¬z¸#­ð ×,Ñ,¨S°qÐ,Ó9�ð
 —<‘< 4§9¡9Ò,ð =  B Q Ð<¬Ð<¨s°1°q±5°7¨|Ñ<‘Gð " " 1˜g¨¨A°©E¨G¨Ñ4�Gä˜7“| qÒ(Ø")¨!¡*˜ô ×$Ñ$ WÔ-Ø"’Nä˜w¨¯	©	Ó2°7Ñ;Ò;ðA 	<ôD Ð,Ó-Ð-÷SYñ Yús   ÃHÈHc                óü  — |D ]  }t        |«       Œ t        |«      | j                  kD  rº| j                  dk7  rt	        d«      ‚t        d„ |D «       «      r4t        t        «      5  t        d| «      j                  |«      cd d d «       S t        | j                  t        «      rt        d„ |D «       «      rt        d«      ‚| j                  xs d}| j                  ||¬«      S | j                  }t        |«      d	z
  }t!        |«      D ]c  }t#        j$                  |«      r|d	z  }Œt'        || j                  «      j                  ||¬«      }|d	z  }t)        |«      st+        |d
«      rŒb |S  |S # 1 sw Y   Œ¹xY w)Nrl   zToo many indicesc              3  ód   K  — | ](  }t        |d ¬«      xs t        j                  |«      –— Œ* y­w)Fr†   N)r   rž   r#  rÊ   s     r\   r³   z9_LocationIndexer._getitem_nested_tuple.<locals>.<genexpr>÷  s/   è ø€ ò ØNO”˜A¨5Ô1ÒI´S×5FÑ5FÀqÓ5IÓIñùs   ‚.0rm   c              3  ó<   K  — | ]  }t        |t        «      –— Œ y ­wrX   ©r‰   rŠ   r°   s     r\   r³   z9_LocationIndexer._getitem_nested_tuple.<locals>.<genexpr>  s   è ø€ ò 9Ø)*”
˜1œe×$ñ9ùr  r  r   r…   r›   r�   )r‹   r�   r�   r~   r  r»   r   r   r   r/  r‰   r   r3   r  ry   r%  r"  rž   r#  r$  r%   Úhasattr)rZ   r  r•   ry   r   s        r\   r.  z&_LocationIndexer._getitem_nested_tupleè  s  € ð
 ò 	,ˆCÜ& sÕ+ð	,ô ˆs‹8�d—i‘iÒØ�y‰y˜EÒ!ä Ð!3Ó4Ð4Üñ ØSVôô ô œmÓ,ñ Ü ¨tÓ4×WÑWØó÷ñ ô ˜DŸH™H¤iÔ0´Sñ 9Ø.1ô9ô 6ô $Ð$7Ó8Ð8ð —9‘9’> ˆDØ×%Ñ% c°Ð%Ó5Ð5ð �h‰hˆô �3‹x˜!‰|ˆÜ˜C“=ò 
	ˆCÜ× Ñ  Ô%Ø˜‘	�Øä˜#˜tŸy™yÓ)×7Ñ7¸À$Ð7ÓGˆCØ�A‰IˆDô ˜Œ~¤W¨S°&Õ%9Øàˆ
ð
	ð ˆ
÷Kð ús   Á&E2Å2E;c                ó   — t        | «      ‚rX   rü   rý   s      r\   r”   z$_LocationIndexer._convert_to_indexer$  ó   € Ü! $Ó'Ð'r^   c                óp   — | j                   dk(  r&t        |«      rt        |t        «      rt	        d«      ‚|S )Nrh   z;Returning a tuple from a callable with iloc is not allowed.)r~   Úcallabler‰   rŠ   r  )rZ   r•   rÜ   s      r\   r×   z&_LocationIndexer._raise_callable_usage'  s6   € à�9‰9˜Ò¤8¨C¤=´ZÀÔPUÔ5VÜØMóð ð Ðr^   c                ó°  ‡ — t        |«       t        |«      t        u red„ |D «       }t        ˆ fd„|D «       «      }‰ j                  |«      r& ‰ j                  j
                  |d‰ j                  iŽS ‰ j                  |«      S ‰ j                  xs d}t        j                  |‰ j                  «      }‰ j                  ||«      }‰ j                  ||¬«      S )Nc              3  óL   K  — | ]  }t        |«      rt        |«      n|–— Œ y ­wrX   rÉ   rÊ   s     r\   r³   z/_LocationIndexer.__getitem__.<locals>.<genexpr>3  rË   rÌ   c              3  ó^   •K  — | ]$  }t        j                  |‰j                  «      –— Œ& y ­wrX   rÎ   rÐ   s     €r\   r³   z/_LocationIndexer.__getitem__.<locals>.<genexpr>4  rÑ   rÒ   Útakeabler   r…   )r‹   r}   rŠ   Ú_is_scalar_accessr   Ú
_get_valuer{   Ú_getitem_tuplery   rž   rÏ   r×   r%  )rZ   r•   ry   rÜ   s   `   r\   r]   z_LocationIndexer.__getitem__/  s½   ø€ ä" 3Ô'Ü�‹9œÑÙA¸SÔAˆCÜÓHÀCÔHÓHˆCØ×%Ñ% cÔ*Ø*�t—x‘x×*Ñ*¨CÐI¸$¿.¹.ÑIÐIØ×&Ñ& sÓ+Ð+ð —9‘9’> ˆDä ×2Ñ2°3¸¿¹ÓAˆNØ!×7Ñ7¸¸^ÓLˆNØ×%Ñ% n¸4Ð%Ó@Ð@r^   c                ó   — t         ‚rX   ©ÚNotImplementedErrorr  s     r\   rB  z"_LocationIndexer._is_scalar_access@  ó   € Ü!Ð!r^   c                ó   — t        | «      ‚rX   rü   r  s     r\   rD  z_LocationIndexer._getitem_tupleC  r;  r^   c                ó   — t         ‚rX   rF  rý   s      r\   r%  z_LocationIndexer._getitem_axisF  rH  r^   c                ó   — t        | «      ‚rX   rü   ©rZ   r¨   s     r\   rØ   z+_LocationIndexer._has_valid_setitem_indexerI  r;  r^   c                ó°   — | j                   j                  |«      }t        ||«      }|j                  «       d   }| j                   j	                  ||¬«      S )Nr   r…   )r   rŽ   Úcheck_bool_indexerr    Útake)rZ   r•   ry   ÚlabelsÚindss        r\   Ú_getbool_axisz_LocationIndexer._getbool_axisL  sK   € ð —‘×#Ñ# DÓ)ˆÜ  ¨Ó-ˆØ�{‰{‹}˜QÑˆØ�x‰x�}‰}˜T¨ˆ}Ó-Ð-r^   rX   )ry   zAxis | Noner_   r   ©r_   ÚNone)rÞ   z"DtypeObj | npt.NDArray[np.object_]rß   zIndex | Noner_   rT  ©ry   rH   r_   rT  )r  rŠ   r_   rŠ   )r•   rŠ   r_   rŠ   ©r  rŠ   r_   rz   ©r  rŠ   ©ry   rH   )r•   r   rÜ   rK   r_   rK   )r•   rŠ   ©r_   rz   )r`   ra   rb   Ú__annotations__ry   r   rƒ   r˜   r­   rˆ   rà   rÛ   rþ   r  r  r  r‘   r
  r(  r4  r.  r”   r×   r]   rB  rD  r%  rØ   rR  rY   r^   r\   rv   rv   0  s‡  … ØÓØ€Dˆ.Óð ƒOà
ó	ó ð	ò#5ðJ ñ2ó ð2ðh ó1Vó ð1Vðf ò#Hó ð#HðJ7à;ð7ð #ð7ð 
ó	7ór(ð, òó ðð( òó ðð òó ðð òó ðð ò	ó ð	ð òó ðð6 ò@.ó ð@.ðD ò9ó ð9óv(óð ñAó ðAó "ó(ó"ó(ð ò.ó ñ.r^   rv   c                  óŒ   — e Zd ZU dZdZded<   dZdd„Zdd„Zdd„Z	dd	„Z
dd
„Zdd„Zdd„Zdd„Zdd„Zdd„Zdd„Zdd„Zdd„Zy)rm   a'  
    Access a group of rows and columns by label(s) or a boolean array.

    ``.loc[]`` is primarily label based, but may also be used with a
    boolean array.

    Allowed inputs are:

    - A single label, e.g. ``5`` or ``'a'``, (note that ``5`` is
      interpreted as a *label* of the index, and **never** as an
      integer position along the index).
    - A list or array of labels, e.g. ``['a', 'b', 'c']``.
    - A slice object with labels, e.g. ``'a':'f'``.

      .. warning:: Note that contrary to usual python slices, **both** the
          start and the stop are included

    - A boolean array of the same length as the axis being sliced,
      e.g. ``[True, False, True]``.
    - An alignable boolean Series. The index of the key will be aligned before
      masking.
    - An alignable Index. The Index of the returned selection will be the input.
    - A ``callable`` function with one argument (the calling Series or
      DataFrame) and that returns valid output for indexing (one of the above)

    See more at :ref:`Selection by Label <indexing.label>`.

    Raises
    ------
    KeyError
        If any items are not found.
    IndexingError
        If an indexed key is passed and its index is unalignable to the frame index.

    See Also
    --------
    DataFrame.at : Access a single value for a row/column label pair.
    DataFrame.iloc : Access group of rows and columns by integer position(s).
    DataFrame.xs : Returns a cross-section (row(s) or column(s)) from the
                   Series/DataFrame.
    Series.loc : Access group of values using labels.

    Examples
    --------
    **Getting values**

    >>> df = pd.DataFrame(
    ...     [[1, 2], [4, 5], [7, 8]],
    ...     index=["cobra", "viper", "sidewinder"],
    ...     columns=["max_speed", "shield"],
    ... )
    >>> df
                max_speed  shield
    cobra               1       2
    viper               4       5
    sidewinder          7       8

    Single label. Note this returns the row as a Series.

    >>> df.loc["viper"]
    max_speed    4
    shield       5
    Name: viper, dtype: int64

    List of labels. Note using ``[[]]`` returns a DataFrame.

    >>> df.loc[["viper", "sidewinder"]]
                max_speed  shield
    viper               4       5
    sidewinder          7       8

    Single column label. Note this returns the column as a Series.

    >>> df.loc[:, "max_speed"]
    cobra         1
    viper         4
    sidewinder    7
    Name: max_speed, dtype: int64

    List with a single column label. Note this returns a DataFrame.

    >>> df.loc[:, ["max_speed"]]
                max_speed
    cobra               1
    viper               4
    sidewinder          7

    Single label for row and column

    >>> df.loc["cobra", "shield"]
    2

    Slice with labels for row and single label for column. As mentioned
    above, note that both the start and stop of the slice are included.

    >>> df.loc["cobra":"viper", "max_speed"]
    cobra    1
    viper    4
    Name: max_speed, dtype: int64

    Boolean list with the same length as the row axis

    >>> df.loc[[False, False, True]]
                max_speed  shield
    sidewinder          7       8

    Alignable boolean Series:

    >>> df.loc[pd.Series([False, True, False], index=["viper", "sidewinder", "cobra"])]
                         max_speed  shield
    sidewinder          7       8

    Conditional that returns a boolean Series

    >>> df.loc[df["shield"] > 6]
                max_speed  shield
    sidewinder          7       8

    Conditional that returns a boolean Series with column labels specified

    >>> df.loc[df["shield"] > 6, ["max_speed"]]
                max_speed
    sidewinder          7

    Multiple conditional using ``&`` that returns a boolean Series

    >>> df.loc[(df["max_speed"] > 1) & (df["shield"] < 8)]
                max_speed  shield
    viper          4       5

    Multiple conditional using ``|`` that returns a boolean Series

    >>> df.loc[(df["max_speed"] > 4) | (df["shield"] < 5)]
                max_speed  shield
    cobra               1       2
    sidewinder          7       8

    Please ensure that each condition is wrapped in parentheses ``()``.
    See the :ref:`user guide<indexing.boolean>`
    for more details and explanations of Boolean indexing.

    .. note::
        If you find yourself using 3 or more conditionals in ``.loc[]``,
        consider using :ref:`advanced indexing<advanced.advanced_hierarchical>`.

        See below for using ``.loc[]`` on MultiIndex DataFrames.

    Callable that returns a boolean Series

    >>> df.loc[lambda df: df["shield"] == 8]
                max_speed  shield
    sidewinder          7       8

    **Setting values**

    Set value for all items matching the list of labels

    >>> df.loc[["viper", "sidewinder"], ["shield"]] = 50
    >>> df
                max_speed  shield
    cobra               1       2
    viper               4      50
    sidewinder          7      50

    Set value for an entire row

    >>> df.loc["cobra"] = 10
    >>> df
                max_speed  shield
    cobra              10      10
    viper               4      50
    sidewinder          7      50

    Set value for an entire column

    >>> df.loc[:, "max_speed"] = 30
    >>> df
                max_speed  shield
    cobra              30      10
    viper              30      50
    sidewinder         30      50

    Set value for rows matching callable condition

    >>> df.loc[df["shield"] > 35] = 0
    >>> df
                max_speed  shield
    cobra              30      10
    viper               0       0
    sidewinder          0       0

    Add value matching location

    >>> df.loc["viper", "shield"] += 5
    >>> df
                max_speed  shield
    cobra              30      10
    viper               0       5
    sidewinder          0       0

    Setting using a ``Series`` or a ``DataFrame`` sets the values matching the
    index labels, not the index positions.

    >>> shuffled_df = df.loc[["viper", "cobra", "sidewinder"]]
    >>> df.loc[:] += shuffled_df
    >>> df
                max_speed  shield
    cobra              60      20
    viper               0      10
    sidewinder          0       0

    **Getting values on a DataFrame with an index that has integer labels**

    Another example using integers for the index

    >>> df = pd.DataFrame(
    ...     [[1, 2], [4, 5], [7, 8]],
    ...     index=[7, 8, 9],
    ...     columns=["max_speed", "shield"],
    ... )
    >>> df
       max_speed  shield
    7          1       2
    8          4       5
    9          7       8

    Slice with integer labels for rows. As mentioned above, note that both
    the start and stop of the slice are included.

    >>> df.loc[7:9]
       max_speed  shield
    7          1       2
    8          4       5
    9          7       8

    **Getting values with a MultiIndex**

    A number of examples using a DataFrame with a MultiIndex

    >>> tuples = [
    ...     ("cobra", "mark i"),
    ...     ("cobra", "mark ii"),
    ...     ("sidewinder", "mark i"),
    ...     ("sidewinder", "mark ii"),
    ...     ("viper", "mark ii"),
    ...     ("viper", "mark iii"),
    ... ]
    >>> index = pd.MultiIndex.from_tuples(tuples)
    >>> values = [[12, 2], [0, 4], [10, 20], [1, 4], [7, 1], [16, 36]]
    >>> df = pd.DataFrame(values, columns=["max_speed", "shield"], index=index)
    >>> df
                         max_speed  shield
    cobra      mark i           12       2
               mark ii           0       4
    sidewinder mark i           10      20
               mark ii           1       4
    viper      mark ii           7       1
               mark iii         16      36

    Single label. Note this returns a DataFrame with a single index.

    >>> df.loc["cobra"]
             max_speed  shield
    mark i          12       2
    mark ii          0       4

    Single index tuple. Note this returns a Series.

    >>> df.loc[("cobra", "mark ii")]
    max_speed    0
    shield       4
    Name: (cobra, mark ii), dtype: int64

    Single label for row and column. Similar to passing in a tuple, this
    returns a Series.

    >>> df.loc["cobra", "mark i"]
    max_speed    12
    shield        2
    Name: (cobra, mark i), dtype: int64

    Single tuple. Note using ``[[]]`` returns a DataFrame.

    >>> df.loc[[("cobra", "mark ii")]]
                   max_speed  shield
    cobra mark ii          0       4

    Single tuple for the index with a single label for the column

    >>> df.loc[("cobra", "mark i"), "shield"]
    2

    Slice from index tuple to single label

    >>> df.loc[("cobra", "mark i") : "viper"]
                         max_speed  shield
    cobra      mark i           12       2
               mark ii           0       4
    sidewinder mark i           10      20
               mark ii           1       4
    viper      mark ii           7       1
               mark iii         16      36

    Slice from index tuple to index tuple

    >>> df.loc[("cobra", "mark i") : ("viper", "mark ii")]
                        max_speed  shield
    cobra      mark i          12       2
               mark ii          0       4
    sidewinder mark i          10      20
               mark ii          1       4
    viper      mark ii          7       1

    Please see the :ref:`user guide<advanced.advanced_hierarchical>`
    for more details and explanations of advanced indexing.

    **Assignment with Series**

    When assigning a Series to .loc[row_indexer, col_indexer], pandas aligns
    the Series by index labels, not by order or position.

    Series assignment with .loc and index alignment:

    >>> df = pd.DataFrame({"A": [1, 2, 3]}, index=[0, 1, 2])
    >>> s = pd.Series([10, 20], index=[1, 0])  # Note reversed order
    >>> df.loc[:, "B"] = s  # Aligns by index, not order
    >>> df
       A   B
    0  1  20.0
    1  2  10.0
    2  3 NaN
    Frz   r{   zšlabels (MUST BE IN THE INDEX), slices of labels (BOTH endpoints included! Can be slices of integers if the index is integers), listlike of labels, booleanc                óà  — | j                   j                  |«      }t        |t        «      rpt	        |j
                  «      s[|j
                  j                  dk(  sBt        |t        «      r$t	        |j                  d«      j
                  «      st        |› d�«      ‚t        |t        «      rCt        |j                  t        «      st        |j                  t        «      rt        |› d�«      ‚yy)rû   Úbooleanr   z7: boolean label can not be used without a boolean indexz+: boolean values can not be used in a sliceN)r   rŽ   r‰   rz   r   r¤   r~   rC   Úget_level_valuesr�   r,  ÚstartÚstopÚ	TypeError)rZ   r•   ry   r—   s       r\   rþ   z_LocIndexer._validate_key­  sÀ   € ð0 �X‰X×Ñ Ó%ˆÜ�cœ4Ô Ü˜"Ÿ(™(Ô#Ø�x‰x�}‰} 	Ò)ä˜2œzÔ*Ü! "×"5Ñ"5°aÓ"8×">Ñ">Ô?ô Ø�%ÐNÐOóð ô �cœ5Ô!Ü�s—y‘y¤$Ô'¬:°c·h±hÄÔ+Eä˜s˜eÐ#NÐOÓPÐPð ,Fð "r^   c                 ó   — y)NTrY   rL  s     r\   rØ   z&_LocIndexer._has_valid_setitem_indexer×  s   € Ør^   c                ó$  — t        |«      | j                  k7  ryt        |«      D ]i  \  }}t        |«      s y| j                  j
                  |   }t        |t        «      r yt        |t        «      r|j                  r y|j                  rŒi y y)r  FT)r�   r�   r  r%   r   r  r‰   rC   rw   Ú!_supports_partial_string_indexingÚ_index_as_unique)rZ   r•   rœ   r²   r—   s        r\   rB  z_LocIndexer._is_scalar_accessÚ  s   € ô ˆs‹8�t—y‘yÒ Øä˜c“Nò 	‰DˆAˆqÜ˜Q”<Ùà—‘—‘˜qÑ!ˆBÜ˜"œjÔ)Ùä˜!œSÔ! b×&JÒ&Jñ à×&Ó&Ùð	ð  r^   c                óN   — t        d„ |D «       «      syt        d„ |D «       «       S )a§  
        Check whether there is the possibility to use ``_multi_take``.

        Currently the limit is that all axes being indexed, must be indexed with
        list-likes.

        Parameters
        ----------
        tup : tuple
            Tuple of indexers, one per axis.

        Returns
        -------
        bool
            Whether the current indexing,
            can be passed through `_multi_take`.
        c              3  ó2   K  — | ]  }t        |«      –— Œ y ­wrX   )r?   rÊ   s     r\   r³   z6_LocIndexer._multi_take_opportunity.<locals>.<genexpr>  s   è ø€ Ò8¨qÔ'¨×*Ñ8ùr´   Fc              3  óF   K  — | ]  }t        j                  |«      –— Œ y ­wrX   )rž   rŸ   rÊ   s     r\   r³   z6_LocIndexer._multi_take_opportunity.<locals>.<genexpr>  s   è ø€ Ò;°!”s×*Ñ*¨1×-Ñ;ùs   ‚!)r»   r  r  s     r\   Ú_multi_take_opportunityz#_LocIndexer._multi_take_opportunityü  s+   € ô$ Ñ8°CÔ8Ô8Øô Ñ;°sÔ;Ó;Ð;Ð;r^   c           	     óÒ   — t        || j                  j                  d¬«      D ��ci c]  \  }}|| j                  ||«      “Œ }}}| j                  j	                  |d¬«      S c c}}w )a±  
        Create the indexers for the passed tuple of keys, and
        executes the take operation. This allows the take operation to be
        executed all at once, rather than once for each dimension.
        Improving efficiency.

        Parameters
        ----------
        tup : tuple
            Tuple of indexers, one per axis.

        Returns
        -------
        values: same type as the object being indexed
        Træ   ©Ú
allow_dups)rï   r   Ú_AXIS_ORDERSÚ_get_listlike_indexerÚ_reindex_with_indexers)rZ   r  r•   ry   Úds        r\   Ú_multi_takez_LocIndexer._multi_take  sk   € ô&  # 3¨¯©×(=Ñ(=ÀdÔK÷
á��dð �$×,Ñ,¨S°$Ó7Ñ7ð
ˆñ 
ð �x‰x×.Ñ.¨q¸TÐ.ÓBÐBùó	
s   ¦A#c                ó’   — | j                  ||«       | j                  ||«      \  }}| j                  j                  |||gid¬«      S )aé  
        Index current object with an iterable collection of keys.

        Parameters
        ----------
        key : iterable
            Targeted labels.
        axis : int
            Dimension on which the indexing is being made.

        Raises
        ------
        KeyError
            If no key was found. Will change in the future to raise if not all
            keys were found.

        Returns
        -------
        scalar, DataFrame, or Series: indexed value(s).
        Trk  )rþ   rn  r   ro  )rZ   r•   ry   Úkeyarrr¨   s        r\   Ú_getitem_iterablez_LocIndexer._getitem_iterable-  sW   € ð. 	×Ñ˜3 Ô%ð ×4Ñ4°S¸$Ó?‰ˆ�Ø�x‰x×.Ñ.Ø�F˜GÐ$Ð%°$ð /ó 
ð 	
r^   c                ó  — t        t        «      5  | j                  |«      }| j                  |«      cd d d «       S # 1 sw Y   nxY w| j	                  |«      }| j                  |«      r| j                  |«      S | j                  |«      S rX   )r   r   r  r4  r  ri  rq  r(  r  s     r\   rD  z_LocIndexer._getitem_tupleL  s�   € Ü”mÓ$ñ 	/Ø×'Ñ'¨Ó,ˆCØ×)Ñ)¨#Ó.÷	/÷ 	/ò 	/úð
 ×*Ñ*¨3Ó/ˆð ×'Ñ'¨Ô,Ø×#Ñ# CÓ(Ð(à×+Ñ+¨CÓ0Ð0s	   �"<¼Ac                ó<   — | j                   j                  ||¬«      S r  )r   Úxs)rZ   Úlabelry   s      r\   Ú
_get_labelz_LocIndexer._get_labelZ  s   € à�x‰x�{‰{˜5 tˆ{Ó,Ð,r^   c                ó  — | j                   xs d}	 | j                  ||¬«      S # t        $ rP}| j                  t	        |«      cxk  r$| j
                  j                  j                  k  r|‚ t        d«      |‚d }~ww xY w)Nr   r…   zNo label returned)	ry   ry  r�   r�   r�   r   rä   Únlevelsr   )rZ   r  ry   Úeks       r\   r/  z._LocIndexer._handle_lowerdim_multi_index_axis0^  st   € à�y‰yŠ~˜Aˆð		=à—?‘? 3¨T�?Ó2Ð2øäò 	=ð �y‰yœ3˜s›8Ô= t§x¡x§~¡~×'=Ñ'=Ò=Ø�ð >äÐ 3Ó4¸"Ð<ûð	=ús   ’% ¥	A>®AA9Á9A>c                ó4  — t        |«      }t        |«      rt        |«      }|t        u rt	        d «      }| j
                  j                  |«      }t        |t        «      rt        |t        «      rt        |«      }t        |t        «      r%| j                  ||«       | j                  ||¬«      S t        j                  |«      r| j                  ||¬«      S t        |«      �r‚t        |t        «      rt        |t        «      s9t!        |d«      r|j"                  dkD  rt%        d«      ‚| j'                  ||¬«      S t)        ||«      �r|j+                  |«      }t	        d «      g| j"                  z  }|||<   | j
                  j,                  t        |«         }t/        d„ |D «       «      }|sµg }t1        |«      D ]c  \  }	}
t3        |
«      s|j5                  |	«       Œ#t        |
t        «      sŒ4	 |j6                  |	   j9                  |
«       |j5                  |	«       Œe |r@t=        |«      |j>                  k\  r|jA                  d|¬«      }|S |jC                  ||¬«      }|S | j                  ||«       | jE                  ||¬«      S # t:        $ r Y ŒÚw xY w)Nr…   r�   r›   z&Cannot index with multidimensional keyc              3  ój   K  — | ]+  }t        |t        «      xs t        j                  |«      –— Œ- y ­wrX   )r‰   r,  rž   rŸ   r°   s     r\   r³   z,_LocIndexer._getitem_axis.<locals>.<genexpr>‘  s/   è ø€ ò (ØGH”J˜q¤%Ó(ÒB¬C×,?Ñ,?ÀÓ,BÓBñ(ùs   ‚13r   )#r   r!   r“   r  r,  r   rŽ   r‰   rŠ   rC   rþ   Ú_get_slice_axisrž   rŸ   rR  r?   r9  r�   r  rt  r  Úget_locsrh   r  r  r"   ÚappendÚlevelsr�   r�   r�   r{  Ú_ixsÚ	droplevelry  )rZ   r•   ry   rP  Úlocsr¨   ÚresultÚhas_slice_or_maskÚlevels_to_droprö   r²   s              r\   r%  z_LocIndexer._getitem_axisl  sY  € Ü Ó$ˆÜ�sÔÜ�s“)ˆCØ”(‰?Ü˜“+ˆCà—‘×#Ñ# DÓ)ˆä�cœ5Ô!¤j°¼Ô&DÜ˜“*ˆCä�cœ5Ô!Ø×Ñ˜s DÔ)Ø×'Ñ'¨°$Ð'Ó7Ð7Ü× Ñ  Ô%Ø×%Ñ% c°Ð%Ó5Ð5Ü! #Õ&ä˜s¤EÔ*¬z¸&Ä*Ô/MÜ˜3 Ô'¨C¯H©H°qªLÜ$Ð%MÓNÐNà×-Ñ-¨c¸Ð-Ó=Ð=ô ˜s FÕ+Ø—‘ sÓ+�Ü?DÀT»{¸mÈdÏiÉiÑ>W�Ø $�˜‘ØŸ™Ÿ™¤u¨W£~Ñ6�ô %(ñ (ØLOô(ó %Ð!ñ )Ø%'�NÜ"+¨C£.ò 
%™˜˜QÜ+¨AœØ*×1Ñ1°#Õ6Ü'¨¬5Õ1ð%Ø &§¡¨cÑ 2× :Ñ :¸1Ô =Ø .× 5Ñ 5°cÕ :ð
%ñ &Ü˜~Ó.°&·.±.Ò@ð &,§[¡[°¸ [Ó%>˜Fð �ð &,×%5Ñ%5°nÈ4Ð%5Ó%P˜Fà�ð 	×Ñ˜3 Ô%Ø�‰˜s¨ˆÓ.Ð.øô $,ò %Ù $ð%ús   Ç1/JÊ	JÊJc                ól  — | j                   }t        |«      s|j                  d¬«      S |j                  |«      }|j	                  |j
                  |j                  |j                  «      }t        |t        «      r| j                   j                  ||¬«      S | j                   j                  ||¬«      S )zL
        This is pretty simple as we just have to deal with labels.
        Fr   r…   )r   r1  r·   rŽ   Úslice_indexerr_  r`  Ústepr‰   r,  Ú_slicerO  )rZ   Ú	slice_objry   r   rP  r¨   s         r\   r  z_LocIndexer._get_slice_axis°  sŽ   € ð
 �h‰hˆÜ˜)Ô$Ø—8‘8 �8Ó'Ð'à—‘˜tÓ$ˆØ×&Ñ& y§¡¸	¿¹È	ÏÉÓWˆä�gœuÔ%Ø—8‘8—?‘? 7°�?Ó6Ð6ð —8‘8—=‘= ¨t�=Ó4Ð4r^   c                óx  — | j                   j                  |«      }t        |t        «      r|j	                  |d¬«      S t        |t
        «      r8t        |t        «      s(| j                  dk  rt        |«      dkD  rt        d«      ‚d}t        |t
        «      rt        d„ |D «       «      }t        |«      st        |t        «      rt        |«      r|s	 |j                  |«      S t'        ||«      r=| j                  dk(  rt        d	„ |D «       «      rt        d«      ‚|j)                  |«      S t+        |«      rNt-        |«      rt/        |«      }t1        j2                  |«      rt5        ||«      }|S | j7                  ||«      d   S 	 |j                  |«      S # t        $ rB t        |t
        «      r/t        |t        «      rt        |«      |j                  k(  rd|icY S ‚ Y Œþt         $ r t        |t        «      s‚ Y �Œt"        $ r t%        |«      s‚ d|icY S w xY w# t        $ r t+        |«      sd|icY S ‚ w xY w)
aÒ  
        Convert indexing key into something we can use to do actual fancy
        indexing on an ndarray.

        Examples
        ix[:5] -> slice(0, 5)
        ix[[1,2,3]] -> [1,2,3]
        ix[['foo', 'bar', 'baz']] -> [i, j, k] (indices of foo, bar, baz)

        Going by Zen of Python?
        'In the face of ambiguity, refuse the temptation to guess.'
        raise AmbiguousIndexError with integer labels?
        - No, prefer label-based indexing
        rl   )r¥   rš   r›   r  Fc              3  ó<   K  — | ]  }t        |t        «      –— Œ y ­wrX   r+  )r±   Úvs     r\   r³   z2_LocIndexer._convert_to_indexer.<locals>.<genexpr>ã  s   è ø€ Ò C¸!¤¨A¬u×!5Ñ Cùr  r•   c              3  ó<   K  — | ]  }t        |t        «      –— Œ y ­wrX   r8  r°   s     r\   r³   z2_LocIndexer._convert_to_indexer.<locals>.<genexpr>ü  s   è ø€ Ò%H¸q¤j°´E×&:Ñ%Hùr  )r   rŽ   r‰   r,  Ú_convert_slice_indexerrŠ   rC   r�   r�   r   r  r%   r   r�   ÚLookupErrorr{  r   r  r    r  r€  r?   r!   r“   rž   rŸ   rN  rn  )rZ   r•   ry   rP  Úcontains_slices        r\   r”   z_LocIndexer._convert_to_indexerÃ  sÿ  € ð —‘×#Ñ# DÓ)ˆä�cœ5Ô!Ø×0Ñ0°¸5Ð0ÓAÐAô �sœEÔ"Ü˜v¤zÔ2Ø—	‘	˜A’Ü�C“˜1’äÐ 3Ó4Ð4ð ˆÜ�cœ5Ô!Ü Ñ C¸sÔ CÓCˆNä�SŒ>Ü�vœzÔ*¬{¸3Ô/?Éð
$Ø—~‘~ cÓ*Ð*ô ˜3 Ô'Ø�y‰y˜AŠ~¤#Ñ%HÀCÔ%HÔ"Hä#Ð$7Ó8Ð8Ø—?‘? 3Ó'Ð'ä! #Ô&Ü˜3ÔÜ˜3“i�ä×"Ñ" 3Ô'Ü(¨°Ó5�Ø�
à×1Ñ1°#°tÓ<¸QÑ?Ð?ðØ—~‘~ cÓ*Ð*øô? ò Ü˜c¤5Ô)¬j¸ÄÔ.LÜ˜3“x 6§>¡>Ò1Ø % s˜|Ò+ØùÜ$ò ä! &¬*Ô5Øò 6äò $Ü! #”ØØ˜s�|Ò#ð$ûô. ò ä+¨CÔ0Ø! 3˜<Ò'Øð	ús7   ÃF ÆH ÆAHÇ HÇ#HÇ?HÈHÈH9È7H9c                ó    — | j                   j                  |«      }| j                   j                  |«      }|j                  ||«      \  }}||fS )aJ  
        Transform a list-like of keys into a new index and an indexer.

        Parameters
        ----------
        key : list-like
            Targeted labels.
        axis:  int
            Dimension on which the indexing is being made.

        Raises
        ------
        KeyError
            If at least one key was requested but none was found.

        Returns
        -------
        keyarr: Index
            New index (coinciding with 'key' if the axis is unique).
        values : array-like
            Indexer for the return object, -1 denotes keys not found.
        )r   rŽ   Ú_get_axis_nameÚ_get_indexer_strict)rZ   r•   ry   r—   Ú	axis_namers  r¨   s          r\   rn  z!_LocIndexer._get_listlike_indexer  sL   € ð. �X‰X×Ñ Ó%ˆØ—H‘H×+Ñ+¨DÓ1ˆ	à×0Ñ0°°iÓ@‰ˆ�à�wˆÐr^   N)ry   rG   r_   rT  rY  ©r•   rŠ   r_   rz   rV  rW  rX  ©r�  r,  ry   rH   )r`   ra   rb   rc   r{   rZ  rx   rþ   rØ   rB  ri  rq  rt  rD  ry  r/  r%  r  r”   rn  rY   r^   r\   rm   rm   U  sh   … ñKðZ
 €IˆtÓð	:ð ó(QóTóóD<ó0Có2
ó>1ó-ó=óB/óH5ó&Nô`r^   rm   c                  óÞ   — e Zd ZdZdZdZdd„Zdd„Zdd„Zdd„Z	dd„Z
d d	„Zd d
„Zd!d„Zd"d„Zd„ Zdd„Zd#d„Zd$d#d„Zd%d„Zd&d„Z	 	 	 	 	 	 d'd„Zd(d„Zd#d„Zd„ Zd„ Z	 d)	 	 	 	 	 d*d„Zd+d„Zy),ri   a“  
    Purely integer-location based indexing for selection by position.

    .. versionchanged:: 3.0

       Callables which return a tuple are deprecated as input.

    ``.iloc[]`` is primarily integer position based (from ``0`` to
    ``length-1`` of the axis), but may also be used with a boolean
    array.

    Allowed inputs are:

    - An integer, e.g. ``5``.
    - A list or array of integers, e.g. ``[4, 3, 0]``.
    - A slice object with ints, e.g. ``1:7``.
    - A boolean array.
    - A ``callable`` function with one argument (the calling Series or
      DataFrame) and that returns valid output for indexing (one of the above).
      This is useful in method chains, when you don't have a reference to the
      calling object, but would like to base your selection on
      some value.
    - A tuple of row and column indexes. The tuple elements consist of one of the
      above inputs, e.g. ``(0, 1)``.

    ``.iloc`` will raise ``IndexError`` if a requested indexer is
    out-of-bounds, except *slice* indexers which allow out-of-bounds
    indexing (this conforms with python/numpy *slice* semantics).

    See more at :ref:`Selection by Position <indexing.integer>`.

    See Also
    --------
    DataFrame.iat : Fast integer location scalar accessor.
    DataFrame.loc : Purely label-location based indexer for selection by label.
    Series.iloc : Purely integer-location based indexing for
                   selection by position.

    Examples
    --------
    >>> mydict = [
    ...     {"a": 1, "b": 2, "c": 3, "d": 4},
    ...     {"a": 100, "b": 200, "c": 300, "d": 400},
    ...     {"a": 1000, "b": 2000, "c": 3000, "d": 4000},
    ... ]
    >>> df = pd.DataFrame(mydict)
    >>> df
          a     b     c     d
    0     1     2     3     4
    1   100   200   300   400
    2  1000  2000  3000  4000

    **Indexing just the rows**

    With a scalar integer.

    >>> type(df.iloc[0])
    <class 'pandas.Series'>
    >>> df.iloc[0]
    a    1
    b    2
    c    3
    d    4
    Name: 0, dtype: int64

    With a list of integers.

    >>> df.iloc[[0]]
       a  b  c  d
    0  1  2  3  4
    >>> type(df.iloc[[0]])
    <class 'pandas.DataFrame'>

    >>> df.iloc[[0, 1]]
         a    b    c    d
    0    1    2    3    4
    1  100  200  300  400

    With a `slice` object.

    >>> df.iloc[:3]
          a     b     c     d
    0     1     2     3     4
    1   100   200   300   400
    2  1000  2000  3000  4000

    With a boolean mask the same length as the index.

    >>> df.iloc[[True, False, True]]
          a     b     c     d
    0     1     2     3     4
    2  1000  2000  3000  4000

    With a callable, useful in method chains. The `x` passed
    to the ``lambda`` is the DataFrame being sliced. This selects
    the rows whose index label even.

    >>> df.iloc[lambda x: x.index % 2 == 0]
          a     b     c     d
    0     1     2     3     4
    2  1000  2000  3000  4000

    **Indexing both axes**

    You can mix the indexer types for the index and columns. Use ``:`` to
    select the entire axis.

    With scalar integers.

    >>> df.iloc[0, 1]
    2

    With lists of integers.

    >>> df.iloc[[0, 2], [1, 3]]
          b     d
    0     2     4
    2  2000  4000

    With `slice` objects.

    >>> df.iloc[1:3, 0:3]
          a     b     c
    1   100   200   300
    2  1000  2000  3000

    With a boolean array whose length matches the columns.

    >>> df.iloc[:, [True, False, True, False]]
          a     c
    0     1     3
    1   100   300
    2  1000  3000

    With a callable function that expects the Series or DataFrame.

    >>> df.iloc[:, lambda df: [0, 2]]
          a     c
    0     1     3
    1   100   300
    2  1000  3000
    zlinteger, integer slice (START point is INCLUDED, END point is EXCLUDED), listlike of integers, boolean arrayTc                óÄ  — t        j                  |«      rLt        |d«      r?t        |j                  t
        «      r%|j                  j                  dk(  ry t        d«      ‚y t        |t        «      ry t        |«      r| j                  ||«       y t        |t        «      rt        d«      ‚t        |«      �rt        |t        «      r|j                  }n#t!        |«      r|}nt#        j$                  |«      }t'        | j(                  j+                  |«      «      }t-        |j.                  «      st1        d|› �«      ‚t'        |«      r~t        |j.                  t2        «      r#|j5                  d«      }|j5                  d«      }n*t#        j6                  |«      }t#        j8                  |«      }||k\  s|| k  rt1        d«      ‚y y t        d	| j:                  › d
�«      ‚)Nrä   ÚintegerzBiLocation based boolean indexing cannot use an indexable as a maskr  z%.iloc requires numeric indexers, got ÚmaxÚminú%positional indexers are out-of-boundsz#Can only index by location with a [ú])rž   rŸ   r9  r‰   rä   rB   Úinferred_typer  r,  r    Ú_validate_integerrŠ   r   r?   r3   rê   r   r¢   r:   r�   r   rŽ   r#   r¤   Ú
IndexErrorr+   Ú_reducerž  rŸ  rx   )rZ   r•   ry   ÚarrÚlen_axisÚarr_maxÚarr_mins          r\   rþ   z_iLocIndexer._validate_keyË  s�  € Ü×Ñ˜sÔ#Ü�s˜GÔ$¬°C·I±I¼uÔ)EØ—9‘9×*Ñ*¨iÒ7ØÜ ØXóð ð ä�cœ5Ô!ØÜ˜Œ_Ø×"Ñ" 3¨Õ-Ü˜œUÔ#ô  Ð 3Ó4Ð4Ü! #Õ&Ü˜#œyÔ)Ø—k‘k‘Ü3°CÔ8Ø‘ä—h‘h˜s“m�Ü˜4Ÿ8™8×-Ñ-¨dÓ3Ó4ˆHô $ C§I¡IÔ.Ü Ð#HÈÈÐ!NÓOÐOä�3ŒxÜ˜cŸi™i¬Ô8Ø!Ÿk™k¨%Ó0�GØ!Ÿk™k¨%Ó0‘Gä Ÿf™f S›k�GÜ Ÿf™f S›k�Gð ˜hÒ&¨'°X°IÒ*=Ü$Ð%LÓMÐMð +>ð ô ÐBÀ4×CTÑCTÐBUÐUVÐWÓXÐXr^   c                óÊ  — t        |t        «      rt        d«      ‚t        |t        «      rt	        d«      ‚t        |t
        «      st        | j                  |«      }t        | j                  j                  |d¬«      D ]b  \  }}t        |t        «      rŒt        |«      rŒ#t        |«      r|t        |«      k\  sŒ=t        d«      ‚t        |t        «      sŒYt        d«      ‚ y)zÂ
        Validate that a positional indexer cannot enlarge its target
        will raise if needed, does not modify the indexer externally.

        Returns
        -------
        bool
        z%iloc cannot enlarge its target objectzsDataFrame indexer for .iloc is not supported. Consider using .loc with a DataFrame indexer for automatic alignment.Fræ   T)r‰   Údictr¤  r0   ra  rŠ   Ú_tuplifyr�   rï   r   r  r,  r?   r    r�   )rZ   r¨   r—   rœ   s       r\   rØ   z'_iLocIndexer._has_valid_setitem_indexerø  sÊ   € ô �gœtÔ$ÜÐDÓEÐEä�gœ|Ô,ÜðXóð ô
 ˜'¤5Ô)Ü˜tŸy™y¨'Ó2ˆGä˜Ÿ™Ÿ™¨¸Ô>ò 	J‰EˆB�Ü˜!œUÔ#àÜ% aÔ(àÜ˜A”Øœ˜B›“<Ü$Ð%LÓMÐMÜ˜AœtÕ$Ü Ð!HÓIÐIð	Jð r^   c                óX   — t        |«      | j                  k7  ryt        d„ |D «       «      S )r  Fc              3  ó2   K  — | ]  }t        |«      –— Œ y ­wrX   )r    r°   s     r\   r³   z1_iLocIndexer._is_scalar_access.<locals>.<genexpr>)	  s   è ø€ Ò. Q”:˜a—=Ñ.ùr´   )r�   r�   r»   r  s     r\   rB  z_iLocIndexer._is_scalar_access	  s(   € ô ˆs‹8�t—y‘yÒ ØäÑ.¨#Ô.Ó.Ð.r^   c                óx   — t        | j                  j                  |«      «      }||k\  s|| k  rt        d«      ‚y)a@  
        Check that 'key' is a valid position in the desired axis.

        Parameters
        ----------
        key : int
            Requested position.
        axis : int
            Desired axis.

        Raises
        ------
        IndexError
            If 'key' is not a valid position in axis 'axis'.
        z*single positional indexer is out-of-boundsN)r�   r   rŽ   r¤  )rZ   r•   ry   r§  s       r\   r£  z_iLocIndexer._validate_integer+	  s=   € ô  �t—x‘x×)Ñ)¨$Ó/Ó0ˆØ�(Š?˜c X IšoÜÐIÓJÐJð .r^   c                ó²   — | j                  |«      }t        t        «      5  | j                  |«      cd d d «       S # 1 sw Y   nxY w| j	                  |«      S rX   )r  r   r   r4  r(  r  s     r\   rD  z_iLocIndexer._getitem_tupleA	  sP   € Ø×*Ñ*¨3Ó/ˆÜ”mÓ$ñ 	/Ø×)Ñ)¨#Ó.÷	/÷ 	/ò 	/úð ×+Ñ+¨CÓ0Ð0s	   ¡<¼Ac                óx   — 	 | j                   j                  ||¬«      S # t        $ r}t        d«      |‚d}~ww xY w)a  
        Return Series values by list or array of integers.

        Parameters
        ----------
        key : list-like positional indexer
        axis : int

        Returns
        -------
        Series object

        Notes
        -----
        `axis` can only be zero.
        r…   r   N)r   rO  r¤  )rZ   r•   ry   r  s       r\   Ú_get_list_axisz_iLocIndexer._get_list_axisH	  s?   € ð"	OØ—8‘8—=‘= ¨4�=Ó0Ð0øÜò 	OäÐDÓEÈ3ÐNûð	Oús   ‚ Ÿ	9¨4´9c                ól  — |t         u rt        d «      }nt        |t        «      rt	        d«      ‚t        |t        «      r| j                  ||¬«      S t        |«      rt        |«      }t        |t        «      rt        j                  |«      }t        j                  |«      r%| j                  ||«       | j                  ||¬«      S t        |«      r| j                  ||¬«      S t!        |«      }t#        |«      st%        d«      ‚| j'                  ||«       | j(                  j+                  ||¬«      S )NzWDataFrame indexer is not allowed for .iloc
Consider using .loc for automatic alignment.r…   z5Cannot index by location index with a non-integer key)r  r,  r‰   r0   r¤  r  r!   r“   r¢   Úasarrayrž   rŸ   rþ   rR  r?   r²  r   r    ra  r£  r   rƒ  rý   s      r\   r%  z_iLocIndexer._getitem_axis_	  s  € Ø”(‰?Ü˜“+‰CÜ˜œ\Ô*Üð?óð ô
 �cœ5Ô!Ø×'Ñ'¨°$Ð'Ó7Ð7ä�sÔÜ�s“)ˆCä�cœ4Ô Ü—*‘*˜S“/ˆCä×Ñ˜sÔ#Ø×Ñ˜s DÔ)Ø×%Ñ% c°Ð%Ó5Ð5ô " #Ô&Ø×&Ñ& s°Ð&Ó6Ð6ô $ CÓ(ˆCÜ˜c”?ÜÐ WÓXÐXð ×"Ñ" 3¨Ô-à—8‘8—=‘= ¨4�=Ó0Ð0r^   c                óÒ   — | j                   }t        |«      s|j                  d¬«      S |j                  |«      }|j	                  |«       | j                   j                  ||¬«      S )NFr   r…   )r   r1  r·   rŽ   Ú_validate_positional_slicerŒ  )rZ   r�  ry   r   rP  s        r\   r  z_iLocIndexer._get_slice_axis„	  sW   € à�h‰hˆä˜)Ô$Ø—8‘8 �8Ó'Ð'à—‘˜tÓ$ˆØ×)Ñ)¨)Ô4Ø�x‰x�‰˜y¨tˆÓ4Ð4r^   c                ó   — |S )zL
        Much simpler as we only have to deal with our valid types.
        rY   rý   s      r\   r”   z _iLocIndexer._convert_to_indexer�	  s	   € ð ˆ
r^   c                óŒ   — t        |«      rt        |«      }| j                  �!t        | j                  | j                  |«      }|S rX   )r!   r“   ry   rŒ   r�   r  s     r\   r˜   z!_iLocIndexer._get_setitem_indexer•	  s8   € ä�sÔÜ�s“)ˆCà�9‰9Ð Ü(¨¯©°D·I±I¸sÓCˆCàˆ
r^   c                ó<  — | j                   j                  j                   }|s't        |t        «      r|j                  j                   }|s¨t        | j                   j                  j                  «      r| j                  dkD  rpt        |t        «      rt        |j                  «       «      n|}| j                   j                  j                  d   j                  }t        |t        |d¬«      «       }t        |t        «      r‹t        |«      t        | j                   j                  «      k(  r`t        || j                   j                  d¬«      D ];  \  }}t        |t         «      sŒt#        |«      rŒ#t%        j&                  |«      rŒ9d} n |sŠt        |t        «      rzt        |«      dk(  rlt#        |d   «      r^t#        |d   «      sPt)        |«      rEt        |t*        t        f«      s/| j                   j                  j                  d   j,                  rd}|S )zD
        Decide whether we will take a block-by-block path.
        r›   r   T©Úextract_numpyræ   rš   )r   r¿   Úis_single_blockr‰   r0   r�   Úblocksr�   r«  r“   Úvaluesr   r<   rŠ   r  rï   rC   r    rž   r#  r"   r3   Úis_extension)rZ   r¨   r©   Útake_split_pathÚvalr¦  rœ   r—   s           r\   Ú_decide_split_pathz_iLocIndexer._decide_split_path¡	  s�  € ð #Ÿh™hŸm™m×;Ñ;Ð;ˆá¤:¨e´\Ô#Bà"'§*¡*×"<Ñ"<Ð<ˆOñ ¤3 t§x¡x§}¡}×';Ñ';Ô#<ÀÇÁÈQÂä*4°U¼DÔ*A”$�u—|‘|“~Ô&ÀuˆCØ—(‘(—-‘-×&Ñ& qÑ)×0Ñ0ˆCÜ"2Ø”] 3°dÔ;ó#ð ˆOô �gœuÔ%¬#¨g«,¼#¸d¿h¹h¿m¹mÓ:LÒ*LÜ˜W d§h¡h§m¡m¸DÔAò ‘��2Ü˜b¤*Õ-Ü˜q•M¤S×%6Ñ%6°qÕ%9à&*�OÙðñ  Ü˜7¤EÔ*Ü�G“ Ò!Ü˜7 1™:Ô&Ü˜w q™zÔ*Ü˜UÔ#Ü˜u¤y´,Ð&?Ô@à—‘—‘×$Ñ$ QÑ'×4Ò4à"ˆOàÐr^   c           
     ó4  — t        |t        «      rddlm}  ||«      }t	        | j
                  «      s&t        |«      st        d«      ‚|| j
                  |<   yt        j                  |d   «      r|| j
                  |<   yt        |«      rÓt        |d¬«      }dt        j                  t	        | j
                  «      t        j                  ¬«      z  }t        j                   ||«      }t        |t"        «      sTt        |t        j$                  «      r"|j&                  d	k(  rt	        |«      d	k(  r|d   }|||d   <   || j
                  |<   y|| j
                  |<   �nt)        |«      s-t+        |t	        | j
                  «      «      | j
                  |<   nÎt-        |t/        t1        t	        |«      «      «      d
¬«      }dt        j                  t	        | j
                  «      t        j                  ¬«      z  }t        j                   ||«      }t        |t        j$                  «      r"|j&                  d	k(  rt	        |«      d	k(  r|d   }|||d   <   || j
                  |<   yt3        || j
                  j4                  «      }	| j7                  |	||«       y)zX
        _setitem_with_indexer cases that can go through DataFrame.__setitem__.
        r   ©rN   z5cannot set a frame with no defined index and a scalarNTrº  r-  râ   r›   Fr¶   )r‰   r«  rd   rN   r�   r   r?   r  rž   r#  r   r<   r¢   ÚonesÚintpÚalgosÚtake_ndr3   r£   r�   r"   r5   r=   rB   r’   Ú"convert_from_missing_indexer_tupler  rÚ   )
rZ   r¨   r•   r©   r~   rN   r¦  ÚtakerÚempty_valueÚnew_indexers
             r\   Ú_setitem_new_columnz _iLocIndexer._setitem_new_columnÔ	  s  € ô �eœTÔ"Ý%á˜5“MˆEô �4—8‘8Œ}Ü'¨Ô.Ü ØKóð ð "ˆD�H‰H�S‰MØô ×Ñ˜W Q™ZÔ(à!ˆD�H‰H�S‰MØÜ/°Ô6ä °TÔ:ˆCØœŸ™¤ T§X¡X£´b·g±gÔ>Ñ>ˆEÜŸ-™-¨¨UÓ3ˆKÜ˜e¤YÔ/ô ˜c¤2§:¡:Ô.°3·8±8¸q²=ÄSÈÃXÐQRÂ]Ø˜a™&�CØ*-�˜G A™JÑ'Ø +�—‘˜‘Øà'ˆD�H‰H�S‹MÜ˜eÔ$ÜGØ”s˜4Ÿ8™8“}óˆD�H‰H�SŠMô ! ¬¬e´C¸³JÓ.?Ó(@ÀuÔMˆCØœŸ™¤ T§X¡X£´b·g±gÔ>Ñ>ˆEÜŸ-™-¨¨UÓ3ˆKÜ˜#œrŸz™zÔ*¨s¯x©x¸1ª}ÄÀSÃÈQÂØ˜!‘f�Ø&)ˆK˜ ™
Ñ#Ø'ˆD�H‰H�S‰MØä8¸À$Ç(Á(Ç-Á-ÓPˆØ×"Ñ" ;°°tÔ<àr^   c                óÜ  — | j                   j                  }| j                  ||«      }t        |t        «      �rMg }t        |«      D �]0  \  }}t        |«      \  }}	|	�r|}
| j                  dkD  r||k(  r| j                  ||
||¬«        y| j                   j                  |«      }t        ||
dd¬«       |j                  t        |«      |
«      }t        j                  t        |«      dz   t        j                  ¬«      }d|d<   |||fi}| j                   j!                  |d	¬
«      }|j"                  | j                   _        |j%                  |j'                  |
«      «       �Œ |j%                  |«       �Œ3 t	        |«      }n#t        |«      \  }}	|	r| j)                  ||«       y|dk(  r| j+                  ||«      \  }}|r| j-                  |||«       y| j/                  |||«       y)zÓ
        _setitem_with_indexer is for setting values on a Series/DataFrame
        using positional indexers.

        If the relevant keys are not present, the Series/DataFrame may be
        expanded.
        r›   ©r~   Núrow on a DataFrameú$Use a full-length tuple key instead.©ÚtargetÚhintrâ   r-  Trk  rl   )r   Ú_info_axis_numberrÂ  r‰   rŠ   r  Úconvert_missing_indexerr�   rÍ  rŽ   Úmaybe_warn_multiindex_expansionÚinsertr�   r¢   ÚarangerÆ  ro  r¿   r�  r�   Ú_setitem_with_indexer_missingr­   Ú _setitem_with_indexer_split_pathÚ_setitem_single_block)rZ   r¨   r©   r~   Ú	info_axisrÀ  Únindexerrœ   rö   Úmissingr•   rä   rP  rÊ  Ú
reindexersÚnew_objs                   r\   rÚ   z"_iLocIndexer._setitem_with_indexer
  sÐ  € ð —H‘H×.Ñ.ˆ	Ø×1Ñ1°'¸5ÓAˆä�gœuÕ%ØˆHÜ# GÓ,ó ()‘��3Ü6°sÓ;‘��WÚð �Cð —y‘y 1’}¨¨iªØ×0Ñ0°¸#¸uÈ4Ð0ÔPÙð !ŸH™H×.Ñ.¨qÓ1�EÜ3ØØØ3ØCõ	ð #Ÿ\™\¬#¨e«*°cÓ:�Fô
 ŸI™I¤c¨%£j°1¡n¼B¿G¹GÔD�EØ "�E˜"‘IØ"# f¨e _Ð!5�JØ"Ÿh™h×=Ñ=Ø"¨tð >ó �Gð %,§L¡L�D—H‘H”Mà—O‘O F§N¡N°3Ó$7Ö8ð —O‘O CÖ(ðQ()ôT ˜H“o‰Gä6°wÓ?ÑˆG�WáØ×2Ñ2°7¸EÔBØà�5Š=à!×;Ñ;¸GÀUÓK‰NˆG�Uñ à×1Ñ1°'¸5À$ÕGà×&Ñ& w°°tÕ<r^   c                ó¼  — | j                   dk(  sJ ‚t        |t        «      st        | j                   |«      }t	        |«      | j                   kD  rt        d«      ‚t        |d   t        j                  «      r|d   j                   dkD  rt        d«      ‚t        |t        «      r|dk7  st        |t        «      rddlm} | j                  | ||«      «      }|d   }| j                  |«      }|d   }t        || j                   j"                  «      }t%        |«      �r$t'        |dd«      dkD  �rt        |t(        «      r| j+                  |||«       yt-        |t	        |«      «      r| j/                  ||«       yt	        |«      dk(  r0|t	        |«      k(  r"t1        |«      s| j3                  |d   ||«       y| j5                  |«      rFt7        | j                   j8                  j:                  |d      «      r| j3                  |d   ||«       yt	        |«      dk(  rUd|cxk7  rt	        |«      k7  rAn n>t	        |«      dk(  r%t=        |«      s| j?                  ||d   f|d   «      S t        d	«      ‚|dk(  r,t	        |«      t	        | j                   j"                  «      k(  ryt	        |«      t	        |«      k(  r*tA        ||d
¬«      D ]  \  }	}
| j3                  |	|
|«       Œ yt	        |«      dk(  rDtC        jD                  |«      r/t	        | j                   «      dk(  r| j3                  |d   ||«       yt        d	«      ‚|D ]  }	| j3                  |	||«       Œ y)z&
        Setitem column-wise.
        rš   ztoo many indices for arrayr   zCannot set values with ndim > 2rh   rÄ  r›   r�   z@Must have equal len keys and value when setting with an iterableTræ   N)#r�   r‰   rŠ   r¬  r�   r¤  r¢   r£   r  r3   r«  rd   rN   r¡   Ú_ensure_iterable_column_indexerrA   r   rä   r?   r$  r0   Ú!_setitem_with_indexer_frame_valueÚ_is_2d_value_for_columnsÚ_setitem_with_indexer_2d_valuer%   Ú_setitem_single_columnrB  r$   Údtypesrê   r    rÚ   rï   rž   r#  )rZ   r¨   r©   r~   rN   rÝ  Úilocsrª   Úlplane_indexerrl   r�  s              r\   rÛ  z-_iLocIndexer._setitem_with_indexer_split_path_
  sì  € ð
 �y‰y˜AŠ~Ðˆ~ä˜'¤5Ô)Ü˜tŸy™y¨'Ó2ˆGÜˆw‹<˜$Ÿ)™)Ò#ÜÐ9Ó:Ð:Ü�g˜a‘j¤"§*¡*Ô-°'¸!±*·/±/ÀAÒ2EÜÐ?Ó@Ð@ä�uœiÔ(¨T°Vª^Ä
È5ÔRVÔ@WÝ%à×&Ñ& w±°u³Ó>ˆEð ˜A‘Jˆ	Ø×4Ñ4°YÓ?ˆà�Q‰ZˆÜ*¨2¨t¯x©x¯~©~Ó>ˆô
   Õ&¬7°5¸&À!Ó+DÀqÓ+HÜ˜%¤Ô.Ø×6Ñ6°wÀÀtÕLä)¨%´°U³Ô<Ø×3Ñ3°G¸UÕCä�U“˜q’ ^´s¸5³zÒ%AÌ)ÐTVÌ-à×+Ñ+¨E°!©H°e¸RÕ@à×'Ñ'¨Ô0´_Ø—‘—‘×'Ñ'¨¨a©Ñ1ô6ð
 ×+Ñ+¨E°!©H°e¸RÕ@ä�U“˜q’ Q¨.Ô%F¼CÀ»JÕ%Fô
 �u“: ’?¬:°iÔ+@ð  ×5Ñ5°r¸9ÀQ¹<Ð6HÈ%ÐPQÉ(ÓSÐSä ØVóð ð   1Ò$¬¨U«´s¸4¿8¹8¿>¹>Ó7JÒ)Jàä�U“œs 5›zÒ)ä! %¨°tÔ<ò <‘F�C˜Ø×/Ñ/°°Q¸Õ;ñ<ô �U“˜q’¤S×%6Ñ%6°rÔ%:¼sÀ4Ç8Á8»}ÐPQÒ?Qð ×+Ñ+¨E°!©H°e¸RÕ@ô !ØVóð ð ò <�Ø×+Ñ+¨C°¸Õ;ñ<r^   c                ó¸  — |d   }| j                  |d   «      }t        |t        «      s t        |«      st	        j
                  |«      }d}t        |t        «      r]t        |«      }g }|D ]H  }t        |«      |k7  rt        |«      ‚t        |«      t        urt        |«      }|j                  |«       ŒJ |}n&|j                  d   t        |«      k7  rt        |«      ‚t        |«      D ]i  \  }	}
t        |t        «      r|D �cg c]  }||	   ‘Œ	 }}n.|d d …|	f   }t        |j                  «      r|j                  «       }| j!                  |
||«       Œk y c c}w )Nr   r›   z?Must have equal len keys and value when setting with an ndarray)rã  r‰   r“   r   r¢   r´  r�   r  r}   Ú_positional_rowr�  r¦   r  r$   r¤   Útolistrç  )rZ   r¨   r©   rª   ré  ÚmsgÚnkeysÚrowsÚrowrœ   rl   Ú	value_cols               r\   ræ  z+_iLocIndexer._setitem_with_indexer_2d_value·
  sD  € ð �Q‰ZˆØ×4Ñ4°W¸Q±ZÓ@ˆä˜%¤Ô&Ô/QØô0
ô —J‘J˜uÓ%ˆEàOˆÜ�eœTÔ"Ü˜“JˆEØˆDØò !�Ü�s“8˜uÒ$Ü$ S›/Ð)Ü˜“9¤DÑ(Ü)¨#Ó.�CØ—‘˜CÕ ð!ð ‰EØ�[‰[˜‰^œs 5›zÒ)Ü˜S“/Ð!ä Ó&ò 	<‰FˆAˆsÜ˜%¤Ô&Ø/4Ö5¨˜S ›VÐ5�	Ñ5à!¢! Q $™K�	Ü" 9§?¡?Ô3Ø )× 0Ñ 0Ó 2�IØ×'Ñ'¨¨Y¸Õ;ñ	<ùâ5s   ÄEc                ó¬  — | j                  |d   «      }t        |«      }|d   }t        | j                  j                  t
        «      }|j                  j                  }|dk(  r:t        |«      D ]+  \  }	}
|j                  d d …|	f   }| j                  |
||«       Œ- y |sª|j                  j                  | j                  j                  «      r{|D ]u  }
| j                  j                  |
   }||v r3||d<   | j                  t        |«      |j                  d d …|
f   |«      }nt        j                  }| j                  |
||«       Œw y |st        d«      ‚|D ]y  }
| j                  j                  |
   }||v r7||d<   ||   }| j                  t        |«      ||«      }||j                   u r|}nt        j                  }| j                  |
||«       Œ{ y )Nr›   r   rh   z/Setting with non-unique columns is not allowed.)rã  r“   r‰   r   rº   rC   rî   r  rh   rç  Úequalsr¡   rŠ   r¢   Únanr  rê   )rZ   r¨   r©   r~   ré  Úsub_indexerrª   Úmultiindex_indexerÚunique_colsrœ   rl   rÁ  ÚitemÚsers                 r\   rä  z._iLocIndexer._setitem_with_indexer_frame_valueÙ
  sÍ  € ð ×4Ñ4°W¸Q±ZÓ@ˆä˜7“mˆØ�Q‰Zˆä'¨¯©×(8Ñ(8¼*ÓEÐà—m‘m×-Ñ-ˆð �6Š>Ü# EÓ*ò :‘��3Ø—j‘j¢ A Ñ&�Ø×+Ñ+¨C°°bÕ9ñ:ñ  §¡×!5Ñ!5°d·h±h×6FÑ6FÔ!Gð ò :�Ø—x‘x×'Ñ'¨Ñ,�Ø˜5‘=Ø%)�K ‘NØ×,Ñ,Ü˜kÓ*ØŸ
™
¢1 c 6Ñ*Ø*ó‘Cô Ÿ&™&�Cà×+Ñ+¨C°°bÕ9ñ:ñ ÜÐNÓOÐOð ò :�Ø—x‘x×'Ñ'¨Ñ,�Ø˜5‘=Ø%)�K ‘NØ ™+�CØ×,Ñ,Ü˜kÓ*ØØ*ó�Cð ˜cŸk™kÑ)Ø!™äŸ&™&�Cà×+Ñ+¨C°°bÕ9ñ%:r^   c                ó¾  — |}t        j                  |«      xs) t        j                  |t        | j                  «      «      }t        j
                  |«      xs t        |«      xr t        |«      dk(  }|ry|r+	 | j                  j                  j                  |||d¬«       y| j                  j                  j                  |   }|t        j                  k(  r;t'        |t        | j                  «      «      }	| j                  j%                  ||	«       | j                  j                  j                  |||«       y# t        t        t        f$ rŠ}| j                  j                  j                  |   }|t        j                  t         fvr)| j                  j"                  st        d|› d|› d�«      |‚| j                  j%                  ||«       Y d}~yd}~ww xY w)zÕ

        Parameters
        ----------
        loc : int
            Indexer for column position
        plane_indexer : int, slice, listlike[int]
            The indexer we use for setitem along axis=0.
        r   NT)Úinplace_onlyzInvalid value 'z' for dtype 'ú')rž   r#  Úis_full_slicer�   r   Úis_empty_slicer   r¿   Úcolumn_setitemr  ra  r   rè  rh   r¢   ÚvoidÚobjectÚemptyrí   r5   )
rZ   rl   r©   Úplane_indexerrª   Úis_full_setterÚis_null_setterÚexcr¤   rñ   s
             r\   rç  z#_iLocIndexer._setitem_single_column  s‘  € ð ˆä×*Ñ*¨2Ó.ÒV´#×2CÑ2CÀBÌÈDÏHÉHËÓ2Vˆä×+Ñ+¨BÓ/ò 
Ü.¨rÓ2ÒC´s¸2³wÀ!±|ð 	ñ àáð.Ø—‘—‘×,Ñ,Ø˜¨¸Dð -õ ð4 —H‘H—O‘O×(Ñ(¨Ñ-ˆEØœŸ™Òô FØœ3˜tŸx™x›=ó�ð —‘×!Ñ! # wÔ/Ø�H‰H�M‰M×(Ñ(¨¨m¸UÕCøôG ¤	Ô+<Ð=ò .ð Ÿ™Ÿ™×,Ñ,¨SÑ1�Ø¤§¡¬&Ð 1Ñ1¸$¿(¹(¿.º.ô $Ø)¨%¨°¸e¸WÀAÐFóàðð —‘×!Ñ! # u×-Ñ-ûð'.ús   Á;)D> Ä>GÅB GÇGc           	     ó  — ddl m} t        |t        «      r|dk7  st        |t        «      r| j                  | ||«      «      }| j                  j                  }| j                  j                  |«      }t        |t        «      �r•| j                  t        |«      cxk(  rdk(  rwn ntt        |d   «      rft        j                  |d   «      rN|||      }t        |j                  |g«      «      dk(  r(|j!                  |«      }| j#                  |||d   «       y| j                  dk(  r¨t        |«      dk(  rš| j                  j$                  d   dkD  r~t        j                  |d   «      sft        |t&        «      sVt)        | j                  j*                  j,                  d   j.                  t1        |d¬«      «      s| j3                  |||«       y| j                  dk(  �r1t        |«      dk(  �r"t        |d   «      �st5        |d   «      �st        |t&        «      sôt7        |«      rét9        |d	d«      dk(  rÙt        |d   t:        t<        t>        t@        jB                  t        tD        f«      r¢t9        |d   d	d«      dk(  r�| jG                  |d   «      }	t        |	«      dk(  rmtI        |d«      sa|	d   }t        |«      rQtK        |d   | j                  jL                  «      }
|
t        |«      k(  r | j#                  tO        |«      ||d   «       ytQ        |Ž }t        |t&        «      r!|dk7  r| jS                  ||«      jT                  }| j                  j*                  jW                  ||¬
«      | j                  _        y)zQ
        _setitem_with_indexer for the case when we have a single Block.
        r   rÄ  rh   rš   r›   NTrº  r�   )r¨   r©   ),rd   rN   r‰   r3   r«  r¡   r   rÕ  rŽ   rŠ   r�   r�   r    rž   r#  Úget_indexer_forr�   rç  r¦   r0   r   r¿   r½  r¾  r<   rÛ  r%   r?   r$  r,  r’   r“   r¢   r£   r2   rã  rå  rA   rä   ÚintÚmaybe_convert_ixr§   rê   Úsetitem)rZ   r¨   r©   r~   rN   rÝ  Úitem_labelsr÷   rl   ré  Únrowss              r\   rÜ  z"_iLocIndexer._setitem_single_blockT  sã  € õ 	"ä�uœiÔ(¨T°Vª^Ä
È5ÔRVÔ@Wð ×&Ñ& w±°u³Ó>ˆEà—H‘H×.Ñ.ˆ	Ø—h‘h×(Ñ(¨Ó3ˆÜ�gœuÕ%ð
 —	‘	œS ›\Ô.¨QÕ.Ü˜w q™zÔ*Ü×%Ñ% g¨a¡jÔ1à! '¨)Ñ"4Ñ5�Ü�{×2Ñ2°C°5Ó9Ó:¸aÒ?à%×-Ñ-¨cÓ2�CØ×/Ñ/°°U¸GÀA¹JÔGØð —	‘	˜Q’Ü˜“L AÒ%Ø—H‘H—N‘N 1Ñ%¨Ò)Ü×)Ñ)¨'°!©*Ô5Ü" 5¬,Ô7Ü(Ø—H‘H—M‘M×(Ñ(¨Ñ+×2Ñ2Ü! %°tÔ<ôð
 ×5Ñ5°g¸uÀdÔKØð —	‘	˜Q“Ü˜“L AÓ%ô # 7¨1¡:Õ.Ü! '¨!¡*Õ-Ü" 5¬,Ô7Ü(¨Ô/Ü˜E 6¨1Ó-°Ò2ô
 Ø˜A‘J¤¬¬t´R·Z±ZÄÌHÐ Uôô ˜G A™J¨°Ó2°aÒ7à×<Ñ<¸WÀQ¹ZÓH�Ü�u“: ’?Ô+CÀEÈ1Ô+Mð   ™(�CÜ! #”Ü 1°'¸!±*¸d¿h¹h¿n¹nÓ M˜Ø ¤C¨£JÒ.ð
 !×7Ñ7¼¸C»À%ÈÐQRÉÔTØ"ä&¨Ð0ˆGä�eœ\Ô*¨t°vª~Ø×%Ñ% g¨uÓ5×=Ñ=ˆEð Ÿ™Ÿ™×-Ñ-°gÀUÐ-ÓKˆ�‰�r^   c                óÎ  — ddl m} | j                  dk(  �r¬| j                  j                  }t        ||dd¬«       |j                  t        |«      |«      }|j                  r:|j                  |dd «      }|dk7  j                  «       r| j                  ||d	«      S t        |«      sn`t        || j                  j                  «      r@t        | j                  j                  «      s!t!        | j                  j                  d
¬«      }t#        | j                  j$                  |gd
¬«      }t        | j                  j&                  «      r,t)        |«      }t+        | j                  j&                  |g«      }| j                  j-                  ||| j                  j.                  ¬«      j0                  | j                  _        y| j                  dk(  �r“t        | j                  j                  |dd¬«       t        | j                  j2                  «      sŽ| j                  j                  j                  t        | j                  j                  «      |«      }| j                  j-                  || j                  j2                  ¬«      j0                  | j                  _        yt5        |d«      }t7        |t8        «      r.|j;                  | j                  j2                  ¬«      }||_        n•t7        |t<        «      r% ||| j                  j2                  |t>        ¬«      }n`tA        |«      r6t        |«      t        | j                  j2                  «      k7  rtC        d«      ‚ ||| j                  j2                  |¬«      }t        | j                  «      sš|jE                  «       jF                  }	| j                  j                  }
t7        |
tH        «      r|
jJ                  }n|
j.                  }tM        |g|¬«      |	_        |s|	jO                  «       }	|	j0                  | j                  _        y| j                  jQ                  |«      j0                  | j                  _        yy)zN
        Insert new row(s) or column(s) into the Series or DataFrame.
        r   rÄ  r›   zvalue on a SeriesrÑ  rÒ  r-  Nrl   F)Úcompat©Úwarn_if_castrã   rš   rÐ  zaUse a full-length tuple key and an explicit column indexer instead, e.g. df.loc[key, :] = values.)rä   rº   r¤   ©rä   )rä   r~   r¤   z(cannot set a row with mismatched columnsrÏ  ))rd   rN   r�   r   rä   r×  rØ  r�   rî   r¾   r  rÚ   r%   r6   r¤   r$   r8   ré   r:   rê   r;   r'   rë   r~   r¿   rº   r9  r‰   r3   Úreindexr«  r  r?   r  Úto_framerK   rC   ÚnamesrB   Úinfer_objectsÚ_append_internal)rZ   r¨   r©   rN   rä   Ú	new_indexrÌ  Ú
new_valuesÚ	has_dtypeÚdfrö   r~   s               r\   rÚ  z*_iLocIndexer._setitem_with_indexer_missing«  sH  € õ 	"ð �9‰9˜‹>Ø—H‘H—N‘NˆEÜ+ØØØ*Ø;õ	ð Ÿ™¤S¨£Z°Ó9ˆIð �Šð $×/Ñ/°	¸"¸#°Ó?�Ø 2Ñ%×*Ñ*Ô,à×5Ñ5°kÀ5È%ÓPÐPô ˜UÔ#Øä& u¨d¯h©h¯n©nÔ=Ü& t§x¡x§~¡~Ô6ä.¨t¯x©x¯~©~ÀeÔL�Eä1Ø—‘—‘  °eôˆJô �4—8‘8×#Ñ#Ô$ô <¸JÓG�
Ü*¨D¯H©H×,<Ñ,<¸jÐ+IÓJ�
Ø ŸH™H×1Ñ1Ø )°$·(±(·-±-ð 2ó ç‰dð �H‰H�Mð �Y‰Y˜!‹^Ü+Ø—‘—‘ØØ+ðAõ	ô �t—x‘x×'Ñ'Ô(à ŸH™HŸN™N×1Ñ1´#°d·h±h·n±nÓ2EÀwÓO�	Ø $§¡× 5Ñ 5Ø#¨T¯X©X×-=Ñ-=ð !6ó !ç‘$ð —‘”ð ä  wÓ/ˆIÜ˜%¤Ô+àŸ™¨D¯H©H×,<Ñ,<˜Ó=�Ø$�•
Ü˜E¤4Ô(ÙØ §¡×!1Ñ!1¸Ävô‘ô
 (¨Ô.ä˜5“z¤S¨¯©×)9Ñ)9Ó%:Ò:Ü(Ð)SÓTÐTá˜u¨D¯H©H×,<Ñ,<À7ÔK�ä�t—x‘x”=ð —^‘^Ó%×'Ñ'�à—h‘h—n‘n�Ü˜c¤:Ô.ØŸ9™9‘DàŸ8™8�Dä  ' °Ô6�”Ù ð ×)Ñ)Ó+�BØ "§¡�—‘•à $§¡× 9Ñ 9¸%Ó @× EÑ E�—‘•ðk r^   c                óF  — t        |«      r|g}|S t        |t        «      r-t        t	        | j
                  j                  «      «      |   }|S t        j                  |«      r<t        j                  t	        |«      «      t        j                  |t        ¬«         }|S |}|S )zX
        Ensure that our column indexer is something that can be iterated over.
        râ   )r    r‰   r,  r’   r�   r   rº   rž   rŸ   r¢   rÙ  r´  rz   )rZ   Úcolumn_indexerré  s      r\   rã  z,_iLocIndexer._ensure_iterable_column_indexer  s•   € ô
 �nÔ%Ø#Ð$ˆEð ˆô ˜¬Ô.Üœ#˜dŸh™h×.Ñ.Ó/Ó0°Ñ@ˆEð ˆô × Ñ  Ô0Ü—I‘Iœc .Ó1Ó2Ü—
‘
˜>´Ô6ñˆEð
 ˆð #ˆEØˆr^   c                óÀ  — t        |t        t        j                  t        t
        f«      r|f}t        |t        «      �ròt        |«      dk(  r]t        |d   t        j                  «      r@|d   j                  t        j                  k(  r |d   t        j                  |d   «      d   f}d„ }t        t        ||«      «      }|D �cg c]  }t        j                  |«       ‘Œ }}t        |«      }|dk(  }| j                  dk(  }	| j                   }
|	r	|xr |d   }t#        d„ |D «       «      r°|j%                  |
j&                  d   |d      «      j(                  }t        |«      dkD  rr|spt        |d   t        «      rt        |
j&                  d   |d      «      }nt        |d   «      }t        j*                  ||«      j-                  |d«      j.                  }|S t1        |«      D �]:  \  }}|
j&                  |   }t3        |«      st        |t        «      r‘|rt        j                  |«      rŒI||   }t5        |«      st        |g«      }nt        |«      }t        |«      r|j6                  j9                  |«      r|j(                  c S |j%                  |«      j(                  c S |sŒÅ| j                   j&                  d   }|j6                  j9                  |«      st        |«      s|j(                  j;                  «       c S |j%                  |«      j(                  c S  tC        d«      ‚t=        |«      rž| j                  dk(  r�t?        | j                   j                  «      r|S | j                   jA                  d«      }|j6                  j9                  |«      r|j(                  j;                  «       S |j%                  |«      j(                  |   S t=        |«      rk| j                   jA                  d«      }|j6                  j9                  |«      r|j(                  j;                  «       S |j%                  |«      j(                  S tC        d«      ‚c c}w )aT  
        Parameters
        ----------
        indexer : tuple, slice, scalar
            Indexer used to get the locations that will be set to `ser`.
        ser : pd.Series
            Values to assign to the locations specified by `indexer`.
        multiindex_indexer : bool, optional
            Defaults to False. Should be set to True if `indexer` was from
            a `pd.MultiIndex`, to avoid unnecessary broadcasting.

        Returns
        -------
        `np.array` of `ser` broadcast to the appropriate shape for assignment
        to the locations selected by `indexer`
        rš   r›   r   c                óZ   — t        | t        j                  «      r| j                  «       S | S rX   )r‰   r¢   r£   Úravel)rœ   s    r\   r!  z)_iLocIndexer._align_series.<locals>.ravelO  s    € Ü$.¨q´"·*±*Ô$=�q—w‘w“yÐDÀ1ÐDr^   c              3  óV   K  — | ]!  }t        |«      xs t        |t        «      –— Œ# y ­wrX   )r&   r‰   r,  )r±   Ú_s     r\   r³   z-_iLocIndexer._align_series.<locals>.<genexpr>d  s#   è ø€ ÒK¸a”;˜q“>Ò9¤Z°´5Ó%9Ó9ÑKùs   ‚')r-  z Incompatible indexer with Series)"r‰   r,  r¢   r£   r“   rB   rŠ   r�   r¤   Úbool_ÚwhereÚmaprž   r#  Úsumr�   r   r»   r  r  rê   ÚtileÚreshaperK   r  r&   r?   rä   rô  r·   r    r$   rŽ   r  )rZ   r¨   rú  r÷  r!  rö   ÚalignersÚsum_alignersÚsingle_alignerÚis_framer   Ú
ser_valuesÚlen_indexerrœ   r—   Únew_ixs                   r\   r¡   z_iLocIndexer._align_series-  s‘  € ô, �g¤¤r§z¡z´4¼Ð?Ô@Ø�jˆGä�gœuÕ%ô �G“ Ò!Ü˜w q™z¬2¯:©:Ô6Ø˜A‘J×$Ñ$¬¯©Ò0à" 1™:¤r§x¡x°¸±
Ó';¸AÑ'>Ð?�òEô œC  wÓ/Ó0ˆGØ>EÖF°sœC×-Ñ-¨cÓ2Ò2ÐFˆHÐFÜ˜x›=ˆLØ)¨QÑ.ˆNØ—y‘y A‘~ˆHØ—(‘(ˆCñ Ø!/Ò!?°H¸Q±K�ô ÑKÀ7ÔKÔKØ Ÿ[™[¨¯©°!©°W¸Q±ZÑ)@ÓA×IÑI�
ô �w“< !Ò#Ñ,>Ü! '¨!¡*¬eÔ4Ü&)¨#¯(©(°1©+°g¸a±jÑ*AÓ&B™ä&)¨'°!©*£o˜äŸ™ 
¨KÓ8×@Ñ@ÀÈbÓQ×SÑSð ð "Ð!ä# GÓ,ó 3‘��3Ø—X‘X˜a‘[�ô ˜sÔ#¤z°#´uÔ'=Ù%¬#×*;Ñ*;¸CÔ*@Ø Ø ™W�FÜ/°Ô7Ü!&¨ x£™ä!& v£˜Ü˜vœ;¨#¯)©)×*:Ñ*:¸6Ô*BØ"Ÿ{™{Ò*àŸ;™; vÓ.×6Ñ6Ò6ò $àŸ™Ÿ™ qÑ)�BØ—y‘y×'Ñ'¨Ô+´3°r´7Ø"Ÿ{™{×/Ñ/Ó1Ò1ØŸ;™; r›?×2Ñ2Ò2ð/3ôX Ð;Ó<Ð<ô' ˜Ô  T§Y¡Y°!¢^Ü˜tŸx™xŸ~™~Ô.à�
Ø—‘×#Ñ# AÓ&ˆBà�y‰y×Ñ Ô#Ø—{‘{×'Ñ'Ó)Ð)à—;‘;˜r“?×*Ñ*¨7Ñ3Ð3ä˜Ô Ø—‘×#Ñ# AÓ&ˆBà�y‰y×Ñ Ô#Ø—{‘{×'Ñ'Ó)Ð)à—;‘;˜r“?×*Ñ*Ð*äÐ;Ó<Ð<ùòY Gs   ÃQc                óò  — | j                   dk(  }t        |t        «      rÿd\  }}g }t        |«      D ]‡  \  }}| j                  j
                  |   }	t        |«      st        |t        «      r=t        |t        j                  «      r|j                  d«      }|€|	|   }Œm|€|	|   }Œu n|j                  |«       Œ‰ |��/|��,|j                  j                  |«      r-|j                  j                  |«      r|j                  «       }
|
S |j!                  ||¬«      }
|
S t        |t        «      st#        |«      r´|r²| j                  j                  |   }	|j                  j                  |	«      r|j                  «       }
|
S t        |	t$        «      rHt        |j                  t$        «      r.|	j&                  |j                  j&                  k7  rt)        d«      ‚|j!                  |	¬«      }
|
S t+        d«      ‚)Nrš   )NNr-  )rº   zAcannot align on a multi-index with out specifying the join levelsr  z#Incompatible indexer with DataFrame)r�   r‰   rŠ   r  r   r  r&   r,  r¢   r£   r)  r�  rä   rô  rº   r·   r  r?   rC   r{  ra  r  )rZ   r¨   r  r-  rö   ÚcolsÚ	sindexersrœ   Úixr—   rÁ  s              r\   r§   z_iLocIndexer._align_frame¡  s®  € Ø—9‘9 ‘>ˆä�gœuÔ%Ø"‰IˆC�ØˆIÜ" 7Ó+ò (‘��2Ø—X‘X—]‘] 1Ñ%�Ü˜r”?¤j°´UÔ&;Ü! "¤b§j¡jÔ1ØŸZ™Z¨›^˜Ø�{Ø  ™f™Ø˜Ø! "™v™áà×$Ñ$ QÕ'ð(ð ‰ 4Ñ#3Ø—8‘8—?‘? 3Ô'¨B¯J©J×,=Ñ,=¸dÔ,CØŸ'™'›)�Cð �
ð Ÿ*™* S°$˜*Ó7�CØ�
ä˜¤%Ô(Ô,@ÀÔ,IÉxØ—‘—‘ Ñ(ˆBØ�x‰x�‰˜rÔ"Ø—g‘g“i�ð ˆJô ˜r¤:Ô.Ü" 2§8¡8¬ZÔ8ØŸ
™
 b§h¡h×&6Ñ&6Ò6ä#ð5óð ð
 —j‘j r�jÓ*�ØˆJäÐ>Ó?Ð?r^   NrU  rY  r™  )r•   zint | np.integerry   rH   r_   rT  rW  rX  rš  )r•   rK   ry   rH   r_   rK   )r~   rw   r_   rT  )rh   )r~   rw   rS  )r©   rM   r~   rw   r_   rT  )rl   r
  r_   rT  )F)rú  rN   r÷  rz   r_   zArrayLike | Series)r  rM   r_   rM   )r`   ra   rb   rc   rx   r{   rþ   rØ   rB  r£  rD  r²  r%  r  r”   r˜   rÂ  rÍ  rÚ   rÛ  ræ  rä  rç  rÜ  rÚ  rã  r¡   r§   rY   r^   r\   ri   ri   2  sà   „ ñMð`	Bð ð €Ió
+YóZ"óH/óKó,1óOó.#1óJ	5óòó1óf?ôBH=óTV<óp <ðD9:Ø'ð9:Ø/2ð9:à	ó9:óv>Dó@ULònoFòbð* $)ð	r=ð ðr=ð !ð	r=ð
 
ór=ôh/@r^   ri   c                  ó0   — e Zd ZU dZded<   d„ Zd„ Zdd„Zy)	Ú_ScalarAccessIndexerz!
    Access scalars quickly.
    rz   r{   c                ó   — t        | «      ‚rX   rü   r  s     r\   Ú_convert_keyz!_ScalarAccessIndexer._convert_keyÛ  r;  r^   c                óÄ   — t        |t        «      st        |«      s|f}nt        d«      ‚| j	                  |«      } | j
                  j                  |d| j                  iŽS )Nú)Invalid call for scalar access (getting)!rA  )r‰   rŠ   r?   r  r8  r   rC  r{   r  s     r\   r]   z _ScalarAccessIndexer.__getitem__Þ  sW   € Ü˜#œuÔ%ä'¨Ô,Ø�f‘ä Ð!LÓMÐMà×Ñ Ó$ˆØ"ˆt�x‰x×"Ñ" CÐA°$·.±.ÑAÐAr^   c                ó¤  ‡ — t        |t        «      rt        ˆ fd„|D «       «      }n t        j                  |‰ j                  «      }t        |t        «      st        ‰ j                  |«      }t        ‰ j                  |«      «      }t        |«      ‰ j                  k7  rt        d«      ‚ ‰ j                  j                  ||‰ j                  dœŽ y )Nc              3  ó^   •K  — | ]$  }t        j                  |‰j                  «      –— Œ& y ­wrX   rÎ   rÐ   s     €r\   r³   z3_ScalarAccessIndexer.__setitem__.<locals>.<genexpr>ë  rÑ   rÒ   z0Not enough indexers for scalar access (setting)!)r©   rA  )r‰   rŠ   rž   rÏ   r   r¬  r�   r“   r8  r�   r  Ú
_set_valuer{   )rZ   r•   r©   s   `  r\   rà   z _ScalarAccessIndexer.__setitem__é  sœ   ø€ Ü�cœ5Ô!ÜÓHÀCÔHÓH‰Cô ×'Ñ'¨¨T¯X©XÓ6ˆCä˜#œuÔ%Ü˜4Ÿ9™9 cÓ*ˆCÜ�4×$Ñ$ SÓ)Ó*ˆÜˆs‹8�t—y‘yÒ ÜÐOÓPÐPàˆ�‰×Ñ˜S¨¸¿¹ÔGr^   NrS  )r`   ra   rb   rc   rZ  r8  r]   rà   rY   r^   r\   r6  r6  Ó  s   … ñð
 ƒOò(ò	BôHr^   r6  c                  óR   ‡ — e Zd ZdZdZd„ Zdd„Zed	d„«       Zˆ fd„Z	dˆ fd„Z
ˆ xZS )
rp   aÆ  
    Access a single value for a row/column label pair.

    Similar to ``loc``, in that both provide label-based lookups. Use
    ``at`` if you only need to get or set a single value in a DataFrame
    or Series.

    Raises
    ------
    KeyError
        If getting a value and 'label' does not exist in a DataFrame or Series.

    ValueError
        If row/column label pair is not a tuple or if any label
        from the pair is not a scalar for DataFrame.
        If label is list-like (*excluding* NamedTuple) for Series.

    See Also
    --------
    DataFrame.at : Access a single value for a row/column pair by label.
    DataFrame.iat : Access a single value for a row/column pair by integer
        position.
    DataFrame.loc : Access a group of rows and columns by label(s).
    DataFrame.iloc : Access a group of rows and columns by integer
        position(s).
    Series.at : Access a single value by label.
    Series.iat : Access a single value by integer position.
    Series.loc : Access a group of rows by label(s).
    Series.iloc : Access a group of rows by integer position(s).

    Notes
    -----
    See :ref:`Fast scalar value getting and setting <indexing.basics.get_value>`
    for more details.

    Examples
    --------
    >>> df = pd.DataFrame(
    ...     [[0, 2, 3], [0, 4, 1], [10, 20, 30]],
    ...     index=[4, 5, 6],
    ...     columns=["A", "B", "C"],
    ... )
    >>> df
        A   B   C
    4   0   2   3
    5   0   4   1
    6  10  20  30

    Get value at specified row/column pair

    >>> df.at[4, "B"]
    2

    Set value at specified row/column pair

    >>> df.at[4, "B"] = 10
    >>> df.at[4, "B"]
    10

    Get value within a Series

    >>> df.loc[5].at["B"]
    4
    Fc                óF   — | j                   dk(  rt        |«      dkD  r|f}|S )zd
        Require they keys to be the same type as the index. (so we don't
        fallback)
        r›   )r�   r�   r  s     r\   r8  z_AtIndexer._convert_key=  s%   € ð �9‰9˜Š>œc #›h¨šlØ�&ˆCàˆ
r^   c                óh  — | j                   dk(  rVt        |t        «      rt        |«      dk7  ry|d   | j                  j
                  f|d   | j                  j                  fg}n>|}t        |t        «      rt        |«      dk(  r|d   }|| j                  j
                  fg}|D ]u  \  }}t        |t        «      st        |«      rt        |t        «      sŒ2	 ||v}|sŒ:| j                   dk(  rdnd}t        j                  d|› d�t        t        «       ¬	«        y y# t        t        f$ r Y ŒŠw xY w)
zI
        GH#48323 - Warn if .at setitem would expand the object.
        rš   Nr   r›   rM   rN   zSetting a value on a zƒ via .at with a key that does not exist in the index is deprecated and will raise a KeyError in a future version. Use .loc instead.rÆ   )r�   r‰   rŠ   r�   r   rä   rº   r,  r?   ra  r   rÕ   rÖ   r   r   )rZ   r•   ÚchecksÚ	check_keyry   Úis_expandingÚobj_types          r\   Ú_warn_if_expandingz_AtIndexer._warn_if_expandingJ  s+  € ð �9‰9˜Š>Ü˜c¤5Ô)¬S°«X¸ª]ØØ˜1‘v˜tŸx™xŸ~™~Ð.°°Q±¸¿¹×9IÑ9IÐ0JÐK‰FàˆIÜ˜#œuÔ%¬#¨c«(°aª-Ø ™F�	Ø  $§(¡(§.¡.Ð1Ð2ˆFà%ò 	‰OˆI�tô ˜)¤UÔ+Ô/CÀIÔ/NÜ! )¬UÔ3ØðØ(°Ð4�ò Ø*.¯)©)°qª.™;¸h�Ü—‘Ø+¨H¨:ð 6(ð (ô #Ü/Ó1õñ ñ-	øô Ô0Ð1ò Ùðús   ÃDÄD1Ä0D1c                ó¨   — | j                   dk(  sJ ‚| j                  j                  j                  xr  | j                  j                  j                  S )Nrš   )r�   r   rä   rî   rº   rj   s    r\   Ú_axes_are_uniquez_AtIndexer._axes_are_uniquep  s=   € ð �y‰y˜AŠ~Ðˆ~Ø�x‰x�~‰~×'Ñ'ÒF¨D¯H©H×,<Ñ,<×,FÑ,FÐFr^   c                óä   •— | j                   dk(  rR| j                  sFt        |t        «      rt	        d„ |D «       «      st        d«      ‚| j                  j                  |   S t        ‰| �%  |«      S )Nrš   c              3  ó2   K  — | ]  }t        |«      –— Œ y ­wrX   ©r%   rÊ   s     r\   r³   z)_AtIndexer.__getitem__.<locals>.<genexpr>y  ó   è ø€ Ò4OÀa´Y¸q·\Ñ4Oùr´   r:  )
r�   rG  r‰   rŠ   r»   r  r   rl   Úsuperr]   )rZ   r•   Ú	__class__s     €r\   r]   z_AtIndexer.__getitem__v  s\   ø€ Ø�9‰9˜Š> $×"7Ò"7ä˜c¤5Ô)´Ñ4OÈ3Ô4OÔ1OÜ Ð!LÓMÐMØ—8‘8—<‘< Ñ$Ð$ä‰wÑ" 3Ó'Ð'r^   c                ó¢  •— t         sFt        j                  | j                  «      t        k  r t        j                  t        t        d¬«       | j                  |«       | j                  dk(  rS| j                  sGt        |t        «      rt        d„ |D «       «      st        d«      ‚|| j                  j                   |<   y t"        ‰| �I  ||«      S )Nrš   rÆ   c              3  ó2   K  — | ]  }t        |«      –— Œ y ­wrX   rJ  rÊ   s     r\   r³   z)_AtIndexer.__setitem__.<locals>.<genexpr>‹  rK  r´   z)Invalid call for scalar access (setting)!)r   rÓ   rÔ   r   r   rÕ   rÖ   r   r   rE  r�   rG  r‰   rŠ   r»   r  rl   rL  rà   ©rZ   r•   r©   rM  s      €r\   rà   z_AtIndexer.__setitem__  s�   ø€ Ý'Ü�‰˜tŸx™xÓ(¬MÒ9Ü—‘Ü+Ô-CÐPQõð
 	×Ñ Ô$à�9‰9˜Š> $×"7Ò"7ä˜c¤5Ô)´Ñ4OÈ3Ô4OÔ1OÜ Ð!LÓMÐMà %ˆD�H‰H�L‰L˜ÑØä‰wÑ" 3¨Ó.Ð.r^   rS  rY  )r`   ra   rb   rc   r{   r8  rE  rt   rG  r]   rà   Ú__classcell__©rM  s   @r\   rp   rp   ù  s@   ø„ ñ?ðB €Iòó$ðL òGó ðGô
(÷/ñ /r^   rp   c                  ó.   ‡ — e Zd ZdZdZd„ Zdˆ fd„Zˆ xZS )rs   aè  
    Access a single value for a row/column pair by integer position.

    Similar to ``iloc``, in that both provide integer-based lookups. Use
    ``iat`` if you only need to get or set a single value in a DataFrame
    or Series.

    Raises
    ------
    IndexError
        When integer position is out of bounds.

    See Also
    --------
    DataFrame.at : Access a single value for a row/column label pair.
    DataFrame.loc : Access a group of rows and columns by label(s).
    DataFrame.iloc : Access a group of rows and columns by integer position(s).

    Examples
    --------
    >>> df = pd.DataFrame([[0, 2, 3], [0, 4, 1], [10, 20, 30]], columns=["A", "B", "C"])
    >>> df
        A   B   C
    0   0   2   3
    1   0   4   1
    2  10  20  30

    Get value at specified row/column pair

    >>> df.iat[1, 2]
    1

    Set value at specified row/column pair

    >>> df.iat[1, 2] = 10
    >>> df.iat[1, 2]
    10

    Get value within a series

    >>> df.loc[0].iat[1]
    2
    Tc                ó@   — |D ]  }t        |«      rŒt        d«      ‚ |S )zH
        Require integer args. (and convert to label arguments)
        z1iAt based indexing can only have integer indexers)r    r  )rZ   r•   rœ   s      r\   r8  z_iAtIndexer._convert_keyÃ  s/   € ð ò 	VˆAÜ˜a•=Ü Ð!TÓUÐUð	Vð ˆ
r^   c                ó¼   •— t         sFt        j                  | j                  «      t        k  r t        j                  t        t        d¬«       t        ‰| �)  ||«      S )Nrš   rÆ   )r   rÓ   rÔ   r   r   rÕ   rÖ   r   r   rL  rà   rP  s      €r\   rà   z_iAtIndexer.__setitem__Ì  sD   ø€ Ý'Ü�‰˜tŸx™xÓ(¬MÒ9Ü—‘Ü+Ô-CÐPQõô ‰wÑ" 3¨Ó.Ð.r^   rS  )r`   ra   rb   rc   r{   r8  rà   rQ  rR  s   @r\   rs   rs   ”  s   ø„ ñ*ðX €Iò÷/ñ /r^   rs   c                óÈ   — t        | t        «      r| j                  S t        | t        t        j
                  t        t        f«      r| S t	        j                  | t        ¬«      S )a|  
    Return a row of a 2D setitem value that can be indexed by position.

    ``_setitem_with_indexer_2d_value`` extracts each column with ``row[i]``,
    which is wrong for a Series (indexed by *label*) and for a foreign array
    such as ``pyarrow.Array`` (``__getitem__`` hands back a boxed scalar).
    Rows that already index positionally are returned as-is, to skip a copy.
    Anything else goes through ``np.asarray``, as every row did before GH#64230
    replaced it with ``row[i]``; ``dtype=object`` is what keeps a heterogeneous
    row from being collapsed onto one numpy dtype, and ``pd.NA`` from becoming
    ``nan``.
    râ   )
r‰   r3   rê   rŠ   r¢   r£   r1   r2   r´  r  )rñ  s    r\   rì  rì  Ö  sF   € ô �#”yÔ!Ø�{‰{ÐÜ�#œœrŸz™zÔ+<¼hÐGÔHØˆ
Ü�:‰:�c¤Ô(Ð(r^   c                óš   — t        | «      syt        | t        «      xr- |dk(  xr& t        | d   t        «      xr t	        | d   «      dk7   S )a3  
    Whether ``value`` should be treated as a 2-D value for ``ncols`` columns.

    A list of tuples aimed at a single column is per-cell values unless the
    tuples are length-1 (GH#37629). With more columns it takes the 2-D path
    whatever the tuple width, which rejects a mismatched one. GH#65264
    Fr›   r   )Ú_is_2d_valuer‰   r“   rŠ   r�   )r©   Úncolss     r\   rå  rå  ê  sY   € ô ˜ÔØä�5œ$Óò 	Ø�Q‰Jò	ä�u˜Q‘x¤Ó'ò	ô ��a‘‹M˜QÑð	ð r^   c                óZ  — t        | t        «      r„t        | «      dk(  ry| d   }t        |t        t        f«      ryt        |t        t
        t        t        j                  f«       xr, t        |d«      xr t        |d«      xr t        |dd«      dk(  S t        j                  | «      dk(  S )	zECheck if value is 2-dimensional, avoiding np.asarray for plain lists.r   FTÚ__len__r]   r�   r›   rš   )r‰   r“   r�   rŠ   rw   Úbytesr}   r   ÚMappingr9  r$  r¢   r�   )r©   Úfirsts     r\   rX  rX  ü  s    € ä�%œÔÜˆu‹:˜Š?ØØ�a‘ˆÜ�eœd¤E˜]Ô+Øô ˜5¤3¬¬t´S·[±[Ð"AÓBÐBò /Ü˜˜yÓ)ò/ä˜˜}Ó-ò/ô ˜˜v qÓ)¨QÑ.ð		
ô �7‰7�5‹>˜QÑÐr^   c                óp   — t        | «      D �cg c]  }t        dd«      ‘Œ }}||d<   t        |«      S c c}w )zÖ
    Given an indexer for the first dimension, create an equivalent tuple
    for indexing over all dimensions.

    Parameters
    ----------
    ndim : int
    loc : object

    Returns
    -------
    tuple
    Nr   )r’   r,  rŠ   )r�   rl   r#  Ú_tups       r\   r¬  r¬    s:   € ô (-¨T£{Ö3 !ŒE�$˜ÕÐ3€DÐ3Ø€Dˆ�GÜ�‹;Ðùò 4s   Ž3c                ó@   — t        d«      g| z  }|||<   t        |«      S )zI
    If we have an axis, adapt the given key to be axis-independent.
    N)r,  rŠ   )r�   ry   r•   r  s       r\   rŒ   rŒ   '  s'   € ô �T‹{ˆm˜dÑ"€GØ€GˆD�MÜ�‹>Ðr^   c                óâ  — |}t        |t        «      r�|j                  j                  | «      st|j                  j	                  | «      }d|v rt        d«      ‚|j                  |«      }t        |j                  t        «      s|j                  t        «      j                  S t        |«      rt        j                  |t        ¬«      }nt        |«      st!        |t        ¬«      }t#        | |«      S )aL  
    Check if key is a valid boolean indexer for an object with such index and
    perform reindexing or conversion if needed.

    This function assumes that is_bool_indexer(key) == True.

    Parameters
    ----------
    index : Index
        Index of the object on which the indexing is done.
    key : list-like
        Boolean indexer to check.

    Returns
    -------
    np.array
        Resulting key.

    Raises
    ------
    IndexError
        If the key does not have the same length as index.
    IndexingError
        If the index of the key is unalignable to index.
    r-  ztUnalignable boolean Series provided as indexer (index of the boolean Series and of the indexed object do not match).râ   )r‰   r3   rä   rô  r	  r   rO  r¤   r+   Úastyperz   rê   r$   r¢   r´  r   rè   r>   )rä   r•   r†  r¨   s       r\   rN  rN  0  sÁ   € ð4 €FÜ�#”yÔ!¨#¯)©)×*:Ñ*:¸5Ô*AØ—,‘,×.Ñ.¨uÓ5ˆØ�‰=Üð4óð ð —‘˜WÓ%ˆô ˜&Ÿ,™,¬Ô7Ø—=‘=¤Ó&×.Ñ.Ð.ä�sÔä—‘˜F¬$Ô/‰Ü/°Ô7ô ˜&¬Ô-ˆÜ˜u fÓ-Ð-r^   c                ór   — t        | t        «      r$| d   } t        | t        «      rt        d«      ‚| dfS | dfS )zƒ
    Reverse convert a missing indexer, which is a dict
    return the scalar indexer and a boolean indicating if we converted
    r•   z.cannot use a single bool to index into setitemTF)r‰   r«  rz   r�   )r¨   s    r\   rÖ  rÖ  d  sA   € ô
 �'œ4Ô à˜%‘.ˆä�gœtÔ$ÜÐKÓLÐLØ˜ˆ}Ðà�Eˆ>Ðr^   c                óJ   ‡‡— ˆfd„Št        ˆfd„t        | «      D «       «      S )zK
    Create a filtered indexer that doesn't have any missing indexers.
    c                óV   •— t        |t        «      r‰|    j                  |d   «      S |S )Nr•   )r‰   r«  r�   )Ú_iÚ_idxr  s     €r\   r¾   z7convert_from_missing_indexer_tuple.<locals>.get_indexery  s*   ø€ Ü0:¸4ÄÔ0Fˆt�B‰x×Ñ  U¡Ó,ÐPÈDÐPr^   c              3  ó6   •K  — | ]  \  }} ‰||«      –— Œ y ­wrX   rY   )r±   rg  rh  r¾   s      €r\   r³   z5convert_from_missing_indexer_tuple.<locals>.<genexpr>|  s   øè ø€ ÒJ©8¨2¨t‘˜R ×&ÑJùr  )rŠ   r  )r¨   r  r¾   s    `@r\   rÉ  rÉ  t  s!   ù€ ô
Qô ÓJ´yÀÓ7IÔJÓJÐJr^   c                 ó�   — | D ]0  }t        |t        j                  t        t        t
        f«      rŒ.| c S  t        j                  | Ž S )z3
    We likely want to take the cross-product.
    )r‰   r¢   r£   r“   r3   rB   Úix_)Úargsr[   s     r\   r  r    s?   € ð ò ˆÜ˜#¤§
¡
¬D´)¼UÐCÕDØŠKðô �6‰6�4ˆ=Ðr^   c                óŽ   — t        | t        «      sy| D ]/  }t        |«      st        |t        «      sŒt        |t        «      c S  y)ú&
    Returns
    -------
    bool
    F)r‰   rŠ   r"   r,  rC   )r  rP  r²   s      r\   r  r  ‰  sB   € ô �cœ5Ô!Øàò 2ˆÜ˜Œ?œj¨¬EÕ2Ü˜f¤jÓ1Ò1ð2ð r^   c                óT   — t        | t        «       xr t        | «       xr | t        uS )rn  )r‰   r,  r?   r  ©r•   s    r\   r0  r0  š  s3   € ô �sœEÓ"Ð"ò 	 Ü$ SÓ)Ð)ò	 à”xÐðr^   c                ó€   — | j                   duxs/ | j                  duxs | j                  duxr | j                  dk7  S )rn  Nr›   )r_  r`  r‹  )r   s    r\   r1  r1  ¨  sD   € ð 	�	‰	˜Ðò 	4Ø�8‰8˜4Ðò	4à�H‰H˜DÐ Ò2 S§X¡X°¡]ðr^   c                óú   — t        | t        «      s"t        | t        «      rt        d„ | D «       «      rt	        d«      ‚t        | t
        «      s"t        | t        «      rt        d„ | D «       «      rt	        d«      ‚yy)zX
    Check if the indexer is or contains a dict or set, which is no longer allowed.
    c              3  ó<   K  — | ]  }t        |t        «      –— Œ y ­wrX   )r‰   ÚsetrÊ   s     r\   r³   z-check_dict_or_set_indexers.<locals>.<genexpr>º  s   è ø€ Ò&G¸a¤z°!´S×'9Ñ&Gùr  zAPassing a set as an indexer is not supported. Use a list instead.c              3  ó<   K  — | ]  }t        |t        «      –— Œ y ­wrX   )r‰   r«  rÊ   s     r\   r³   z-check_dict_or_set_indexers.<locals>.<genexpr>Á  s   è ø€ Ò&H¸q¤z°!´T×':Ñ&Hùr  zBPassing a dict as an indexer is not supported. Use a list instead.N)r‰   rt  rŠ   r  ra  r«  rp  s    r\   r‹   r‹   µ  sq   € ô �#”sÔÜ�3œÔ¤3Ñ&GÀ3Ô&GÔ#GäØOó
ð 	
ô �#”tÔÜ�3œÔ¤3Ñ&HÀCÔ&HÔ#HäØPó
ð 	
ð $IÐr^   c                ó,  — | j                   }t        |t        «      r|j                  n|}t        |t        j                   «      rN|j
                  dv r@t        |t        j                  «      r&|j                   j
                  dk(  rt        ||«      syt        |t        «      rt        t	        j                  | «      |«      S t        |t        t        t        t        j                   f«      s|dk(  rt        | |«      S 	 t        j                  «       5  t        j                  d«       t!        ||¬«      }ddd«       t%        t	        j                  t&        ¬«      t	        j                  |t&        ¬«      «      S # 1 sw Y   ŒGxY w# t"        $ r Y yw xY w)z¼
    Can new_arr's values be set losslessly into an array of orig's dtype?

    Decides whether a dtype change during setitem-with-expansion gets the
    GH#62369 deprecation warning.
    ÚiuÚfFÚstringÚignorerâ   N)r¤   r‰   r-   Únumpy_dtyper¢   r¥   r£   r   r   r´  r.   r,   r*   rÕ   Úcatch_warningsÚsimplefilterrè   Ú	Exceptionr4   r  )Úorigrñ   r¤   Únp_dtypeÚ	converteds        r\   Ú_expansion_can_holdr‚  È  s=  € ð �J‰J€EÜ$.¨u´lÔ$Cˆu× Ò È€Hä�8œRŸX™XÔ&Ø�M‰M˜TÑ!Ü�w¤§
¡
Ô+Ø�M‰M×Ñ #Ò%Ü(¨°(Ô;ð
 ä�%œÔ&ô  ¤§
¡
¨4Ó 0°'Ó:Ð:Ü�%œ+¤}´oÄrÇxÁxÐPÔQØ�Òô    gÓ.Ð.ðÜ×$Ñ$Ó&ñ 	7ô ×!Ñ! (Ô+Ü  °Ô6ˆI÷	7ô Ü
�
‰
�9¤FÔ+¬R¯Z©Z¸ÄvÔ-Nóð ÷	7ð 	7ûô ò ñ ð	ús*   Ã>F Ä#E;Ä5F Å;FÆ F Æ	FÆFc                óÌ   — t        | t        «      rTt        |t        «      rt        |«      | j                  k(  s+t        j                  d|› d|› �t        t        «       ¬«       yyy)zã
    GH#17024 warn when expanding a MultiIndex axis with a key that is not a
    full-length tuple.  Depending on the path, such keys currently either
    flatten the MultiIndex to an Index of tuples or get padded with "".
    zSetting a new zq with a MultiIndex using a key that is not a full-length tuple is deprecated and will raise in a future version. rÆ   N)	r‰   rC   rŠ   r�   r{  rÕ   rÖ   r   r   )rä   r•   rÓ  rÔ  s       r\   r×  r×  û  s^   € ô �%œÔ$Ü�3œÔ¤3 s£8¨u¯}©}Ò#<ä�‰Ø˜V˜Hð %à#˜fð&ô Ü'Ó)ö	
ð $=ð %r^   c                óÖ   — t        | t        j                  «      r!| j                  t        j                  d¬«      S | j                  t        j                  t        j                  ¬«      S )zJ
    Numpy float64 representation of a numeric array, with NA as NaN.
    Fr¶   )r¤   Úna_value)r‰   r¢   r£   rc  Úfloat64Úto_numpyrõ  )r¦  s    r\   Ú_as_float64rˆ    sD   € ô �#”r—z‘zÔ"Ø�z‰zœ"Ÿ*™*¨5ˆzÓ1Ð1Ø�<‰<œbŸj™j´2·6±6ˆ<Ó:Ð:r^   Tr  c          	     óZ  — | j                  |«      }| j                  }t        |t        «      r|j                  }d }t        |j                  t        «      rt        |«      }|j                  }t        |j                  d«      rt        |d«      rt        ||«      }�n5t        |t        «      rÍ|j                  dv r¿|j                  j                  dk(  r¦	 t        |«      }t        |t        t        f«      r|j                  }nt        |t        «      r|j                  }nd }|�#t!        |t#        j$                  |«          |«      r2|j'                  | j                  «      }t)        t        |«      |«      r|}nX|j                  dv rJ|j                  |k7  r;t/        |«      }	 |j1                  | j2                  d¬«      }|j                  |k(  r|}	 |j                  |k7  r‘|r�t        |d«      xr1 t        |j                  d«      xr t7        |«      j9                  «       }	|	sNt;        | |«      sBt=        j>                  d|› d|j                  › d|j                  › d	�t@        tC        «       ¬
«       |� ||«      }|S # t*        t,        f$ r Y Œ½w xY w# t4        t*        t,        f$ r Y Œ×w xY w)Nrx  rw  ÚmMF)Úround_okz~Setting an item of incompatible dtype is deprecated and will raise an error in a future version of pandas. The existing dtype z: cannot hold the value being set, so the result has dtype z. Cast the object to z6 before this operation to retain the current behavior.rÆ   )"Ú_cast_pointwise_resultr¤   r‰   r-   r{  r}   Ú_ndarrayr   r   r+   r¥   rˆ  r(   r)   r/   Úsubtyper   r¢   Úisnanrc  r4   r  ra  r;   Úas_unitÚunitÚAttributeErrorr7   r  r‚  rÕ   rÖ   r   r   )
r  rñ   r  r¤   Úarr_typeÚfloatsr€  r�  ÚwrappedÚpdep6_alloweds
             r\   ré   ré     sy  € ð ×)Ñ)¨'Ó2€Gà�J‰J€EÜ�%œÔ&ð ×!Ñ!ˆð €HÜ�'—-‘-¤Ô.Ü˜“=ˆØ×"Ñ"ˆä�7—=‘= #Ô&¬;°u¸dÔ+CÜ)¨'°5Ó9Šä�5œ.Ô)Ø�J‰J˜$ÑØ�M‰M×Ñ #Ò%ð	Ü  Ó)ˆFô ˜%¤*¬oÐ!>Ô?Ø ×,Ñ,‘Ü˜E¤;Ô/Ø Ÿ=™=‘ð  �ØÐÔ#;ØœŸ™ Ó(Ð(Ñ)¨8ô$ð $ŸN™N¨4¯:©:Ó6�	ô
 $¤K°	Ó$:¸FÔCØ'�Gøð 
�‰�tÑ	 §¡°Ò 6ô 1°Ó9ˆð	$ØŸ™¨¯	©	¸E˜ÓBˆIð �‰ %Ò'Ø#‘ð ‡}�}˜Ò¡,ô ˜˜tÓ$ò $Ü˜GŸM™M¨3Ó/ò$ä�W“×!Ñ!Ó#ð 	ñ
 Ô%8¸¸wÔ%GÜ�M‰Mð&à&+ Wð -0Ø07·±¨ð ?Ø$Ÿ]™]˜Oð ,/ð	0ô Ü+Ó-õ	ð ÐÙ˜7Ó#ˆØ€NøôW œIÐ&ò 	Ùð	ûô ¤
¬IÐ6ò 	Ùð	ús%   ÃB$I> Æ#J É>JÊJÊJ*Ê)J*)rY  r
  r_   rz   rY  )r�   r
  rl   rD   r_   ztuple[Hashable | slice, ...])r�   r
  ry   rH   r_   rŠ   )rä   rB   r_   ú
np.ndarray)r¨   rŠ   r  zlist[Index]r_   rŠ   )r   r,  r_   rz   rS  )r  rO   r_   rz   )rä   rB   rÓ  rw   rÔ  rw   r_   rT  )r¦  rF   r_   r—  )r  rO   r  rz   r_   rF   )•Ú
__future__r   Úcollectionsr   Ú
contextlibr   rÓ   Útypingr   r   r   r	   r
   r   r   rÕ   Únumpyr¢   Úpandas._libs.indexingr   Úpandas._libs.libr   r   Úpandas.compatr   Úpandas.compat._constantsr   Úpandas.errorsr   r   r   r   r   r   Úpandas.errors.cowr   Úpandas.util._exceptionsr   Úpandas.core.dtypes.castr   r   r   Úpandas.core.dtypes.commonr   r   r   r    r!   r"   r#   r$   r%   r&   Úpandas.core.dtypes.concatr'   Úpandas.core.dtypes.dtypesr(   r)   r*   r+   r,   r-   r.   r/   Úpandas.core.dtypes.genericr0   r1   r2   r3   Úpandas.core.dtypes.missingr4   r5   r6   r7   r8   Úpandas.corer9   rÇ  Úpandas.core.commonÚcoreÚcommonrž   Úpandas.core.constructionr:   rè   r;   r<   r=   Úpandas.core.indexersr>   r?   r@   rA   Úpandas.core.indexes.apirB   rC   Úcollections.abcrD   rE   Úpandas._typingrF   rG   rH   rI   rJ   rK   rL   rd   rM   rN   Úpandas.core.arraysrO   Úpandas.core.baserP   rŠ   r,  rQ   rZ  rR   rS   r  r  rV   Ú
IndexSlicera   rf   rv   rm   ri   r6  rp   rs   rì  rå  rX  r¬  rŒ   rN  rÖ  rÉ  r  r  r0  r1  r‹   r‚  r×  rˆ  ré   rY   r^   r\   ú<module>r¶     sV  ðÞ "å Ý Û 
÷÷ ñ ó ã å 4÷õ 3Ý 2÷÷ õ 6Ý 4÷ñ ÷
÷ ÷ õ 4÷	÷ 	ó 	÷ó ÷õ õ ,ß  Ð  ÷ó ÷ó ÷ñ
 ÷÷
÷ ñ ÷õ 2Ý.à"'¨¸Ñ(>ÀÑ(IÈEÑ(QÐSVÐ(VÑ"WÐ�iÓWð 	�Ñ˜EÑ!Ð$4Ñ4°uÐ=MÈsÐ=RÑ7SÑSð �ió ñ  Ð 3Ð;KÔLÐñ ˆD�$Ó€ØBÐ ÷0ñ 0ñf ‹]€
Ø €
Ô ÷n	(ñ n	(ôbb.Ð)ô b.ôJZÐ"ô Zôz^@Ð#ô ^@ôB%#HÐ-ô #HôLX/Ð%ô X/ôv?/Ð&ô ?/òD)ó(ó$ó.ó(ó1.òhó Kòóó"ó
ó
ó&0óf
ó$;ð ñ	^Ø
ð^ð ð	^ð
 ô^r^   