1d fixes
All checks were successful
Build on RHEL9 / build (push) Successful in 2m50s
Build on RHEL8 / build (push) Successful in 4m55s

This commit is contained in:
2025-06-29 01:06:34 +02:00
parent 25e4070168
commit 856ca1e558
2 changed files with 25 additions and 9 deletions

View File

@@ -819,15 +819,17 @@ std::vector<defs::ROI> Caller::parseRoiVector(const std::string &input) {
parts.push_back(num);
}
if (parts.size() != 4) {
throw RuntimeError("ROI must have 4 comma-separated integers");
if (parts.size() != 2 && parts.size() != 4) {
throw RuntimeError("ROI must have 2 or 4 comma-separated integers");
}
defs::ROI roi;
roi.xmin = StringTo<int>(parts[0]);
roi.xmax = StringTo<int>(parts[1]);
roi.ymin = StringTo<int>(parts[2]);
roi.ymax = StringTo<int>(parts[3]);
if (parts.size() == 4) {
roi.ymin = StringTo<int>(parts[2]);
roi.ymax = StringTo<int>(parts[3]);
}
rois.emplace_back(roi);
}
return rois;