Hello, all, this is my first Julia question. Apologies is my formatting is off or if I am posting in the wrong place.
My Julia journey started with the book Tanmay Teaches: Julia for beginners, which is a nice intro for me. I am in the last chapter and there is a simple machine learning example he gives. I feed a picture, and the image is classified for me.
Here is the code per the book (2020, so perhaps some things have changed):
using Metalhead: VGG19, preprocess, load, labels
using Flux: onecold
model=VGG19()
class_labels=labels(model)
print("Enter the name of your file: ")
user_image=preprocess(load(readline()))
model_prediction=model(user_image)
top_class=onecold(model_prediction)[1]
class_name=class_labels[top_class]
println(“I think this image contains: $(class_name)”)
The error I get:
WARNING: could not import Metalhead.VGG19 into Main
WARNING: could not import Metalhead.preprocess into Main
WARNING: could not import Metalhead.labels into Main
ERROR: LoadError: UndefVarError: VGG19
not defined in Main
Stacktrace:
Any thoughts? I really wasn’t sure what to do. I have added installed already the Flux, Metalhead, Images, and PyCall packages.