Skip to content

CLI Reference

This page documents all available biahub command-line tools.

biahub

command-line tools for biahub

Usage:

biahub [OPTIONS] COMMAND [ARGS]...

Options:

  -h, --help  Show this message and exit.

Subcommands

biahub apply-inv-tf

Apply inverse transfer function to dataset

Usage:

biahub apply-inv-tf [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -t, --transfer-function-dirpath PATH
                                  Path to transfer function .zarr.  [required]
  -c, --config-filepath FILE      Path to YAML configuration file.  [required]
  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -j, --num-processes INTEGER     Number of parallel processes
  -sb, --sbatch-filepath FILE     SBATCH filepath that contains slurm
                                  parameters to overwrite defaults. For
                                  example, '#SBATCH --mem-per-cpu=16G' will
                                  override the default memory per CPU.
  -l, --local                     Run jobs locally instead of submitting to
                                  SLURM.
  -m, --monitor                   Monitor of submitted SLURM jobs.
  -h, --help                      Show this message and exit.

biahub characterize-psf

Characterize point spread function (PSF)

Usage:

biahub characterize-psf [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -c, --config-filepath FILE      Path to YAML configuration file.  [required]
  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -h, --help                      Show this message and exit.

biahub compute-tf

Compute transfer function using PSF

Usage:

biahub compute-tf [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -c, --config-filepath FILE      Path to YAML configuration file.  [required]
  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -h, --help                      Show this message and exit.

biahub concatenate

Concatenate datasets (with optional cropping)

Usage:

biahub concatenate [OPTIONS]

Options:

  -c, --config-filepath FILE      Path to YAML configuration file.  [required]
  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -sb, --sbatch-filepath FILE     SBATCH filepath that contains slurm
                                  parameters to overwrite defaults. For
                                  example, '#SBATCH --mem-per-cpu=16G' will
                                  override the default memory per CPU.
  -l, --local                     Run jobs locally instead of submitting to
                                  SLURM.
  -m, --monitor                   Monitor of submitted SLURM jobs.
  -h, --help                      Show this message and exit.

biahub deconvolve

Deconvolve across T and C axes using a PSF

Usage:

biahub deconvolve [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -p, --psf-dirpath DIRECTORY     Path to psf.zarr  [required]
  -c, --config-filepath FILE      Path to YAML configuration file.  [required]
  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -sb, --sbatch-filepath FILE     SBATCH filepath that contains slurm
                                  parameters to overwrite defaults. For
                                  example, '#SBATCH --mem-per-cpu=16G' will
                                  override the default memory per CPU.
  -l, --local                     Run jobs locally instead of submitting to
                                  SLURM.
  -m, --monitor                   Monitor of submitted SLURM jobs.
  -h, --help                      Show this message and exit.

biahub deskew

Deskew a single position across T and C axes

Usage:

biahub deskew [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -c, --config-filepath FILE      Path to YAML configuration file.  [required]
  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -sb, --sbatch-filepath FILE     SBATCH filepath that contains slurm
                                  parameters to overwrite defaults. For
                                  example, '#SBATCH --mem-per-cpu=16G' will
                                  override the default memory per CPU.
  -l, --local                     Run jobs locally instead of submitting to
                                  SLURM.
  -m, --monitor                   Monitor of submitted SLURM jobs.
  -h, --help                      Show this message and exit.

biahub estimate-bleaching

Estimate bleaching from raw data

Usage:

biahub estimate-bleaching [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -h, --help                      Show this message and exit.

biahub estimate-crop

Estimate crop region for dual-channel alignment

Usage:

biahub estimate-crop [OPTIONS]

Options:

  -c, --config-filepath FILE   Path to YAML configuration file.  [required]
  -o, --output-filepath FILE   Path to output file  [required]
  -sb, --sbatch-filepath FILE  SBATCH filepath that contains slurm parameters
                               to overwrite defaults. For example, '#SBATCH
                               --mem-per-cpu=16G' will override the default
                               memory per CPU.
  -l, --local                  Run jobs locally instead of submitting to
                               SLURM.
  --lf-mask-radius FLOAT       (Optional) Radius of the circular mask given as
                               fraction of image width to apply to the phase
                               channel.
  -h, --help                   Show this message and exit.

biahub estimate-deskew

Routine for estimating deskewing parameters

Usage:

biahub estimate-deskew [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -o, --output-filepath FILE      Path to output file  [required]
  -h, --help                      Show this message and exit.

biahub estimate-psf

Estimate point spread function from beads

Usage:

biahub estimate-psf [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -c, --config-filepath FILE      Path to YAML configuration file.  [required]
  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -h, --help                      Show this message and exit.

biahub estimate-registration

Estimate affine transform between timepoints or arms

Usage:

biahub estimate-registration [OPTIONS]

Options:

  -s, --source-position-dirpaths TUPLE
                                  Paths to source positions, for example:
                                  "source.zarr/0/0/0" or "source.zarr/*/*/*"
                                  [required]
  -t, --target-position-dirpaths TUPLE
                                  Paths to target positions, for example:
                                  "target.zarr/0/0/0" or "target.zarr/*/*/*"
                                  [required]
  -o, --output-filepath FILE      Path to output file  [required]
  -c, --config-filepath FILE      Path to YAML configuration file.  [required]
  -sb, --sbatch-filepath FILE     SBATCH filepath that contains slurm
                                  parameters to overwrite defaults. For
                                  example, '#SBATCH --mem-per-cpu=16G' will
                                  override the default memory per CPU.
  -l, --local                     Run jobs locally instead of submitting to
                                  SLURM.
  -rt, --registration-target-channel TEXT
                                  Name of the target channel to be used when
                                  registration params are applied. If not
                                  provided, the target channel from the config
                                  file will be used.
  -rs, --registration-source-channel TEXT
                                  Name of the source channels to be used when
                                  registration params are applied. May be
                                  passed multiple times. If not provided, the
                                  source channels from the config file will be
                                  used.
  -h, --help                      Show this message and exit.

biahub estimate-stabilization

Estimate translation matrices for XYZ stabilization

Usage:

biahub estimate-stabilization [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -c, --config-filepath FILE      Path to YAML configuration file.  [required]
  -sb, --sbatch-filepath FILE     SBATCH filepath that contains slurm
                                  parameters to overwrite defaults. For
                                  example, '#SBATCH --mem-per-cpu=16G' will
                                  override the default memory per CPU.
  -l, --local                     Run jobs locally instead of submitting to
                                  SLURM.
  -h, --help                      Show this message and exit.

biahub estimate-stitch

Estimate stitching parameters for positions

Usage:

biahub estimate-stitch [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -o, --output-filepath FILE      Path to output file  [required]
  --fliplr                        Flip images left-right before stitching
  --flipud                        Flip images up-down before stitching
  --flipxy                        Flip images along the diagonal before
                                  stitching
  --pcc-channel-name TEXT         Channel name to use for phase cross-
                                  correlation optimization (default: None,
                                  disables optimization)
  --pcc-z-index INTEGER           Z slice index to use for phase cross-
                                  correlation optimization (default: 0)
  --add_offset                    add the offset to estimated shifts, needed
                                  for OPS experiments
  -l, --local                     Run jobs locally instead of submitting to
                                  SLURM.
  -m, --monitor                   Monitor of submitted SLURM jobs.
  -h, --help                      Show this message and exit.

biahub flip

Flip images in a dataset

Usage:

biahub flip [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -x                              Enable the x flag.
  -y                              Enable the y flag.
  -h, --help                      Show this message and exit.

biahub optimize-registration

Optimize transform based on match filtering

Usage:

biahub optimize-registration [OPTIONS]

Options:

  -s, --source-position-dirpaths TUPLE
                                  Paths to source positions, for example:
                                  "source.zarr/0/0/0" or "source.zarr/*/*/*"
                                  [required]
  -t, --target-position-dirpaths TUPLE
                                  Paths to target positions, for example:
                                  "target.zarr/0/0/0" or "target.zarr/*/*/*"
                                  [required]
  -c, --config-filepath FILE      Path to YAML configuration file.  [required]
  -o, --output-filepath FILE      Path to output file  [required]
  -d, --display-viewer            Display the registered channels in a napari
                                  viewer
  -h, --help                      Show this message and exit.

biahub process-with-config

Process data with YAML-defined functions

Usage:

biahub process-with-config [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -c, --config-filepath FILE      Path to YAML configuration file.  [required]
  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -sb, --sbatch-filepath FILE     SBATCH filepath that contains slurm
                                  parameters to overwrite defaults. For
                                  example, '#SBATCH --mem-per-cpu=16G' will
                                  override the default memory per CPU.
  -l, --local                     Run jobs locally instead of submitting to
                                  SLURM.
  -m, --monitor                   Monitor of submitted SLURM jobs.
  -h, --help                      Show this message and exit.

biahub reconstruct

Reconstruct a dataset using config

Usage:

biahub reconstruct [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -c, --config-filepath FILE      Path to YAML configuration file.  [required]
  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -j, --num-processes INTEGER     Number of parallel processes
  -sb, --sbatch-filepath FILE     SBATCH filepath that contains slurm
                                  parameters to overwrite defaults. For
                                  example, '#SBATCH --mem-per-cpu=16G' will
                                  override the default memory per CPU.
  -l, --local                     Run jobs locally instead of submitting to
                                  SLURM.
  -m, --monitor                   Monitor of submitted SLURM jobs.
  -h, --help                      Show this message and exit.

biahub register

Apply an affine transformation to a single position

Usage:

biahub register [OPTIONS]

Options:

  -s, --source-position-dirpaths TUPLE
                                  Paths to source positions, for example:
                                  "source.zarr/0/0/0" or "source.zarr/*/*/*"
                                  [required]
  -t, --target-position-dirpaths TUPLE
                                  Paths to target positions, for example:
                                  "target.zarr/0/0/0" or "target.zarr/*/*/*"
                                  [required]
  -c, --config-filepath FILE      Path to YAML configuration file.  [required]
  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -l, --local                     Run jobs locally instead of submitting to
                                  SLURM.
  -sb, --sbatch-filepath FILE     SBATCH filepath that contains slurm
                                  parameters to overwrite defaults. For
                                  example, '#SBATCH --mem-per-cpu=16G' will
                                  override the default memory per CPU.
  -m, --monitor                   Monitor of submitted SLURM jobs.
  -h, --help                      Show this message and exit.

biahub segment

Segment a position using pretrained model or pipeline

Usage:

biahub segment [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -c, --config-filepath FILE      Path to YAML configuration file.  [required]
  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -sb, --sbatch-filepath FILE     SBATCH filepath that contains slurm
                                  parameters to overwrite defaults. For
                                  example, '#SBATCH --mem-per-cpu=16G' will
                                  override the default memory per CPU.
  -l, --local                     Run jobs locally instead of submitting to
                                  SLURM.
  -m, --monitor                   Monitor of submitted SLURM jobs.
  -h, --help                      Show this message and exit.

biahub stabilize

Apply stabilization transforms to dataset

Usage:

biahub stabilize [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -c, --config-filepaths TUPLE    Paths to YAML configuration files. All must
                                  be existing files with .yml extension.
                                  [required]
  -sb, --sbatch-filepath FILE     SBATCH filepath that contains slurm
                                  parameters to overwrite defaults. For
                                  example, '#SBATCH --mem-per-cpu=16G' will
                                  override the default memory per CPU.
  -l, --local                     Run jobs locally instead of submitting to
                                  SLURM.
  -m, --monitor                   Monitor of submitted SLURM jobs.
  -h, --help                      Show this message and exit.

biahub stitch

Stitch positions in wells of a zarr store

Usage:

biahub stitch [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -c, --config-filepath FILE      Path to YAML configuration file.  [required]
  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -sb, --sbatch-filepath FILE     SBATCH filepath that contains slurm
                                  parameters to overwrite defaults. For
                                  example, '#SBATCH --mem-per-cpu=16G' will
                                  override the default memory per CPU.
  -l, --local                     Run jobs locally instead of submitting to
                                  SLURM.
  -v, --verbose                   Verbose stitching output. Default is False.
  -b, --blending-exponent FLOAT   Exponent for blending weights. 0.0 is
                                  average blending, 1.0 is linear blending,
                                  and >1.0 is progressively sharper S-curve
                                  blending.
  --debug                         Run in debug mode
  -m, --monitor                   Monitor of submitted SLURM jobs.
  -h, --help                      Show this message and exit.

biahub track

Track objects in 2D/3D time-lapse microscopy

Usage:

biahub track [OPTIONS]

Options:

  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -c, --config-filepath FILE      Path to YAML configuration file.  [required]
  -sb, --sbatch-filepath FILE     SBATCH filepath that contains slurm
                                  parameters to overwrite defaults. For
                                  example, '#SBATCH --mem-per-cpu=16G' will
                                  override the default memory per CPU.
  -l, --local                     Run jobs locally instead of submitting to
                                  SLURM.
  -h, --help                      Show this message and exit.

biahub virtual-stain

Run VisCy virtual staining

Usage:

biahub virtual-stain [OPTIONS]

Options:

  -i, --input-position-dirpaths TUPLE
                                  Paths to input positions, for example:
                                  "input.zarr/0/0/0" or "input.zarr/*/*/*"
                                  [required]
  -o, --output-dirpath DIRECTORY  Path to output directory  [required]
  -sb-preprocess, --sbatch-filepath-preprocess FILE
                                  SBATCH filepath that contains slurm
                                  parameters to overwrite defaults. For
                                  example, '#SBATCH --mem-per-cpu=16G' will
                                  override the default memory per CPU.
  -sb-predict, --sbatch-filepath-predict FILE
                                  SBATCH filepath that contains slurm
                                  parameters to overwrite defaults. For
                                  example, '#SBATCH --mem-per-cpu=16G' will
                                  override the default memory per CPU.
  -j, --num-processes INTEGER     Number of parallel processes
  -l, --local                     Run jobs locally instead of submitting to
                                  SLURM.
  -m, --monitor                   Monitor of submitted SLURM jobs.
  --verbose                       Verbose output.
  --path-viscy-env TEXT           Conda environment with VisCy installed.
                                  [required]
  --preprocess-config-filepath TEXT
                                  Path to the VisCy preprocess config file.
  --predict-config-filepath TEXT  Path to the VisCy predict config file.
  --run-mode [all|preprocess|predict]
                                  Which VisCy stage(s) to run.
  -h, --help                      Show this message and exit.