Sampling almost-periodic functions with random probes of finite density