Skip to content

Commit

Permalink
Merge pull request #1335 from fspindle/fix_fedora25_warning_new
Browse files Browse the repository at this point in the history
Fix warning detected on Fedora25 ci: comparison between signed and un…
  • Loading branch information
fspindle authored Feb 16, 2024
2 parents 3d969f9 + 863e3f2 commit bab020d
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ int main(int argc, char **argv)
vec_img_data.reserve(g.getLastFrameIndex() * height * width);

std::vector<double> times;
int iter = 0;
size_t iter = 0;
while (!g.end()) {
g.acquire(I);
tracker.track(I);
Expand Down Expand Up @@ -175,14 +175,14 @@ int main(int argc, char **argv)
tracker.getModelForDisplay(mapOfModels, mapOfW, mapOfH, mapOfcMos, mapOfCams);

std::vector<std::vector<double>> model = mapOfModels[camera_name];
const std::string model_iter = toString("model_%06d", iter);
const std::string model_iter = toString("model_%06zu", iter);
const std::string model_iter_sz = model_iter + "_sz";
const size_t model_size = model.size();
visp::cnpy::npz_save(npz_filename, model_iter_sz, &model_size, { 1 }, "a");

for (size_t i = 0; i < model.size(); i++) {
char buffer[100];
int res = snprintf(buffer, 100, "model_%06d_%06zu", iter, i);
int res = snprintf(buffer, 100, "model_%06zu_%06zu", iter, i);
if (res > 0 && res < 100) {
const std::string model_iter_data = buffer;
std::vector<double> &vec_line = model[i];
Expand Down

0 comments on commit bab020d

Please sign in to comment.