| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Test not only `xarray` inputs, but also `xtensor` and `xtensor_fixed`. These are currently failing. Also test some more cases with `column_major` inputs.
An `xaxis_slice_iterator` always refers to a 1d view, so just use an array of size 1 for the shape and stride. Another type would probably be more optimal in case of compile-time fixed size (e.g. `xtensor_fixed`), but at least this is correct. Always use runtime dimensionality `xaxis_iterator` shape and strides. Other types would probably be more optimal in case of compile-time fixed dimension and/or size (e.g. `xtensor`, `xtensor_fixed`), but at least this is correct.
| Back | FazBrowse Home | New Git URL |
Checklist
Description
Fixes #2116.
As described by @dchansen in #2723:
So I changed the type of the shape and strides members in the returned views/iterators as follows:
For both iterators, this loses some compile-time information in certain cases. E.g.:
Someone else would have to look into that if that's desired. However, I think the above paragraph would be more of an optimization, and this fix at least makes the iterators on xtensor and xtensor_fixed functionally correct, in the sense that their views have the correct shape and contain the correct elements.
I also made the iterator test cases type parameterized, so the existing test cases check all of xarray, xtensor, and xtensor_fixed as input types.