diff --git a/stimela/cargo/base/aimfast/Dockerfile b/stimela/cargo/base/aimfast/Dockerfile index 004698bb9..7d0ff53b9 100644 --- a/stimela/cargo/base/aimfast/Dockerfile +++ b/stimela/cargo/base/aimfast/Dockerfile @@ -3,4 +3,4 @@ RUN docker-apt-install python3-pip \ python3-numpy RUN pip3 install --upgrade numpy -RUN pip3 install aimfast==1.0rc3 +RUN pip3 install aimfast==1.0rc11 diff --git a/stimela/cargo/cab/aimfast/parameters.json b/stimela/cargo/cab/aimfast/parameters.json index a722579d0..01d25fc75 100644 --- a/stimela/cargo/cab/aimfast/parameters.json +++ b/stimela/cargo/cab/aimfast/parameters.json @@ -75,21 +75,21 @@ "dtype": "int" }, { - "info": "Two tigger model (text/lsm.html) files to compare", - "delimiter": " ", - "name": "compare-models", - "io": "output", - "default": null, - "dtype": "list:file", + "info": "Tigger model (text/lsm.html) files to compare", + "delimiter": " ", + "name": "compare-models", + "io": "output", + "default": null, + "dtype": "list:file", "required": false }, { - "info": "Two residual (fits) files to compare. e.g: ['res1.fits:res2.fits']", - "delimiter": " ", - "name": "compare-residuals", - "io": "output", - "default": null, - "dtype": "list:file", + "info": "Residual (fits) files to compare. e.g: ['res1.fits', 'res2.fits']", + "delimiter": " ", + "name": "compare-residuals", + "io": "output", + "default": null, + "dtype": "list:file", "required": false }, { @@ -170,6 +170,14 @@ "required": false, "name": "fov-factor", "dtype": "float" + }, + { + "info": "aimfast fidelity results file (JSON format)", + "default": null, + "required": false, + "name": "fidelity-results", + "io": "output", + "dtype": "file" } ] } diff --git a/stimela/cargo/cab/aimfast/src/run.py b/stimela/cargo/cab/aimfast/src/run.py index 409e0c0c7..4a95c2c73 100644 --- a/stimela/cargo/cab/aimfast/src/run.py +++ b/stimela/cargo/cab/aimfast/src/run.py @@ -26,9 +26,15 @@ elif value is False: continue - if type(value) is list: - args += ['{0}{1} {2}'.format(cab['prefix'], name, - " ".join([val.replace(':output', '') for val in value]))] + if 'compare' in name: + compare = [] + for i, val in enumerate(value): + compare.append(val) + # Compare models/images in pairs + if i%2: + args += ['{0}{1} {2}'.format(cab['prefix'], + name, " ".join(compare))] + compare = [] else: args += ['{0}{1} {2}'.format(cab['prefix'], name, value)]