Skip to content

Commit

Permalink
Merge pull request #29 from mmzdouc/dev_mmz
Browse files Browse the repository at this point in the history
Fixed bug in SummaryWriter
  • Loading branch information
mmzdouc authored May 26, 2024
2 parents 8882ac8 + 7540251 commit 82cde8e
Show file tree
Hide file tree
Showing 3 changed files with 43 additions and 30 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,12 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm

N/A

## [0.2.1] 26-05-2024

### Fixed

- Fixed bug in "SummaryWriter": implemented error catching.

## [0.2.0] 26-05-2024

### Changed
Expand Down
65 changes: 36 additions & 29 deletions fermo_core/input_output/class_summary_writer.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,9 +133,9 @@ def summarize_featurefilteringparameters(self: Self):
self.summary.append(
f"Molecular features were filtered and only retained if they were "
f"inside the relative area range of "
f"'{self.params.FeatureFilteringParameters.filter_rel_int_range[0]}"
f"'{self.params.FeatureFilteringParameters.filter_rel_area_range[0]}"
f"-"
f"{self.params.FeatureFilteringParameters.filter_rel_int_range[1]}'"
f"{self.params.FeatureFilteringParameters.filter_rel_area_range[1]}'"
f" in at least one sample (relative to the feature with the "
f"highest area in the sample)."
)
Expand Down Expand Up @@ -349,30 +349,37 @@ def summarize_askcbdeepscorematchingparams(self: Self):

def assemble_summary(self: Self):
"""Call methods to assemble the summary file"""
logger.debug("'SummaryWriter': Started summary: files")
self.summarize_peaktableparameters()
self.summarize_msmsparameters()
self.summarize_phenotypeparameters()
self.summarize_groupmetadataparameters()
self.summarize_speclibparameters()
self.summarize_ms2queryresultsparameters()
self.summarize_asresultsparameters()
logger.debug("'SummaryWriter': Completed summary: files")
logger.debug("'SummaryWriter': Started summary: analysis modules")
self.summarize_featurefilteringparameters()
self.summarize_adductannotationparameters()
self.summarize_neutrallossparameters()
self.summarize_fragmentannparameters()
self.summarize_specsimnetworkcosineparameters()
self.summarize_specsimnetworkdeepscoreparameters()
self.summarize_blankassignmentparameters()
self.summarize_groupfactassignmentparameters()
self.summarize_phenoqualassgnparams()
self.summarize_phenoquantpercentassgnparams()
self.summarize_phenoquantconcassgnparams()
self.summarize_spectrallibmatchingcosineparameters()
self.summarize_spectrallibmatchingdeepscoreparameters()
self.summarize_ms2queryannotationparameters()
self.summarize_askcbcosinematchingparams()
self.summarize_askcbdeepscorematchingparams()
logger.debug("'SummaryWriter': Completed summary: analysis modules")
try:
logger.debug("'SummaryWriter': Started summary: files")
self.summarize_peaktableparameters()
self.summarize_msmsparameters()
self.summarize_phenotypeparameters()
self.summarize_groupmetadataparameters()
self.summarize_speclibparameters()
self.summarize_ms2queryresultsparameters()
self.summarize_asresultsparameters()
logger.debug("'SummaryWriter': Completed summary: files")
logger.debug("'SummaryWriter': Started summary: analysis modules")
self.summarize_featurefilteringparameters()
self.summarize_adductannotationparameters()
self.summarize_neutrallossparameters()
self.summarize_fragmentannparameters()
self.summarize_specsimnetworkcosineparameters()
self.summarize_specsimnetworkdeepscoreparameters()
self.summarize_blankassignmentparameters()
self.summarize_groupfactassignmentparameters()
self.summarize_phenoqualassgnparams()
self.summarize_phenoquantpercentassgnparams()
self.summarize_phenoquantconcassgnparams()
self.summarize_spectrallibmatchingcosineparameters()
self.summarize_spectrallibmatchingdeepscoreparameters()
self.summarize_ms2queryannotationparameters()
self.summarize_askcbcosinematchingparams()
self.summarize_askcbdeepscorematchingparams()
logger.debug("'SummaryWriter': Completed summary: analysis modules")
except Exception as e:
logger.error(str(e))
logger.error(
"SummaryWriter: error occurred during writing of summary. "
"Write steps until error occurred."
)
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "fermo_core"
version = "0.2.0"
version = "0.2.1"
description = "Data processing/analysis functionality of metabolomics dashboard FERMO"
readme = "README.md"
requires-python = ">=3.11,<3.12"
Expand Down

0 comments on commit 82cde8e

Please sign in to comment.