Data compression for quantum machine learning