25-06-25 - Today I Learned...
I learned the hard way that you should run your python and AI projects in a virtual environment so they don't create problems with other dependencies.
python -m venv env
with env as the name for the environment.
To run the environment you write env\Scripts\activate.bat
or env\Scripts\activate
.
With deactivate
we simply can deactivate the virtual environment.
The packages and dependencies that we used in the environment we then can save in a requirements.txt
file so if somebody else uses the project they can download themselves without us sending the dependencies.
pip freeze > requirements.txt