Anaconda

pip packages not included in “conda env export”

非 Y 不嫁゛ 提交于 2020-01-22 10:40:06
问题 My python project runs on a conda virtual environment. I install packages on the environment with conda install whenever that package is available for installing that way, otherwise, I install it with pip install . To make the project installation easier for other developers, I export the list of packages that are used on the conda environment to a file: conda env export > conda_environment_export.yml . However, since a while, the package export does no longer contain the packages installed

How to activate different anaconda environment from powershell

你。 提交于 2020-01-22 08:54:08
问题 I have two environments in anaconda, namely: root , 2env . When I open anaconda prompt, I can switch from root to 2env by typing: activate 2env . I also have conda in my powershell, but when I open powershell and try to run conda activate 2env it gives the following error: CommandNotFoundError: 'activate' Any suggestions on how to fix this? 回答1: Although Conda previously did not support PowerShell, this is now resolved in Conda 4.6. After adding Anaconda3/Scripts/ to your PATH variable, you

django_python_生成验证时报错TypeError: string argument expected, got 'bytes'

耗尽温柔 提交于 2020-01-22 08:43:02
问题描述: 在django的views.py视图中定义视图函数生成二维码并返回给网页,生成验证码过程中发生错误,如下: TypeError: string argument expected, got 'bytes' Traceback (most recent call last): File "G:\anaconda\lib\site-packages\django\core\handlers\exception.py", line 34, in inner response = get_response(request) File "G:\anaconda\lib\site-packages\django\core\handlers\base.py", line 115, in _get_response response = self.process_exception_by_middleware(e, request) File "G:\anaconda\lib\site-packages\django\core\handlers\base.py", line 113, in _get_response response = wrapped_callback(request, *callback_args, **callback_kwargs) File "F:

anaconda安装xgboost遇到的一些细节问题

妖精的绣舞 提交于 2020-01-22 00:29:28
如果你直接在anaconda prompt用pip install、conda install 能安装,那么恭喜你。我在安装这个包时运气不好,只能自己下载来安装,结果因为细节问题,浪费了一些安装时间,特意把这些问题记下来。 一、下载包的地址 https://www.lfd.uci.edu/~gohlke/pythonlibs/#xgboost 直接在上面这个网址上下载对应的包即可,如下图,“cp34”、“cp35”这些代表的是你的python版本,根据你自己安装的版本选择即可,“win amd64”代表64位操作系统,同理,“win32”代表32位系统,根据这两个条件选择你需要的包下载即可。 二、下载完放哪里? 下载完,一般是放在你安装python对应的Scripts文件夹下,如果忘记你这个文件在哪里,可以右键桌面“计算机”--属性--高级系统设置--环境变量--用户变量--path下就有你当时安装anaconda时配置的路径。 文件按上述位置放好,打开cmd窗口,输入:pip install 上一步下载的文件名(例如:pip install xgboost-0.90-cp36-cp36m-win_amd64.whl) 三、安装过程中可能会遇到哪些问题? 1、提示文件不存在(but the file does not exist) 这个问题是你下载的包放置的位置不对导致的

MacOSX 安装 TensorFlow

邮差的信 提交于 2020-01-21 23:50:22
TensorFlow 是一个端到端开源机器学习平台。它拥有一个包含各种工具、库和社区资源的全面灵活生态系统,可以让研究人员推动机器学习领域的先进技术的。 准备 安装 Anaconda TensorFlow 安装的前提是系统安装了 Python 2.5 或更高版本,教程中的例子是以 Python 3.6(Anaconda 3 版)为基础设计的。为了安装 TensorFlow ,首先确保你已经安装了 Anaconda。可以从网址( https://www.anaconda.com/distribution/#download-section)中下载并安装适用于 Windows/macOS 或 Linux 的 Anaconda。 这个是 macos 的连接,一个是命令行的,一个是GUI的 https://repo.anaconda.com/archive/Anaconda3-2019.10-MacOSX-x86_64.sh https://repo.anaconda.com/archive/Anaconda3-2019.10-MacOSX-x86_64.pkg 关于安装 anaconda , 可以参考官方的文档。 > https://docs.anaconda.com/anaconda/install/ 配置 Anaconda 执行这个命令 source ~/.bash_profile

Anaconda: find version with Spyder IDE

偶尔善良 提交于 2020-01-21 15:15:27
问题 I just ran into an issue. I had an installation of Anaconda from 2016, it was version 4.1. I then downloaded a new version of Anaconda version 5.1. I installed this version on windows 7. I have now 3 versions of Anaconda on my windows machine, one is for Anaconda with python-2 (v4.1 anaconda), and Anaconda v4.1 with python-3. And the new Anaconda v5.1 with Python-3. In the older versions when using Spyder IDE, when the console came up, it would state the python version and the version of

Anaconda: find version with Spyder IDE

↘锁芯ラ 提交于 2020-01-21 15:13:45
问题 I just ran into an issue. I had an installation of Anaconda from 2016, it was version 4.1. I then downloaded a new version of Anaconda version 5.1. I installed this version on windows 7. I have now 3 versions of Anaconda on my windows machine, one is for Anaconda with python-2 (v4.1 anaconda), and Anaconda v4.1 with python-3. And the new Anaconda v5.1 with Python-3. In the older versions when using Spyder IDE, when the console came up, it would state the python version and the version of

Pandas: cannot import name compat

时光怂恿深爱的人放手 提交于 2020-01-21 14:42:13
问题 I have some code, preprocess_align.py which runs perfectly on my PC but I get an ImportError when running it on a server. The ImportError supposedly comes when pandas is imported. Here is the error: Traceback (most recent call last): File "get_features.py", line 12, in <module> import preprocess_align as prep File "/home/influenza/preprocess_align.py", line 7, in <module> import pandas as pd File "/home/influenza/anaconda2/lib/python2.7/site-packages/pandas/__init__.py", line 42, in <module>

Anaconda搭建Django环境

萝らか妹 提交于 2020-01-21 14:28:48
Anaconda是一个程序包管理器,一个环境管理器,一个Python数据科学发行版。使用Anaconda可以解决多版本Python环境共存、切换。支持 Linux, Mac, Windows系统 Django是Python语言开发的一个开源web框架,遵循MVC设计模式,Django提供多种功能组件,让开发更简便快捷。 开始搭建环境(我这里使用的是MacOS Anaconda3) Anaconda下载链接:https://www.anaconda.com/distribution/ 按照提示安装就行,windows记得把环境变量勾选上。 1.创建一个新的环境 conda create -n DjangoPath python=3.5 这里DjangoPath是环境的名称,python=3.5是要安装的Python版本 2.进入环境 conda activate DjangoPath 3.安装Django pip install django==版本号 如果安装速度慢,可以换源(清华源:https://pypi.tuna.tsinghua.edu.cn/simple/ ) 4.创建Django项目 django-admin startproject mydjango 5.完成 来源: CSDN 作者: ChenHuang1998 链接: https://blog.csdn.net

conda update scikit-learn (also scipy and numpy)

南楼画角 提交于 2020-01-21 12:27:51
问题 I think I have made a mess using pip install when I am supposed to use conda. As a result I couldn't update the scikit-learn package to the latest version. I uninstalled scikit-learn with both conda and pip, and then installed again using conda but now I have issue import sklearn: Python 2.7.11 |Anaconda custom (x86_64)| (default, Dec 6 2015, 18:57:58) [GCC 4.2.1 (Apple Inc. build 5577)] on darwin Type "help", "copyright", "credits" or "license" for more information. Anaconda is brought to