Yes, it contradicts our earlier knowledge that magnetic forces cannot do any work and hence cannot increase the kinetic energy of the system. When opposite poles are facing each other, an attractive force acts between them so the magnets are pulled towards each other. As the two magnets come close to each other so the force between them increases and hence, the kinetic energy also increases.