我的个人小站
02
28
git代理问题 git代理问题
开启代理 git config --global https.proxy http://127.0.0.1:1080 git config --global https.proxy https://127.0.0.1:1080 取消代理
2020-02-28
28
28
28
下载图片 下载图片
下载图片的三种方式 os.makedirs('./image/', exist_ok=True) IMAGE_URL = "http://image.nationalgeographic.com.cn/2017/1122/20171122
2020-02-28
28
文件处理相关 文件处理相关
1.判断文件是否存在 os.path.isfile('test.txt') 2.文件夹是否存在 os.path.exists(directory) 3.创建文件夹 os.makedirs("imgs")
2020-02-28
28
数组合并 数组合并
1.直接用+号2.使用extend array=array1.extend(array2)3.使用np import numpy as np arr1=[1,2,3] arr2=[4,5,6] print(np.append(arr1,ar
2020-02-28
28
多线程 多线程
这主要介绍一下treading模块 最简单的方法 tred=threading.Thread(target=start) tred.start() #开始线程 tred.join() #等待线程介绍 注意一定要写target,要不然启动的就
2020-02-28
28
全局变量和类 全局变量和类
全局变量a = 3 def Fuc(): global a print (a) if __name__ == "__main__": print (a) 直接在函数外面申明一下就是全局变量了,如果需要访问,在函数内
2020-02-28
28
PythonGUI库 PythonGUI库
看了网上挺多介绍,最后还是选择了Tkinter库,这个好像是Python标准的GUI库。下面我们简单的使用一下它吧。 找了半天最后还是决定直接看官方文档:https://docs.python.org/zh-cn/3.7/library/t
2020-02-28
28
81 / 105