diff --git a/scripts/planktoscope/segmenter/__init__.py b/scripts/planktoscope/segmenter/__init__.py index d22b343..21474e3 100644 --- a/scripts/planktoscope/segmenter/__init__.py +++ b/scripts/planktoscope/segmenter/__init__.py @@ -601,7 +601,8 @@ class SegmenterProcess(multiprocessing.Process): # Publish the object_id to via MQTT to Node-RED self.segmenter_client.client.publish( - "status/segmenter", f'{{"status":"Segmenting image {filename}"}}' + "status/segmenter", + f'{{"status":"Segmenting image {filename}, image {i+1}/{images_count}"}}', ) # we recalculate the flat if the heuristics detected we should @@ -696,7 +697,7 @@ class SegmenterProcess(multiprocessing.Process): self.__working_obj_path, keep_files=True, ): - logger.succes("Ecotaxa archive export completed for this folder") + logger.success("Ecotaxa archive export completed for this folder") else: logger.error("The ecotaxa export could not be completed") else: diff --git a/scripts/planktoscope/segmenter/ecotaxa.py b/scripts/planktoscope/segmenter/ecotaxa.py index a67f4f0..b6f59c7 100644 --- a/scripts/planktoscope/segmenter/ecotaxa.py +++ b/scripts/planktoscope/segmenter/ecotaxa.py @@ -241,13 +241,13 @@ def ecotaxa_export(archive_filepath, metadata, image_base_path, keep_files=False # add the tsv to the archive archive.writestr( - "export_ecotaxa.tsv", + "ecotaxa_export.tsv", io.BytesIO( tsv_content.to_csv(sep="\t", encoding="utf-8", index=False).encode() ).read(), ) if keep_files: - tsv_file = os.path.join(image_base_path, "export_ecotaxa.tsv") + tsv_file = os.path.join(image_base_path, "ecotaxa_export.tsv") tsv_content.to_csv( path_or_buf=tsv_file, sep="\t", encoding="utf-8", index=False )