Python中包的用法及安裝
本篇文章介紹了Python中一些常見的包的作用和安裝方法,希望對(duì)學(xué)習(xí)Python中的朋友有幫助!
Python中一些包的基本用處和安裝方法
pika可以用來連接RabbitMQ
pip install pika -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
requests是HTTP庫
Request支持HTTP連接保持和連接池,支持使用cookie保持會(huì)話,支持文件上傳,支持自動(dòng)響應(yīng)內(nèi)容的編碼,支持國際化的URL和POST數(shù)據(jù)自動(dòng)編碼。
pip install requests -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
SQLAlchemy是ORM框架
pip install SQLAlchemy -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
pymongo是連接mongodb的庫
pip install pymongo -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
MySQL-python是連接mysql的庫
apt-get install python-mysqldb
gearman分布式任務(wù)系統(tǒng)
pip install gearman -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
lxml是python的一個(gè)解析庫,支持HTML和XML的解析
pip install lxml -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
elasticsearch庫,es的客戶端庫
pip install elasticsearch -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
pycurl是curl庫
pip install pycurl -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
報(bào)錯(cuò)
__main__.ConfigurationError: Could not run curl-config: [Errno 2] No such file or directory
apt-get install libcurl4-openssl-dev
以上就是Python中一些包的基本用處和安裝方法的詳細(xì)內(nèi)容,如果大家有任何補(bǔ)充可以聯(lián)系腳本之家小編。
相關(guān)文章
python數(shù)據(jù)庫操作指南之PyMysql使用詳解
PyMySQL是在Python3.x版本中用于連接MySQL服務(wù)器的一個(gè)庫,Python2 中則使用mysqldb,下面這篇文章主要給大家介紹了關(guān)于python數(shù)據(jù)庫操作指南之PyMysql使用的相關(guān)資料,需要的朋友可以參考下2023-03-03

基于Tensorflow搭建一個(gè)神經(jīng)網(wǎng)絡(luò)的實(shí)現(xiàn)

新手入門學(xué)習(xí)python Numpy基礎(chǔ)操作

opencv實(shí)踐項(xiàng)目之圖像拼接詳細(xì)步驟

python檢測lvs real server狀態(tài)