Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion steps/average_intermediate_resolution.cwl
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,14 @@ inputs:
itemSeparator: ','
valueFrom: "[$(self.map(function(d) { return d.path || d.location; }).join(','))]"

- id: ncpu
type: int?
default: 24
inputBinding:
position: 1
shellQuote: false
prefix: 'numthreads='

outputs:
- id: ms_avg
doc: |
Expand All @@ -44,6 +52,7 @@ arguments:
- msout=concat_1asec.ms
- bdaaverager.timebase=70e3
- bdaaverager.maxinterval=32
- numthreads=$(inputs.ncpu)

requirements:
- class: ShellCommandRequirement
Expand All @@ -56,7 +65,7 @@ hints:
listing:
- entry: $(inputs.msin)
- class: ResourceRequirement
coresMin: 12
coresMin: $(inputs.ncpu)

stdout: dp3_intermediate_avg.log
stderr: dp3_intermediate_avg_err.log
74 changes: 61 additions & 13 deletions steps/wsclean.cwl
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ label: WSClean
doc: Runs WSClean on the input data to produce an image.

baseCommand: wsclean
arguments: [-verbose, -log-time, -no-update-model-required]
arguments: [-verbose, -log-time, -no-update-model-required, -reorder]

inputs:
- id: msin
Expand All @@ -16,15 +16,15 @@ inputs:
position: 2
shellQuote: false
itemSeparator: ' '
- id: tempdir
type: string
- id: tmpdir
type: string?
default: '.'
inputBinding:
position: 1
shellQuote: false
itemSeparator: ' '
prefix: '-temp-dir'
- id: cores
- id: ncpu
type: int?
default: 24
inputBinding:
Expand Down Expand Up @@ -58,6 +58,13 @@ inputs:
position: 1
shellQuote: false
prefix: '-weight'
- id: weighting-rank-filter
type: int?
default: 3
inputBinding:
position: 1
shellQuote: false
prefix: '-weighting-rank-filter'
- id: parallel-reordering
type: int?
default: 6
Expand All @@ -67,7 +74,7 @@ inputs:
prefix: '-parallel-reordering'
- id: mgain
type: float?
default: 0.7
default: 0.75
inputBinding:
position: 1
shellQuote: false
Expand All @@ -81,7 +88,7 @@ inputs:
prefix: '-data-column'
- id: auto-mask
type: float?
default: 3.0
default: 2.5
inputBinding:
position: 1
shellQuote: false
Expand Down Expand Up @@ -130,7 +137,7 @@ inputs:
prefix: '-niter'
- id: multiscale-scale-bias
type: float?
default: 0.6
default: 0.7
inputBinding:
position: 1
shellQuote: false
Expand All @@ -144,7 +151,7 @@ inputs:
prefix: '-parallel-deconvolution'
- id: parallel-gridding
type: int?
default: 4
default: 6
inputBinding:
position: 1
shellQuote: false
Expand Down Expand Up @@ -172,7 +179,7 @@ inputs:
prefix: '-nmiter'
- id: channels-out
type: int?
default: 6
default: 12
inputBinding:
position: 1
shellQuote: false
Expand All @@ -186,18 +193,31 @@ inputs:
prefix: '-join-channels'
- id: fit-spectral-pol
type: int?
default: 3
default: 9
inputBinding:
position: 1
shellQuote: false
prefix: '-fit-spectral-pol'
- id: deconvolution-channels
type: int?
default: 3
inputBinding:
position: 1
shellQuote: false
prefix: '-deconvolution-channels'
- id: local-rms-window
type: int?
default: 50
inputBinding:
position: 1
shellQuote: false
prefix: '-local-rms-window'
- id: local-rms
type: boolean?
default: true
inputBinding:
position: 1
shellQuote: false
prefix: '-local-rms'
- id: gridder
type: string?
default: wgridder
Expand All @@ -207,11 +227,39 @@ inputs:
prefix: '-gridder'
- id: apply-primary-beam
type: boolean?
default: true
default: false
inputBinding:
position: 1
shellQuote: false
prefix: '-apply-primary-beam'
- id: apply-facet-beam
type: boolean?
default: true
inputBinding:
position: 1
shellQuote: false
prefix: '-apply-facet-beam'
- id: facet-beam-update
type: int?
default: 600
inputBinding:
position: 1
shellQuote: false
prefix: '-facet-beam-update'
- id: dd-psf-grid
type: int[]?
default: [3, 3]
inputBinding:
position: 1
shellQuote: false
prefix: '-dd-psf-grid'
- id: scalar-visibilities
type: boolean?
default: true
inputBinding:
position: 1
shellQuote: false
prefix: '-scalar-visibilities'
- id: use-differential-lofar-beam
type: boolean?
default: true
Expand Down Expand Up @@ -301,7 +349,7 @@ requirements:
listing:
- entry: $(inputs.msin)
- class: ResourceRequirement
coresMin: $(inputs.cores)
coresMin: $(inputs.ncpu)

