-
Notifications
You must be signed in to change notification settings - Fork 268
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
244 - 299 problem #152
Comments
u should write it like this and save it to outputfile to work from nsfw_detector import predict Load the modelmodel = predict.load_model('models/nsfw.299x299.h5') Classify images and store the resultsresults = predict.classify(model, 'output_frames299', 299) Define the path to the output text fileoutput_file = 'output_results.txt' Open the file in write mode and write the resultswith open(output_file, 'w') as f: print(f"Output written to {output_file}") |
Hello
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 ?
The text was updated successfully, but these errors were encountered: