上一页 1 ··· 4 5 6 7 8 9 10 11 12 下一页
摘要: 一、针对当前终端生效 最近云服务器安装了centos7系统,python默认版本是2.7.5,但是习惯用anaconda3, 安装anaconda3之后将系统默认python版本更改为python3。 只需执行命令: alias python=/root/anaconda3/bin/python / 阅读全文
posted @ 2018-12-15 23:02 GavinSimons 阅读(1219) 评论(0) 推荐(0) 编辑
摘要: 网址: https://www.lfd.uci.edu/~gohlke/pythonlibs/ 包含了Ta-Lib和PyQt4等模块。 阅读全文
posted @ 2018-12-01 19:37 GavinSimons 阅读(508) 评论(0) 推荐(0) 编辑
摘要: 针对dataframe中的某一行(或列)想做批量字符串处理时,可采用此方法 series.str.python内置的str方法 例如: series.str.replace('A','B') # 整个series中所有字符串全部执行替换操作 python内置str方法汇总: https://www. 阅读全文
posted @ 2018-11-21 13:24 GavinSimons 阅读(1540) 评论(0) 推荐(0) 编辑
摘要: 文章介绍了一种采用循环的方式生产协程列表,并可以向协程函数传递参数。。。# 协程引用import gevent from gevent import monkey, pool monkey.patch_all() # 初始化协程池 poolNum = 10 pool = pool.Pool(pool 阅读全文
posted @ 2018-11-20 12:32 GavinSimons 阅读(622) 评论(0) 推荐(0) 编辑
摘要: https://blog.csdn.net/Trader_Python/article/list/1 阅读全文
posted @ 2018-11-17 00:41 GavinSimons 阅读(523) 评论(0) 推荐(0) 编辑
摘要: 接触VNPY一年多,一直对作者设计原理和思想有所困惑。发一篇vnpy官网的说明文档,便于以后理解项目代码。 http://www.vnpy.org/archives.html 阅读全文
posted @ 2018-11-17 00:15 GavinSimons 阅读(1882) 评论(0) 推荐(0) 编辑
摘要: 转载自http://blog.csdn.net/dcrmg/article/details/52215930 做视频样本切割,切片用ffv1编码,比原数据大了几十倍,看到了这篇文章,防止找不到记录一下 打开视频文件或摄像头视频需要使用Opencv中的VideoCapture类,保存视频或摄像头视频到 阅读全文
posted @ 2018-11-13 00:58 GavinSimons 阅读(3004) 评论(0) 推荐(0) 编辑
摘要: 本文链接自http://www.myhack58.com/Article/48/66/2016/71806.htm 当你安装 Debian Linux 时,安装过程有可能同时为你提供多个可用的 Python 版本,因此系统中会存在多个 Python 的可执行二进制文件。你可以按照以下方法使用 ls  阅读全文
posted @ 2018-07-23 16:39 GavinSimons 阅读(259) 评论(0) 推荐(0) 编辑
摘要: try: 1/0 except Exception,e: print e 输出结果是integer division or modulo by zero,只知道是报了这个错,但是却不知道在哪个文件哪个函数哪一行报的错。 下面使用traceback模块 import traceback try: 1/ 阅读全文
posted @ 2018-07-23 14:30 GavinSimons 阅读(511) 评论(0) 推荐(0) 编辑
摘要: python 中给文件加锁——fcntl模块import fcntl打开一个文件##当前目录下test文件要先存在,如果不存在会报错。或者以写的方式打开f = open('./test')对该文件加密:fcntl.flock(f,fcntl.LOCK_EX)这样就对文件test加锁了,如果有其他进程 阅读全文
posted @ 2018-07-09 14:16 GavinSimons 阅读(562) 评论(0) 推荐(0) 编辑
上一页 1 ··· 4 5 6 7 8 9 10 11 12 下一页