gender-detection-keras icon indicating copy to clipboard operation
gender-detection-keras copied to clipboard

Issue with train.py file

Open krishnamohan123 opened this issue 6 years ago • 6 comments

Hello arun,

Trying to execute train.py file , showing syntax in

(( File "train.py", line 26 ap.add_argument("-m", "--model", type=str, default="gender_detection.model",

 ^

SyntaxError: invalid syntax ))

What is the solution for this error.

Sorryyyyy I had spotted my mistake please reply for next issue I am facing.

Thanks Krishna

krishnamohan123 avatar Oct 24 '18 19:10 krishnamohan123

What error? ValueError: ('Input data in NumpyArrayIterator should have rank 4. You passed an array with shape', (0,))

Where it was showing while exwcuting?

train the model

H = model.fit_generator(aug.flow(trainX, trainY, batch_size=batch_size), ^
validation_data=(testX,testY), steps_per_epoch=len(trainX) // batch_size, epochs=epochs, verbose=1)

This was the error I am facing while running train.py.

Why? this kinda error will come ?

Thanks Krishna

krishnamohan123 avatar Oct 24 '18 20:10 krishnamohan123

May I know the command you are using to run the script ?

arunponnusamy avatar Oct 26 '18 11:10 arunponnusamy

Actually when I tried to run the train.py file , trainX(that u have mentioned) is not getting any input.

krishnamohan123 avatar Oct 28 '18 13:10 krishnamohan123

Can u please ping me 7550248998 if u r free.

krishnamohan123 avatar Oct 28 '18 13:10 krishnamohan123

May I know which dataset you are using to train ?

arunponnusamy avatar Oct 29 '18 11:10 arunponnusamy

The dataset whose link you provided I am facing the same problem

shivangbajaj avatar Feb 28 '20 15:02 shivangbajaj