How to use Anaconda Python to execute a .py file?

You should use Anaconda Prompt instead of common Windows command prompt. Then navigate to your folder with the .py file and run: python myfile.py However if you want to use normal command prompt you should put the path with you’re python.exe which is usually in C:\Users\<username>\AppData\Local\Continuum\anaconda3\python.exe behind this one put your .py file.

How to interpret conda package conflicts?

Some Practical Advice @Quantum7’s answer gives a fine literal interpretation of Conda’s conflict reporting. However, I wanted to offer a more practical take, which is that this “feature” from Conda is too non-specific to be useful in most non-trivial environments. And sometimes it won’t even include the underlying conflict. Don’t waste your time with it! …

Read more

Viewing history of conda transactions?

There is a –revisions, -r flag for this. conda list –revisions Check the conda list –help for more info. If you’d like an exact history, there is a conda-meta/history log in every environment. You could, for example, pull out every command ever executed in an environment, plus a timestamp, using grep -B1 “^# cmd” ${CONDA_PREFIX}/conda-meta/history

How can I display the version of my Jupyter notebook and run cells in Jupyter notebooks? I get an error: bad interpreter

From your terminal, you can simply do: jupyter –version Or, if you are using a notebook then do: !jupyter –version Here is the output in my case: jupyter core : 4.5.0 jupyter-notebook : 5.2.2 qtconsole : 4.5.2 ipython : 5.5.0 ipykernel : 4.10.1 jupyter client : 5.3.1 jupyter lab : not installed nbconvert : 5.5.0 …

Read more

Pipenv with Conda?

You can setup Pipenv to use Conda’s Python executable and site packages directory (ref). pipenv –python=$(conda run which python) –site-packages You can check if you are indeed using your Conda environment in Pipenv: pipenv run python >>> import sys >>> sys.executable, sys.path # <directories under your Conda environment> With NumPy installed through Conda, but not …

Read more