How many ways are there to put 9 differently colored beads on a $3\times3$ grid if the purple bead and the green bead cannot be adjacent (either horizontally, vertically, or diagonally), and rotations and reflections of the grid are considered the same?