Implemented the lossy one