From 24cc0a42873e12b25985254d9b7ec168fea22565 Mon Sep 17 00:00:00 2001 From: jochenstahn Date: Fri, 9 Jan 2026 10:23:35 +0100 Subject: [PATCH 1/3] output name made up from sample name, mu and date --- eos/reduction_reflectivity.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/eos/reduction_reflectivity.py b/eos/reduction_reflectivity.py index b6488c9..765072b 100644 --- a/eos/reduction_reflectivity.py +++ b/eos/reduction_reflectivity.py @@ -104,6 +104,16 @@ class ReflectivityReduction: self.read_file_block(i, short_notation) # output + if self.config.output.outputName == 'fromEOS': + import datetime + _date = datetime.datetime.now().replace(microsecond=0).isoformat() + if self.header.sample.name: + _sampleName = self.header.sample.name.replace(' ', '_') + else: + _sampleName = 'unknown' + _mu = int(self.dataset.geometry.mu * 3) + self.config.output.outputName = f'{_sampleName}_{_mu:03}_{_date}' + logging.warning('output:') if 'Rqz.ort' in self.config.output.outputFormats: From 54f2169888fe85610dd3cb213ef8940472f96297 Mon Sep 17 00:00:00 2001 From: jochenstahn Date: Tue, 20 Jan 2026 08:08:10 +0100 Subject: [PATCH 2/3] changed cache path to `/home/amor/nicosdata/cache` --- eos/file_reader.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eos/file_reader.py b/eos/file_reader.py index 7f1cbc3..0638a08 100644 --- a/eos/file_reader.py +++ b/eos/file_reader.py @@ -29,7 +29,7 @@ except ImportError: AMOR_LOCAL_TIMEZONE = zoneinfo.ZoneInfo(key='Europe/Zurich') if platform.node().startswith('amor'): - NICOS_CACHE_DIR = '/home/amor/nicosdata/amor/cache/' + NICOS_CACHE_DIR = '/home/amor/nicosdata/cache/' GREP = '/usr/bin/grep "value"' else: NICOS_CACHE_DIR = None From 61ba1cf084f88489009097b0caf6ded09b702c5b Mon Sep 17 00:00:00 2001 From: jochenstahn Date: Tue, 20 Jan 2026 14:01:04 +0100 Subject: [PATCH 3/3] output name checking for default rather than string in code --- eos/reduction_reflectivity.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eos/reduction_reflectivity.py b/eos/reduction_reflectivity.py index 765072b..16d1884 100644 --- a/eos/reduction_reflectivity.py +++ b/eos/reduction_reflectivity.py @@ -104,7 +104,7 @@ class ReflectivityReduction: self.read_file_block(i, short_notation) # output - if self.config.output.outputName == 'fromEOS': + if self.config.output.is_default('outputName'): import datetime _date = datetime.datetime.now().replace(microsecond=0).isoformat() if self.header.sample.name: