Skip to content
This repository has been archived by the owner on Aug 22, 2024. It is now read-only.

sh: 1: Syntax error: Unterminated quoted string #60

Open
yanuarrizki68 opened this issue Nov 6, 2019 · 1 comment
Open

sh: 1: Syntax error: Unterminated quoted string #60

yanuarrizki68 opened this issue Nov 6, 2019 · 1 comment

Comments

@yanuarrizki68
Copy link

when I run: perl bin/createsamples.pl positives.txt negatives.txt samples 1500 "opencv_createsamples -bgcolor 0 -bgthresh 0 -maxxangle 1.1
-maxyangle 1.1 maxzangle 0.5 -maxidev 40 -w 20 -h 20"

@varunjain3
Copy link

using the perl function, we are trying to run the quoted command, but as you see the quoted function is separated by a "\n" and thus it is interpreted as two different functions.

To resolve this -

  1. You can run the command in one line.
    For eg> perl bin/createsamples.pl positives.txt negatives.txt samples 1500 "opencv_createsamples -bgcolor 0 -bgthresh 0 -maxxangle 1.1 -maxyangle 1.1 maxzangle 0.5 -maxidev 40 -w 80 -h 40"

  2. or you can use a line separator such as-
    For Linux -
    perl bin/createsamples.pl positives.txt negatives.txt samples 1500
    "opencv_createsamples -bgcolor 0 -bgthresh 0 -maxxangle 1.1
    -maxyangle 1.1 maxzangle 0.5 -maxidev 40 -w 80 -h 40"
    For Windows -
    perl bin/createsamples.pl positives.txt negatives.txt samples 1500 ^
    "opencv_createsamples -bgcolor 0 -bgthresh 0 -maxxangle 1.1 ^
    -maxyangle 1.1 maxzangle 0.5 -maxidev 40 -w 80 -h 40"

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants