Example #1
0
File: io.py Project: rolveb/modin
def read_parquet(path, engine: str = "auto", columns=None, **kwargs):
    """Load a parquet object from the file path, returning a DataFrame.

    Args:
        path: The filepath of the parquet file.
              We only support local files for now.
        engine: This argument doesn't do anything for now.
        kwargs: Pass into parquet's read_pandas function.
    """
    from modin.data_management.factories.dispatcher import EngineDispatcher

    return DataFrame(query_compiler=EngineDispatcher.read_parquet(
        path=path, columns=columns, engine=engine, **kwargs))
Example #2
0
File: io.py Project: yangl235/modin
def read_parquet(
    path,
    engine: str = "auto",
    columns=None,
    use_nullable_dtypes: bool = False,
    **kwargs,
):
    from modin.data_management.factories.dispatcher import EngineDispatcher

    Engine.subscribe(_update_engine)
    return DataFrame(query_compiler=EngineDispatcher.read_parquet(
        path=path,
        columns=columns,
        engine=engine,
        use_nullable_dtypes=use_nullable_dtypes,
        **kwargs,
    ))