levels of contents
摘要: 生成器 生成器是用来生成数据的一个办法 yield关键字 yield相当于是return,当函数运行到这里之后会暂停,并且返回后面的变量给调用的位置 yield是没有返回值的,所以 num = yield a,这个时候num的值是None next()函数可以使函数接着运行下去 每一次next()都 阅读全文
posted @ 2023-03-08 17:26 niko5960 阅读(31) 评论(0) 推荐(0)
摘要: pandas 阅读全文
posted @ 2023-03-08 16:48 niko5960 阅读(9) 评论(0) 推荐(0)
摘要: numpy ndarray #参数 numpy.array(object, dtype = None, copy = True, order = None, subok = False, ndmin = 0) object 数组 dtype 数组元素的数据类型 copy 是否可复制 order 创建 阅读全文
posted @ 2023-03-06 17:29 niko5960 阅读(40) 评论(0) 推荐(0)
摘要: 多线程的两种实现方式 方法1:直接使用threading.Thread() import threading def run(n): print("current task:", n) if __name__ == "__main__": t1 = threading.Thread(target=r 阅读全文
posted @ 2023-03-03 11:20 niko5960 阅读(34) 评论(0) 推荐(0)