LBlend / mann-eller-kvinne

🤵 En nettside som bruker maskinlæring til å gjette om du er mann eller kvinne basert på hva du skriver 💃
https://mannellerkvinne.lblend.moe
GNU General Public License v3.0
1 stars 0 forks source link

Specify lib versions for requirements.txt #45

Closed marksverdhei closed 2 years ago

marksverdhei commented 2 years ago

This reduces the risk of incompatible installations. We already did this with numpy due to some bug but ideally, we should do it for all of them

LBlend commented 2 years ago

I'm thinking pipenv could be suitable solution to this. Although you could specify a version manually, pipenv gives us the ability to easily install and manage packages as well as specifying their minimum version requirements

marksverdhei commented 2 years ago

I think the virtual environment can be arbitrary to whoever uses the repo, whether it's pipenv or conda. Were you thinking of using pipenv in deployment? I think in addition to specifying the lib versions, we should have a reference python version for development (e.g. the version you currently use). I'd prefer to use virtual environments for all my projects, but specifying versions should be the only thing necessary.

marksverdhei commented 2 years ago

You can simply use pip freeze to get all your current versions and go from there

LBlend commented 2 years ago

I think the virtual environment can be arbitrary to whoever uses the repo, whether it's pipenv or conda. Were you thinking of using pipenv in deployment? I think in addition to specifying the lib versions, we should have a reference python version for development (e.g. the version you currently use). I'd prefer to use virtual environments for all my projects, but specifying versions should be the only thing necessary.

I was thinking of using it in deployment as well. I don't know how it impacts performance but it's great in development IMO. I don't need to setup a virtual environment myself nor remember to activate it everytime.

As you mentioned we should have a reference python version, which pipenv takes care of for us.

However I'm open to just use pip freeze if that's what you think is the best option. If we're going to go ahead with it, we need to remove pipenv from the current rewrite branch