随笔分类 - python相关
摘要:python -m http.server 之后可以局域网内,可以通过web浏览器访问和下载文件,也可以使用 wget 命令下载文件
阅读全文
摘要:步骤: 用户通过浏览器请求一个页面 请求到达Request Middlewares,中间件对request做一些预处理或者直接response请求 URLConf通过urls.py文件和请求的URL找到相应的View View Middlewares被访问,它同样可以对request做一些处理或者直
阅读全文
摘要:用miniforge3 conda 代替之前的anaconda; 安装Numpy / Pandas 等时必须先:conda install openblas;否则会报错 libcblas.3.dylib (no such file)
阅读全文
摘要:在一定的python环境下执行命令 pip install --user jupyter 成功后,执行命令 python -m IPython notebook or jupyter notebook 打开网页即可
阅读全文
摘要:dict my_dict.setdefault(key, []).append(new_value) 比如,我们新建了这样一个字典:dd = defaultdict(list),如果键 'new-key' 在 dd 中还不存在的话,表达式 dd['new-key'] 会按照以下的步骤来行事。 (1)
阅读全文
摘要:Python库之Elasticsearch 与关系型数据库的对比 关系型数据库 Elasticsearch Databases 库 Indices 索引 Tables 表 Types 类型 Rows 行(记录) Documents 文档 Columns 列(字段) Fields 域(字段) 6.0
阅读全文
摘要:代码文件setup_c.py如下 from distutils.core import setup from Cython.Build import cythonize import os import shutil def all_path(dirname): result = [] # 所有的文
阅读全文
摘要:## python镜像源 ``` 阿里云 http://mirrors.aliyun.com/pypi/simple/ 中国科技大学 https://pypi.mirrors.ustc.edu.cn/simple/ douban http://pypi.douban.com/simple Pytho
阅读全文