fixed bug with numpy column-major array