MCPcopy Create free account
hub / github.com/apache/arrow / read_feather

Function read_feather

python/pyarrow/feather.py:206–235  ·  view source on GitHub ↗

Read a pandas.DataFrame from Feather format. To read as pyarrow.Table use feather.read_table. Parameters ---------- source : str file path, or file-like object You can use MemoryMappedFile as source, for explicitly use memory map. columns : sequence, optional

(source, columns=None, use_threads=True,
                 memory_map=False, **kwargs)

Source from the content-addressed store, hash-verified

204
205
206def read_feather(source, columns=None, use_threads=True,
207 memory_map=False, **kwargs):
208 """
209 Read a pandas.DataFrame from Feather format. To read as pyarrow.Table use
210 feather.read_table.
211
212 Parameters
213 ----------
214 source : str file path, or file-like object
215 You can use MemoryMappedFile as source, for explicitly use memory map.
216 columns : sequence, optional
217 Only read a specific set of columns. If not provided, all columns are
218 read.
219 use_threads : bool, default True
220 Whether to parallelize reading using multiple threads. If false the
221 restriction is used in the conversion to Pandas as well as in the
222 reading from Feather format.
223 memory_map : boolean, default False
224 Use memory mapping when opening file on disk, when source is a str.
225 **kwargs
226 Additional keyword arguments passed on to `pyarrow.Table.to_pandas`.
227
228 Returns
229 -------
230 df : pandas.DataFrame
231 The contents of the Feather file as a pandas.DataFrame
232 """
233 return (_read_table_internal(
234 source, columns=columns, memory_map=memory_map,
235 use_threads=use_threads).to_pandas(use_threads=use_threads, **kwargs))
236
237
238def _read_table_internal(source, columns=None, memory_map=False,

Calls 1

_read_table_internalFunction · 0.85