# 下載并安裝TensorFlow 2軟體包。將TensorFlow匯入程式中:
from __future__ import absolute_import, division, print_function, unicode_literals
# Install TensorFlow
import tensorflow as tf
from keras.applications.imagenet_utils import decode_predictions
import matplotlib.pyplot as plt
from PIL import Image
# 保存模型:
keras_model_path = "keras_save"
# 現在,從該檔案重新加載模型:
model = tf.keras.models.load_model(keras_model_path)
#單個圖片預測
data_dir = r'D:\images\shuzitest\shuzi\IM10.jpg'
轉載請註明出處,本文鏈接:https://www.uj5u.com/qita/150198.html
標籤:人工智能技術
下一篇:Kotlin從入門到跑路(一)
