compress_layout function

Compress an Euler layout