Refactor; save shapes in JSON ROI format