Azure 机器学习工作室 - 设计师无需培训即可使用 DenseNet?

问题描述

我实际上正在使用免费帐户在 Azure ML Studio 上上课。我有一个非常简单的笔记本,我从 Keras 加载 DenseNet 并使用它(没有拆分和训练)来预测一些图像。

from keras.preprocessing.image import load_img
from keras.preprocessing.image import img_to_array
from keras.applications.densenet import DenseNet121
from keras.applications.densenet import preprocess_input
from keras.applications.densenet import decode_predictions
from imageio import imread
from PIL import Image
import io
import numpy as np

# load the model
model = DenseNet121()

image = load_img("images/image2.jpeg",target_size=(224,224))

image = img_to_array(image)

image = image.reshape((1,image.shape[0],image.shape[1],image.shape[2]))

image = preprocess_input(image)

# predict the probability across all output classes
yhat = model.predict(image)

# convert the probabilities to class labels
label = decode_predictions(yhat)

# retrieve the most likely result,e.g. highest probability 
label = label[0][0]

# print the classification
print('%s' % (label[1]))
print('%s' % (label[2]*100))

我想知道是否可以在 Azure ML Studio 设计器(低代码)中加载在 ImageNet 上预训练的 DenseNet 而不进行训练,并且像我在笔记本中那样仅将其用于预测?

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)