News for hackers. Stuff that matters.
Re:Estimating Number of Jupyter Notebooks on Github by claytonjy on Wednesday May 08, 2019 @12:24PM (#19860386)
How does this compare to Jupytext?

I prefer pipenv to Conda, and I don't like having Jupyter(Lab) installed in each venv separately, so instead I only add `Ipykernel` to each venv and then use my system-level JupyterLab to access per-project kernels; seems like that wouldn't work here?

Re:Estimating Number of Jupyter Notebooks on Github by kbd on Wednesday May 08, 2019 @01:02PM (#19860824)
Thanks for mentioning that project. I'm wasn't familiar with it, but the difference seems to be that Jupytext is a tool to convert notebooks between ipynb and text formats, while VSCode supports the same format (#%% cell delimiters) but enables you to edit text-based notebooks similar to how you would in the browser, including keyboard shortcuts to execute individual cells, it'll render the markdown, and so on.

I'm not sure if I understand your kernel question, but VSCode's Python extension has everything built-in. As soon as you add a #%% comment it considers what follows to be a notebook cell and automatically gives you a "run cell" button that uses your chosen Python interpreter.

Re:Estimating Number of Jupyter Notebooks on Github by bawana on Wednesday May 08, 2019 @01:20PM (#19860985)
I've noticed that if I dont install jupyter to each venv, then the pythonpath defaults to the jupyter install. As a result, the jupyter notebook cannot find the packages in the venv(for example, caffe, module not found errors)
Re:Estimating Number of Jupyter Notebooks on Github by claytonjy on Wednesday May 08, 2019 @02:21PM (#19861510)
huh, I've never used Caffe but wrapping my venvs with pipenv has never caused me this kind of grief.

I tell pipenv to store venv stuff in the project folder (`export PIPENV_VENV_IN_PROJECT=1`), and then do the following to start a new project:

    pipenv --python 3.7
    pipenv install ipykernel
    pipenv run python -m ipykernel install --user --name=`basename $(pipenv run dirname '$VIRTUAL_ENV')
    jupyter lab
(all the magic is in that third command)

Then in the list of kernels, in addition to the usual suspects I'll have one named for the folder I ran the above in. If I started a notebook before all that, I'll have to change it's kernel. Doing more `pipenv install` at the prompt makes new packages immediately available in the running notebook.

Re:Estimating Number of Jupyter Notebooks on Github by xvilka on Wednesday May 08, 2019 @10:33PM (#19864871)
Exactly. Conda is the worst of Python world - installing gigabytes of unnecessary garbage every time.
Re:Estimating Number of Jupyter Notebooks on Github by linalgmixer on Wednesday May 08, 2019 @11:07PM (#19865027)
But the purpose of Anaconda is to have a easily installable set of frequently used tool for a variety of data science tasks. It's not meant to be a minimalist package.
Re:Estimating Number of Jupyter Notebooks on Github by kalefranz on Thursday May 09, 2019 @09:11AM (#19867927)
Conda can create environments with literally nothing in them. If you’re putting the full-blown anaconda metapackage in every environment, then it sounds like you’re using conda wrong for your use case. Just tell conda to install the packages you actually need.