lama/registration_pipeline/run_lama.py
def write_stats_config(config_path: Path, config, key_values):
    """
    Write a config for input into the stats pipeline
    """
    out_path = config_path.parent / 'stats.yaml'
    keys = list(key_values.keys())

    # TODo make the name in the values not paths
    stats_cfg = dict(
        # Put in target dir
        stats_types = ['intensity', 'jacobians', 'organ_volume'],
        shape=config['pad_dims'],
        mask=config['stats_mask'],
        label_map=config['label_map'],
        blur_fwhm=DEFAULT_FWHM,
        voxel_size=DEFAULT_VOXEL_SIZE
    )

    with open(out_path, 'w') as fh:
        fh.write(yaml.dump(stats_cfg))

    Write a config for input into the stats pipeline
    
Write a config for input into the stats pipeline
Write a config for input into the stats pipeline
def write_stats_config(config_path: Path, config, key_values):
    out_path = config_path.parent / 'stats.yaml'
    keys = list(key_values.keys())
    stats_cfg = dict(
        stats_types = ['intensity', 'jacobians', 'organ_volume'],
        shape=config['pad_dims'],
        mask=config['stats_mask'],
        label_map=config['label_map'],
        blur_fwhm=DEFAULT_FWHM,
        voxel_size=DEFAULT_VOXEL_SIZE
    )
    with open(out_path, 'w') as fh:
        fh.write(yaml.dump(stats_cfg))
def write_stats_config ( config_path : Path , config , key_values ) : out_path = config_path . parent / 'stats.yaml' keys = list ( key_values . keys ( ) ) stats_cfg = dict ( stats_types = [ 'intensity' , 'jacobians' , 'organ_volume' ] , shape = config [ 'pad_dims' ] , mask = config [ 'stats_mask' ] , label_map = config [ 'label_map' ] , blur_fwhm = DEFAULT_FWHM , voxel_size = DEFAULT_VOXEL_SIZE ) with open ( out_path , 'w' ) as fh : fh . write ( yaml . dump ( stats_cfg ) )
Write a config for input into the stats pipeline
Write a config for input into the stats pipeline
"""
    Write a config for input into the stats pipeline
    """ # TODo make the name in the values not paths # Put in target dir
config_path
Path
config
key_values