stdout: wsclean.log
stderr: wsclean_err.log
31 changes: 19 additions & 12 deletions workflows/image_intermediate_resolution.cwl
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ inputs:
type: Directory[]
doc: MeasurementSets that will be imaged.

- id: number_cores
- id: ncpu
type: int?
default: 12
default: 24
doc: The minimum number of cores that should be available for steps that require high I/O.

- id: dd_solutions
Expand All @@ -38,12 +38,19 @@ inputs:
type: File?
doc: Optional user-provided facet layout file

- id: tmpdir_wsclean
type: string?
default: '.'
doc: Temporary directory for wsclean reordering

steps:
- id: average_data
label: average
in:
- id: msin
source: msin
- id: ncpu
source: ncpu
out:
- id: ms_avg
run: ../steps/average_intermediate_resolution.cwl
Expand All @@ -52,7 +59,8 @@ steps:
label: facet_layout
in:
- id: msin
source: average_data/ms_avg
source: msin
valueFrom: $(self[0])
- id: h5parm
source: dd_solutions
- id: imsize
Expand All @@ -73,9 +81,11 @@ steps:
label: intermediate_resolution_image
in:
- id: msin
source: msin
- id: cores
source: number_cores
source: average_data/ms_avg
- id: ncpu
source: ncpu
- id: tmpdir
source: tmpdir_wsclean
- id: size
source: image_size
- id: scale
Expand Down Expand Up @@ -106,7 +116,6 @@ steps:
- id: MFS_model
- id: MFS_psf
- id: channel_model_images

run: ../steps/wsclean.cwl

- id: validate_image
Expand All @@ -116,10 +125,8 @@ steps:
source: make_intermediate_resolution_image/MFS_image_pb
out:
- id: validation_csv

run: ../steps/validate_1arcsec_image.cwl


outputs:
- id: facet_region
type: File?
Expand All @@ -136,7 +143,7 @@ outputs:
doc: |
Final primary-beam corrected MFS FITS image at intermediate resolution.
- id: MFS_image
outputSource: make_intermediate_resolution_image/MFS_image_pb
outputSource: make_intermediate_resolution_image/MFS_image
type: File
doc: |
Final apparent corrected MFS FITS image at intermediate resolution.
Expand All @@ -147,7 +154,7 @@ outputs:
doc: |
Final primary-beam corrected MFS FITS image at intermediate resolution.
- id: MFS_residual
outputSource: make_intermediate_resolution_image/MFS_residual_pb
outputSource: make_intermediate_resolution_image/MFS_residual
type: File
doc: |
Final apparent corrected MFS FITS image at intermediate resolution.
Expand All @@ -158,7 +165,7 @@ outputs:
doc: |
Final primary-beam corrected MFS FITS image at intermediate resolution.
- id: MFS_model
outputSource: make_intermediate_resolution_image/MFS_model_pb
outputSource: make_intermediate_resolution_image/MFS_model
type: File
doc: |
Final apparent corrected MFS FITS image at intermediate resolution.
Expand Down
Loading