pyarrow.parquet.read_pandas

pyarrow.parquet.read_pandas(source, columns=None, use_threads=True, memory_map=True, metadata=None)[source]

Read a Table from Parquet format, also reading DataFrame index values if known in the file metadata

Parameters:
  • source (str, pyarrow.NativeFile, or file-like object) – If a string passed, can be a single file name or directory name. For file-like objects, only read a single file. Use pyarrow.BufferReader to read a file contained in a bytes or buffer-like object
  • columns (list) – If not None, only these columns will be read from the file. A column name may be a prefix of a nested field, e.g. ‘a’ will select ‘a.b’, ‘a.c’, and ‘a.d.e’
  • use_threads (boolean, default True) – Perform multi-threaded column reads
  • metadata (FileMetaData) – If separately computed
  • memory_map (boolean, default True) – If the source is a file path, use a memory map to read file, which can improve performance in some environments
Returns:

pyarrow.Table – Content of the file as a Table of Columns, including DataFrame indexes as columns