now it works on CPU