Some tweaks to the simulator to make it work properly with the output of the contour finding code.