Since switching to nixos, my Python development environment couldn't be more satisfying. I use a default.nix file and a requirements.txt file and then with a single command I'm into a shell and virtual environment with all dependencies and packages installed, that I can easily transfer between machines. That is unless I want to use PyQt5.
My Python Development Environment, 2018 Edition
61–70 of 224 posts
Re: My Python Development Environment, 2018 Edition
#62I’m using Anaconda because it was recommended in a step by step tutorial for playing with deep learning. What would be involved in removing it from my system and moving instead to this set of tools? Not necessarily looking for s step by step answer, just for general suggestions. My guess is: find out which python the deep learning tools are using, remove Anaconda, and reinstall the python version needed, using the to…
That said anaconda does have a whole variety of extremely annoying quirks, like packages not being backwards compatible with old versions of conda, or conda going crazy and reinstalling itself, or the way the conda-forge repo has far more packages than the official conda repo. It's very far from perfect. But for data science I think it's basically the standard package manager in Python land.
Re: My Python Development Environment, 2018 Edition
#63Earlier quoted context omitted.
In what way is NPM and package.json different from using pip and requirements.txt?
npm installs to a local node_modules file by default, whereas you have to set up a virtualenv or something similar to get that from pip
Re: My Python Development Environment, 2018 Edition
#64I just have latest Python installed and the nice support on Visual Studio. https://www.visualstudio.com/vs/python/
This, me too. I never understood the need for virtualenv and similar. Do people really encounter trouble with conflicting packages that often? I try to write scripts so they run on different versions of python anyway, unless there is a very specific reason why that is not possible; and even then you can run python versions in parallel on a Debian/Ubuntu box, with different pip installs for each of them. As for produc…
Re: My Python Development Environment, 2018 Edition
#65Earlier quoted context omitted.
How does it compare to PyCharm?
It's on par, as long as you don't do too many refactors on nasty codebases. Now, PyCharm chokes on those nasty refactors too, guessing the right stuff only 70% the stuff in a way that sometimes feels purely random, but at least its find and refactor preview UIs save the day sort of... One thing that annoys me on VSC is that some operations (jump to defnition etc.) have delays on larger projects, because it does not c…
Re: My Python Development Environment, 2018 Edition
#66there are way too many python dep/env managers/things pipenv pyenv mkvirtualenv virtualenv pipsi venv pew conda virtualenvwrapper i'm sure i'm forgetting like 5. this is like https://xkcd.com/927/ for the record i use pyenv and virtualenv (although playing with ML i'm using conda)
There's pyenv, pip and virtualenv/venv (same thing) and then there's a bunch of tools to make them more implicit or ergonomic (if you like the way these tools work more than the base).
So really there's not a multitude of competing standards, there's 2/3 complementary standards and then people building their own tools atop that, not entirely unlike the multitudes of Jabber or Twitter clients we used to have.
Things were worse before virtualenv rose to prominence.
Re: My Python Development Environment, 2018 Edition
#67Earlier quoted context omitted.
You miss a package manager layered on top of the one already in your OS, one that's seemingly run by people with no clue what they're doing, is rife with security issues and can break your entire system as we saw today? I have no clue why a sane person would run npm.
And yet millions do?
Re: My Python Development Environment, 2018 Edition
#68Re: My Python Development Environment, 2018 Edition
#69I’m using Anaconda because it was recommended in a step by step tutorial for playing with deep learning. What would be involved in removing it from my system and moving instead to this set of tools? Not necessarily looking for s step by step answer, just for general suggestions. My guess is: find out which python the deep learning tools are using, remove Anaconda, and reinstall the python version needed, using the to…
I think you could probably use both, side-by-side (but not at the same time/for the same project). Anaconda might be nicer if the packages you need are C-based and would need compiling on your platform. Depends on your use-case. For experimentation/playing around, stick with what works for you. But if a project required me to install Anaconda, I wouldn’t take it seriously. And pipenv is pretty easy to use, too. So if…
Many data science environments are pretty much based on Anaconda installations.
(See e.g. these dockers: https://github.com/jupyter/docker-stacks/tree/master/scipy-n...)
I mean, all packages I know DONT require Anaconda. But if you need the whole environment, sometimes Anaconda is the easiest tool too install all dependencies.
Re: My Python Development Environment, 2018 Edition
#70Earlier quoted context omitted.
Pyenv is great. On our Macs we've had zero issues installing older, specific versions of Python, every time. Highly recommended. (Getting it working properly with zsh was a bit frustrating, but that's my own fault.)
Curious here... why would you use it over just venv (assuming python3)?