Generate random slices for a single dimension.
(n, allow_empty=False)
| 717 | return randslice_from_slicelen(slicelen, n) |
| 718 | |
| 719 | def rslices(n, allow_empty=False): |
| 720 | """Generate random slices for a single dimension.""" |
| 721 | for _ in range(5): |
| 722 | yield rslice(n, allow_empty) |
| 723 | |
| 724 | def rslices_ndim(ndim, shape, iterations=5): |
| 725 | """Generate random slice tuples for 'shape'.""" |