not able to load model using python code #2168
ayuraj736
started this conversation in
Show and tell
Replies: 1 comment 1 reply
-
Looks like you have a file you created called "/home/ayush_python/whisper.py". Rename this file to something other than 'whisper.py' otherwise Python will be confused when you 'import whisper'. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
code I am using is
import whisper
model = whisper.load_model("medium")
result = model.transcribe("/home/ayush_python/8ca36823-8c90-4abb-bbb0-45c076a34c47.mp3")
print(result["text"])
and when I am executing the python command
python3 whisper2.py
Traceback (most recent call last):
File "/home/ayush_python/whisper2.py", line 1, in
import whisper
File "/home/ayush_python/whisper.py", line 3, in
model = whisper.load_model("base")
AttributeError: partially initialized module 'whisper' has no attribute 'load_model' (most likely due to a circular import)
Beta Was this translation helpful? Give feedback.
All reactions