Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support polars data frames #1151

Open
krz opened this issue Mar 23, 2024 · 2 comments
Open

Support polars data frames #1151

krz opened this issue Mar 23, 2024 · 2 comments
Labels
enhancement New feature or request

Comments

@krz
Copy link
Contributor

krz commented Mar 23, 2024

Polars is a high-performance data frame library in python, renowned for its blazing-fast data processing capabilities and efficient, less cumbersome syntax. It stands out with its multi-threaded query engine and seamless integration with the Python ecosystem, making it an excellent choice for handling large datasets

While many popular libraries such as scikit-learn and seaborn support polars data frames, dowhy currently does not.
The current way to use a polars data frames is to convert them to pandas before using them with dowhy (e.g. polars_df.to_pandas()

Please support polars natively, as its popularity is increasing.

@krz krz added the enhancement New feature or request label Mar 23, 2024
@amit-sharma
Copy link
Member

Thanks for raising this @krz. Can you give more details on how scikit-learn supports polars DFs? Do they have a common API that can support both pandas and polars (if installed)?

Also, we'd love to have contributions. Would you like to start a PR to support polars?

@krz
Copy link
Contributor Author

krz commented Mar 25, 2024

Thanks for your reply. scikit-learn made sure that all their code supports the Python dataframe interchange protocol. See commits scikit-learn/scikit-learn#26464 and scikit-learn/scikit-learn#27315 and discussion scikit-learn/scikit-learn#25896.

I think an important first step for dowhy would be to remove functionality that solely relies on pandas, such as #1135

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants