I’m following along lesson 1 with google colab. Great fun, and very interesting, but I’ve run into an issue.
I pulled the whole repo down to my google drive. This was kind of an accident. I did it before I read the instructions to get one file at a time and then use ‘save a copy’ as you go. However, I decided to run with it, because I’ll have to remember to ‘save a copy’ and risk losing my work.
I first had an issue with learn.save()
, because it was saving the model to some directory that actually exists in the parent directory of my Google Drive. I always thought ‘My Drive’ was the root directory but I guess I was wrong.
So I fixed that with the directions from this post: How to save FAST AI resnet50 model to Google Drive after training in google colab notebook
basically I set
learn.path = '/content/gdrive/My Drive/Colab Notebooks/course-v3/nbs/dl1/models/'
and everything worked great. Model saved.
Now, I’m to the part of lesson one where we are supposed to use learner.load()
, However, it seems like the load function isn’t getting the notice about the changed path where my models reside. It is trying to load my model from:
/content/gdrive/My Drive/Colab Notebooks/course-v3/nbs/dl1/models/models/stage-1.pth
You might notice, it is looking in ../models/models/
, which is not a folder that exists, and is not the path I specified when I set learn.path
.
I wanted to read the docs about how this function works, but I can’t find the method under vision.learner
. In fact I can’t find much info about any of the methods. The docs seem to be missing a lot, and that’s making it really hard for me to figure this out.
I also tried using the doc()
function as in earlier in lesson one:
doc(vision.learner.load())
and I get a error saying the method load does not exist. When I Ctrl+Click on the load method, it shows me the definition, but the code is barely readable for someone of my ability…
I saw mention of another method load_learner
but is also not described in the documentation. All and all the docs seem kinda lacking.
So I’m stuck, and I’m frustrated. Can someone please help me?