uber / causalml

Uplift modeling and causal inference with machine learning algorithms
Other
5.01k stars 771 forks source link

Consider building OS & platform-specific whl archives for PyPI #712

Closed alexander-pv closed 5 months ago

alexander-pv commented 10 months ago

Is your feature request related to a problem? Please describe. Sometimes people face difficulties installing the package via pypi. Most of these difficulties are related to Cython code compilation. Current .tar.gz causalml archives in PyPI contain Cython code translated into pure C. The compilation process occurs on the user side. From time to time it may be a bit tricky and may require extra time, especially on Win.

I think we need to tackle this question by uploading to PyPI .whl packages with precompiled Cython code for the most commonly used OS & platform configurations:

Nevertheless, .tar.gz should be also kept in PyPI for rare combinations of os and process architecture.

Related issues: #678, #703, #581

Describe the solution you'd like GitHub Actions pipeline which builds platform-specific .whl packages with precompiled Cython code and pushes them into PyPI.

Describe alternatives you've considered

Additional context I have tested .whl building with GitHub Actions for python 3.7-3.11 and everything seems to be working correctly. Logs: https://github.com/alexander-pv/causalml/actions/runs/6920806678

Available free GitHub runners: https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners/about-github-hosted-runners