very good everyone, thank you for going into my problem, so I’m going to get to the point, it turns out that when I compile with pyinstaller everything works well, tensorflow is imported correctly, I don’t see any problems when importing the h5 model either, the problem is when I want to do a prediction with .predict(), when you run the application with the predict line in the application, instead of opening the application an error window opens that says:
Traceback (most recent call last):
File “main.py”, line 37, in
y_pred= modelo.predict(numeros_variados)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “kerassrcutilstraceback_utils.py”, line 122, in error_handler
File “kerassrcutilstraceback_utils.py”, line 119, in error_handler
File “kerassrcbackendtensorflowtrainer.py”, line 506, in predict
File “kerassrccallbackscallback_list.py”, line 126, in on_predict_batch_end
File “kerassrccallbacksprogbar_logger.py”, line 66, in on_predict_batch_end
File “kerassrccallbacksprogbar_logger.py”, line 95, in _update_progbar
File “kerassrcutilsprogbar.py”, line 182, in update
File “kerassrcutilsio_utils.py”, line 98, in print_msg
AttributeError: ‘NoneType’ object has no attribute ‘write’
I also attach a screenshot of the error, and thank you very much in advance
I need to be able to make the .predict() predictions without the error I described above appearing
Jesus Peña is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.