Skip to content
fn

require_square_matrix

void require_square_matrix(const int & sh, const int & label)

Refuse a shape that is not a square matrix or a batch of them: rank < 2 is InvalidArgument, unequal trailing dims ShapeMismatch (both ValueErrors on the Python side). label names the op and operand.