shawwn / openai-server

OpenAI API webserver
Other
180 stars 23 forks source link

ModuleNotFoundError: tensorflow.contrib #1

Closed SomethingGeneric closed 1 year ago

SomethingGeneric commented 1 year ago

In https://github.com/shawwn/openai-server/blob/master/openai_server/gpt/model.py#L3 , it would appear that the tensorflow library doesn't have .contrib anymore? Possibly related to a version change?

waundme commented 1 year ago

You must downgrade tensorflow to 1.15.

You must also install ftfy (or add it to requirements.txt) and downgrade sanic to 21.12.2, otherwise openai-server won't even start.

SomethingGeneric commented 1 year ago

Do you mean tensorflow 1.15.0 ? If so, that's what the requirements file already says

SomethingGeneric commented 1 year ago

Oh wait it's a tensorflow 1 only thing. Got it

waundme commented 1 year ago

Yes, and in order to install tensorflow==1.15 you may have to downgrade python to 3.7.

SomethingGeneric commented 1 year ago

Thanks! pyenv got me closer.