diff --git a/ndbioimage/readers/cziread.py b/ndbioimage/readers/cziread.py index c97eef2..c345d7b 100644 --- a/ndbioimage/readers/cziread.py +++ b/ndbioimage/readers/cziread.py @@ -349,7 +349,7 @@ class OmeParse: model.Objective(id=f'Objective:Tubelens:{idx}', model=tube_lens, nominal_magnification=nominal_magnification)) elif self.version in ('1.1', '1.2'): - for tubelens in self.instrument.find('TubeLenses'): + for tubelens in self.def_list(self.instrument.find('TubeLenses')): try: nominal_magnification = float(re.findall(r'\d+(?:[,.]\d*)?', tubelens.attrib['Name'])[0].replace(',', '.')) @@ -384,8 +384,8 @@ class OmeParse: model.Laser( id=f"LightSource:{light_source.attrib['Id']}", power=float(self.text(light_source.find('Power'))), - wavelength=float(light_source.attrib['Id'][-3:]))) - except AttributeError: + wavelength=float(light_source.attrib['Id'][-3:]))) # TODO: follow Id reference + except (AttributeError, ValueError): pass def get_filters(self) -> None: diff --git a/pyproject.toml b/pyproject.toml index 64ddff5..3937234 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "ndbioimage" -version = "2025.1.1" +version = "2025.1.2" description = "Bio image reading, metadata and some affine registration." authors = ["W. Pomp "] license = "GPLv3"