keras/src/ops/linalg.py/_assert_1d
def _assert_1d(*arrays):
    for a in arrays:
        if a.ndim < 1:
            raise ValueError(
                "Expected input to have rank >= 1. "
                "Received scalar input {a}."
            )