chore: 批量新增各类工具脚本与配置文件
1. 新增音频录制、下载、上传相关脚本 2. 新增数据库操作、API调用工具 3. 新增Excel数据处理脚本 4. 新增弱密码检测脚本
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
import pandas as pd
|
||||
import sys
|
||||
|
||||
# 读取Excel文件
|
||||
file_path = r'e:\project\python\工具\智慧校园\本部\消费数据\2024学生.xlsx'
|
||||
df = pd.read_excel(file_path)
|
||||
|
||||
print("数据形状:", df.shape)
|
||||
print("\n列名:")
|
||||
for i, col in enumerate(df.columns):
|
||||
print(f"{i+1}. {col}")
|
||||
|
||||
print("\n前5行数据:")
|
||||
print(df.head().to_string())
|
||||
|
||||
# 检查年级和班级相关字段
|
||||
print("\n查找年级/班级相关字段...")
|
||||
for col in df.columns:
|
||||
if any(keyword in str(col) for keyword in ['年级', '班级', 'grade', 'class', 'Grade', 'Class']):
|
||||
print(f"找到字段: {col}")
|
||||
print(f"唯一值: {df[col].unique()[:10]}") # 只显示前10个唯一值
|
||||
|
||||
print("\n数据类型:")
|
||||
print(df.dtypes)
|
||||
Reference in New Issue
Block a user