assign compress function
test for compress function