Open sanurielf opened 2 months ago
Hey @hiohiohio this is to add polars support, we currently use polars but the pandas to polars conversion is CPU intensive for large data.
@sanurielf thank you for the PR. Regarding polars and/or design of alpaca-py, wondering points in the below. sorry still lacking confidence to say. a. should we set polars and pandas as optional dependency? i.e. installing with alpaca-py[pandas], alpaca-py[polars]. or we are ok to set pandas/polars as dependencies since usually both are already installed for data related work? b. should we introduce pandas/polars interface into client instead of response model to skip computation of json to pydantic layer? or should we separate raw data client and pydantic/pandas/polars wrapping clients? (keeping pydantic for request model validation)
This PR is to include to_polars function to export data in polars DataFrame format. Basic unittest included also.