Skip to content

244 - 299 problem #152

@NasaKHw

Description

@NasaKHw

Hello

ValueError: Input 0 of layer "model_1" is incompatible with the layer: expected shape=(None, 299, 299, 3), found shape=(None, 224, 224, 3)

im sure that my images are 299 299
i also tried :

from nsfw_detector import predict
model = predict.load_model('models/nsfw.299x299.h5')
predict.classify(model, 'test/frames/', 299)

or

from nsfw_detector import predict
model = predict.load_model('models/nsfw.299x299.h5')

Predict single image

predict.classify(model, 'test/frames/output_0045.jpg', 299)

output :
:38] TF-TRT Warning: Could not find TensorRT
test/frames/output_0045.jpg size: (299, 299)
1/1 [==============================] - 2s 2s/step
[root@server-194-5-205-78 nsfw_model]#

but it did not print the result and only printed images name and , 299 thats all
any trick to solve it ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions