From 5423e0efe3cbcff89bf89ef48cf8070d849697e2 Mon Sep 17 00:00:00 2001 From: "Thomson, Alec (CASS, Kensington)" Date: Thu, 14 Dec 2023 14:16:05 +1100 Subject: [PATCH] ruff it up --- arrakis/cutout.py | 1 - arrakis/linmos.py | 1 - arrakis/makecat.py | 2 +- arrakis/process_spice.py | 9 ++------- 4 files changed, 3 insertions(+), 10 deletions(-) diff --git a/arrakis/cutout.py b/arrakis/cutout.py index e5ba0eb8..fa9705e3 100644 --- a/arrakis/cutout.py +++ b/arrakis/cutout.py @@ -21,7 +21,6 @@ from astropy.utils.exceptions import AstropyWarning from astropy.wcs.utils import skycoord_to_pixel from dask.distributed import Client, LocalCluster -from distributed import get_client from prefect import flow, task, unmapped from spectral_cube import SpectralCube from spectral_cube.utils import SpectralCubeWarning diff --git a/arrakis/linmos.py b/arrakis/linmos.py index 165c6990..17dfd8d0 100644 --- a/arrakis/linmos.py +++ b/arrakis/linmos.py @@ -15,7 +15,6 @@ from astropy.utils.exceptions import AstropyWarning from dask.distributed import Client, LocalCluster from prefect import flow, task, unmapped -from prefect.utilities.annotations import quote from racs_tools import beamcon_3D from spectral_cube.utils import SpectralCubeWarning from spython.main import Client as sclient diff --git a/arrakis/makecat.py b/arrakis/makecat.py index 71480770..1283d627 100644 --- a/arrakis/makecat.py +++ b/arrakis/makecat.py @@ -17,7 +17,7 @@ from astropy.stats import sigma_clip from astropy.table import Column, Table from dask.diagnostics import ProgressBar -from prefect import flow, task, unmapped +from prefect import flow, task from rmtable import RMTable from scipy.stats import lognorm, norm from tqdm import tqdm diff --git a/arrakis/process_spice.py b/arrakis/process_spice.py index 641c67cc..2951451a 100644 --- a/arrakis/process_spice.py +++ b/arrakis/process_spice.py @@ -3,18 +3,14 @@ import logging import os from pathlib import Path -from typing import Any, Optional, Tuple import configargparse import pkg_resources import yaml from astropy.time import Time -from dask.distributed import Client, LocalCluster -from dask_mpi import initialize -from distributed.deploy.cluster import Cluster from prefect import flow from prefect.task_runners import BaseTaskRunner -from prefect_dask import DaskTaskRunner, get_dask_client +from prefect_dask import DaskTaskRunner from arrakis import ( cleanup, @@ -28,8 +24,7 @@ ) from arrakis.logger import logger from arrakis.utils.database import test_db -from arrakis.utils.meta import class_for_name -from arrakis.utils.pipeline import logo_str, performance_report_prefect +from arrakis.utils.pipeline import logo_str @flow(name="Combining+Synthesis on Arrakis")