code: def to_pydatetime(self):
      # GH#20306
      warnings.warn(
          f"The behavior of {type(self).__name__}.to_pydatetime is deprecated, "
          "in a future version this will return a Series containing python "
          "datetime objects instead of an ndarray. To retain the old behavior, "
          "call `np.array` on the result",
          FutureWarning,
          stacklevel=find_stack_level(),
      )
      return cast(
          ArrowExtensionArray, self._parent.array
      )._dt_to_pydatetime()
  
imports: from __future__ import annotations
  from typing import TYPE_CHECKING, cast
  import warnings
  import numpy
  from pandas._libs import lib
  from pandas.util._exceptions import find_stack_level
  from pandas.core.dtypes.common import is_integer_dtype, is_list_like
  from pandas.core.dtypes.dtypes import ArrowDtype, CategoricalDtype, DatetimeTZDtype, PeriodDtype
  from pandas.core.dtypes.generic import ABCSeries
  from pandas.core.accessor import PandasDelegate, delegate_names
  from pandas.core.arrays import DatetimeArray, PeriodArray, TimedeltaArray
  from pandas.core.arrays.arrow.array import ArrowExtensionArray
  from pandas.core.base import NoNewAttributesMixin, PandasObject
  from pandas.core.indexes.datetimes import DatetimeIndex
  from pandas.core.indexes.timedeltas import TimedeltaIndex
label_desc: Use image node_id 5 for calling the ArrowTemporalProperties obj's underlying member method code with example usage: obj.to_pydatetime() and returns: cast