Anaconda

Anaconda equivalent of “setup.py develop”

二次信任 提交于 2020-01-03 11:01:31
问题 How can I install a package under development to an Anaconda environment? With pip: pip install -e /path/to/mypackage or with regular setuptools: python /path/to/mypackage/setup.py develop 回答1: Using either of those will work with Anaconda. Make sure that you have pip or setuptools installed into the conda environment you want to install into, and that you have it activated. 回答2: There is also conda develop available now. http://conda.pydata.org/docs/commands/build/conda-develop.html Update

DBF - encoding cp1250

扶醉桌前 提交于 2020-01-03 10:23:12
问题 I have dbf database encoded in cp1250 and I am reading this database using folowing code: import csv from dbfpy import dbf import os import sys filename = sys.argv[1] if filename.endswith('.dbf'): print "Converting %s to csv" % filename csv_fn = filename[:-4]+ ".csv" with open(csv_fn,'wb') as csvfile: in_db = dbf.Dbf(filename) out_csv = csv.writer(csvfile) names = [] for field in in_db.header.fields: names.append(field.name) #out_csv.writerow(names) for rec in in_db: out_csv.writerow(rec

Anaconda安装在D盘后无法在CMD窗口执行python命令

泄露秘密 提交于 2020-01-03 08:56:29
Anaconda安装在D盘后无法在CMD窗口执行python命令以及库的安装办法 解决办法: 1、添加环境变量 我的电脑——右键属性——高级系统设置——环境变量——双击变量PATH——将Anaconda和Scripts的路径加入即可,如下图所示: 库的安装办法 添加环境变量后,能够在CMD窗口运行python命令,但是仍然存在无法正常使用pip install命令(出现各种warning)。 解决办法: 1、下载python库后,例如下载selenium 2、CMD环境进入到selenium压缩包中的setup.py文件所在目录 3、运行 python setup.py install命令进行安装 Selenium和driver的下载地址 selenium+drvier下载地址 Firefox浏览器对应geckodriver下载地址:https://github.com/mozilla/geckodriver/releases Chrome浏览器对应chromedriver下载地址https://npm.taobao.org/mirrors/chromedriver/或者http://chromedriver.storage.googleapis.com/index.html IE浏览器对应IEDriverServer下载地址http://selenium-release

plt.show() hangs on OSX with Anaconda Python

给你一囗甜甜゛ 提交于 2020-01-03 07:20:21
问题 import matplotlib.pyplot as plt plt.figure() plt.show() ...crickets. The interpreter hangs and I can't seem to interrupt it. This is with Python 2.7.9 and Anaconda 2.2.0 (x86_64) on OSX. Does this happen for anyone else? How can I solve this problem? 回答1: Try starting Python using pythonw instead of python . 回答2: This is most likely an issue with your backend setting. If you want your plots to show up inline (inside of your notebook) import with this added line: import matplotlib.pyplot as

unable to execute 'x86_64-conda_cos6-linux-gnu-gcc': No such file or directory (pysam installation)

僤鯓⒐⒋嵵緔 提交于 2020-01-03 06:49:06
问题 I am trying to install pysam. After excecuting: python path/to/pysam-master/setup.py build This error is produced: unable to execute 'x86_64-conda_cos6-linux-gnu-gcc': No such file or directory error: command 'x86_64-conda_cos6-linux-gnu-gcc' failed with exit status 1 There are similar threads, but they all seem to address the problem assumig administriator rights, which I do not have. Is there a way around to install the needed files? DISCLAIMER: This question derived from a previous post of

Jupyter Notebook dead Kernel after Anaconda update

我怕爱的太早我们不能终老 提交于 2020-01-03 05:47:28
问题 I got the following problem. After update Anaconda because I got an error to import skimage.io to a project in Jupyter Notebook an even a greater error appear - Dead Kernel. Right now I could not ever start a project because the Jupyter gives the following error is: Copy/paste this URL into your browser when you connect for the first time, to login with a token: http://localhost:8888/? token=aaf85a5e18489792c87cce65d7a53a0263cd5c08cc7248b 6 [I 00:55:13.451 NotebookApp] Accepting one-time

Installing SenticNet package on Anaconda gives UnicodeDecodeError

[亡魂溺海] 提交于 2020-01-03 04:49:08
问题 When I try to install SenticNet for sentiment analysis using Conda it cannot find it. Then I tried pip install and I got the error: Collecting senticnet Using cached senticnet-0.3.3.tar.gz Complete output from command python setup.py egg_info: Traceback (most recent call last): File "<string>", line 20, in <module> File "C:\Users\A00220~1\AppData\Local\Temp\pip-build-ez4td4hb\senticnet\setup.py", line 20, in <module> license=open('LICENSE').read(), File "C:\Anaconda3\lib\encodings\cp1252.py",

Python——anaconda下的jupyter找不到pip下载的模块

╄→гoц情女王★ 提交于 2020-01-02 15:17:57
问题 :pip了pandas和sklearn模块到anaconda下的study3.7环境,可是打开juypter却找不到相应的模块。 解决思路 : 1.配置的本地python3.7环境变量下pip相应pandas和sklearn模块,均以安装成功。 1 pip install pandas 2 pip install sklearn 2.进入anconda的study3.7环境下pip和conda pandas和sklearn包,均以安装成功。 1 activate study3.7 2 pip install pandas 3 conda install pandas 4 pip install sklearn 5 conda install sklearn 3.查看study3.7下载安装包是否已有pandas和sklearn,也能找到pandas和sklearn。 1 conda list 4.查看anaconda navi的环境中是否已安装pandas和sklearn,发现pandas已安装,sklearn没有也无法下载。 5.尝试在环境变量中添加PYTHONPATH变量,变量设置为D:software\python3.7\Lib\site-packages,为本地python环境位置,该文件夹下有pandas和sklearn。 启动study3.7下的juypter

anaconda py3安装pypcap等网络库

廉价感情. 提交于 2020-01-02 11:29:23
https://blog.csdn.net/weixin_34342992/article/details/88004374 参考https://www.cnblogs.com/jackadam/p/8279080.html 报错Microsoft Visual C++ 14.0 is required. 不要挂V默认装 https://blog.csdn.net/vkingnew/article/details/89857774 pyshark 没有尝试 https://www.dazhuanlan.com/2019/10/08/5d9b696f67c9d/ https://www.jianshu.com/p/122f5bf8749e 然后命令行又做了下python setup.py install 运行测试代码 import pcap # list all of the Internet devices devs = pcap.findalldevs() print(*devs, sep='\n') pc = pcap.pcap(devs[3], promisc=True, immediate=True, timeout_ms=50) # fiter http pcakets pc.setfilter('tcp port 80') for ptime, pdata in pc:

How to view class objects in Spyder's variable explorer

拈花ヽ惹草 提交于 2020-01-02 06:19:29
问题 This is a repeat of this question. It seems that I can't view instances of my classes in the variable explorer in Python, when I'm debugging. There the answer claims that this is resolved, so I'm wondering what I'm doing wrong. 回答1: ( Spyder maintainer here ) By default we show builtins (ints, floats, strings, list, dicts and tuples), Numpy arrays and Dataframes in our Variable Explorer. If you want to see all objects present in your namespace, you need to go to the menu Tools > Preferences >