Data compression for the CMS pixel detector at High-Luminosity LHC