Commit 2e6c1f1d authored by mancini's avatar mancini

Merge branch 'LoSoTo-FlagStation' into 'master'

Add LoSoTo flag station - Resolves EOSC-27

See merge request !8
parents 3514a5b4 19a31cec
Pipeline #488 passed with stages
in 3 minutes and 39 seconds
......@@ -119,7 +119,11 @@ losoto_flagextend:
allow_failure: true
script:
- cwl-runner --no-container steps/LoSoTo.Flagextend.cwl test_jobs/losoto_flagextend.json
losoto_flagstation:
stage: test_steps
allow_failure: true
script:
- cwl-runner --no-container steps/LoSoTo.FlagStation.cwl test_jobs/losoto_flagstation.json
losoto_faraday:
stage: test_steps
allow_failure: true
......
#!/usr/bin/env cwl-runner
class: CommandLineTool
cwlVersion: v1.0
id: losoto_flagstation
$namespaces:
lofar: https://git.astron.nl/eosc/ontologies/raw/master/schema/lofar.owl
doc: |
This operation for LoSoTo implements a station-flagging procedure. Flags are time-independent.
WEIGHT: compliant
requirements:
InlineJavascriptRequirement:
expressionLib:
- { $include: utils.js}
InitialWorkDirRequirement:
listing:
- entryname: 'parset.config'
entry: $(get_losoto_config('FLAGSTATION').join('\n'))
- entryname: $(inputs.input_h5parm.basename)
entry: $(inputs.input_h5parm)
writable: true
baseCommand: "losoto"
arguments:
- $(inputs.input_h5parm.basename)
- parset.config
hints:
DockerRequirement:
dockerPull: lofareosc/lofar-pipeline-ci:latest
inputs:
- id: input_h5parm
type: File
format: lofar:#H5Parm
- id: soltab
type: string
doc: "Solution table"
- id: mode
type:
type: enum
symbols:
- bandpass
- resid
doc: |
Fitting algorithm: bandpass or resid. Bandpass mode clips amplitudes
relative to a model bandpass (only LOFAR is currently supported).
Resid mode clips residual phases or log(amplitudes).
- id: maxFlaggedFraction
type: float?
doc: |
This sets the maximum allowable fraction of flagged solutions above
which the entire station is flagged.
- id: nSigma
type: float?
doc: |
This sets the number of standard deviations considered when outlier
clipping is done.
- id: maxStddev
type: float?
doc: |
Maximum allowable standard deviation when outlier clipping is done. For phases, this should value
should be in radians, for amplitudes in log(amp). If None (or negative), a value of 0.1 rad is
used for phases and 0.01 for amplitudes.
- id: ampRange
type: float[]?
doc: |
2-element array of the median amplitude level to be acceptable,
ampRange[0]: lower limit, ampRange[1]: upper limit.
If None or [0, 0], a reasonable range for typical observations is used.
- id: telescope
type: string?
doc: Specifies the telescope if mode = 'bandpass'.
- id: skipInternational
type: string?
doc: |
If True, skip flagging of international LOFAR stations (only used if
telescope = 'lofar')
- id: refAnt
type: string?
doc: |
If mode = resid, this sets the reference antenna for phase solutions,
by default None.
- id: soltabExport
type: string?
doc: |
Soltab to export station flags to. Note: exported flags are not time- or
frequency-dependent.
- id: ncpu
type: int?
doc: Number of cpu to use, by default all available.
outputs:
- id: output_h5parm
type: File
format: lofar:#H5Parm
outputBinding:
glob: $(inputs.input_h5parm.basename)
$schema:
- https://git.astron.nl/eosc/ontologies/raw/master/schema/lofar.owl
{
"input_h5parm": {"class": "File", "path": "/data/example.h5", "format": "lofar:#H5Parm"},
"soltab": "sol000/amplitude000",
"mode": "bandpass"
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment