numpoly.dsplit¶
- numpoly.dsplit(ary: numpoly.typing.PolyLike, indices_or_sections: Union[numpy._typing._array_like._SupportsArray[numpy.dtype], numpy._typing._nested_sequence._NestedSequence[numpy._typing._array_like._SupportsArray[numpy.dtype]], bool, int, float, complex, str, bytes, numpy._typing._nested_sequence._NestedSequence[Union[bool, int, float, complex, str, bytes]]]) → List[numpoly.baseclass.ndpoly][source]¶
Split array into multiple sub-arrays along the 3rd axis (depth).
Please refer to the split documentation. dsplit is equivalent to split with
axis=2
, the array is always split along the third axis provided the array dimension is greater than or equal to 3.- Example:
>>> poly = numpoly.monomial(8).reshape(2, 2, 2) >>> poly polynomial([[[1, q0], [q0**2, q0**3]], [[q0**4, q0**5], [q0**6, q0**7]]]) >>> part1, part2 = numpoly.dsplit(poly, 2) >>> part1 polynomial([[[1], [q0**2]], [[q0**4], [q0**6]]]) >>> part2 polynomial([[[q0], [q0**3]], [[q0**5], [q0**7]]])