lama/staging/staging_metric_maker.py
def scaling_factor_staging(root_registration_dir: Path, outdir: Path):
    """
    Make a csv of estimated CRL (from registration scaling factor) viven a list of registration folders
    (usually the final non-linear stage)

    Parameters
    ----------
    root_registration_dir: Contains subfolders of registrations from which to generate staging data from
    outdir: Whaere to put staging csv
    """

    root_registration_dir = Path(root_registration_dir)
    outdir = Path(outdir)

    output = {}

    for dir_ in root_registration_dir.iterdir():

        if not os.path.isdir(dir_):
            continue

        tform_param = asf.extract_affine_transformation_parameters(dir_)

        if not tform_param:
            print(dir_)

        scaling_factor = asf.get_scaling_factor(tform_param)
        vol_id = dir_.stem
        output[vol_id] = scaling_factor

    _write_output(output, outdir)
    return scaling_factor

    Make a csv of estimated CRL (from registration scaling factor) viven a list of registration folders
    (usually the final non-linear stage)

    Parameters
    ----------
    root_registration_dir: Contains subfolders of registrations from which to generate staging data from
    outdir: Whaere to put staging csv
    
Make a csv of estimated CRL (from registration scaling factor) viven a list of registration folders
(usually the final non-linear stage)

Parameters

Contains subfolders of registrations from which to generate staging data from
outdir: Whaere to put staging csv
Make a csv of estimated CRL ( from registration scaling factor ) viven a list of registration folders ( usually the final non - linear stage ) Parameters Contains subfolders of registrations from which to generate staging data from outdir : Whaere to put staging csv
def scaling_factor_staging(root_registration_dir: Path, outdir: Path):
    root_registration_dir = Path(root_registration_dir)
    outdir = Path(outdir)
    output = {}
    for dir_ in root_registration_dir.iterdir():
        if not os.path.isdir(dir_):
            continue
        tform_param = asf.extract_affine_transformation_parameters(dir_)
        if not tform_param:
            print(dir_)
        scaling_factor = asf.get_scaling_factor(tform_param)
        vol_id = dir_.stem
        output[vol_id] = scaling_factor
    _write_output(output, outdir)
    return scaling_factor
def scaling_factor_staging ( root_registration_dir : Path , outdir : Path ) : root_registration_dir = Path ( root_registration_dir ) outdir = Path ( outdir ) output = { } for dir_ in root_registration_dir . iterdir ( ) : if not os . path . isdir ( dir_ ) : continue tform_param = asf . extract_affine_transformation_parameters ( dir_ ) if not tform_param : print ( dir_ ) scaling_factor = asf . get_scaling_factor ( tform_param ) vol_id = dir_ . stem output [ vol_id ] = scaling_factor _write_output ( output , outdir ) return scaling_factor
Make a csv of estimated CRL (from registration scaling factor) viven a list of registration folders
(usually the final non-linear stage)
Make a csv of estimated CRL ( from registration scaling factor ) viven a list of registration folders ( usually the final non - linear stage )
"""
    Make a csv of estimated CRL (from registration scaling factor) viven a list of registration folders
    (usually the final non-linear stage)

    Parameters
    ----------
    root_registration_dir: Contains subfolders of registrations from which to generate staging data from
    outdir: Whaere to put staging csv
    """
root_registration_dir
Path
outdir
Path