From ae9fb2abbd8e2b7e079b56bf1cf39754d7c091ac Mon Sep 17 00:00:00 2001
From: Nadeen Udantha <udanthan@gmail.com>
Date: Fri, 18 May 2018 08:49:19 +0000
Subject: [PATCH] ojbects -> objects
---
src/data.c | 8 +++++++-
1 files changed, 7 insertions(+), 1 deletions(-)
diff --git a/src/data.c b/src/data.c
index 3b014b4..8da1234 100644
--- a/src/data.c
+++ b/src/data.c
@@ -137,7 +137,10 @@
{
box_label *boxes = calloc(1, sizeof(box_label));
FILE *file = fopen(filename, "r");
- if(!file) file_error(filename);
+ if (!file) {
+ printf("Can't open label file. \n");
+ file_error(filename);
+ }
float x, y, h, w;
int id;
int count = 0;
@@ -215,6 +218,7 @@
find_replace(labelpath, ".jpg", ".txt", labelpath);
find_replace(labelpath, ".JPG", ".txt", labelpath);
find_replace(labelpath, ".JPEG", ".txt", labelpath);
+ find_replace(labelpath, ".ppm", ".txt", labelpath);
int count = 0;
box_label *boxes = read_boxes(labelpath, &count);
@@ -255,6 +259,7 @@
find_replace(labelpath, ".png", ".txt", labelpath);
find_replace(labelpath, ".JPG", ".txt", labelpath);
find_replace(labelpath, ".JPEG", ".txt", labelpath);
+ find_replace(labelpath, ".ppm", ".txt", labelpath);
int count = 0;
box_label *boxes = read_boxes(labelpath, &count);
randomize_boxes(boxes, count);
@@ -306,6 +311,7 @@
find_replace(labelpath, ".bmp", ".txt", labelpath);
find_replace(labelpath, ".JPG", ".txt", labelpath);
find_replace(labelpath, ".JPEG", ".txt", labelpath);
+ find_replace(labelpath, ".ppm", ".txt", labelpath);
int count = 0;
int i;
box_label *boxes = read_boxes(labelpath, &count);
--
Gitblit v1.10.0