ak.from_arrow
-------------

.. py:module: ak.from_arrow

Defined in `awkward.operations.ak_from_arrow <https://github.com/scikit-hep/awkward/blob/36da52cfa8846355c390beb6555eac1d31c27c26/src/awkward/operations/ak_from_arrow.py>`__ on `line 16 <https://github.com/scikit-hep/awkward/blob/36da52cfa8846355c390beb6555eac1d31c27c26/src/awkward/operations/ak_from_arrow.py#L16>`__.

.. py:function:: ak.from_arrow(array, *, generate_bitmasks=False, highlevel=True, behavior=None, attrs=None)


    :param array: Apache Arrow array to convert into an  Awkward Array.
    :type array: ``pyarrow.Array``, ``pyarrow.ChunkedArray``, ``pyarrow.RecordBatch``, or ``pyarrow.Table``
    :param generate_bitmasks: If enabled and Arrow/Parquet does not have Awkward
                          metadata, ``generate_bitmasks=True`` creates empty bitmasks for nullable
                          types that don't have bitmasks in the Arrow/Parquet data, so that the
                          Form (BitMaskedForm vs UnmaskedForm) is predictable.
    :type generate_bitmasks: bool
    :param highlevel: If True, return an :py:obj:`ak.Array`; otherwise, return
                  a low-level :py:obj:`ak.contents.Content` subclass.
    :type highlevel: bool
    :param behavior: Custom :py:obj:`ak.behavior` for the output array, if
                 high-level.
    :type behavior: None or dict
    :param attrs: Custom attributes for the output array, if
              high-level.
    :type attrs: None or dict

Converts an Apache Arrow array into an Awkward Array.

This function always preserves the values of a dataset; i.e. the Python objects
returned by :py:obj:`ak.to_list` are identical to the Python objects returned by Arrow's
``to_pylist`` method. If :py:obj:`ak.to_arrow` was invoked with ``extensionarray=True``, this
function also preserves the data type (high-level :py:obj:`ak.types.Type`, though not the
low-level :py:obj:`ak.forms.Form`), even through Parquet, making Parquet a good way to save
Awkward Arrays for later use.

Because awkward uses numpy's dtype system, timestamp types do not have timezones.
If encountering timestamp types with timezones in the input arrow data, they
will be silently dropped.

See also :py:obj:`ak.to_arrow`, :py:obj:`ak.to_arrow_table`, :py:obj:`ak.from_parquet`, :py:obj:`ak.from_arrow_schema`.