The code you kindly ran has a mistake.
The following lines must have a layer of indention:
X_TRAIN.append(np.array([np.float32(a1), np.float32(a2)]))
Y_TRAIN.append(np.array([np.float32(a2a1), np.float32(a2a1)]))
X_TEST.append(np.array([np.float32(a1),np.float32(a2)]))
Y_TEST.append(np.array([np.float32(a2a1), np.float32(a2a1)]))