Ask Your Question
0

createsamples cannot read positive image

asked 2020-06-10 18:55:37 -0600

coder29 gravatar image

updated 2020-06-11 06:30:55 -0600

Hi all, When I try to make a vector file out of my 1400 positive images, it says it cannot read my first image. I have tracked the issue to my info file. The file directory for each image contains a space that I cannot remove. This makes it use an uncomplete and wrong path for the image, thus it cannot be found. How can I bypass this problem? I use windows 10 and OpenCV 3.4.1.

It also states: OpenCV Error: Assertion failed (0 <= roi.x && 0 <= roi.width && roi.x + roi.width <= m.cols && 0 <= roi.y && 0 <= roi.height && roi.y + roi.height <= m.rows)

My issue is similar to this post: https://answers.opencv.org/question/5...

How can I proceed? Thanks in advance!

Edit: The problem is, the space is part of my username. Therefore the path is something like: /Users/User Name/... There is a space in my username. I tried changing my username but the folder name doesn't change.

edit retag flag offensive close merge delete

Comments

The file directory for each image contains a space that I cannot remove.

yep, poor tool cannot handle that. rename or copy images to a different folder

berak gravatar imageberak ( 2020-06-11 02:25:41 -0600 )edit
1

The problem is, the space is part of my username. Therefore the path is something like: /Users/User Name/... There is a space in my username. I tried changing my username but the folder name doesn't change.

coder29 gravatar imagecoder29 ( 2020-06-11 06:26:39 -0600 )edit

1 answer

Sort by ยป oldest newest most voted
0

answered 2020-06-13 16:24:09 -0600

coder29 gravatar image

Here's the solution: DON'T USE WINDOWS!!! On my Raspberry Pi, it worked perfectly. traincascade works fine on windows though.

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2020-06-10 18:55:37 -0600

Seen: 189 times

Last updated: Jun 13 '20