![](https://img-blog.csdnimg.cn/20201014180756926.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
python
文章平均质量分 81
acuteracuter
这个作者很懒,什么都没留下…
展开
-
python笔记
1)__ -- 对返回值不感兴趣的变量,例子 def fun() return 1.2.3 fi1,__,__ =fun() 2)每个class和实例都有一个__dict__ >>> class A: ... def __init__(self): ... self.a=10 ... self...原创 2018-12-05 15:24:31 · 92 阅读 · 0 评论 -
numpy的元素或
>>> a array([[[ 0., 0., 0., 0.], [ 0., 0., 0., 0.], [ 0., 0., 0., 0.]], [[ 0., 0., 0., 0.], [ 0., 255., 0., 0.], [ ...原创 2019-02-26 22:51:57 · 600 阅读 · 0 评论 -
色差处理
https://www.cnblogs.com/wangyong/p/9119394.html 图像色差处理-光照问题3种处理方法 https://blog.csdn.net/yingchunhua365/article/details/14044773 背景颜色的去处方法,提取肤色 https://www.cnblogs.com/Py00/p/8876825.html OpenC...转载 2019-03-03 10:24:59 · 1437 阅读 · 0 评论 -
点集(contours)相加
def addBlob(blobInfs,contours): #同种颜色块合并 blob = colorBlobInfo() blob.area=0 ct = np.empty(shape= [0,1,2],dtype=np.int32) for bl in blobInfs: blob.area += bl.area ct=np.appen...原创 2019-02-28 17:19:12 · 520 阅读 · 0 评论 -
python常见问题
程序崩溃 1、对象调用不合适的函数,一般是用错对象变量了 如 r = self.stateTable.currentRow() 写成 r = self.combineList.currentRow() 其中combineList是list对象,stateTable是 QTableWidget的派生对象,currentRow是其自定义的函数 2、没有import对应的文件 ...原创 2019-01-18 09:06:56 · 108 阅读 · 0 评论 -
numpy.reshape
C:\Users\comba>ipython Python 3.5.3 (v3.5.3:1880cb95a742, Jan 16 2017, 16:02:32) [MSC v.1900 64 bit (AM D64)] Type 'copyright', 'credits' or 'license' for more information IPython 7.1.1 -- An enhan...原创 2018-12-18 20:09:35 · 271 阅读 · 0 评论 -
NumPy基本方法
一、数组方法 创建数组:arange()创建一维数组;array()创建一维或多维数组,其参数是类似于数组的对象,如列表等 读取数组元素:如a[0],a[0,0] 数组变形:如b=a.reshape(2,3,4)将得到原数组变为2*3*4的三维数组后的数组;或是a.shape=(2,3,4)或a.resize(2,3,4)直接改变数组a的形状 数组组合:水平组合hstack((a,b...转载 2018-12-28 17:06:19 · 216 阅读 · 0 评论 -
一些工具
1、jupyter notebook 用途:交互式笔记本,在里面运行python等,较为方便,特别是看帮助翻页等2 安装网站及命令http://jupyter.org/install pip install jupyter 安装完成后在命令行里运行jupyter notebook 2、help help(cv2.findContours) 建议在jupyter下看 help...转载 2018-12-20 17:41:56 · 195 阅读 · 0 评论 -
numpy 常用
这里写自定义目录标题欢迎使用Markdown编辑器新的改变功能快捷键合理的创建标题,有助于目录的生成如何改变文本的样式插入链接与图片如何插入一段漂亮的代码片生成一个适合你的列表创建一个表格设定内容居中、居左、居右SmartyPants创建一个自定义列表如何创建一个注脚注释也是必不可少的KaTeX数学公式新的甘特图功能,丰富你的文章UML 图表FLowchart流程图导出与导入导出导入 欢迎使用Ma...原创 2019-03-20 19:22:19 · 120 阅读 · 0 评论