Hi Hanjun,
Please find below the updated code. The code contains the followings:
The burn in phase was separated from the chain generation.
I also added the dumping capability of samples in the middle of chain generation. In the case of CO the best sample is being selected from the batch based on the evaluation step and in the case of ESS as the objective function, a random sample is being selected from the batch. The selected sample is being dumped in a dictionary. Additionally, if the visualization flag is True, the sample is being reshaped and is being saved as a gray scale image for now.
Hi Hanjun, Please find below the updated code. The code contains the followings: