added the compression part