SelectROIs bug fixes

Several bug fixes for selectROIs