From c1bba778b9388bdf2c6a5d6d35fc3a208949aac0 Mon Sep 17 00:00:00 2001 From: Holger Frey Date: Thu, 20 Oct 2022 14:14:50 +0200 Subject: [PATCH] removed debugging output --- src/sensospot_parser/__init__.py | 7 +++---- src/sensospot_parser/parser.py | 1 - src/sensospot_parser/recordtime.py | 4 ---- 3 files changed, 3 insertions(+), 9 deletions(-) diff --git a/src/sensospot_parser/__init__.py b/src/sensospot_parser/__init__.py index 1ad604a..19fb897 100644 --- a/src/sensospot_parser/__init__.py +++ b/src/sensospot_parser/__init__.py @@ -3,10 +3,9 @@ Parsing the numerical output from Sensovations Sensospot image analysis. """ -__version__ = "0.9.0" +__version__ = "0.9.1" -import sys from pathlib import Path import click @@ -67,10 +66,10 @@ def _output(data, folder, outfile): outfile: the name of the outfile, '-' will output to stdout """ if outfile.strip() == "-": - data.to_csv(sys.stdout, sep="\t") + click.echo(data.to_csv(None, sep="\t", index=False)) else: csv_file = Path(folder) / outfile - data.to_csv(csv_file, sep="\t") + data.to_csv(csv_file, sep="\t", index=False) def _parse_one_folder(source, outfile, quiet): diff --git a/src/sensospot_parser/parser.py b/src/sensospot_parser/parser.py index 799afa5..73f0656 100644 --- a/src/sensospot_parser/parser.py +++ b/src/sensospot_parser/parser.py @@ -227,7 +227,6 @@ def parse_folder(folder: PathLike, quiet: bool = False) -> pandas.DataFrame: raise ValueError(f"No sensospot data found in folder '{folder}'") data_frame = add_measurement_parameters(data_frame, folder_path) data_frame = add_record_time(data_frame, folder_path) - print(data_frame) if quiet: return data_frame return _sanity_check(data_frame) diff --git a/src/sensospot_parser/recordtime.py b/src/sensospot_parser/recordtime.py index 7d7c721..6bda6c8 100644 --- a/src/sensospot_parser/recordtime.py +++ b/src/sensospot_parser/recordtime.py @@ -90,13 +90,9 @@ def add_record_time( the measurement data with parameters added """ record_path = _search_records_file(folder) - print(f"PATH: {record_path}") if record_path is None: - print("assuming record path is None") measurement[columns.ANALYSIS_DATETIME] = numpy.NAN return measurement data_frame = _parse_records_file(record_path) - print(data_frame) - print(measurement[columns.ANALYSIS_IMAGE].iloc[0]) return measurement.merge(data_frame, how="left", on=columns.ANALYSIS_IMAGE)