I’m trying to create a pyannote Inference Endpoint with a custom inference handler.
I’m using HuggingFace’s example by @philschmid virtually as-is: philschmid/pyannote-speaker-diarization-endpoint · Hugging Face
I’ve run into 2 problems:
I created a project from scratch, heavily borrowing from @philschmid’s example, but adding
pyannote-audio~=2.1 directly to
requirements.txt (in his example he used a pyannote clone due to a HuggingFace requirement conflict that has since been fixed upstream).
I can run it locally just fine, and deploy it to HuggingFace just fine.
However when running on the cloud against any input I get the following error:
ERROR | 'NoneType' object is not callable.
There is no other context whatsoever to go on.
This is the first line logged after the 3 logs apparently associated with the endpoint initialization:
bm7hp 2022-11-04T23:13:20.279Z 2022-11-04 23:13:20,279 | INFO | Initializing model from directory:/repository bm7hp 2022-11-04T23:13:20.279Z 2022-11-04 23:13:20,279 | INFO | Found custom pipeline at /repository/handler.py bm7hp 2022-11-04T23:13:21.392Z 2022-11-04 23:13:21,392 | INFO | Model initialized successfully bm7hp 2022-11-04T23:16:08.468Z 2022-11-04 23:16:08,468 | ERROR | 'NoneType' object is not callable
I tried adding logging in the
__call__, but these aren’t showing up. The error must be happening even prior to the
__init__ getting called.
Just in case, I tried directly cloning @philschmid repo above.
I get an error on deploy, complaining that files on the pyannote/speaker-diarization repo cannot be accessed because they don’t exist or because I’m unauthorized. (I don’t have exact error available right now but can reproduce if needed).
I encountered similar errors while implementing (1), solved by approving pyannote’s terms of service on their repos. Not sure why these errs recur here.
Any pointers would be much appreciated.