摘要: 1.安装Selenium pip install selenium 2.下载 ChromeDriver: 首先你是否已经安装了 Chrome 浏览器。有的话找到chrome浏览器的版本信息,然后,访问 ChromeDriver 的官方网站(https://chromedriver.chromium. 阅读全文
posted @ 2024-03-23 01:45 月下云生 阅读(81) 评论(0) 推荐(0) 编辑
摘要: 1.依赖插件等无需每次打包都重新打包 vite.config.js文件中配置 export default () => { return { build: { sourcemap: false, manifest: true, rollupOptions: { output: { manualChu 阅读全文
posted @ 2024-03-10 22:06 月下云生 阅读(7) 评论(0) 推荐(0) 编辑
摘要: 1.cesium插件引入,vite-plugin-cesium 是一个专门为 Vite 构建工具定制的插件,用于在 Vite 项目中轻松使用 Cesium 库。它简化了在 Vite 项目中集成 Cesium 的过程,并提供了一些额外的功能和配置选项。而直接安装 Cesium 库,你需要手动配置 Vi 阅读全文
posted @ 2024-03-06 17:18 月下云生 阅读(215) 评论(0) 推荐(0) 编辑
摘要: UDP协议 用户数据包协议 socket bind() sendall() recvfrom() sendto() close() TCP服务器端流程: 使用socket类创建一个套接字对象 使用bind((ip,port))方法绑定ip地址和端口号 使用listen()方法开始TCP监听 使用ac 阅读全文
posted @ 2024-02-23 17:48 月下云生 阅读(1) 评论(0) 推荐(0) 编辑
摘要: 操作文件步骤 打开/创建 变量名 = open(filename,mode,encoding) 操作 变量名.read() 变量名.write() 关闭 变量名.close() with open(...) as file: pass json模块 json.dumps(obj) json(lst, 阅读全文
posted @ 2024-02-15 21:47 月下云生 阅读(1) 评论(0) 推荐(0) 编辑
摘要: 自定义模块优先级大于系统模块 模块分为系统模块,自定义模块,第三方模块 导入方式 import 模块名称 [as 别名] from 模块名称 import 变量/函数/类* 包的导入 import 包名.模块名 as 别名 form 包名 import 模块名 as 别名 form 包名.模块名 i 阅读全文
posted @ 2024-02-14 21:38 月下云生 阅读(3) 评论(0) 推荐(0) 编辑
摘要: 类 创建 class 类名 (): # 类名首字母大写,()可写可不写 pass 对象 对象名 = 类名() 类的组成 class Student: school ='北京xx学校' # 类属性,定义在类中方法外的变量 # 初始方法 def __init__ (self,xm,age): self. 阅读全文
posted @ 2024-02-13 01:01 月下云生 阅读(1) 评论(0) 推荐(0) 编辑
摘要: 异常处理 try-except try-except-except try-except-except-else try-except-except-else-finally: raise关键字 raise Exception('自定义异常') 异常类型 ZeroDivisionError 除数为零 阅读全文
posted @ 2024-02-11 20:52 月下云生 阅读(1) 评论(0) 推荐(0) 编辑
摘要: 字符串 不可变数据类型 字符串的常用操作方法: lower() 转小写 upper() 转大写 split('') 分割 count('x') 包含个数 find() index() endswith() 以什么结尾 startswith() 以什么开始 replace() 替换 (lod,new, 阅读全文
posted @ 2024-02-06 01:11 月下云生 阅读(1) 评论(0) 推荐(0) 编辑
摘要: range python内置函数,产生一个(n,m)的整数序列,包含n不包含m 组合数据类型 切片 访问序列的一种方法 系列[start:end:step] 列表 是指一系列的按照特定顺序排列的元素组成 使用[]直接创建 列表名 = [element1,element2,element3,...] 阅读全文
posted @ 2024-02-06 01:10 月下云生 阅读(1) 评论(0) 推荐(0) 编辑