Custom forward function

Hi, is it possible to upload a model to the hub with a custom forward function? It seems like you can’t but i just wanted to check?

Hello! You might want to check this PR. It guides through the process to achieve this.

Thanks this is really helpful!!

I’ve been able to upload a custom model to the hub now but i’m not having difficulty in calling it using the API. It seems that even though the model is custom it must use one of the available Pipelines in order to allow it to be called by an API? Is there a way of also allowing it to use a custom pipeline or getting around this somehow?

Hi there! I’m almost sure this is not possible, since allowing custom calls in the API would allow people to exploit the API to run custom code for the wrong reasons. @Narsil can probably confirm, but this isn’t in the roadmap.