-
Notifications
You must be signed in to change notification settings - Fork 2.2k
ENH: add more error conversions #38
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
Conversation
d19f32c to
2b9fdbe
Compare
|
Fixed compilation bug and rebased, should be fine now. |
|
what was the issue out of curiosity? |
|
|
|
A short note is that I fail to compile the library in full (since I'm using VS2013), but i can include it properly in a package. Perhaps keeping this would be a nice feature (for me, I would upgrade if I could, but CUDA does not support VS2015 as of yet) I understand if you do not want that however. |
|
There is some particular line of code that is causing VS2013 to crash -- it might be worth investigating that at some point to see if there is an equivalent statement that still allows it to continue. However, I must admit that it's not a big priority for me (though I would accept a PR if the change is not too big). |
|
thanks! |
ENH: add more error conversions
When converting an array to an Eigen matrix, ignore the strides is any dimension size is 0. If the array is empty, the strides aren't relevant, and especially numpy ≥ 1.23 explicitly sets the strides to 0 in this case. (See numpy commit dd5ab7b11520.) Update tests to verify that this works, and continues to work. (This test likely would have caught the behavior change with numpy 1.23.) This expands on the tests added by pybind#38, but also reverts the logic change from that PR, as it is no longer needed, and brings the code closer in line with upstream, since pybind#38 was never pushed upstream.
When converting an array to an Eigen matrix, ignore the strides if any dimension size is 0. If the array is empty, the strides aren't relevant, and especially numpy ≥ 1.23 explicitly sets the strides to 0 in this case. (See numpy commit dd5ab7b11520.) Update tests to verify that this works, and continues to work. (This test likely would have caught the behavior change with numpy 1.23.) This expands on the tests added by pybind#38, but also reverts the logic change from that PR, as it is no longer needed, and brings the code closer in line with upstream, since pybind#38 was never pushed upstream.
When converting an array to an Eigen matrix, ignore the strides if any dimension size is 0. If the array is empty, the strides aren't relevant, and especially numpy ≥ 1.23 explicitly sets the strides to 0 in this case. (See numpy commit dd5ab7b11520.) Update tests to verify that this works, and continues to work. (This test likely would have caught the behavior change with numpy 1.23.) This expands on the tests added by pybind#38, but also reverts the logic change from that PR, as it is no longer needed, and brings the code closer in line with upstream, since pybind#38 was never pushed upstream.
…d#38) Bumps [conda-incubator/setup-miniconda](https://github.com/conda-incubator/setup-miniconda) from v2.0.0 to v2.1.1. - [Release notes](https://github.com/conda-incubator/setup-miniconda/releases) - [Changelog](https://github.com/conda-incubator/setup-miniconda/blob/master/CHANGELOG.md) - [Commits](conda-incubator/setup-miniconda@v2.0.0...35d1405) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Adds more conversions, now supports all errors in boost::python and some more.