I am looking into how you plot the final image from a solution:
ids = list(coords.keys()) #indexes for coords
#example of how to reconstruct an image
for id in ids:
patch = np.array(patches[next(p_ids)][‘patch’])
That code assumes that
ids in the solution are [‘0’, ‘1’, etc]
So do you need the solution ids to be sorted like that or you are ok with solution ids (per sample slice) being in any order?
If you accept any order then your loop should be
for id in ids:
patch = np.array(patches[id][‘patch’])
I’m flagging this in case you have the same assumption in your scoring.
Regards,
Dmitry