上一页 1 ··· 7 8 9 10 11 12 下一页
  2020年10月18日
摘要: 数据预处理部分可以参考之前的那篇LDA模型 读取数据 import numpy as np import pandas as pd from pprint import pprint import xlrd #读取excel数据 import re import jieba #使用结巴进行中文分词 阅读全文
posted @ 2020-10-18 22:17 cookie的笔记簿 阅读(1526) 评论(0) 推荐(0) 编辑
  2020年9月23日
摘要: 报错: cv2.error: OpenCV(4.1.2) C:\projects\opencv-python\opencv\modules\imgproc\src\color.cpp:182: error: 解决措施: 把需要处理的图片转移到路径全是英文的文件下,不再报错。 阅读全文
posted @ 2020-09-23 15:28 cookie的笔记簿 阅读(242) 评论(0) 推荐(0) 编辑
  2020年9月15日
摘要: onenote和有道云都无法同步笔记了。 解决措施:打开IE浏览器,设置,Internet选项,高级,重置。 阅读全文
posted @ 2020-09-15 12:48 cookie的笔记簿 阅读(227) 评论(0) 推荐(0) 编辑
  2020年9月10日
摘要: '''类基于类创建对象时,每个对象都自动具备这种通用行为,然后可根据需要赋予每个对象独特的个性。根据类来创建对象被称为实例化。''' #根据dog类创建的每个实例都将存储名字和年龄,赋予每条小狗蹲下和打滚的能力 sit() roll_over() class Dog(): def __init__( 阅读全文
posted @ 2020-09-10 19:34 cookie的笔记簿 阅读(135) 评论(0) 推荐(0) 编辑
  2020年9月9日
摘要: 函数 #定义函数 def greet_user(): print("Hello!") greet_user() Hello! #向函数传递信息 def greet_user(username): print("Hello, " + username.title() + "!") greet_user 阅读全文
posted @ 2020-09-09 18:55 cookie的笔记簿 阅读(100) 评论(0) 推荐(0) 编辑
  2020年9月7日
摘要: #函数input(),程序暂停运行,等待用户输入一些文本,获取输入后,将其存储在一个变量中 message = input("tell me") print(message) tell mehi hi name = input("Please enter your name:") print("He 阅读全文
posted @ 2020-09-07 17:15 cookie的笔记簿 阅读(136) 评论(0) 推荐(0) 编辑
摘要: #字典,访问字典中的值 alien_0 = {'color':'green','points':5} print(alien_0['color']) print(alien_0['points']) green 5 #将值存储在变量中new_points中 new_points = alien_0[ 阅读全文
posted @ 2020-09-07 16:53 cookie的笔记簿 阅读(134) 评论(1) 推荐(0) 编辑
  2020年9月2日
摘要: 个人见解:像Excel import numpy as np import pandas as pd print(np.array([1,2,3,4,5])) [1 2 3 4 5] print(np.arange(1,10,1)) [1 2 3 4 5 6 7 8 9] print(np.arra 阅读全文
posted @ 2020-09-02 21:36 cookie的笔记簿 阅读(176) 评论(0) 推荐(0) 编辑
  2020年8月31日
摘要: 4.if语句 #一个简单示例 letters = ['aa','bb','cc','dd','ee'] for letter in letters: if letter == 'cc': print(letter.upper()) else: print(letter.title()) AaBbCC 阅读全文
posted @ 2020-08-31 15:03 cookie的笔记簿 阅读(123) 评论(0) 推荐(0) 编辑
摘要: 操作列表 遍历整个列表 避免缩进错误 创建数值列表 使用列表的一部分 元组 设置代码格式 littles = ['q','w','e','m'] for little in littles: print(little) #for循环 qw em #在for循环中执行更多的操作 for little 阅读全文
posted @ 2020-08-31 14:52 cookie的笔记簿 阅读(125) 评论(0) 推荐(0) 编辑
上一页 1 ··· 7 8 9 10 11 12 下一页