diff --git a/Dockerfile b/Dockerfile index a3b3710c477a73be21bd8c1c7ea93f2ab0a21a47..0f9e78bb4f6f2573229943124991e29d0dc3c07d 100644 --- a/Dockerfile +++ b/Dockerfile @@ -145,6 +145,7 @@ RUN cd /software/makemask && \ # Imcal ADD imcal.py /opt/imcal.py +ADD cluster.py /opt/cluster.py ADD imcal.yml /opt/imcal.yml RUN ln -s /opt/imcal.py /usr/local/bin/imcal.py diff --git a/imcal.py b/imcal.py index d1850fd1c2854d8895cd448810f0686515b5b365..c2da165b7c72e7e4293e2854108c3905035c74ef 100755 --- a/imcal.py +++ b/imcal.py @@ -199,7 +199,6 @@ def dical(msin, srcdb, msout=None, h5out=None, solint=1, startchan=0, split_ncha check_return_code(return_code) return msout -# TODO add minvisratio to te config def ddecal(msin, srcdb, msout=None, h5out=None, solint=120, nfreq=30, startchan=0, nchan=0, minvisratio=0.6, mode='diagonal', uvlambdamin=500, subtract=True): """ Perform direction dependent calibration with DPPP """ @@ -284,7 +283,6 @@ def view_sols(h5param, outname=None): # plt.show() -# TODO def remove_model_components_below_level(model, level=0.0, out=None): """ Clip the model to be above the given level @@ -359,8 +357,7 @@ def main(msin, outbase=None, cfgfile='imcal.yml'): logging.info('The final image exists. Exiting...') return 0 -# TODO check if splitting is needed - if not os.path.exists(ms_split): + if (not os.path.exists(ms_split)) and (cfg['split1']['startchan'] or cfg['split1']['nchan']): ms_split = split_ms(msin, msout_path=ms_split, **cfg['split1']) # Clean + DIcal diff --git a/imcal.yml b/imcal.yml index 6fc1ea0144877e895a1e8ef874eae9f17193844b..90df1c57f618fbe80910de6836fba262bc5f60e7 100644 --- a/imcal.yml +++ b/imcal.yml @@ -14,11 +14,9 @@ split1: startchan: 0 # start channel to split from nchan: 0 # 0 means till the end -# TODO: skip clean0: # initial clean max_over_thresh: 250 # the threshold for initial CLEAN is set to image_max/max_over_thresh -# TODO add fixed threshold of 100 uJy - +# TODO add fixed threshold of 100 uJy clean1: # wsclean setup imagesize: 3072 @@ -29,7 +27,7 @@ clean1: # wsclean setup autothresh: 5 multiscale: False clip_model_level: null # use a float number to clip the model to above this level. null is None. - kwstring: '-use-wgridder -parallel-deconvolution 1400' # use this for additional wsclean options, e.g. '-weight uniform -use-idg' + kwstring: '-use-wgridder -parallel-deconvolution 1400 -weight briggs 0.0' # use this for additional wsclean options, e.g. '-weight uniform -use-idg' dical1: # DPPP setup for direction independent calibration solint: 20 @@ -46,7 +44,7 @@ clean2: autothresh: 5 multiscale: True clip_model_level: null - kwstring: '-use-wgridder -parallel-deconvolution 1400 -parallel-gridding 8 -deconvolution-channels 3' + kwstring: '-use-wgridder -parallel-deconvolution 1400 -parallel-gridding 8 -deconvolution-channels -weight briggs 0.0' dical2: solint: 1 @@ -62,7 +60,7 @@ clean3: autothresh: 3.5 multiscale: True clip_model_level: null - kwstring: '-use-wgridder -parallel-deconvolution 1400 -parallel-gridding 8 -deconvolution-channels 3' + kwstring: '-use-wgridder -parallel-deconvolution 1400 -parallel-gridding 8 -deconvolution-channels 3 -weight briggs 0.0' dical3: solint: 240