Closed RUrlus closed 3 years ago
The current branch requires that a C++ compiler with support for >=C++14 standard is present. This requirement can be prevented by building wheels with pre-compiled libs for the combination of platform and python ABI's.
This requires setting up multiplatform CI/CD
Three significant changes have been made:
Minimum supported Python version is 3.6 Pybind11 requires python>=3.6, dropping support for Python 3.5 is in line with Numpy
Moved phik
out from python
directory
The python directory only contained the phik directory
Include work-around for Asyncio bug in Python>=3.8 on Windows A work-around is needed to use nbconvert on Windows
C++ implementation Patefield algorithm The original C++ implementation is wrapped using Pybind11. Note that the implementation uses 32 bit ints. I would say it's very unlikely but not impossible to overflow these. This would only happen if a dataset contained more than 2,147B entries for a single bin.
Cross platform CI/CD To prevent introducing a significant requirement in the form of a compiler we have set-up a cross platform CI/CD pipeline. For the combinations of Python[3.6...3.9] on [Linux, MacOS, Windows] we create wheels. Additionally a test matrix has been added that runs the test set on the same matrix.
The wheels are pushed to PyPi on tags. @mbaak See here on how to create and store the token
Failures to build the C++ extension are now caught in the setup and a version will be installed without the extension. If the extension is not present a NotImplemented error will be raised when the hypergeometric method is chosen.
A section has been added to the README explaining the above.
This will significantly improve the speed of the hypergeometric method for simulation at the cost of requiring a C++ compiler. The package remains a simple pip install for all users except those on windows that don't work with conda.