Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor to make all algorithms use the same formats, simplify parall…
…elism, direct pre-conditioning and produce uniformly blurred images (#111) * add option to visualise init graphs * name jones ones * clone t mapping in stokes2vis * print visualised graph locations to log * add jsk wavelets and initial approach to distribute spotless * growing bytearray problem * eliminate wavelets and cf.futures for testing * band actor chaos * images rst * heading at the top * unify gain-table and gain-term params in init * simplified band actors approach * residuals decreasing * Add imit worker that combines init and grid steps (for use with distributed minors) * cleaner distributed workflow * add l2 reweighting to dist_spotless * tweak when L2 reweighting happens * add imit cab * add missing xds_from_zarr import to imit * allow diagonal jones in imit worker * add unique keys for imit jobs, print scheduler address * add key for reading in worker_client in stokes2im * test to_zarr with no dask * clone subds in imit * direct to workers in imit client * clone inside image_data_products * set OMP_NUM_THREADS so wgridder can parallelise * print update and ratio timings * test communication times with direct_to_workers * cache of imaging data products. allow worker compression * numba ratio computation * allow overwriting existing model * allow fits output format for fastim worker * add DATE-OBS to fits header * add BDA support * make sure ddsstore is initialised when overwriting * norm wsum when writing fits out of fastim * depend on uninneddeps qcal branch * typo * depend on codex-africanus >= 0.3.7 * prepend protocol to ds_list) * l2reweight-from option * remove print debug statements * try except around imaging call * direct to workers to false * print cache name that we are attempting to write to * print cname * don't use flag_row in bda * test broadcast_to trick for psf_vis * print shape after bda * print shapes outside of sunbmit call * check for infs or nans * check for null subbands * allow empty string for frange. Write residual at iter0 * grab uvw from res after averaging * change imit output name to xds * re-enable bda * update chan_width after simple average * debug call to stokes vis func outside of client * debug call to stokes vis func outside of client, ipdb * typo * remove debug call * drop flagged rows in intermediaries * add wgt in compute_counts * make grid app compatible with init output * sum counts before filtering extremely low values * test negate w * also negate w in degrid * undo w negation * yet another fastim test * overwrite restore products by default. Scale by pixel area. raise error if fastim future errs * add or-model-with-mask option to fluxmop * keep track of initial model and residual after fluxmop in case of failure * typo * don't zero model outside mask by default * make model2comps write output fits cube * output model cube in model2comps * use model-out to set fits output path if set * residname to fluxmop in case of recovery * linear extrapolation in model2comps * pin numpy <= 2.0.0 * resize ducc threadpool * separate distributed spotless algorithm from memory conservative sara deconv worker * fastim -> hci * report number of basis functions used for fit in model2comps * report interpolation error in model2comps * fastim -> hci in main * slice out time 0 for reporting fractional interp error * try except in sum_overlap * rudimentary support for MFS weighting (only on second run of grid app) * allow null input model in fluxmop * add memory greedy option to fluxmop * use cetral frequency as ref_freq * set memory limit. Move imit functionality to init and remove duplicate. remove dead pcg code * remove imit import from main * start simplifying band_worker * set crpix3 for MFS fits files * allow running fluxmop without psf in dds * pin numba, don't ignore deprecatin warnings * unpin numba and prefer_literal in overload * remove imit cab * add noise map option to grid worker * start incorporating new preconditioner * use model and resid name in restore worker * add separate fits output folder * test precond * report compute time after grid and sara * rewrite band_actor with precond and full hess * tweak spotless * fix missing xds_from_zarr import * compare full Hessian in forward and backward steps * don't import vis2dirty and dirty2vis from experimental module * add minimal hessian vs psf convolve test * add .vscode to gitignore * test .rst docs * naming conventions * naming conventions * fix testing suite after changing naming conventions * fix failing tests * add missing imports and create naming.py for consistent naming conventions * apply min-val cut after extrapolating in model2comps * fix typo in fits output name * fix another typo in fits output name * add fits-output-folder for restore and model2comps * remove nthreads-dask from hci and smoovie inputs * fake client for testing * move grid worker to client interface. Introduce fake_client * fix beam test * drop all collections in sara and klean * get fluxmop working with new data structures * make fluxmop reversible again * start towards uniformly blurred image * client interface in restore worker * don't over-subscribe threads in compute_counts * make BDA max_fov an input * set_client -> get_client in fluxmop * compare parallel to serial read zarr from list of datasets * do not use RGI unnecessarily * remove serial read comparison * fix slow im weight computation * don't pass evaluated dds when writing fits * typo max-field-of0view -> max-field-of-view * remove tbid from compute_counts inputs * return sum over grid axis in _compute_counts * don't log in submit calls * write fits in parallel when using client in fluxmop * add missing wait import * taper preconditioner for CG * test image restoration tweak for more homogenous resolution * typo * write fits to correct location in restore * fix direct inverse bug * direct to workers by default in spotless * original psi * optimise wavelets and direct hess-approx * typo * test retrieving result with as_completed * crude actor test to find where the time is spent * checkpoint * test numexpr and add missing imports * sara with new direct updates * time pd units * control number of vertical numba threads with context manager * try process pool for wavelets * truly vertical psi * test if copyto is more consistent * fix tests * restore __version__ * fix noise realisation * add option to compute intrinsic model resolution by deconvolving psf. Change psi settings for better performance * report timings in primal dual * fix typo * fix stupid uint8 slicing bug * psfhat -> abspsf for precond * fix failing sara test * fix failing clean test, raise error if PSF is too small * fix restore mess * iterable pd-tol * fix failing convolve2gaussres test * fix sara test * add ability to combine models in model2comps * wait for futures when using restore worker * add option to drop nearly null bands * freq_factor when thresholding * add init-factor, rms-outside-model to sara and allow empty list for drop-bands in restore * try inverted freq_factor * try low order poly fit in major cycle * check for missing/inconsistent number of antennas * raise error if future does not complete correctly in init * check if future result in BaseError * report antenna table size vs max ants inferred from ant1 and ant2 in stokes2vis * report msid when things go wrong in stokes2vis * fix init bug when using multiple measurement sets without gain solutions. add concat-time option to hci worker * fix fits reference freq * add timing summary to primal dual * eps per scan and fix indexing when no-concat in dds2fits * make freq ordering optional in dds_from_list * propagate change to dds2fits * use per basis rms_comps, add epsfactor * typo in model2comps * remove repeated tol in stokes2im * fix imports in stokes2im * add import in hci * cellx -> cell_rad in stokes2im * robustness -> opts.robustness in stokes2im * add natural grad to hci * remove concat_time in hci for now * tweak freq mapping in hci * allow freq selection in degrid * add model-column as input to hci * model-column also in hci parset * typo * remove fmap in hci * scatter mds to workers in degrid * fix bug when transferring model from comps * cast model to double precision in stokes2im * flip_v everywhere and correct fits crpix2 convention * fix and improve sara test * fix weighting and polproducts test * fix hanging behaviour when ntasks < nworkers in init and hci * report worker memory in init * attempt to clear memory with client.run * clean up custom as_completed logic * make memory reporting optional * attempt to get rid of cluster cleanup errors * remove debugging print statements * consistent use of _ in l1 and l2 reweight params * add hci can definition * add pass_missing_as_none policies to all workers * remove stray quit() * remove defaults dict from worker definitions --------- Co-authored-by: landmanbester <[email protected]>
- Loading branch information