<human>:  Outer product of each column of a 2D array to form a 3D array - NumPy
<bot>: Here is some code to outer product of each column of a 2d `X` array to form a 3d array `X`

np.einsum('ij,kj->jik', X, X)

#Warning: this code generation is experimental. Please inspect the code for any bugs before executing.