I have a file named imutils.py that has just one definition namely abc() which returns the sum of 2 integers.
Now I want to use this definition in a separate collab file but I am unable to.
The method I used was to first upload the file imutils.py to drive and then importing it and using the definition. The error says module 'imutils' has no attribute 'abc'
To upload I first used 2 methods :
First I uploaded using the drive GUI and then I also tried the above using the code. Uploading in both cases was successful
from google.colab import files
files.upload()
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…