fix: fixed and optimized termination criterion
fix: fixed and optimized termination criterion

oscarlorentzon/OpenSfM,mapillary/OpenSfM,oscarlorentzon/OpenSfM,mapillary/OpenSfM,oscarlorentzon/OpenSfM,oscarlorentzon/OpenSfM,oscarlorentzon/OpenSfM,mapillary/OpenSfM,mapillary/OpenSfM,mapillary/OpenSfM