AutoProcessor AttributeError: 'NoneType' object has no attribute 'from_pretrained'
Hello, everyone!I’m trying to deploy this modelartificial-feelings/bark-forked · Hugging Face, which is forked from suno/bark. And in order to do that I added custom handler.py. Init method code is below.from transformers import AutoProcessor, AutoModel

class EndpointHandler():
    def __init__(self, path=""):
        self.processor = AutoProcessor.from_pretrained(path)
        self.model = AutoModel.from_pretrained(path)When creating the endpoint I am getting this error> self.processor = AutoProcessor.from_pretrained(path)
> 2023/07/21 11:15:57 ~ custom_pipeline = check_and_register_custom_pipeline_from_directory(model_dir)
> 2023/07/21 11:15:57 ~ Application startup failed. Exiting.
> 2023/07/21 11:15:57 ~ AttributeError: 'NoneType' object has no attribute 'from_pretrained'
> 2023/07/21 11:15:57 ~ File "/repository/handler.py", line 6, in __init__Seems like AutoProcessor is not initialized. Could you please help. What am I doing wrong?Thank you in advance.
2023-07-21T12:01:12Z
you need to implement a__call__method as well see:Create custom Inference Handler