Lossy compression of matrices by black-box optimisation of mixed integer nonlinear programming