Python / Algorithmic Puzzles

Is this a valid magic square?
AskAI

The problem is to check whether a given 2D array of integers is a valid magic square. A magic square is a square array of integers where the sum of each row, column, and diagonal is the same.