flint.predict.crystalball¶
Items in and out the model visibility prediction using the crystalball python package.
Classes¶
Options related to running crystal ball |
Functions¶
|
|
|
A very simply wrapper around the Crystalball.predict function. Basic |
|
Module Contents¶
- class flint.predict.crystalball.CrystalBallOptions(/, **data: Any)[source]¶
Bases:
flint.options.BaseOptionsOptions related to running crystal ball
- crystallball_wsclean_pol_mode: list[str] = ['i'][source]¶
The polarisation of the wsclean model that was generated
- memory_fraction: float = 0.75[source]¶
The fraction of available memory to use to define the target chunk size
- flint.predict.crystalball.crystalball_predict(ms: flint.ms.MS, crystalball_options: CrystalBallOptions, wsclean_source_list_path: pathlib.Path | None = None, dask_client: dask.distributed.Client | None = None, output_column: str = 'MODEL_DATA', update_crystalball_options: dict[str, Any] | None = None) flint.ms.MS[source]¶
A very simply wrapper around the Crystalball.predict function. Basic checks to ensure that the BB6 style source model path exists, which is the format used by the wsclean -save-source-list option.
If no wsclean_source_list_path is specified one is guess from the name of the input MS.path.
- Parameters:
ms (MS) – The MS instance whose path is to the measurement set to predict into.
crystalball_options (CrystalBallOptions) – Options that control the crystalball.predict call.
wsclean_source_list_path (Path | None, optional) – The path to the file with the model components to predict. If None an attempt is made to find it from the MS. Defaults to None.
dask_client (Client | None, optional) – A specialised Dask distributed task. If None one is created by crystalball. Defaults to None.
output_column (str, optional) – The column to predict into. The MS.model_column will reflect this. Defaults to “MODEL_DATA”.
update_crystalball_options (dict[str, Any] | None, optional) – Update options to the provided crystalball_options. Defaults to None.
- Returns:
The MS that was predicted into, with the model_column set appropriately.
- Return type: