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)