The only criteria I am aware of is that the flow has to be as smooth as possible before it reaches the inlet flange because otherwise this can negatively affect the compressor performance (and predictability of performance -> contractual guarantees) therefore a minimum straight length is often required by compressor vendors. Another thing that also impacts piping design, is the load imposed on compressor flanges (usually expressed as x times NEMA); excessive loading, especially for lighter compressor frames, would have negative effect on vibrations, rotor-dynamics, sealing components and therefore badly affect reliability and MTBF. On the other hand, relaxing the loading sometimes imposes more expansion loops in piping design which is not wanted by piping and stress engineers. As regards the losses at inlet, I do not see this as a particular issues except that these are losses per se (means not efficient from energy stand point). Losses (when tangible) should be accounted for in the design of the control system. As for acoustics, I do not know if these are determining/setting piping design. Usually, if the acoustic emissions are excessive (on how they impact overall emissions - near field and/or far field) - insulation measures are taken. Maybe others can enlighten us better.
Life is not about waiting for the storm to pass. It's about learning dance in the rain.