Factor out generate_samples() function
Factor out generate_samples() function

Enable proper sample generation outside of the channel-related code
block by moving all the relevant code into a new function.

grantisu/Markov-Server