xtensor icon indicating copy to clipboard operation
xtensor copied to clipboard

C++ tensors with broadcasting and lazy computing

Results 252 xtensor issues
Sort by recently updated
recently updated
newest added

To make `xt::pad` more general and more compliant with NumPy, the xtensor implementation should be extended with: * More (all) algorithms that [NumPy](https://docs.scipy.org/doc/numpy/reference/generated/numpy.pad.html) features. * Recursively call of `pad` if...

Feature Request

I have a small problem with assigning to an xview that was created from an xtensor with `xt::newaxis()`. The code is given below, and also in a separate PR for...

Bug

Consider a simple example: we want to take a slice iterator over a sorted array and apply `std::lower_bound` function to it. ``` #include #include #include xarray a = {{{1, 2,...

Tests typically use the `xt::xarray`, sometimes `xt::xtensor`, but it turns there are some subtle differences between all available containers/expressions/views that leads to error when switching one for another. A few...

Hi, I have been comparing computing the standard deviation myself ("homemade" version in the MWE below) and xtensor's standard deviation: the homemade version seems about 10 times faster than xtensor's...

When configured with `-DXTENSOR_USE_{XSIMD,OPENMP}=1 -DBUILD_TESTS=1` the test fails with ``` /tmp/xtensor/test/test_xoptional.cpp:92: TEST CASE: xoptional.bool_operation /tmp/xtensor/test/test_xoptional.cpp:98: ERROR: CHECK_EQ( res(0, 1).value(), true ) is NOT correct! values: CHECK_EQ( {?}, true ) ```...

The error I get it ``` xpad.hpp:101:25: error: no matching constructor for initialization of 'return_type' (aka 'pyarray') ```

Bug

xtensor is missing cross product indices generation **(numpy.ix_)** https://numpy.org/doc/stable/reference/generated/numpy.ix_.html I am posting this code as a suggestion. It works for my use cases but definitely requires more testing. The idea...

Rather than flatten the array, it would be cool to find unique rows, or columns, etc. Numpy can currently do this https://www.numpy.org/devdocs/reference/generated/numpy.unique.html#numpy.unique

Enhancement

My eye crossed https://stackoverflow.com/q/74100940/2646505 . The goal there is to mimic ```python import numpy as np keep = np.array([True, False, True]) A = np.array([[1, 2, 3], [4, 5, 6], [7,...