feat: implement DTW comparison, add data segmentation and persistence, and update QML UI for file imports and graphing.

This commit is contained in:
jack
2026-06-23 21:38:45 -07:00
parent 20a34e22ee
commit 62ce5a9c37
16 changed files with 1049 additions and 8 deletions
+20
View File
@@ -45,3 +45,23 @@ class CsvRecorder:
self._file_handle.close()
path, self._file_handle, self._path = self._path, None, None
return path
@staticmethod
def write_segment(file_path: str, source_path: str, start_frame: int, end_frame: int) ->bool:
"""Copy a range of frames from source CSV into a new file.
Args:
file_path: Output CSV path.
source_path: Source CSV path with full wafer data
start_frame: First frame index (inclusive).
end_frame: Last frame index (inclusive)
Returns:
True on success.
"""
import pandas as pd
df = pd.read_csv(source_path)
segment = df.iloc[start_frame:end_frame + 1]
segment.to_csv(file_path, index=False)
return True