other_files
detect_log_type ¶
Detect the type of log file based on its structure and content.
Parameters:
Returns:
-
str–String indicating the log type ('FT', 'HTHPIR', 'LPIR', 'Robert', 'unknown')
Source code in src/chromstream/parsers/other_files.py
parse_MTO_asc ¶
parse_MTO_asc(
Path: str | Path,
) -> tuple[Chromatogram, Chromatogram, Chromatogram]
Parses an ASCII file. from the MTO setup. The file contains the chromatograms for all channels under each other.
Parameters:
Returns:
-
tuple[Chromatogram, Chromatogram, Chromatogram]–The Chromatogram objects.
Source code in src/chromstream/parsers/other_files.py
parse_MTO_metadata ¶
Parses the metadata section from an MTO ASCII file and returns it as a dictionary.
Parameters:
Returns:
-
dict(dict) –Dictionary containing metadata with cleaned keys and processed values.
Source code in src/chromstream/parsers/other_files.py
parse_log_MTO ¶
Source code in src/chromstream/parsers/other_files.py
parse_log_file ¶
Automatically detect and parse any supported log file type. To be extended.
Parameters:
Returns:
-
DataFrame–Parsed DataFrame with metadata as attributes
Raises:
-
ValueError–If the file type is not recognized or supported
Source code in src/chromstream/parsers/other_files.py
parse_log_type_ft ¶
Parse FT type log files.
Parameters:
Returns:
-
DataFrame–Parsed DataFrame with metadata as attributes
Source code in src/chromstream/parsers/other_files.py
parse_log_type_hthpir ¶
Parse HTHPIR type log files.
Parameters:
Returns:
-
DataFrame–Parsed DataFrame with metadata as attributes
Source code in src/chromstream/parsers/other_files.py
273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 | |
parse_log_type_lpir ¶
Parse LPIR type log files.
Parameters:
Returns:
-
DataFrame–Parsed DataFrame with metadata as attributes
Source code in src/chromstream/parsers/other_files.py
parse_log_type_robert ¶
Parse Robert type log files.
Parameters:
Returns:
-
DataFrame–Parsed DataFrame with metadata as attributes
Source code in src/chromstream/parsers/other_files.py
parse_metadata_section ¶
Parse the metadata section at the top of log files.
Parameters:
-
lines(list) –List of lines from the file
Returns: