Skip to content

Commit

Permalink
Pass dryrun
Browse files Browse the repository at this point in the history
  • Loading branch information
AlecThomson committed Sep 3, 2024
1 parent f3d9bf8 commit f80ad67
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions arrakis/cutout.py
Original file line number Diff line number Diff line change
Expand Up @@ -346,6 +346,7 @@ def make_cutout(
pad: float = 3,
username: Optional[str] = None,
password: Optional[str] = None,
dryrun: bool = False,
):
_, _, comp_col = get_db(
host=host, epoch=epoch, username=username, password=password
Expand All @@ -367,7 +368,7 @@ def make_cutout(
beam_num=beam_num,
stoke=stoke,
pad=pad,
dryrun=False,
dryrun=dryrun,
)
weight_update = cutout_weight(
image_name=image_name,
Expand All @@ -376,7 +377,7 @@ def make_cutout(
field=field,
beam_num=beam_num,
stoke=stoke,
dryrun=False,
dryrun=dryrun,
)
return [image_update, weight_update]

Expand All @@ -396,6 +397,7 @@ def big_cutout(
username: Optional[str] = None,
password: Optional[str] = None,
limit: Optional[int] = None,
dryrun: bool = False,
) -> List[pymongo.UpdateOne]:
wild = f"image.restored.{stoke.lower()}*contcube*beam{beam_num:02}.conv.fits"
images = list(datadir.glob(wild))
Expand Down Expand Up @@ -444,6 +446,7 @@ def big_cutout(
pad=pad,
username=username,
password=password,
dryrun=dryrun,
)
)
for future in tqdm(futures, file=TQDM_OUT, desc=f"Cutting {image_name}"):
Expand Down Expand Up @@ -570,6 +573,7 @@ def cutout_islands(
username=username,
password=password,
limit=limit,
dryrun=dryrun,
)
cuts.append(results)

Expand Down

0 comments on commit f80ad67

Please sign in to comment.