perf: 优化 processors、cache、packing 模块性能并简化 README

This commit is contained in:
2026-03-30 17:50:26 +08:00
parent 7baa3ea0c3
commit f67bad0d8b
5 changed files with 129 additions and 220 deletions
+1
View File
@@ -34,6 +34,7 @@ class IOHandler:
def save_h5(output_dir: str, file_name: str, tensor_group: Dict[str, List[Tensor]]) -> None:
os.makedirs(output_dir, exist_ok=True)
full_path = os.path.join(output_dir, f"{file_name}.h5")
with h5py.File(full_path, 'w') as f:
for key, tensors in tensor_group.items():
grp = f.create_group(key)