From 037d90e769956025724b2d0625ac330d03be2d3c Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 26 Oct 2023 11:32:23 +0200 Subject: [PATCH 001/136] perf: move some imports to functions --- fd_shifts/cli.py | 23 +++++++++++++++++++---- fd_shifts/loaders/prepare.py | 15 ++++++++------- fd_shifts/reporting/__init__.py | 15 ++++++++------- fd_shifts/reporting/tables.py | 3 ++- 4 files changed, 37 insertions(+), 19 deletions(-) diff --git a/fd_shifts/cli.py b/fd_shifts/cli.py index e7d61c1..7fca900 100644 --- a/fd_shifts/cli.py +++ b/fd_shifts/cli.py @@ -1,12 +1,22 @@ import argparse -from fd_shifts import experiments, reporting -from fd_shifts.experiments import launcher +from fd_shifts import reporting +from fd_shifts.experiments import get_all_experiments, launcher from fd_shifts.loaders import prepare -def _list_experiments(_) -> None: - _experiments = experiments.get_all_experiments() +def _list_experiments(args) -> None: + _experiments = launcher.filter_experiments( + dataset=args.dataset, + dropout=args.dropout, + model=args.model, + backbone=args.backbone, + exclude_model=args.exclude_model, + run_nr=args.run, + rew=args.reward, + name=args.name, + ) + for exp in _experiments: print(exp.to_path()) @@ -21,6 +31,7 @@ def main() -> None: parser.set_defaults(command=lambda _: parser.print_help()) list_parser = subparsers.add_parser("list") + launcher.add_filter_arguments(list_parser) list_parser.set_defaults(command=_list_experiments) launch_parser = subparsers.add_parser("launch") @@ -36,3 +47,7 @@ def main() -> None: args = parser.parse_args() args.command(args) + + +if __name__ == "__main__": + main() diff --git a/fd_shifts/loaders/prepare.py b/fd_shifts/loaders/prepare.py index d0be08a..31a29ef 100644 --- a/fd_shifts/loaders/prepare.py +++ b/fd_shifts/loaders/prepare.py @@ -4,13 +4,6 @@ import imageio.core.util -from fd_shifts.loaders.preparation import ( - prepare_dermoscopy, - prepare_lidc, - prepare_rxrx1, - prepare_xray, -) - def ignore_warnings(*args, **kwargs): pass @@ -32,12 +25,20 @@ def add_arguments(parser: argparse.ArgumentParser) -> argparse.ArgumentParser: def main(args: argparse.Namespace): data_dir = Path(os.getenv("DATASET_ROOT_DIR", "./data")) if args.dataset == "all" or args.dataset == "microscopy": + from fd_shifts.loaders.preparation import prepare_rxrx1 + prepare_rxrx1(data_dir) if args.dataset == "all" or args.dataset == "xray": + from fd_shifts.loaders.preparation import prepare_xray + prepare_xray(data_dir) if args.dataset == "all" or args.dataset == "dermoscopy": + from fd_shifts.loaders.preparation import prepare_dermoscopy + prepare_dermoscopy(data_dir) if args.dataset == "all" or args.dataset == "lung_ct": + from fd_shifts.loaders.preparation import prepare_lidc + prepare_lidc(data_dir) diff --git a/fd_shifts/reporting/__init__.py b/fd_shifts/reporting/__init__.py index 1e30125..56fdd98 100644 --- a/fd_shifts/reporting/__init__.py +++ b/fd_shifts/reporting/__init__.py @@ -5,13 +5,6 @@ import pandas as pd from fd_shifts.experiments import Experiment, get_all_experiments -from fd_shifts.reporting import tables -from fd_shifts.reporting.plots import plot_rank_style, vit_v_cnn_box -from fd_shifts.reporting.tables import ( - paper_results, - rank_comparison_metric, - rank_comparison_mode, -) DATASETS = ( "svhn", @@ -485,6 +478,14 @@ def main(base_path: str | Path): Args: base_path (str | Path): path where experiment data lies """ + from fd_shifts.reporting import tables + from fd_shifts.reporting.plots import plot_rank_style, vit_v_cnn_box + from fd_shifts.reporting.tables import ( + paper_results, + rank_comparison_metric, + rank_comparison_mode, + ) + pd.set_option("display.max_rows", None) pd.set_option("display.max_columns", None) pd.set_option("display.width", None) diff --git a/fd_shifts/reporting/tables.py b/fd_shifts/reporting/tables.py index 93baaf4..4d87334 100644 --- a/fd_shifts/reporting/tables.py +++ b/fd_shifts/reporting/tables.py @@ -5,7 +5,6 @@ from pathlib import Path from typing import Callable -import matplotlib import numpy as np import pandas as pd @@ -323,6 +322,8 @@ def _print_original_mode(data: pd.DataFrame, metric: str): def _compute_gmap(data: pd.DataFrame, invert: bool): + import matplotlib + # NOTE: Manually compute gradient map because Normalize returns 0 if vmax - vmin == 0, but we # NOTE: want it to be 1 in that case From 25f8e3fa15a28ae72e320a35fe5724e5f1907be7 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 26 Oct 2023 11:33:59 +0200 Subject: [PATCH 002/136] perf: get_all_experiments should be an iterator --- fd_shifts/experiments/__init__.py | 502 +++++++++++++++++------------- 1 file changed, 279 insertions(+), 223 deletions(-) diff --git a/fd_shifts/experiments/__init__.py b/fd_shifts/experiments/__init__.py index a5096c8..211465f 100644 --- a/fd_shifts/experiments/__init__.py +++ b/fd_shifts/experiments/__init__.py @@ -1,6 +1,6 @@ -from collections.abc import Iterable +from collections.abc import Iterable, Iterator from dataclasses import dataclass -from itertools import product +from itertools import chain, product from pathlib import Path from rich import print as pprint @@ -257,20 +257,18 @@ def from_iterables( rewards: Iterable[float], learning_rates: Iterable[float | None], ): - return list( - map( - lambda args: Experiment(*args), - product( - (group_dir,), - datasets, - models, - backbones, - dropouts, - runs, - rewards, - learning_rates, - ), - ) + return map( + lambda args: Experiment(*args), + product( + (group_dir,), + datasets, + models, + backbones, + dropouts, + runs, + rewards, + learning_rates, + ), ) @@ -422,12 +420,16 @@ def get_ms_experiments() -> list[Experiment]: def get_all_experiments( - with_hyperparameter_sweep=False, with_vit_special_runs=True, with_ms_runs=True -) -> list[Experiment]: + with_hyperparameter_sweep=False, + with_vit_special_runs=True, + with_ms_runs=True, + with_precision_study=True, +) -> Iterator[Experiment]: _experiments = [] # ViT Best lr runs - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("svhn",), @@ -437,10 +439,11 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("svhn",), @@ -450,10 +453,11 @@ def get_all_experiments( dropouts=(0, 1), runs=range(5), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("svhn", "svhn_openset"), @@ -463,10 +467,11 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(2.2, 3, 6, 10), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("svhn", "svhn_openset"), @@ -476,10 +481,11 @@ def get_all_experiments( dropouts=(0, 1), runs=range(5), rewards=(2.2, 3, 6, 10), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("svhn_openset",), @@ -489,10 +495,11 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("svhn_openset",), @@ -502,10 +509,11 @@ def get_all_experiments( dropouts=(0, 1), runs=range(5), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("cifar10",), @@ -515,10 +523,11 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("cifar10",), @@ -528,10 +537,11 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("cifar10",), @@ -541,10 +551,11 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(2.2, 3, 6, 10), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("cifar10",), @@ -554,10 +565,11 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(2.2, 3, 6, 10), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("cifar100",), @@ -567,10 +579,11 @@ def get_all_experiments( dropouts=(1, 0), runs=range(5), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("super_cifar100",), @@ -580,10 +593,11 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("super_cifar100",), @@ -593,10 +607,11 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("cifar100",), @@ -606,10 +621,11 @@ def get_all_experiments( dropouts=(1, 0), runs=range(5), rewards=(2.2, 3, 6, 10, 12, 15, 20), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("super_cifar100",), @@ -619,10 +635,11 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(2.2, 3, 6, 10, 12, 15, 20), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("super_cifar100",), @@ -632,10 +649,11 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(2.2, 3, 6, 10, 12, 15, 20), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("wilds_animals",), @@ -645,10 +663,11 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("wilds_animals",), @@ -658,10 +677,11 @@ def get_all_experiments( dropouts=(0, 1), runs=range(5), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("wilds_animals_openset",), @@ -671,10 +691,11 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("wilds_animals_openset",), @@ -684,10 +705,11 @@ def get_all_experiments( dropouts=(0, 1), runs=range(5), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=( @@ -700,10 +722,11 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(2.2, 3, 6, 10, 15), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=( @@ -716,10 +739,11 @@ def get_all_experiments( dropouts=(0, 1), runs=range(5), rewards=(2.2, 3, 6, 10, 15), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("wilds_camelyon",), @@ -729,10 +753,11 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("wilds_camelyon",), @@ -742,10 +767,11 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("wilds_camelyon",), @@ -755,10 +781,11 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(2.2, 3, 6, 10), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("wilds_camelyon",), @@ -768,10 +795,11 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(2.2, 3, 6, 10), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("breeds",), @@ -781,10 +809,11 @@ def get_all_experiments( dropouts=(0,), runs=range(2), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("breeds",), @@ -794,10 +823,11 @@ def get_all_experiments( dropouts=(1,), runs=range(2), rewards=(0,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("breeds",), @@ -807,10 +837,11 @@ def get_all_experiments( dropouts=(0,), runs=range(2), rewards=(2.2, 3, 6, 10, 15), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("breeds",), @@ -820,12 +851,13 @@ def get_all_experiments( dropouts=(1,), runs=range(2), rewards=(2.2, 3, 6, 10, 15), - ) + ), ) # ViT Best lr runs # Non-vit - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("svhn",), @@ -835,10 +867,11 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("svhn",), @@ -848,10 +881,11 @@ def get_all_experiments( runs=range(5), rewards=(2.2, 3, 6, 10), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("svhn_openset",), @@ -861,10 +895,11 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("svhn_openset",), @@ -874,10 +909,11 @@ def get_all_experiments( runs=range(5), rewards=(2.2, 3, 6, 10), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("cifar10",), @@ -887,10 +923,11 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("cifar10",), @@ -900,10 +937,11 @@ def get_all_experiments( runs=range(5), rewards=(2.2, 3, 6, 10), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("cifar100",), @@ -913,10 +951,11 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("cifar100",), @@ -926,10 +965,11 @@ def get_all_experiments( runs=range(5), rewards=(2.2, 3, 6, 10, 12, 15, 20), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("supercifar",), @@ -939,10 +979,11 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("supercifar",), @@ -952,10 +993,11 @@ def get_all_experiments( runs=range(5), rewards=(2.2, 3, 6, 10, 12, 15, 20), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("animals",), @@ -965,10 +1007,11 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("animals",), @@ -978,10 +1021,11 @@ def get_all_experiments( runs=range(5), rewards=(2.2, 3, 6, 10, 15), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("animals_openset",), @@ -991,10 +1035,11 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("animals_openset",), @@ -1004,10 +1049,11 @@ def get_all_experiments( runs=range(5), rewards=(2.2, 3, 6, 10, 15), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("camelyon",), @@ -1017,10 +1063,11 @@ def get_all_experiments( runs=range(10), rewards=(2.2,), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("camelyon",), @@ -1030,10 +1077,11 @@ def get_all_experiments( runs=range(10), rewards=(2.2, 3, 6, 10), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("breeds",), @@ -1043,10 +1091,11 @@ def get_all_experiments( runs=range(2), rewards=(2.2,), learning_rates=(None,), - ) + ), ) - _experiments.extend( + _experiments = chain( + _experiments, Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("breeds",), @@ -1056,137 +1105,144 @@ def get_all_experiments( runs=range(2), rewards=(2.2, 3, 6, 10, 15), learning_rates=(None,), + ), + ) + + if with_precision_study: + _experiments = chain( + _experiments, + Experiment.from_iterables( + group_dir=Path("fd-shifts/svhn_precision_study16"), + datasets=("svhn",), + models=("confidnet",), + backbones=("svhn_small_conv",), + dropouts=(0, 1), + runs=range(5), + rewards=(2.2,), + learning_rates=(None,), + ), ) - ) - - # precision study - _experiments.extend( - Experiment.from_iterables( - group_dir=Path("fd-shifts/svhn_precision_study16"), - datasets=("svhn",), - models=("confidnet",), - backbones=("svhn_small_conv",), - dropouts=(0, 1), - runs=range(5), - rewards=(2.2,), - learning_rates=(None,), - ) - ) - _experiments.extend( - Experiment.from_iterables( - group_dir=Path("fd-shifts/svhn_precision_study32"), - datasets=("svhn",), - models=("confidnet",), - backbones=("svhn_small_conv",), - dropouts=(0, 1), - runs=range(5), - rewards=(2.2,), - learning_rates=(None,), + _experiments = chain( + _experiments, + Experiment.from_iterables( + group_dir=Path("fd-shifts/svhn_precision_study32"), + datasets=("svhn",), + models=("confidnet",), + backbones=("svhn_small_conv",), + dropouts=(0, 1), + runs=range(5), + rewards=(2.2,), + learning_rates=(None,), + ), ) - ) - _experiments.extend( - Experiment.from_iterables( - group_dir=Path("fd-shifts/svhn_precision_study64"), - datasets=("svhn",), - models=("confidnet",), - backbones=("svhn_small_conv",), - dropouts=(0, 1), - runs=range(5), - rewards=(2.2,), - learning_rates=(None,), + _experiments = chain( + _experiments, + Experiment.from_iterables( + group_dir=Path("fd-shifts/svhn_precision_study64"), + datasets=("svhn",), + models=("confidnet",), + backbones=("svhn_small_conv",), + dropouts=(0, 1), + runs=range(5), + rewards=(2.2,), + learning_rates=(None,), + ), ) - ) - _experiments.extend( - Experiment.from_iterables( - group_dir=Path("fd-shifts/camelyon_precision_study16"), - datasets=("camelyon",), - models=("confidnet",), - backbones=("resnet50",), - dropouts=(0, 1), - runs=range(5), - rewards=(2.2,), - learning_rates=(None,), + _experiments = chain( + _experiments, + Experiment.from_iterables( + group_dir=Path("fd-shifts/camelyon_precision_study16"), + datasets=("camelyon",), + models=("confidnet",), + backbones=("resnet50",), + dropouts=(0, 1), + runs=range(5), + rewards=(2.2,), + learning_rates=(None,), + ), ) - ) - _experiments.extend( - Experiment.from_iterables( - group_dir=Path("fd-shifts/camelyon_precision_study32"), - datasets=("camelyon",), - models=("confidnet",), - backbones=("resnet50",), - dropouts=(0, 1), - runs=range(5), - rewards=(2.2,), - learning_rates=(None,), + _experiments = chain( + _experiments, + Experiment.from_iterables( + group_dir=Path("fd-shifts/camelyon_precision_study32"), + datasets=("camelyon",), + models=("confidnet",), + backbones=("resnet50",), + dropouts=(0, 1), + runs=range(5), + rewards=(2.2,), + learning_rates=(None,), + ), ) - ) - _experiments.extend( - Experiment.from_iterables( - group_dir=Path("fd-shifts/camelyon_precision_study64"), - datasets=("camelyon",), - models=("confidnet",), - backbones=("resnet50",), - dropouts=(0, 1), - runs=range(5), - rewards=(2.2,), - learning_rates=(None,), + _experiments = chain( + _experiments, + Experiment.from_iterables( + group_dir=Path("fd-shifts/camelyon_precision_study64"), + datasets=("camelyon",), + models=("confidnet",), + backbones=("resnet50",), + dropouts=(0, 1), + runs=range(5), + rewards=(2.2,), + learning_rates=(None,), + ), ) - ) - _experiments.extend( - Experiment.from_iterables( - group_dir=Path("fd-shifts/vit_precision_study16"), - datasets=("svhn",), - models=("vit",), - backbones=("vit",), - learning_rates=(1e-2,), - dropouts=(0, 1), - runs=range(5), - rewards=(0,), + _experiments = chain( + _experiments, + Experiment.from_iterables( + group_dir=Path("fd-shifts/vit_precision_study16"), + datasets=("svhn",), + models=("vit",), + backbones=("vit",), + learning_rates=(1e-2,), + dropouts=(0, 1), + runs=range(5), + rewards=(0,), + ), ) - ) - _experiments.extend( - Experiment.from_iterables( - group_dir=Path("fd-shifts/vit_precision_study32"), - datasets=("svhn",), - models=("vit",), - backbones=("vit",), - learning_rates=(1e-2,), - dropouts=(0, 1), - runs=range(5), - rewards=(0,), + _experiments = chain( + _experiments, + Experiment.from_iterables( + group_dir=Path("fd-shifts/vit_precision_study32"), + datasets=("svhn",), + models=("vit",), + backbones=("vit",), + learning_rates=(1e-2,), + dropouts=(0, 1), + runs=range(5), + rewards=(0,), + ), ) - ) - _experiments.extend( - Experiment.from_iterables( - group_dir=Path("fd-shifts/vit_precision_study64"), - datasets=("svhn",), - models=("vit",), - backbones=("vit",), - learning_rates=(1e-2,), - dropouts=(0, 1), - runs=range(5), - rewards=(0,), + _experiments = chain( + _experiments, + Experiment.from_iterables( + group_dir=Path("fd-shifts/vit_precision_study64"), + datasets=("svhn",), + models=("vit",), + backbones=("vit",), + learning_rates=(1e-2,), + dropouts=(0, 1), + runs=range(5), + rewards=(0,), + ), ) - ) if not with_vit_special_runs: - _experiments = list( - filter( - lambda exp: not (exp.backbone == "vit" and exp.model != "vit"), - _experiments, - ) + _experiments = filter( + lambda exp: not (exp.backbone == "vit" and exp.model != "vit"), + _experiments, ) - # if with_ms_runs: - _experiments.extend(get_ms_experiments()) + if with_ms_runs: + _experiments = chain(_experiments, get_ms_experiments()) return _experiments From 275fe9ecb290b3275f0d82d94fe1f7234d6d6bf7 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 26 Oct 2023 11:36:51 +0200 Subject: [PATCH 003/136] refactor: take out experiment filter --- fd_shifts/experiments/launcher.py | 153 ++++++++++++++++-------------- 1 file changed, 83 insertions(+), 70 deletions(-) diff --git a/fd_shifts/experiments/launcher.py b/fd_shifts/experiments/launcher.py index b233103..8e33587 100644 --- a/fd_shifts/experiments/launcher.py +++ b/fd_shifts/experiments/launcher.py @@ -4,14 +4,13 @@ import re from datetime import datetime from pathlib import Path -from typing import Any +from typing import Any, Iterator import rich from rich.syntax import Syntax from fd_shifts import experiments, logger from fd_shifts.experiments.cluster import submit -from fd_shifts.experiments.validation import ValidationResult BASH_LOCAL_COMMAND = r""" bash -c 'set -o pipefail; {command} |& tee -a "./logs/{log_file_name}.log"' @@ -22,17 +21,6 @@ """ -def parse_validation_file(validation_file: Path) -> list[ValidationResult]: - with validation_file.open() as file: - _experiments = json.load(file) - - _experiments = list(map(lambda t: ValidationResult(**t[1]), _experiments.items())) - for exp in _experiments: - exp.experiment = experiments.Experiment(**exp.experiment) - exp.logs = [] - return _experiments - - async def worker(name, queue: asyncio.Queue[str]): while True: # Get a "work item" out of the queue. @@ -55,13 +43,21 @@ async def worker(name, queue: asyncio.Queue[str]): def update_overrides( - overrides: dict[str, Any], max_batch_size: int = 32 + overrides: dict[str, Any], iid_only: bool = False, mode: str = "train_test" ) -> dict[str, Any]: - if overrides.get("trainer.batch_size", -1) > max_batch_size: - accum = overrides["trainer.batch_size"] // max_batch_size - overrides["trainer.batch_size"] = max_batch_size + if mode in ["train", "train_test"] and overrides.get("trainer.batch_size", -1) > 32: + accum = overrides["trainer.batch_size"] // 32 + overrides["trainer.batch_size"] = 32 overrides["trainer.accumulate_grad_batches"] = accum + if mode in ["test"]: + overrides["trainer.batch_size"] = 256 + + if iid_only: + overrides["eval.query_studies.noise_study"] = [] + overrides["eval.query_studies.in_class_study"] = [] + overrides["eval.query_studies.new_class_study"] = [] + return overrides @@ -70,6 +66,7 @@ async def run( mode: str, dry_run: bool, max_batch_size: int = 32, + iid_only: bool = False, ): if len(_experiments) == 0: print("Nothing to run") @@ -83,7 +80,7 @@ async def run( for experiment in _experiments: log_file_name = f"{datetime.now().strftime('%Y-%m-%d_%H-%M-%S')}-{str(experiment.to_path()).replace('/', '_').replace('.','_')}" - overrides = update_overrides(experiment.overrides(), max_batch_size) + overrides = update_overrides(experiment.overrides(), iid_only, mode) cmd = BASH_BASE_COMMAND.format( overrides=" ".join(f"{k}={v}" for k, v in overrides.items()), @@ -126,88 +123,96 @@ async def run( await asyncio.gather(*tasks, return_exceptions=True) -def launch( +def filter_experiments( dataset: str | None, dropout: int | None, model: str | None, backbone: str | None, exclude_model: str | None, - mode: str, - dry_run: bool, run_nr: int | None, rew: float | None, - cluster: bool, name: str | None, - max_batch_size: int, -): +) -> Iterator[experiments.Experiment]: _experiments = experiments.get_all_experiments() - _experiments = list( - filter(lambda e: "precision_study" not in str(e.to_path()), _experiments) + _experiments = filter( + lambda e: "precision_study" not in str(e.to_path()), _experiments ) if dataset is not None: - _experiments = list( - filter( - lambda experiment: experiment.dataset == dataset, - _experiments, - ) + _experiments = filter( + lambda experiment: experiment.dataset == dataset, + _experiments, ) if dropout is not None: - _experiments = list( - filter( - lambda experiment: experiment.dropout == dropout, - _experiments, - ) + _experiments = filter( + lambda experiment: experiment.dropout == dropout, + _experiments, ) if rew is not None: - _experiments = list( - filter( - lambda experiment: experiment.reward == rew, - _experiments, - ) + _experiments = filter( + lambda experiment: experiment.reward == rew, + _experiments, ) if run_nr is not None: - _experiments = list( - filter( - lambda experiment: experiment.run == run_nr, - _experiments, - ) + _experiments = filter( + lambda experiment: experiment.run == run_nr, + _experiments, ) if model is not None: - _experiments = list( - filter( - lambda experiment: experiment.model == model, - _experiments, - ) + _experiments = filter( + lambda experiment: experiment.model == model, + _experiments, ) if backbone is not None: - _experiments = list( - filter( - lambda experiment: experiment.backbone == backbone, - _experiments, - ) + _experiments = filter( + lambda experiment: experiment.backbone == backbone, + _experiments, ) if exclude_model is not None: - _experiments = list( - filter( - lambda experiment: experiment.model != exclude_model, - _experiments, - ) + _experiments = filter( + lambda experiment: experiment.model != exclude_model, + _experiments, ) if name is not None: - _experiments = list( - filter( - lambda experiment: str(experiment.to_path()) == name, - _experiments, - ) + _experiments = filter( + lambda experiment: str(experiment.to_path()) == name, + _experiments, ) + return _experiments + + +def launch( + dataset: str | None, + dropout: int | None, + model: str | None, + backbone: str | None, + exclude_model: str | None, + mode: str, + dry_run: bool, + run_nr: int | None, + rew: float | None, + cluster: bool, + name: str | None, + max_batch_size: int, + iid_only: bool, +): + _experiments = filter_experiments( + dataset, + dropout, + model, + backbone, + exclude_model, + run_nr, + rew, + name, + ) print("Launching:") for exp in map( lambda exp: str(exp.to_path()), @@ -216,12 +221,12 @@ def launch( rich.print(exp) if cluster: - submit(_experiments, mode, dry_run) + submit(_experiments, mode, dry_run, iid_only) else: - asyncio.run(run(_experiments, mode, dry_run, max_batch_size)) + asyncio.run(run(_experiments, mode, dry_run, max_batch_size, iid_only)) -def add_arguments(parser: argparse.ArgumentParser): +def add_filter_arguments(parser: argparse.ArgumentParser): parser.add_argument("--dataset", default=None, type=str) parser.add_argument("--dropout", default=None, type=int, choices=(0, 1)) parser.add_argument( @@ -237,6 +242,13 @@ def add_arguments(parser: argparse.ArgumentParser): parser.add_argument("--run", default=None, type=int) parser.add_argument("--reward", default=None, type=float) + parser.add_argument("--name", default=None, type=str) + + return parser + + +def add_arguments(parser: argparse.ArgumentParser): + add_filter_arguments(parser) parser.add_argument("--dry-run", action="store_true") parser.add_argument( "--mode", @@ -244,8 +256,8 @@ def add_arguments(parser: argparse.ArgumentParser): choices=("test", "train", "train_test", "analysis"), ) parser.add_argument("--cluster", action="store_true") + parser.add_argument("--iid-only", action="store_true") - parser.add_argument("--name", default=None, type=str) parser.add_argument("--max-batch-size", default=32, type=int) return parser @@ -267,6 +279,7 @@ def main(args): cluster=args.cluster, name=args.name, max_batch_size=args.max_batch_size, + iid_only=args.iid_only, ) From 3d47c459851af61e0d1d2b8a7b7f33addb1ab3ce Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 26 Oct 2023 11:37:13 +0200 Subject: [PATCH 004/136] feat: make all jobs run on smalles gpu --- fd_shifts/experiments/cluster.py | 132 +++++++++---------------------- 1 file changed, 38 insertions(+), 94 deletions(-) diff --git a/fd_shifts/experiments/cluster.py b/fd_shifts/experiments/cluster.py index f804ef4..6ab1ad8 100644 --- a/fd_shifts/experiments/cluster.py +++ b/fd_shifts/experiments/cluster.py @@ -1,22 +1,13 @@ -import argparse -import asyncio -import json import re import subprocess -import sys -import urllib.request -from datetime import datetime -from pathlib import Path from typing import Any from rich import print -from rich.pretty import pprint -from rich.progress import Progress from rich.syntax import Syntax -from fd_shifts import experiments, logger -from fd_shifts.experiments.sync import sync_to_dir_remote -from fd_shifts.experiments.validation import ValidationResult +from fd_shifts import experiments + +# -R "select[hname!='e230-dgx2-2']" \ BASH_BSUB_COMMAND = r""" bsub -gpu num=1:j_exclusive=yes:gmem={gmem}\ @@ -24,7 +15,6 @@ -q gpu \ -u 'till.bungert@dkfz-heidelberg.de' \ -B {nodes} \ - -R "select[hname!='e230-dgx2-2']" \ -g /t974t/train \ -J "{name}" \ bash -li -c 'set -o pipefail; echo $LSB_JOBID && source .envrc && {command} |& tee -a "/home/t974t/logs/$LSB_JOBID.log"' @@ -35,67 +25,6 @@ """ -def get_jobs() -> list[dict[str, str]]: - with urllib.request.urlopen("http://localhost:3030/jobs") as response: - records: list[dict[str, str]] = json.loads(response.read())["RECORDS"] - return records - - -def is_experiment_running( - experiment: ValidationResult, jobs: list[dict[str, str]] -) -> bool: - _experiments = list( - map( - lambda j: j["JOB_NAME"], - filter(lambda j: j["STAT"] in ("RUN", "PEND", "DONE"), jobs), - ) - ) - running = ( - str(experiment.experiment.to_path().relative_to("fd-shifts")) in _experiments - ) - - if running: - print(f"{experiment.experiment.to_path()} is already running") - - return running - - -def get_batch_size(dataset: str, model: str, mode: str): - match mode: - case "test": - if model == "vit": - return 80 - - if dataset in [ - "wilds_animals", - "animals", - "wilds_animals_openset", - "animals_openset", - "breeds", - ]: - return 128 - - return 512 - case "train" | "train_test": - match model: - case "vit": - match dataset: - case "svhn" | "svhn_openset" | "cifar10" | "breeds": - return "64 +trainer.accumulate_grad_batches=2" - case "wilds_animals" | "wilds_animals_openset" | "cifar100" | "super_cifar100": - return "64 +trainer.accumulate_grad_batches=8" - case _: - match dataset: - case "svhn" | "svhn_openset" | "cifar10" | "cifar100" | "super_cifar100" | "breeds": - return 128 - case "wilds_animals" | "wilds_animals_openset" | "animals" | "animals_openset": - return 16 - case "wilds_camelyon": - return 32 - case _: - return 128 - - def get_nodes(mode: str): match mode: case "train" | "train_test": @@ -109,27 +38,39 @@ def get_gmem(mode: str, model: str): case "train" | "train_test": match model: case "vit": - return "33G" + return "23G" case _: - return "33G" + return "23G" case _: match model: case "vit": - return "33G" + return "23G" case _: - return "33G" + return "23G" -def update_overrides(overrides: dict[str, Any]) -> dict[str, Any]: - if overrides.get("trainer.batch_size", -1) > 64: - accum = overrides["trainer.batch_size"] // 64 - overrides["trainer.batch_size"] = 64 +def update_overrides( + overrides: dict[str, Any], iid_only: bool = False, mode: str = "train_test" +) -> dict[str, Any]: + if mode in ["train", "train_test"] and overrides.get("trainer.batch_size", -1) > 32: + accum = overrides["trainer.batch_size"] // 32 + overrides["trainer.batch_size"] = 32 overrides["trainer.accumulate_grad_batches"] = accum + if mode in ["test"]: + overrides["trainer.batch_size"] = 256 + + if iid_only: + overrides["eval.query_studies.noise_study"] = [] + overrides["eval.query_studies.in_class_study"] = [] + overrides["eval.query_studies.new_class_study"] = [] + return overrides -def submit(_experiments: list[experiments.Experiment], mode: str, dry_run: bool): +def submit( + _experiments: list[experiments.Experiment], mode: str, dry_run: bool, iid_only: bool +): try: from pssh.clients import SSHClient from pssh.exceptions import Timeout @@ -142,19 +83,22 @@ def submit(_experiments: list[experiments.Experiment], mode: str, dry_run: bool) print("Nothing to run") return - client = SSHClient("odcf-worker01.inet.dkfz-heidelberg.de") + if not dry_run: + client = SSHClient("odcf-worker02.inet.dkfz-heidelberg.de") for experiment in _experiments: try: - if path := experiment.overrides().get( - "trainer.callbacks.training_stages.pretrained_backbone_path" - ): - sync_to_dir_remote( - path.replace("${EXPERIMENT_ROOT_DIR%/}/", "fd-shifts/"), - dry_run=dry_run, - ) - - overrides = update_overrides(experiment.overrides()) + # if path := experiment.overrides().get( + # "trainer.callbacks.training_stages.pretrained_backbone_path" + # ): + # sync_to_dir_remote( + # path.replace("${EXPERIMENT_ROOT_DIR%/}/", "fd-shifts/"), + # dry_run=dry_run, + # ) + + overrides = update_overrides( + experiment.overrides(), iid_only=iid_only, mode=mode + ) cmd = BASH_BASE_COMMAND.format( overrides=" ".join(f"{k}={v}" for k, v in overrides.items()), mode=mode, @@ -189,7 +133,7 @@ def submit(_experiments: list[experiments.Experiment], mode: str, dry_run: bool) continue with client.open_shell(read_timeout=1) as shell: - shell.run("cd failure-detection-benchmark") + shell.run("cd ~/Projects/failure-detection-benchmark") shell.run("source .envrc") shell.run(cmd) From bf029204fcdf2eda7d8395f49b7573910e22e9f3 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 26 Oct 2023 12:16:14 +0200 Subject: [PATCH 005/136] feat: check additional exp dirs in reporting --- fd_shifts/reporting/__init__.py | 42 +++++++++++++++++++++++---------- 1 file changed, 29 insertions(+), 13 deletions(-) diff --git a/fd_shifts/reporting/__init__.py b/fd_shifts/reporting/__init__.py index 56fdd98..f86a8ae 100644 --- a/fd_shifts/reporting/__init__.py +++ b/fd_shifts/reporting/__init__.py @@ -59,8 +59,23 @@ def gather_data(data_dir: Path): Args: data_dir (Path): where to collect to """ - experiment_dir = Path(os.environ["EXPERIMENT_ROOT_DIR"]) - experiments = get_all_experiments() + experiment_dirs = [ + Path(os.environ["EXPERIMENT_ROOT_DIR"]), + ] + + if add_dirs := os.getenv("EXPERIMENT_ADD_DIRS"): + ( + experiment_dirs.extend( + map( + lambda path: Path(path), + add_dirs.split(os.pathsep), + ) + ), + ) + + experiments = get_all_experiments( + with_ms_runs=False, with_precision_study=False, with_vit_special_runs=False + ) for dataset in DATASETS + ("animals_openset", "svhn_openset"): print(dataset) @@ -69,19 +84,20 @@ def gather_data(data_dir: Path): _paths = [] _vit_paths = [] - for experiment in _experiments: - if experiment.model == "vit": - _vit_paths.extend( - (experiment_dir / experiment.to_path() / "test_results").glob( - "*.csv" + for experiment_dir in experiment_dirs: + for experiment in _experiments: + if experiment.model == "vit": + _vit_paths.extend( + (experiment_dir / experiment.to_path() / "test_results").glob( + "*.csv" + ) ) - ) - else: - _paths.extend( - (experiment_dir / experiment.to_path() / "test_results").glob( - "*.csv" + else: + _paths.extend( + (experiment_dir / experiment.to_path() / "test_results").glob( + "*.csv" + ) ) - ) if len(_paths) > 0: dframe: pd.DataFrame = pd.concat( From 7f22308157cd5605368e4f3a5242d5b9291a1869 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Fri, 27 Oct 2023 20:47:41 +0200 Subject: [PATCH 006/136] feat: mlflow logging --- .gitignore | 1 + fd_shifts/exec.py | 37 +++++++++++++++----- fd_shifts/models/callbacks/confid_monitor.py | 2 -- fd_shifts/models/devries_model.py | 7 +++- fd_shifts/models/vit_model.py | 7 +++- 5 files changed, 42 insertions(+), 12 deletions(-) diff --git a/.gitignore b/.gitignore index 2d30367..06225a3 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ **/__pycache__ +mlruns .DS_Store *.log *.csv diff --git a/fd_shifts/exec.py b/fd_shifts/exec.py index 973fc25..4623b46 100644 --- a/fd_shifts/exec.py +++ b/fd_shifts/exec.py @@ -1,14 +1,14 @@ import os import random +from pathlib import Path from typing import cast import hydra -import omegaconf import pytorch_lightning as pl import torch from omegaconf import DictConfig, OmegaConf -from pytorch_lightning.callbacks.progress.rich_progress import RichProgressBar -from pytorch_lightning.loggers import CSVLogger, TensorBoardLogger +from pytorch_lightning.callbacks import RichProgressBar +from pytorch_lightning.loggers import CSVLogger, MLFlowLogger, TensorBoardLogger from rich import get_console, reconfigure from torch import multiprocessing @@ -16,6 +16,7 @@ from fd_shifts.loaders.data_loader import FDShiftsDataLoader from fd_shifts.models import get_model from fd_shifts.models.callbacks import get_callbacks +from fd_shifts.models.callbacks.device_stats import DeviceStatsMonitor from fd_shifts.utils import exp_utils configs.init() @@ -73,6 +74,7 @@ def train( limit_batches: float | int = 1.0 num_epochs = cf.trainer.num_epochs val_every_n_epoch = cf.trainer.val_every_n_epoch + log_every_n_steps = 50 if isinstance(cf.trainer.fast_dev_run, bool): limit_batches = 1 if cf.trainer.fast_dev_run else 1.0 @@ -81,10 +83,11 @@ def train( val_every_n_epoch = 1 if cf.trainer.fast_dev_run else val_every_n_epoch elif isinstance(cf.trainer.fast_dev_run, int): limit_batches = cf.trainer.fast_dev_run * accumulate_grad_batches - max_steps = cf.trainer.fast_dev_run * 5 + max_steps = cf.trainer.fast_dev_run * 2 cf.trainer.dg_pretrain_epochs = None cf.trainer.dg_pretrain_steps = (max_steps * 2) // 3 val_every_n_epoch = 1 + log_every_n_steps = 1 num_epochs = None datamodule = FDShiftsDataLoader(cf) @@ -98,13 +101,21 @@ def train( save_dir=str(cf.exp.group_dir), name=cf.exp.name, version=cf.exp.version ) + mlf_logger = MLFlowLogger( + experiment_name="fd_shifts", + run_name=cf.exp.name, + ) + + device_stats_monitor = DeviceStatsMonitor(cpu_stats=True) + trainer = pl.Trainer( accelerator="auto", devices="auto", - logger=[tb_logger, csv_logger], + logger=[tb_logger, csv_logger, mlf_logger], + log_every_n_steps=log_every_n_steps, max_epochs=num_epochs, max_steps=max_steps, - callbacks=[progress] + get_callbacks(cf), + callbacks=[progress, device_stats_monitor] + get_callbacks(cf), resume_from_checkpoint=resume_ckpt_path, benchmark=cf.trainer.benchmark, check_val_every_n_epoch=val_every_n_epoch, @@ -158,17 +169,27 @@ def test(cf: configs.Config, progress: RichProgressBar = RichProgressBar()) -> N os.makedirs(cf.test.dir) limit_batches: float | int = 1.0 + log_every_n_steps = 50 if isinstance(cf.trainer.fast_dev_run, bool): limit_batches = 1 if cf.trainer.fast_dev_run else 1.0 elif isinstance(cf.trainer.fast_dev_run, int): limit_batches = cf.trainer.fast_dev_run + log_every_n_steps = 1 + + mlf_logger = MLFlowLogger( + experiment_name="fd_shifts", + run_name=cf.exp.name, + ) + + device_stats_monitor = DeviceStatsMonitor(cpu_stats=True) trainer = pl.Trainer( accelerator="auto", devices="auto", - logger=False, - callbacks=[progress] + get_callbacks(cf), + logger=mlf_logger, + log_every_n_steps=log_every_n_steps, + callbacks=[progress, device_stats_monitor] + get_callbacks(cf), limit_test_batches=limit_batches, replace_sampler_ddp=False, ) diff --git a/fd_shifts/models/callbacks/confid_monitor.py b/fd_shifts/models/callbacks/confid_monitor.py index 56cb72d..d575181 100644 --- a/fd_shifts/models/callbacks/confid_monitor.py +++ b/fd_shifts/models/callbacks/confid_monitor.py @@ -201,7 +201,6 @@ def on_train_epoch_end(self, trainer, pl_module): ) tqdm.write(f"CHECK TRAIN METRICS {str(monitor_metrics)}") tensorboard = pl_module.loggers[0].experiment - pl_module.log("step", pl_module.current_epoch, sync_dist=self.sync_dist) for k, v in monitor_metrics.items(): pl_module.log("train/{}".format(k), v, sync_dist=self.sync_dist) tensorboard.add_scalar( @@ -396,7 +395,6 @@ def on_validation_epoch_end(self, trainer, pl_module): ext_confid_name=pl_module.ext_confid_name, ) tensorboard = pl_module.loggers[0].experiment - pl_module.log("step", pl_module.current_epoch, sync_dist=self.sync_dist) for k, v in monitor_metrics.items(): pl_module.log("val/{}".format(k), v, sync_dist=self.sync_dist) tensorboard.add_scalar( diff --git a/fd_shifts/models/devries_model.py b/fd_shifts/models/devries_model.py index 961fe04..6550ab3 100644 --- a/fd_shifts/models/devries_model.py +++ b/fd_shifts/models/devries_model.py @@ -1,5 +1,6 @@ from __future__ import annotations +import json import re from typing import TYPE_CHECKING @@ -18,6 +19,10 @@ from fd_shifts import configs +def to_dict(obj): + return json.loads(json.dumps(obj, default=lambda o: getattr(o, "__dict__", str(o)))) + + class net(pl.LightningModule): """ @@ -44,7 +49,7 @@ class net(pl.LightningModule): def __init__(self, cf: configs.Config): super(net, self).__init__() - self.save_hyperparameters() + self.save_hyperparameters(to_dict(cf)) self.optimizer_cfgs = cf.trainer.optimizer self.lr_scheduler_cfgs = cf.trainer.lr_scheduler diff --git a/fd_shifts/models/vit_model.py b/fd_shifts/models/vit_model.py index 6e2e1c1..1ae1cf2 100644 --- a/fd_shifts/models/vit_model.py +++ b/fd_shifts/models/vit_model.py @@ -1,5 +1,6 @@ from __future__ import annotations +import json from itertools import islice from typing import TYPE_CHECKING @@ -21,13 +22,17 @@ from fd_shifts import configs +def to_dict(obj): + return json.loads(json.dumps(obj, default=lambda o: getattr(o, "__dict__", str(o)))) + + class net(pl.LightningModule): """Vision Transformer module""" def __init__(self, cfg: configs.Config): super().__init__() - self.save_hyperparameters() + self.save_hyperparameters(to_dict(cfg)) self.config = cfg From d13700209d4f88fd270cf6cb4e9cb052238b6582 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Fri, 27 Oct 2023 21:13:42 +0200 Subject: [PATCH 007/136] feat: log device stats --- fd_shifts/models/callbacks/device_stats.py | 174 +++++++++++++++++++++ 1 file changed, 174 insertions(+) create mode 100644 fd_shifts/models/callbacks/device_stats.py diff --git a/fd_shifts/models/callbacks/device_stats.py b/fd_shifts/models/callbacks/device_stats.py new file mode 100644 index 0000000..c917add --- /dev/null +++ b/fd_shifts/models/callbacks/device_stats.py @@ -0,0 +1,174 @@ +from typing import Any, Optional + +import pytorch_lightning as pl +from pytorch_lightning.callbacks import Callback +from pytorch_lightning.utilities.exceptions import MisconfigurationException +from pytorch_lightning.utilities.types import STEP_OUTPUT + +# CPU device metrics from lightning 2.1.0, as 1.6.5 doesn't have them yet +_CPU_VM_PERCENT = "cpu_vm_percent" +_CPU_PERCENT = "cpu_percent" +_CPU_SWAP_PERCENT = "cpu_swap_percent" + + +def get_cpu_stats() -> dict[str, float]: + try: + import psutil + except ImportError: + raise ModuleNotFoundError( + "Fetching CPU device stats requires `psutil` to be installed." + ) + + return { + _CPU_VM_PERCENT: psutil.virtual_memory().percent, + _CPU_PERCENT: psutil.cpu_percent(), + _CPU_SWAP_PERCENT: psutil.swap_memory().percent, + } + + +# Adapted from lightning 2.1.0, as it does not have nvidia-smi based stats +class DeviceStatsMonitor(Callback): + r"""Automatically monitors and logs device stats during training, validation and testing stage. + ``DeviceStatsMonitor`` is a special callback as it requires a ``logger`` to passed as argument to the ``Trainer``. + + Args: + cpu_stats: if ``None``, it will log CPU stats only if the accelerator is CPU. + If ``True``, it will log CPU stats regardless of the accelerator. + If ``False``, it will not log CPU stats regardless of the accelerator. + + Raises: + MisconfigurationException: + If ``Trainer`` has no logger. + ModuleNotFoundError: + If ``psutil`` is not installed and CPU stats are monitored. + + Example:: + + from lightning import Trainer + from lightning.pytorch.callbacks import DeviceStatsMonitor + device_stats = DeviceStatsMonitor() + trainer = Trainer(callbacks=[device_stats]) + + """ + + def __init__(self, cpu_stats: Optional[bool] = None) -> None: + self._cpu_stats = cpu_stats + + def setup( + self, + trainer: "pl.Trainer", + pl_module: "pl.LightningModule", + stage: str, + ) -> None: + if stage != "fit": + return + + if not trainer.loggers: + raise MisconfigurationException( + "Cannot use `DeviceStatsMonitor` callback with `Trainer(logger=False)`." + ) + + # warn in setup to warn once + device = trainer.strategy.root_device + + def _get_and_log_device_stats(self, trainer: "pl.Trainer", key: str) -> None: + if not trainer._logger_connector.should_update_logs: + return + + device = trainer.strategy.root_device + if self._cpu_stats is False and device.type == "cpu": + # cpu stats are disabled + return + + # device_stats = trainer.accelerator.get_device_stats(device) + device_stats = {} + + if self._cpu_stats: + # Don't query CPU stats twice if CPU is accelerator + device_stats.update(get_cpu_stats()) + + if device.type == "cuda": + from pytorch_lightning.accelerators.gpu import get_nvidia_gpu_stats + + gpu_stats = get_nvidia_gpu_stats(device) + if any(map(lambda k: k in device_stats, gpu_stats.keys())): + raise RuntimeError("Replacing Stats") + + device_stats.update(gpu_stats) + + for logger in trainer.loggers: + separator = logger.group_separator + prefixed_device_stats = _prefix_metric_keys( + device_stats, f"{self.__class__.__qualname__}.{key}", separator + ) + logger.log_metrics( + prefixed_device_stats, + # step=trainer.fit_loop.epoch_loop._batches_that_stepped, + ) + + def on_train_batch_start( + self, + trainer: "pl.Trainer", + pl_module: "pl.LightningModule", + batch: Any, + batch_idx: int, + ) -> None: + self._get_and_log_device_stats(trainer, "batch_start") + + def on_train_batch_end( + self, + trainer: "pl.Trainer", + pl_module: "pl.LightningModule", + outputs: STEP_OUTPUT, + batch: Any, + batch_idx: int, + ) -> None: + self._get_and_log_device_stats(trainer, "batch_end") + + def on_validation_batch_start( + self, + trainer: "pl.Trainer", + pl_module: "pl.LightningModule", + batch: Any, + batch_idx: int, + dataloader_idx: int = 0, + ) -> None: + self._get_and_log_device_stats(trainer, "batch_start") + + def on_validation_batch_end( + self, + trainer: "pl.Trainer", + pl_module: "pl.LightningModule", + outputs: STEP_OUTPUT, + batch: Any, + batch_idx: int, + dataloader_idx: int = 0, + ) -> None: + self._get_and_log_device_stats(trainer, "batch_end") + + def on_test_batch_start( + self, + trainer: "pl.Trainer", + pl_module: "pl.LightningModule", + batch: Any, + batch_idx: int, + dataloader_idx: int = 0, + ) -> None: + self._get_and_log_device_stats(trainer, "batch_start") + + def on_test_batch_end( + self, + trainer: "pl.Trainer", + pl_module: "pl.LightningModule", + outputs: STEP_OUTPUT, + batch: Any, + batch_idx: int, + dataloader_idx: int = 0, + ) -> None: + self._get_and_log_device_stats(trainer, "batch_end") + + +def _prefix_metric_keys( + metrics_dict: dict[str, float], prefix: str, separator: str +) -> dict[str, float]: + return {prefix + separator + k: v for k, v in metrics_dict.items()} From e696eeb42a2dee53e699937b9079d568a20e68ab Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Fri, 27 Oct 2023 21:57:24 +0200 Subject: [PATCH 008/136] fix: config to dict handle pydantic --- fd_shifts/models/confidnet_model.py | 3 ++- fd_shifts/models/devries_model.py | 6 +----- fd_shifts/models/vit_model.py | 5 +---- fd_shifts/utils/__init__.py | 15 +++++++++++++++ 4 files changed, 19 insertions(+), 10 deletions(-) diff --git a/fd_shifts/models/confidnet_model.py b/fd_shifts/models/confidnet_model.py index d6d529a..043ced1 100644 --- a/fd_shifts/models/confidnet_model.py +++ b/fd_shifts/models/confidnet_model.py @@ -14,6 +14,7 @@ from fd_shifts import logger from fd_shifts.models.networks import get_network from fd_shifts.models.networks.resnet50_imagenet import ResNetEncoder +from fd_shifts.utils import to_dict if TYPE_CHECKING: from fd_shifts import configs @@ -51,7 +52,7 @@ class Module(pl.LightningModule): def __init__(self, cf: configs.Config): super().__init__() - self.save_hyperparameters() + self.save_hyperparameters(to_dict(cf)) self.conf = cf self.test_mcd_samples = cf.model.test_mcd_samples diff --git a/fd_shifts/models/devries_model.py b/fd_shifts/models/devries_model.py index 6550ab3..c49101f 100644 --- a/fd_shifts/models/devries_model.py +++ b/fd_shifts/models/devries_model.py @@ -1,6 +1,5 @@ from __future__ import annotations -import json import re from typing import TYPE_CHECKING @@ -14,15 +13,12 @@ from fd_shifts import logger from fd_shifts.models.networks import get_network +from fd_shifts.utils import to_dict if TYPE_CHECKING: from fd_shifts import configs -def to_dict(obj): - return json.loads(json.dumps(obj, default=lambda o: getattr(o, "__dict__", str(o)))) - - class net(pl.LightningModule): """ diff --git a/fd_shifts/models/vit_model.py b/fd_shifts/models/vit_model.py index 1ae1cf2..a01678f 100644 --- a/fd_shifts/models/vit_model.py +++ b/fd_shifts/models/vit_model.py @@ -17,15 +17,12 @@ from tqdm import tqdm from fd_shifts import logger +from fd_shifts.utils import to_dict if TYPE_CHECKING: from fd_shifts import configs -def to_dict(obj): - return json.loads(json.dumps(obj, default=lambda o: getattr(o, "__dict__", str(o)))) - - class net(pl.LightningModule): """Vision Transformer module""" diff --git a/fd_shifts/utils/__init__.py b/fd_shifts/utils/__init__.py index 0c43498..24fc4b8 100644 --- a/fd_shifts/utils/__init__.py +++ b/fd_shifts/utils/__init__.py @@ -1,4 +1,19 @@ import importlib +import json + +from omegaconf import DictConfig, ListConfig, OmegaConf +from pydantic.json import pydantic_encoder + + +def __to_dict(obj): + if isinstance(obj, DictConfig) or isinstance(obj, ListConfig): + return OmegaConf.to_container(obj) + return pydantic_encoder(obj) + + +def to_dict(obj): + s = json.dumps(obj, default=__to_dict) + return json.loads(s) def instantiate_from_str(name, *args, **kwargs): From c557cf2405fd87700fc4e4c880b740588199c997 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 8 Nov 2023 11:08:40 +0100 Subject: [PATCH 009/136] feat: add temperature scaling --- fd_shifts/analysis/__init__.py | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 3364369..7527c77 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -226,6 +226,33 @@ def __call__(self, confids: npt.NDArray[Any]) -> npt.NDArray[Any]: return 1 / (1 + np.exp(confids * self.a + self.b)) +class TemperatureScaling: + def __init__(self, val_logits: npt.NDArray[Any], val_labels: npt.NDArray[Any]): + logger.info("Fit temperature to validation logits") + self.temperature = torch.ones(1).requires_grad_(True) + + logits = torch.tensor(val_logits) + labels = torch.tensor(val_labels).long() + + optimizer = torch.optim.LBFGS([self.temperature], lr=0.01, max_iter=50) + + def _eval(): + optimizer.zero_grad() + loss = torch.nn.functional.cross_entropy(logits / self.temperature, labels) + loss.backward() + return loss + + optimizer.step(_eval) + + self.temperature = self.temperature.item() + + def __call__(self, logits: npt.NDArray[Any]) -> npt.NDArray[Any]: + return np.max( + torch.softmax(torch.tensor(logits) / self.temperature, dim=1).numpy(), + axis=1, + ) + + @dataclass class QuantileScaling: """Quantile scaling normalization function""" @@ -281,6 +308,8 @@ def __init__( ) ) + self.method_dict["query_confids"].append("temp_logits") + self.secondary_confids = [] if ( From 61a590ee3239992a9ce15dc424db937715186792 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Mon, 13 Nov 2023 22:10:07 +0100 Subject: [PATCH 010/136] fix: more robust and 1000x faster dermo loading --- fd_shifts/loaders/dataset_collection.py | 62 +++++++++++++------------ 1 file changed, 32 insertions(+), 30 deletions(-) diff --git a/fd_shifts/loaders/dataset_collection.py b/fd_shifts/loaders/dataset_collection.py index 0f2cf79..560437a 100644 --- a/fd_shifts/loaders/dataset_collection.py +++ b/fd_shifts/loaders/dataset_collection.py @@ -2,6 +2,7 @@ import io import os import pickle +from pathlib import Path from typing import Any, Callable, Optional, Tuple, TypeVar import albumentations @@ -258,12 +259,18 @@ def __getitem__(self, index): start, end = filepath.split("XXX") channel_path = start + str(channel) + end channels.append(channel_path) - blue = cv2.imread(channels[0])[:, :, 0] - green = cv2.imread(channels[1])[:, :, 0] - red = cv2.imread(channels[2])[:, :, 0] - cyan = cv2.imread(channels[3])[:, :, 0] - magenta = cv2.imread(channels[4])[:, :, 0] - yellow = cv2.imread(channels[5])[:, :, 0] + try: + blue = cv2.imread(channels[0])[:, :, 0] + green = cv2.imread(channels[1])[:, :, 0] + red = cv2.imread(channels[2])[:, :, 0] + cyan = cv2.imread(channels[3])[:, :, 0] + magenta = cv2.imread(channels[4])[:, :, 0] + yellow = cv2.imread(channels[5])[:, :, 0] + except TypeError: + logger.error(f"Error loading {filepath}") + self.csv.drop([index], inplace=True) + self.csv.reset_index(drop=True, inplace=True) + return self.__getitem__(index) image = np.stack((red, green, blue, cyan, magenta, yellow), axis=2) @@ -297,6 +304,11 @@ def __getitem__(self, index): row = self.csv.iloc[index] image = cv2.imread(row.filepath) + if image is None: + logger.error(f"Error loading {row.filepath}") + self.csv.drop([index], inplace=True) + self.csv.reset_index(drop=True, inplace=True) + return self.__getitem__(index) if self.transform is not None: image = Image.fromarray(image) image = self.transform(image) @@ -1954,31 +1966,21 @@ def get_dataset( dataset_name = "all" dataroot = os.environ["DATASET_ROOT_DIR"] csv_file = f"{dataroot}/{dataset}/{dataset_name}_{binary}_{mode}.csv" + if "corr" in name: + _, cor = name.split("xray_chestallcorr") + cor = "_" + cor + else: + cor = "" df = pd.read_csv(csv_file) - - for i in range(len(df)): - atti = df["attribution"].iloc[i] - dataset = atti - datafolder = "/" + dataset - data_dir = os.path.join(dataroot + datafolder) - img_sub_path = df["filepath"].iloc[i] - img_path = data_dir + "/" + img_sub_path - if ".png" in img_path: - start, _ = img_path.split(".png") - end = "png" - if ".jpg" in img_path: - start, _ = img_path.split(".jpg") - end = "jpg" - - # create new path for corrupted images - if "corr" in name: - _, cor = name.split("xray_chestallcorr") - cor = "_" + cor - else: - cor = "" - df.iloc[i, df.columns.get_loc("filepath")] = ( - start + "_256" + cor + "." + end - ) + df["filepath"] = ( + str(Path(dataroot)) + + "/" + + df.attribution.str.strip("/") + + "/" + + df.filepath.str.strip("/") + ) + split = df.filepath.str.rsplit(".", expand=True, n=1) + df["filepath"] = split[0] + "_256" + cor + "." + split[1] pass_kwargs = {"csv": df, "train": train, "transform": transform} return _dataset_factory[name](**pass_kwargs) From 4cc13a636eb451582877ce24fcb340b50f940c3d Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 14 Nov 2023 20:59:11 +0100 Subject: [PATCH 011/136] refactor: merge svhn and svhn_openset --- fd_shifts/data/__init__.py | 1 + fd_shifts/data/svhn.py | 37 ++++++++ fd_shifts/loaders/dataset_collection.py | 82 ++--------------- fd_shifts/tests/test_datasets.py | 112 ++++++++++++++++++++++++ 4 files changed, 158 insertions(+), 74 deletions(-) create mode 100644 fd_shifts/data/__init__.py create mode 100644 fd_shifts/data/svhn.py create mode 100644 fd_shifts/tests/test_datasets.py diff --git a/fd_shifts/data/__init__.py b/fd_shifts/data/__init__.py new file mode 100644 index 0000000..4971f03 --- /dev/null +++ b/fd_shifts/data/__init__.py @@ -0,0 +1 @@ +from .svhn import SVHN diff --git a/fd_shifts/data/svhn.py b/fd_shifts/data/svhn.py new file mode 100644 index 0000000..325bb60 --- /dev/null +++ b/fd_shifts/data/svhn.py @@ -0,0 +1,37 @@ +from typing import Callable, Literal, Optional + +import numpy as np +from torchvision import datasets + + +class SVHN(datasets.SVHN): + """SVHN dataset with support for Open Set splits. + + Attributes: + out_classes: Classes to exclude from the training set. + train: Whether to load the training or test split. + """ + + def __init__( + self, + root: str, + train: bool = True, + split: Literal["all", "openset"] = "all", + transform: Optional[Callable] = None, + target_transform: Optional[Callable] = None, + download: bool = False, + out_classes: list[int] = [0, 1, 2, 3], + ): + super().__init__( + root, + split="train" if train else "test", + transform=transform, + target_transform=target_transform, + download=download, + ) + + self.out_classes = out_classes + self.train = train + if split == "openset" and train: + self.data = self.data[~np.isin(self.labels, self.out_classes)] + self.labels = self.labels[~np.isin(self.labels, self.out_classes)] diff --git a/fd_shifts/loaders/dataset_collection.py b/fd_shifts/loaders/dataset_collection.py index 560437a..f473ee3 100644 --- a/fd_shifts/loaders/dataset_collection.py +++ b/fd_shifts/loaders/dataset_collection.py @@ -3,7 +3,7 @@ import os import pickle from pathlib import Path -from typing import Any, Callable, Optional, Tuple, TypeVar +from typing import Any, Callable, Literal, Optional, Tuple, TypeVar import albumentations import cv2 @@ -29,6 +29,7 @@ from fd_shifts import logger from fd_shifts.analysis import eval_utils +from fd_shifts.data import SVHN from fd_shifts.loaders import breeds_hierarchies @@ -350,48 +351,6 @@ def __getitem__(self, index): return data, torch.tensor(self.csv.iloc[index].target).long() -class BasicDataset(Dataset): - def __init__( - self, - csv: pd.DataFrame, - train: bool, - transform: Optional[Callable] = None, - ): - self.csv = csv.reset_index(drop=True) - self.train = train - self.transform = transform - self.train_df = self.csv.sample(frac=0.8, random_state=200) - self.test_df = self.csv.drop(self.train_df.index) - if self.train: - self.csv = self.train_df - elif not self.train: - self.csv = self.test_df - self.targets = self.csv.target - self.imgs = self.csv["filepath"] - self.samples = self.imgs - - def __len__(self): - return self.csv.shape[0] - - def __getitem__(self, index): - row = self.csv.iloc[index] - - image = cv2.imread(row.filepath) - image = cv2.cvtColor(image, cv2.COLOR_BGR2RGB) - - if self.transform is not None: - res = self.transform(image=image) - image = res["image"].astype(np.float32) - else: - image = image.astype(np.float32) - - image = image.transpose(2, 0, 1) - - data = torch.tensor(image).float() - - return data, torch.tensor(self.csv.iloc[index].target).long() - - class DermoscopyAllDataset(Dataset): def __init__( self, @@ -1482,37 +1441,11 @@ def get_subset(self, split, frac=1.0, transform=None): return subset -class SVHNOpenSet(datasets.SVHN): - def __init__( - self, - root: str, - split: str = "train", - transform: Optional[Callable] = None, - target_transform: Optional[Callable] = None, - download: bool = False, - out_classes: list[int] = [0, 1, 2, 3], - ) -> None: - super().__init__( - root, - split=split, - transform=transform, - target_transform=target_transform, - download=download, - ) - - self.out_classes = out_classes - logger.info("SVHN holdout classes {}", self.out_classes) - - if split == "train": - self.data = self.data[~np.isin(self.labels, self.out_classes)] - self.labels = self.labels[~np.isin(self.labels, self.out_classes)] - - _dataset_factory: dict[str, type] = { - "svhn": datasets.SVHN, - "svhn_384": datasets.SVHN, - "svhn_openset": SVHNOpenSet, - "svhn_openset_384": SVHNOpenSet, + "svhn": SVHN, + "svhn_384": SVHN, + "svhn_openset": SVHN, + "svhn_openset_384": SVHN, "tinyimagenet_384": datasets.ImageFolder, "tinyimagenet_resize": datasets.ImageFolder, "emnist_byclass": datasets.EMNIST, @@ -1713,7 +1646,8 @@ def get_dataset( if name.startswith("svhn"): pass_kwargs = { "root": root, - "split": "train" if train else "test", + "split": "openset" if "openset" in name else "all", + "train": train, "download": download, "transform": transform, } diff --git a/fd_shifts/tests/test_datasets.py b/fd_shifts/tests/test_datasets.py new file mode 100644 index 0000000..c380fb4 --- /dev/null +++ b/fd_shifts/tests/test_datasets.py @@ -0,0 +1,112 @@ +from typing import Callable, Optional + +import numpy as np +from torchvision import datasets + +from fd_shifts.loaders.dataset_collection import SVHN, get_dataset + + +class SVHNOpenSet(datasets.SVHN): + def __init__( + self, + root: str, + split: str = "train", + transform: Optional[Callable] = None, + target_transform: Optional[Callable] = None, + download: bool = False, + out_classes: list[int] = [0, 1, 2, 3], + ) -> None: + super().__init__( + root, + split=split, + transform=transform, + target_transform=target_transform, + download=download, + ) + + self.out_classes = out_classes + + if split == "train": + self.data = self.data[~np.isin(self.labels, self.out_classes)] + self.labels = self.labels[~np.isin(self.labels, self.out_classes)] + + +def test_svhn(): + s1 = datasets.SVHN(root="/home/t974t/Data/svhn", split="train", download=True) + s2 = SVHN(root="/home/t974t/Data/svhn", train=True, split="all", download=True) + + assert len(s1) == len(s2) + for i in range(len(s1)): + assert s1[i] == s2[i] + + s1 = datasets.SVHN(root="/home/t974t/Data/svhn", split="test", download=True) + s2 = SVHN(root="/home/t974t/Data/svhn", train=False, split="all", download=True) + + assert len(s1) == len(s2) + for i in range(len(s1)): + assert s1[i] == s2[i] + + s1 = SVHNOpenSet( + root="/home/t974t/Data/svhn", + split="test", + download=True, + out_classes=[0, 1, 3, 8, 2], + ) + s2 = SVHN( + root="/home/t974t/Data/svhn", + train=False, + split="openset", + download=True, + out_classes=[0, 1, 3, 8, 2], + ) + + assert len(s1) == len(s2) + for i in range(len(s1)): + assert s1[i] == s2[i] + + s1 = get_dataset( + name="svhn", + root="/home/t974t/Data/svhn", + train=True, + download=True, + transform=None, + target_transform=None, + kwargs={"out_classes": [0, 1, 3, 8, 2]}, + ) + s2 = datasets.SVHN(root="/home/t974t/Data/svhn", split="train", download=True) + assert len(s1) == len(s2) + for i in range(len(s1)): + assert s1[i] == s2[i] + + s1 = get_dataset( + name="svhn", + root="/home/t974t/Data/svhn", + train=False, + download=True, + transform=None, + target_transform=None, + kwargs={"out_classes": [0, 1, 3, 8, 2]}, + ) + s2 = datasets.SVHN(root="/home/t974t/Data/svhn", split="test", download=True) + assert len(s1) == len(s2) + for i in range(len(s1)): + assert s1[i] == s2[i] + + s1 = SVHNOpenSet( + root="/home/t974t/Data/svhn", + split="test", + download=True, + out_classes=[0, 1, 3, 8, 2], + ) + s2 = get_dataset( + name="svhn_openset", + root="/home/t974t/Data/svhn", + train=False, + download=True, + transform=None, + target_transform=None, + kwargs={"out_classes": [0, 1, 3, 8, 2]}, + ) + assert len(s1) == len(s2) + for i in range(len(s1)): + assert s1[i] == s2[i] From 3489f8dbd5135166b1342925ffb9317ab800c12e Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Mon, 20 Nov 2023 10:22:56 +0100 Subject: [PATCH 012/136] fix: only try to load mcd outputs when mcd is requested --- fd_shifts/analysis/__init__.py | 25 +++++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 7527c77..b4dd5ed 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -147,18 +147,24 @@ def from_experiment( if (test_dir / "raw_logits.npz").is_file(): with np.load(test_dir / "raw_logits.npz") as npz: - raw_output = npz.f.arr_0 + raw_output = npz.f.arr_0.astype(np.float64) logits = raw_output[:, :-2] softmax = scpspecial.softmax(logits, axis=1) - if ( - mcd_logits_dist := ExperimentData.__load_npz_if_exists( - test_dir / "raw_logits_dist.npz" + if any( + "mcd" in confid for confid in config.eval.confidence_measures.test + ) and ( + ( + mcd_logits_dist := ExperimentData.__load_npz_if_exists( + test_dir / "raw_logits_dist.npz" + ) ) - ) is not None: + is not None + ): mcd_softmax_dist = scpspecial.softmax(mcd_logits_dist, axis=1) else: + mcd_logits_dist = None mcd_softmax_dist = None elif (test_dir / "raw_output.npz").is_file(): @@ -191,9 +197,12 @@ def from_experiment( external_confids = ExperimentData.__load_npz_if_exists( test_dir / "external_confids.npz" ) - mcd_external_confids_dist = ExperimentData.__load_npz_if_exists( - test_dir / "external_confids_dist.npz" - ) + if any("mcd" in confid for confid in config.eval.confidence_measures.test): + mcd_external_confids_dist = ExperimentData.__load_npz_if_exists( + test_dir / "external_confids_dist.npz" + ) + else: + mcd_external_confids_dist = None return ExperimentData( softmax_output=softmax, From 3b63cb659d9c6b520fef8fa909fa59df2ec87662 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 29 Nov 2023 12:03:44 +0100 Subject: [PATCH 013/136] fix: dg logits got double softmax --- fd_shifts/models/callbacks/confid_monitor.py | 4 ++-- fd_shifts/models/confidnet_model.py | 14 +++++++++++++- fd_shifts/models/devries_model.py | 18 +++++++++++++----- 3 files changed, 28 insertions(+), 8 deletions(-) diff --git a/fd_shifts/models/callbacks/confid_monitor.py b/fd_shifts/models/callbacks/confid_monitor.py index d575181..5d04407 100644 --- a/fd_shifts/models/callbacks/confid_monitor.py +++ b/fd_shifts/models/callbacks/confid_monitor.py @@ -12,8 +12,8 @@ DTYPES = { 16: torch.float16, - 32: torch.float32, - 64: torch.float64, + 32: torch.float16, + 64: torch.float16, } diff --git a/fd_shifts/models/confidnet_model.py b/fd_shifts/models/confidnet_model.py index 043ced1..d1910b0 100644 --- a/fd_shifts/models/confidnet_model.py +++ b/fd_shifts/models/confidnet_model.py @@ -311,10 +311,22 @@ def load_only_state_dict(self, path: str | Path) -> None: # For backwards-compatibility with before commit 1bdc717 for param in list(ckpt["state_dict"].keys()): + if param.startswith( + "backbone.classifier.module.model.features" + ) or param.startswith("network.classifier.module.model.features"): + del ckpt["state_dict"][param] + continue + if param.startswith( + "backbone.classifier.module.model.classifier" + ) or param.startswith("network.classifier.module.model.classifier"): + correct_param = param.replace(".model.classifier", "") + ckpt["state_dict"][correct_param] = ckpt["state_dict"][param] + del ckpt["state_dict"][param] + param = correct_param if pattern.match(param): correct_param = re.sub(pattern, r"\1_\2\3", param) ckpt["state_dict"][correct_param] = ckpt["state_dict"][param] del ckpt["state_dict"][param] logger.info("loading checkpoint from epoch {}".format(ckpt["epoch"])) - self.load_state_dict(ckpt["state_dict"], strict=True) + self.load_state_dict(ckpt["state_dict"], strict=False) diff --git a/fd_shifts/models/devries_model.py b/fd_shifts/models/devries_model.py index c49101f..bc04640 100644 --- a/fd_shifts/models/devries_model.py +++ b/fd_shifts/models/devries_model.py @@ -110,8 +110,8 @@ def mcd_eval_forward(self, x, n_samples): soutputs = F.softmax(outputs, dim=1) softmax, reservation = soutputs[:, :-1], soutputs[:, -1] confidence = 1 - reservation - softmax_list.append(outputs[:, :-1].unsqueeze(2)) - conf_list.append(confidence.unsqueeze(1)) + softmax_list.append(outputs[:, :-1].unsqueeze(2).detach()) + conf_list.append(confidence.unsqueeze(1).detach()) self.model.encoder.disable_dropout() @@ -127,7 +127,7 @@ def on_epoch_end(self): ) or ( self.pretrain_steps is not None - and self.global_step >= self.pretrain_steps - 1 + and self.global_step == self.pretrain_steps - 1 ) ) and self.save_dg_backbone_path is not None @@ -288,9 +288,9 @@ def test_step(self, batch, batch_idx, *args): confidence = torch.sigmoid(confidence).squeeze(1) elif self.ext_confid_name == "dg": outputs = self.model.head(z) - outputs = F.softmax(outputs, dim=1) - softmax, reservation = outputs[:, :-1], outputs[:, -1] logits = outputs[:, :-1] + soutputs = F.softmax(outputs, dim=1) + softmax, reservation = soutputs[:, :-1], soutputs[:, -1] confidence = 1 - reservation else: raise NotImplementedError @@ -340,6 +340,14 @@ def load_only_state_dict(self, path: str | Path) -> None: # For backwards-compatibility with before commit 1bdc717 for param in list(ckpt["state_dict"].keys()): + if param.startswith("model.classifier.module.model.features"): + del ckpt["state_dict"][param] + continue + if param.startswith("model.classifier.module.model.classifier"): + correct_param = param.replace(".model.classifier", "") + ckpt["state_dict"][correct_param] = ckpt["state_dict"][param] + del ckpt["state_dict"][param] + param = correct_param if pattern.match(param): correct_param = re.sub(pattern, r"\1_\2\3", param) ckpt["state_dict"][correct_param] = ckpt["state_dict"][param] From 2584ffe55623c8f51335c27d61978a328d2828b6 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 7 Dec 2023 14:39:13 +0100 Subject: [PATCH 014/136] feat: wandb logging --- .pre-commit-config.yaml | 2 +- fd_shifts/exec.py | 56 ++++++++++++++++++------------------ fd_shifts/utils/exp_utils.py | 8 +++--- pyproject.toml | 7 +++++ 4 files changed, 40 insertions(+), 33 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index b56db5d..7863ee4 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -3,7 +3,7 @@ repos: - repo: https://github.com/psf/black - rev: 23.3.0 + rev: 23.10.1 hooks: - id: black name: black code formatting diff --git a/fd_shifts/exec.py b/fd_shifts/exec.py index 4623b46..d393908 100644 --- a/fd_shifts/exec.py +++ b/fd_shifts/exec.py @@ -8,15 +8,13 @@ import torch from omegaconf import DictConfig, OmegaConf from pytorch_lightning.callbacks import RichProgressBar -from pytorch_lightning.loggers import CSVLogger, MLFlowLogger, TensorBoardLogger +from pytorch_lightning.loggers import CSVLogger, TensorBoardLogger, WandbLogger from rich import get_console, reconfigure -from torch import multiprocessing from fd_shifts import analysis, configs, logger from fd_shifts.loaders.data_loader import FDShiftsDataLoader from fd_shifts.models import get_model from fd_shifts.models.callbacks import get_callbacks -from fd_shifts.models.callbacks.device_stats import DeviceStatsMonitor from fd_shifts.utils import exp_utils configs.init() @@ -32,7 +30,7 @@ def train( specified in the configs. """ - logger.info("CHECK CUDNN VERSION", torch.backends.cudnn.version()) + logger.info("CHECK CUDNN VERSION", torch.backends.cudnn.version()) # type: ignore train_deterministic_flag = False if cf.exp.global_seed is not None: exp_utils.set_seed(cf.exp.global_seed) @@ -53,12 +51,14 @@ def train( if cf.trainer.resume_from_ckpt_confidnet: cf.exp.version -= 1 - cf.trainer.callbacks.training_stages.pretrained_confidnet_path = ( + cf.trainer.callbacks.training_stages.pretrained_confidnet_path = ( # type: ignore exp_utils._get_resume_ckpt_path(cf) ) logger.info("resuming previous training:", resume_ckpt_path) if "openset" in cf.data.dataset: + if cf.data.kwargs is None: + cf.data.kwargs = {} cf.data.kwargs["out_classes"] = cf.data.kwargs.get( "out_classes", random.sample(range(cf.data.num_classes), int(0.4 * cf.data.num_classes)), @@ -101,23 +101,22 @@ def train( save_dir=str(cf.exp.group_dir), name=cf.exp.name, version=cf.exp.version ) - mlf_logger = MLFlowLogger( - experiment_name="fd_shifts", - run_name=cf.exp.name, + wandb_logger = WandbLogger( + project="fd_shifts_proto", + name=cf.exp.name, ) - device_stats_monitor = DeviceStatsMonitor(cpu_stats=True) - trainer = pl.Trainer( accelerator="auto", devices="auto", - logger=[tb_logger, csv_logger, mlf_logger], + logger=[tb_logger, csv_logger, wandb_logger], log_every_n_steps=log_every_n_steps, max_epochs=num_epochs, - max_steps=max_steps, - callbacks=[progress, device_stats_monitor] + get_callbacks(cf), + max_steps=max_steps, # type: ignore + callbacks=[progress] + get_callbacks(cf), resume_from_checkpoint=resume_ckpt_path, benchmark=cf.trainer.benchmark, + precision=16, check_val_every_n_epoch=val_every_n_epoch, num_sanity_val_steps=5, deterministic=train_deterministic_flag, @@ -162,7 +161,10 @@ def test(cf: configs.Config, progress: RichProgressBar = RichProgressBar()) -> N logger.info("logging testing to: {}".format(cf.test.dir)) module = get_model(cf.model.name)(cf) - module.load_only_state_dict(ckpt_path) + + # TODO: make common module class with this method + module.load_only_state_dict(ckpt_path) # type: ignore + datamodule = FDShiftsDataLoader(cf) if not os.path.exists(cf.test.dir): @@ -177,21 +179,19 @@ def test(cf: configs.Config, progress: RichProgressBar = RichProgressBar()) -> N limit_batches = cf.trainer.fast_dev_run log_every_n_steps = 1 - mlf_logger = MLFlowLogger( - experiment_name="fd_shifts", - run_name=cf.exp.name, + wandb_logger = WandbLogger( + project="fd_shifts_proto", + name=cf.exp.name, ) - device_stats_monitor = DeviceStatsMonitor(cpu_stats=True) - trainer = pl.Trainer( accelerator="auto", devices="auto", - logger=mlf_logger, + logger=wandb_logger, log_every_n_steps=log_every_n_steps, - callbacks=[progress, device_stats_monitor] + get_callbacks(cf), + callbacks=[progress] + get_callbacks(cf), limit_test_batches=limit_batches, - replace_sampler_ddp=False, + precision=16, ) trainer.test(model=module, datamodule=datamodule) analysis.main( @@ -247,7 +247,7 @@ def _fix_metadata(cfg: DictConfig) -> None: _fix_metadata(dconf) conf: configs.Config = cast(configs.Config, OmegaConf.to_object(dconf)) - conf.__pydantic_validate_values__() + conf.__pydantic_validate_values__() # type: ignore if conf.exp.mode == configs.Mode.train: conf.exp.version = exp_utils.get_next_version(conf.exp.dir) @@ -260,7 +260,7 @@ def _fix_metadata(cfg: DictConfig) -> None: conf.data.num_workers ) - conf.__pydantic_validate_values__() + conf.__pydantic_validate_values__() # type: ignore logger.info(OmegaConf.to_yaml(conf)) train(conf, progress) @@ -276,7 +276,7 @@ def _fix_metadata(cfg: DictConfig) -> None: conf.data.num_workers ) - conf.__pydantic_validate_values__() + conf.__pydantic_validate_values__() # type: ignore logger.info(OmegaConf.to_yaml(conf)) train(conf, progress, subsequent_testing=True) @@ -294,12 +294,12 @@ def _fix_metadata(cfg: DictConfig) -> None: logger.info("CHECK conf.exp.dir", conf.exp.dir) conf.exp.version = exp_utils.get_most_recent_version(conf.exp.dir) ckpt_path = exp_utils._get_resume_ckpt_path(conf) - conf.__pydantic_validate_values__() + conf.__pydantic_validate_values__() # type: ignore logger.info(OmegaConf.to_yaml(conf)) test(conf, progress) elif conf.exp.mode == configs.Mode.analysis: - conf.__pydantic_validate_values__() + conf.__pydantic_validate_values__() # type: ignore logger.info(OmegaConf.to_yaml(conf)) analysis.main( in_path=conf.test.dir, @@ -310,7 +310,7 @@ def _fix_metadata(cfg: DictConfig) -> None: cf=conf, ) else: - conf.__pydantic_validate_values__() + conf.__pydantic_validate_values__() # type: ignore logger.info("BEGIN CONFIG\n{}\nEND CONFIG", OmegaConf.to_yaml(conf)) except Exception as e: logger.exception(e) diff --git a/fd_shifts/utils/exp_utils.py b/fd_shifts/utils/exp_utils.py index 1e9f951..446bda3 100644 --- a/fd_shifts/utils/exp_utils.py +++ b/fd_shifts/utils/exp_utils.py @@ -28,7 +28,7 @@ def set_seed(seed: int) -> None: os.environ["PYTHONHASHSEED"] = str(seed) -def get_next_version(exp_dir: str) -> int: +def get_next_version(exp_dir: str | Path) -> int: """get best.ckpt of experiment. if split over multiple runs (e.g. due to resuming), still find the best.ckpt. if there are multiple overall runs in the folder select the latest. @@ -45,7 +45,7 @@ def get_next_version(exp_dir: str) -> int: return max_ver + 1 -def get_most_recent_version(exp_dir: str) -> int: +def get_most_recent_version(exp_dir: str | Path) -> int: """get best.ckpt of experiment. if split over multiple runs (e.g. due to resuming), still find the best.ckpt. if there are multiple overall runs in the folder select the latest. @@ -148,9 +148,9 @@ def flush(self): # Fix Warmup Bug -from warmup_scheduler import ( +from warmup_scheduler import ( # https://github.com/ildoonet/pytorch-gradual-warmup-lr GradualWarmupScheduler, -) # https://github.com/ildoonet/pytorch-gradual-warmup-lr +) class GradualWarmupSchedulerV2(GradualWarmupScheduler): diff --git a/pyproject.toml b/pyproject.toml index 95b24f1..72e88eb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,6 +43,7 @@ dependencies = [ "typing_extensions>=4.1.1", "warmup_scheduler", "wilds>=1.1.0", + "wandb", ] [project.optional-dependencies] @@ -95,14 +96,20 @@ exclude = ''' ''' [tool.pyright] +exclude = [ + "experiments*", + "analysis_outputs", +] reportOptionalSubscript = "warning" reportOptionalMemberAccess = "warning" reportOptionalCall = "warning" reportOptionalIterable = "warning" reportOptionalContextManager = "warning" reportOptionalOperand = "warning" +# useLibraryCodeForTypes = false [tool.pytest.ini_options] +testpaths = [ "fd_shifts" ] addopts = [ "--import-mode=importlib", ] From f135a508cb6eadb99d9556988deada4e172832bf Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 7 Dec 2023 14:40:48 +0100 Subject: [PATCH 015/136] chore: clean up gitignore --- .gitignore | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/.gitignore b/.gitignore index 06225a3..8a10fea 100644 --- a/.gitignore +++ b/.gitignore @@ -1,24 +1,14 @@ **/__pycache__ -mlruns .DS_Store *.log *.csv *.dat build -.ropeproject *.egg-info .ipynb_checkpoints .env -results -result_images -scripts -launcher -typings -experiments.json _version.py -.coverage -bak_* - -data_folder/ -experiments_folder/ -experiments_test/ +scratchpad/ +output/ +.jupyter_ystore.db +wandb/ From 23179c66e011e53ed7fb26be0253825559b86fd7 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 7 Dec 2023 14:41:20 +0100 Subject: [PATCH 016/136] refactor: move analysis tests --- fd_shifts/tests/analysis/__init__.py | 0 fd_shifts/tests/{analysis/test_metrics.py => test_analysis.py} | 0 2 files changed, 0 insertions(+), 0 deletions(-) delete mode 100644 fd_shifts/tests/analysis/__init__.py rename fd_shifts/tests/{analysis/test_metrics.py => test_analysis.py} (100%) diff --git a/fd_shifts/tests/analysis/__init__.py b/fd_shifts/tests/analysis/__init__.py deleted file mode 100644 index e69de29..0000000 diff --git a/fd_shifts/tests/analysis/test_metrics.py b/fd_shifts/tests/test_analysis.py similarity index 100% rename from fd_shifts/tests/analysis/test_metrics.py rename to fd_shifts/tests/test_analysis.py From 27a5f9d1041fe91beba1d11ffb11dda219b059aa Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 7 Dec 2023 14:43:34 +0100 Subject: [PATCH 017/136] fix: medshifts experiment to path --- fd_shifts/experiments/__init__.py | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/fd_shifts/experiments/__init__.py b/fd_shifts/experiments/__init__.py index 211465f..5d81b53 100644 --- a/fd_shifts/experiments/__init__.py +++ b/fd_shifts/experiments/__init__.py @@ -231,10 +231,7 @@ def to_path(self): if "medshifts" in str(self.group_dir.stem): return self.group_dir / ( - f"ms_{self.dataset}/" - f"{self.model}_" - f"bb{self.backbone}_" - f"run{self.run + 1}" + f"ms_{self.dataset}_run_{self.run + 1}/{self.model}_mcd" ) return self.group_dir / ( @@ -1245,7 +1242,3 @@ def get_all_experiments( _experiments = chain(_experiments, get_ms_experiments()) return _experiments - - -if __name__ == "__main__": - pprint(get_all_experiments()) From 19d0dd900096e9e54cb3bab229afa846eadf6368 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 7 Dec 2023 14:58:44 +0100 Subject: [PATCH 018/136] refactor: remove unused datasets --- fd_shifts/loaders/data_loader.py | 12 +- fd_shifts/loaders/dataset_collection.py | 455 ------------------------ 2 files changed, 9 insertions(+), 458 deletions(-) diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index 3bb48b5..7e14f3b 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -12,7 +12,7 @@ from torch.utils.data.sampler import SubsetRandomSampler import fd_shifts.configs.data as data_configs -from fd_shifts import configs +from fd_shifts import configs, logger from fd_shifts.loaders.dataset_collection import get_dataset from fd_shifts.utils.aug_utils import get_transform, target_transforms_collection @@ -34,7 +34,11 @@ def __init__(self, cf: configs.Config, no_norm_flag=False): self.reproduce_confidnet_splits = cf.data.reproduce_confidnet_splits self.dataset_kwargs = cf.data.kwargs self.devries_repro_ood_split = cf.test.devries_repro_ood_split - self.val_split = cf.trainer.val_split.name + self.val_split = ( + cf.trainer.val_split + if isinstance(cf.trainer.val_split, str) + else cf.trainer.val_split.name + ) self.test_iid_split = cf.test.iid_set_split self.assim_ood_norm_flag = cf.test.assim_ood_norm_flag self.balanced_sampeling = cf.model.balanced_sampeling @@ -100,7 +104,7 @@ def add_target_transforms(self, query_tt, no_norm_flag): target_transforms_collection[tt_key](tt_param) ) self.target_transforms[datasplit_k] = target_transforms[0] - print( + logging.debug( "CHECK TARGET TRANSFORMS", self.assim_ood_norm_flag, self.target_transforms ) @@ -355,6 +359,7 @@ def setup(self, stage=None): logging.debug("len val sampler %s", len(val_idx)) def train_dataloader(self): + logger.info(f"Loading train data with {self.batch_size=}") return torch.utils.data.DataLoader( dataset=self.train_dataset, batch_size=self.batch_size, @@ -392,6 +397,7 @@ def val_dataloader(self): def test_dataloader( self, ): + logger.info(f"Loading test data with {self.batch_size=}") test_loaders = [] for ix, test_dataset in enumerate(self.test_datasets): test_loaders.append( diff --git a/fd_shifts/loaders/dataset_collection.py b/fd_shifts/loaders/dataset_collection.py index f473ee3..1114545 100644 --- a/fd_shifts/loaders/dataset_collection.py +++ b/fd_shifts/loaders/dataset_collection.py @@ -193,44 +193,6 @@ def get_transforms(image_size): return transforms_train, transforms_val -class MelanomaDataset(Dataset): - def __init__(self, csv: pd.DataFrame, train: bool, transform=None): - self.csv = csv.reset_index(drop=True) - self.train = train - self.transform = transform - self.train_df = self.csv.sample(frac=0.8, random_state=200) - self.test_df = self.csv.drop(self.train_df.index) - if self.train: - self.csv = self.train_df - elif not self.train: - self.csv = self.test_df - self.targets = self.csv.target - - self.imgs = self.csv["filepath"] - self.samples = self.imgs - - def __len__(self): - return self.csv.shape[0] - - def __getitem__(self, index): - row = self.csv.iloc[index] - - image = cv2.imread(row.filepath) - image = cv2.cvtColor(image, cv2.COLOR_BGR2RGB) - - if self.transform is not None: - res = self.transform(image=image) - image = res["image"].astype(np.float32) - else: - image = image.astype(np.float32) - - image = image.transpose(2, 0, 1) - - data = torch.tensor(image).float() - - return data, torch.tensor(self.csv.iloc[index].target).long() - - class Rxrx1Dataset(Dataset): """ Returns 6-Channel image, not rgb but stacked greychannels from fluoresenzemicroscopy @@ -403,340 +365,6 @@ def __getitem__(self, index): return data, torch.tensor(self.csv.iloc[index].target).long() -class D7pDataset(Dataset): - def __init__( - self, - csv: pd.DataFrame, - train: bool, - transform: Optional[Callable] = None, - ): - self.csv = csv.reset_index(drop=True) - self.train = train - self.transform = transform - self.train_df = self.csv.sample(frac=0.8, random_state=200) - self.test_df = self.csv.drop(self.train_df.index) - if self.train: - self.csv = self.train_df - elif not self.train: - self.csv = self.test_df - self.targets = self.csv.target - - self.imgs = self.csv["filepath"] - self.samples = self.imgs - - def __len__(self): - return self.csv.shape[0] - - def __getitem__(self, index): - row = self.csv.iloc[index] - - image = cv2.imread(row.filepath) - image = cv2.cvtColor(image, cv2.COLOR_BGR2RGB) - - if self.transform is not None: - res = self.transform(image=image) - image = res["image"].astype(np.float32) - else: - image = image.astype(np.float32) - - image = image.transpose(2, 0, 1) - - data = torch.tensor(image).float() - - return data, torch.tensor(self.csv.iloc[index].target).long() - - -class Ham10000Dataset(Dataset): - def __init__( - self, - csv: pd.DataFrame, - train: bool, - transform: Optional[Callable] = None, - ): - self.csv = csv.reset_index(drop=True) - self.train = train - self.transform = transform - self.train_df = self.csv.sample(frac=0.8, random_state=200) - self.test_df = self.csv.drop(self.train_df.index) - if self.train: - self.csv = self.train_df - elif not self.train: - self.csv = self.test_df - self.targets = self.csv.target - - self.imgs = self.csv["filepath"] - self.samples = self.imgs - - def __len__(self): - return self.csv.shape[0] - - def __getitem__(self, index): - row = self.csv.iloc[index] - - image = cv2.imread(row.filepath) - image = cv2.cvtColor(image, cv2.COLOR_BGR2RGB) - - if self.transform is not None: - res = self.transform(image=image) - image = res["image"].astype(np.float32) - else: - image = image.astype(np.float32) - - image = image.transpose(2, 0, 1) - - data = torch.tensor(image).float() - - return data, torch.tensor(self.csv.iloc[index].target).long() - - -class Ham10000DatasetSubbig(Dataset): - def __init__( - self, - csv: pd.DataFrame, - train: bool, - transform: Optional[Callable] = None, - ): - self.csv = csv.reset_index(drop=True) - self.train = train - self.transform = transform - self.train_df = self.csv.sample(frac=0.8, random_state=200) - self.test_df = self.csv.drop(self.train_df.index) - if self.train: - self.csv = self.train_df - elif not self.train: - self.csv = self.test_df - self.targets = self.csv.target - - self.imgs = self.csv["filepath"] - self.samples = self.imgs - - def __len__(self): - return self.csv.shape[0] - - def __getitem__(self, index): - row = self.csv.iloc[index] - - image = cv2.imread(row.filepath) - image = cv2.cvtColor(image, cv2.COLOR_BGR2RGB) - - if self.transform is not None: - res = self.transform(image=image) - image = res["image"].astype(np.float32) - else: - image = image.astype(np.float32) - - image = image.transpose(2, 0, 1) - - data = torch.tensor(image).float() - - return data, torch.tensor(self.csv.iloc[index].target).long() - - -class Ham10000DatasetSubsmall(Dataset): - def __init__( - self, - csv: pd.DataFrame, - train: bool, - transform: Optional[Callable] = None, - ): - self.csv = csv.reset_index(drop=True) - self.train = train - self.transform = transform - self.targets = self.csv.target - - self.imgs = self.csv["filepath"] - self.samples = self.imgs - - def __len__(self): - return self.csv.shape[0] - - def __getitem__(self, index): - row = self.csv.iloc[index] - - image = cv2.imread(row.filepath) - image = cv2.cvtColor(image, cv2.COLOR_BGR2RGB) - - if self.transform is not None: - res = self.transform(image=image) - image = res["image"].astype(np.float32) - else: - image = image.astype(np.float32) - - image = image.transpose(2, 0, 1) - - data = torch.tensor(image).float() - - return data, torch.tensor(self.csv.iloc[index].target).long() - - -class Isic2020Dataset(Dataset): - def __init__( - self, - csv: pd.DataFrame, - train: bool, - transform: Optional[Callable] = None, - ): - self.csv = csv.reset_index(drop=True) - self.train = train - self.transform = transform - self.train_df = self.csv.sample(frac=0.8, random_state=200) - self.test_df = self.csv.drop(self.train_df.index) - if self.train: - self.csv = self.train_df - elif not self.train: - self.csv = self.test_df - self.targets = self.csv.target - - self.imgs = self.csv["filepath"] - self.samples = self.imgs - - def __len__(self): - return self.csv.shape[0] - - def __getitem__(self, index): - row = self.csv.iloc[index] - - image = cv2.imread(row.filepath) - image = cv2.cvtColor(image, cv2.COLOR_BGR2RGB) - - if self.transform is not None: - res = self.transform(image=image) - image = res["image"].astype(np.float32) - else: - image = image.astype(np.float32) - - image = image.transpose(2, 0, 1) - - data = torch.tensor(image).float() - - return data, torch.tensor(self.csv.iloc[index].target).long() - - -class Ph2Dataset(Dataset): - def __init__( - self, - csv: pd.DataFrame, - train: bool, - transform: Optional[Callable] = None, - ): - self.csv = csv.reset_index(drop=True) - self.train = train - self.transform = transform - self.train_df = self.csv.sample(frac=0.8, random_state=200) - self.test_df = self.csv.drop(self.train_df.index) - if self.train: - self.csv = self.train_df - elif not self.train: - self.csv = self.test_df - self.targets = self.csv.target - - self.imgs = self.csv["filepath"] - self.samples = self.imgs - - def __len__(self): - return self.csv.shape[0] - - def __getitem__(self, index): - row = self.csv.iloc[index] - - image = cv2.imread(row.filepath) - image = cv2.cvtColor(image, cv2.COLOR_BGR2RGB) - - if self.transform is not None: - res = self.transform(image=image) - image = res["image"].astype(np.float32) - else: - image = image.astype(np.float32) - - image = image.transpose(2, 0, 1) - - data = torch.tensor(image).float() - - return data, torch.tensor(self.csv.iloc[index].target).long() - - -class Isicv01(Dataset): - "Class with binary classification benign vs malignant of skin cancer and control" - - def __init__( - self, - csv_file: str, - root: str, - transform: Optional[Callable] = None, - target_transforms: Optional[Callable] = None, - train: bool = True, - download: bool = False, - ): - """ - Args: - csv_file (string): Path to csv with metadata and images - root_dir (string): Directory with the images - transforms (Callable, optional): Torchvision transforms to apply - target_transforms (Callable): target transforms to apply - train (bool): If true traindata if false test data - download (bool): toDo - """ - self.isicv01_df = pd.read_csv(csv_file) - - if isinstance(root, torch._six.string_classes): - root = os.path.expanduser(root) - self.root = root - self.download = download - - self.target_transforms = target_transforms - self.transforms = transform - self.train = train - self.resample_malignant: int = 4 - self.data, self.targets = self._load_data() - self.classes = {"bening": 0, "malignant": 1} - - def __len__(self): - return len(self.targets) - - def _load_data(self) -> Tuple[Any, Any]: - self.train_df = self.isicv01_df.sample(frac=0.8, random_state=200) - self.test_df = self.isicv01_df.drop(self.train_df.index) - if self.resample_malignant > 0: - mal = self.train_df["class"] == 1 - mal_df = self.train_df[mal] - self.train_df = self.train_df.append( - [mal_df] * self.resample_malignant, ignore_index=True - ) - if self.train: - image_files = self.train_df["isic_id"] - target_series = self.train_df["class"] - elif not self.train: - image_files = self.test_df["isic_id"] - target_series = self.test_df["class"] - img_path = self.root + image_files + ".jpg" - data = [] - target = [] - for x in range(len(image_files)): - target.append(target_series.iloc[x]) - image = cv2.imread(img_path.iloc[x]) - image = cv2.cvtColor(image, cv2.COLOR_BGR2RGB) - data.append(image) - # data.append(Image.open(img_path.iloc[x])) - return data, target - - def __getitem__(self, index: int) -> Tuple[Any, Any]: - ImageFile.LOAD_TRUNCATED_IMAGES = True - - """ - Args: - index (int): image and label index in the dataframe to return - Returns: - tupel (image, target): where target is the label of the target class - """ - img, target = self.data[index], int(self.targets[index]) - if self.transforms is not None: - img = self.transforms(img) - if self.target_transforms is not None: - target = self.target_transforms(target) - - return img, target - - class MedMNIST_mod(Dataset): flag = ... @@ -1528,9 +1156,6 @@ def get_subset(self, split, frac=1.0, transform=None): "lidc_idriall_spiculation_ood": Lidc_idriDataset, "lidc_idriall_texture_iid": Lidc_idriDataset, "lidc_idriall_texture_ood": Lidc_idriDataset, - "isic_v01": Isicv01, - "isic_v01_cr": Isicv01, - "isic_winner": MelanomaDataset, "dermoscopyall": DermoscopyAllDataset, "dermoscopyalld7p": DermoscopyAllDataset, "dermoscopyallph2": DermoscopyAllDataset, @@ -1559,8 +1184,6 @@ def get_subset(self, split, frac=1.0, transform=None): "dermoscopyallcorrelastichigh": DermoscopyAllDataset, "dermoscopyallcorrelastichighhigh": DermoscopyAllDataset, "dermoscopy_isic_2020": DermoscopyAllDataset, - "ph2": Ph2Dataset, - "d7p": D7pDataset, "dermoscopyallham10000multi": DermoscopyAllDataset, "dermoscopyallham10000subbig": DermoscopyAllDataset, "dermoscopyallham10000subsmall": DermoscopyAllDataset, @@ -1731,84 +1354,6 @@ def get_dataset( dataset = _dataset_factory[name](split=split, **pass_kwargs) return dataset - elif name == "isicv01": - pass_kwargs = { - "root": root, - "train": train, - "download": download, - "transform": transform, - "csv_file": "/home/l049e/Projects/ISIC/isic_v01_dataframe.csv", - } - return _dataset_factory[name](**pass_kwargs) - elif name == "isic_v01_cr": - pass_kwargs = { - "root": root, - "train": train, - "download": download, - "transform": transform, - "csv_file": "/home/l049e/Projects/ISIC/isic_v01_dataframe.csv", - } - return _dataset_factory[name](**pass_kwargs) - - elif name == "isic_winner": - out_dim = 9 - data_dir = root - data_folder = "512" # input image size - df_train, df_test, meta_features, n_meta_features, mel_idx = get_df( - out_dim, data_dir, data_folder - ) - transforms_train, transforms_val = get_transforms(512) - if train: - transforms = transforms_train - else: - transforms = transforms_val - pass_kwargs = {"csv": df_train, "train": train, "transform": transforms} - return _dataset_factory[name](**pass_kwargs) - - elif name == "d7p": - out_dim = 2 - data_dir = root - data_folder = "512" # input image size - csv_file = f"{root}/d7p_binaryclass" - df_train = pd.read_csv(csv_file) - df_train["filepath"] = root + "/" + df_train["filepath"] - transforms_train, transforms_val = get_transforms(512) - if train: - transforms = transforms_train - else: - transforms = transforms_val - pass_kwargs = {"csv": df_train, "train": train, "transform": transforms} - return _dataset_factory[name](**pass_kwargs) - - elif name == "isic_2020": - out_dim = 2 - data_dir = root - data_folder = "512" # input image size - csv_file = f"{root}/isic2020_binaryclass" - df_train = pd.read_csv(csv_file) - df_train["filepath"] = root + "/" + df_train["filepath"] - - transforms_train, transforms_val = get_transforms(512) - if train: - transforms = transforms_train - else: - transforms = transforms_val - pass_kwargs = {"csv": df_train, "train": train, "transform": transforms} - return _dataset_factory[name](**pass_kwargs) - elif name == "ph2": - out_dim = 2 - data_dir = root - data_folder = "512" # input image size - csv_file = f"{root}/ph2_binaryclass" - df_train = pd.read_csv(csv_file) - df_train["filepath"] = root + "/" + df_train["filepath"] - transforms_train, transforms_val = get_transforms(512) - if train: - transforms = transforms_train - else: - transforms = transforms_val - pass_kwargs = {"csv": df_train, "train": train, "transform": transforms} - return _dataset_factory[name](**pass_kwargs) elif "dermoscopyall" in name: oversampeling = 0 binary = "binaryclass" From 1ed0b7ac9fdaa3be05d8b2208c83b4de4cddd4b7 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 7 Dec 2023 15:04:28 +0100 Subject: [PATCH 019/136] feat: more post-hoc csfs --- fd_shifts/analysis/__init__.py | 341 +++++++++++++++++++++++----- fd_shifts/analysis/confid_scores.py | 36 ++- fd_shifts/analysis/eval_utils.py | 39 +--- fd_shifts/analysis/studies.py | 9 +- 4 files changed, 328 insertions(+), 97 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index b4dd5ed..627fa32 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -6,6 +6,7 @@ from pathlib import Path from typing import Any +import faiss import numpy as np import numpy.typing as npt import pandas as pd @@ -14,6 +15,7 @@ from omegaconf import DictConfig, ListConfig, OmegaConf from rich import inspect from scipy import special as scpspecial +from sklearn import neighbors from sklearn.calibration import _sigmoid_calibration as calib from fd_shifts import configs @@ -52,6 +54,20 @@ class ExperimentData: _mcd_labels: npt.NDArray[Any] | None = field(default=None) _correct: npt.NDArray[Any] | None = field(default=None) + _features: npt.NDArray[Any] | None = field(default=None) + _train_features: npt.NDArray[Any] | None = field(default=None) + _last_layer: tuple[npt.NDArray[Any], npt.NDArray[Any]] | None = field(default=None) + + _react_logits: npt.NDArray[Any] | None = field(default=None) + _maha_dist: npt.NDArray[Any] | None = field(default=None) + _vim_score: npt.NDArray[Any] | None = field(default=None) + _dknn_dist: npt.NDArray[Any] | None = field(default=None) + _react_softmax: npt.NDArray[Any] | None = field(default=None) + + @property + def predicted(self) -> npt.NDArray[Any]: + return np.argmax(self.softmax_output, axis=1) + @property def correct(self) -> npt.NDArray[Any]: if self._correct is not None: @@ -86,6 +102,90 @@ def mcd_labels(self) -> npt.NDArray[Any] | None: return None return self.labels + @property + def features(self) -> npt.NDArray[Any] | None: + return self._features + + @property + def last_layer(self) -> tuple[npt.NDArray[Any], npt.NDArray[Any]]: + if self._last_layer is not None: + return self._last_layer + raise NotImplementedError("TODO: Load last layer") + + @property + def vim_score(self): + if self._vim_score is None: + if self.features is None: + return None + + self._vim_score = _vim( + train_features=self._train_features, + features=self.features, + logits=self.logits, + last_layer=self.last_layer, + ) + + return self._vim_score + + @property + def maha_dist(self): + if self._maha_dist is None: + if self.features is None: + return None + + self._maha_dist = _maha_dist( + train_features=self._train_features, + features=self.features, + labels=self.labels, + predicted=self.predicted, + dataset_idx=self.dataset_idx, + ) + + return self._maha_dist + + @property + def dknn_dist(self): + if self._dknn_dist is None: + if self.features is None: + return None + + self._dknn_dist = _deep_knn( + train_features=self._train_features, + features=self.features, + labels=self.labels, + predicted=self.predicted, + dataset_idx=self.dataset_idx, + ) + + return self._dknn_dist + + @property + def react_logits(self): + if self._react_logits is None: + if self.features is None: + return None + + self._react_logits = _react( + last_layer=self.last_layer, + features=self.features, + train_features=self._train_features, + dataset_idx=self.dataset_idx, + ) + + return self._react_logits + + @property + def react_softmax(self): + if self.react_logits is None: + return None + + if self._react_softmax is None: + self._react_softmax = scpspecial.softmax( + self.react_logits.astype(np.float64), axis=1 + ) + + return self._react_softmax + def dataset_name_to_idx(self, dataset_name: str) -> int: if dataset_name == "val_tuning": return 0 @@ -124,8 +224,13 @@ def _filter_if_exists(data: npt.NDArray[Any] | None): mcd_softmax_dist=_filter_if_exists(self.mcd_softmax_dist), mcd_logits_dist=_filter_if_exists(self.mcd_logits_dist), external_confids=_filter_if_exists(self.external_confids), + _react_logits=_filter_if_exists(self.react_logits), + _maha_dist=_filter_if_exists(self.maha_dist), + _dknn_dist=_filter_if_exists(self.dknn_dist), + _vim_score=_filter_if_exists(self.vim_score), mcd_external_confids_dist=_filter_if_exists(self.mcd_external_confids_dist), config=self.config, + _train_features=self._train_features, ) @staticmethod @@ -178,7 +283,7 @@ def from_experiment( test_dir / "raw_output_dist.npz" ) else: - raise FileNotFoundError("Could not find model output") + raise FileNotFoundError(f"Could not find model output in {test_dir}") if holdout_classes is not None: softmax[:, holdout_classes] = 0 @@ -204,6 +309,19 @@ def from_experiment( else: mcd_external_confids_dist = None + if ( + features := ExperimentData.__load_npz_if_exists( + test_dir / "encoded_output.npz" + ) + ) is not None: + features = features[:, :-1] + last_layer: tuple[npt.NDArray[np.float_], npt.NDArray[np.float_]] | None = None + if (test_dir / "last_layer.npz").is_file(): + last_layer = tuple(np.load(test_dir / "last_layer.npz").values()) # type: ignore + train_features = None + if (test_dir / "train_features.npz").is_file(): + with np.load(test_dir / "train_features.npz") as npz: + train_features = npz.f.arr_0 return ExperimentData( softmax_output=softmax, logits=logits, @@ -214,6 +332,9 @@ def from_experiment( external_confids=external_confids, mcd_external_confids_dist=mcd_external_confids_dist, config=config, + _features=features, + _train_features=train_features, + _last_layer=last_layer, ) @@ -251,7 +372,7 @@ def _eval(): loss.backward() return loss - optimizer.step(_eval) + optimizer.step(_eval) # type: ignore self.temperature = self.temperature.item() @@ -262,6 +383,129 @@ def __call__(self, logits: npt.NDArray[Any]) -> npt.NDArray[Any]: ) +def _react( + last_layer: tuple[npt.NDArray[np.float_], npt.NDArray[np.float_]], + train_features: npt.NDArray[np.float_] | None, + features: npt.NDArray[np.float_], + dataset_idx: npt.NDArray[np.integer], + clip_quantile=99, + val_set_index=0, +): + logger.info("Compute REACT logits") + logger.warning( + "Currently uses validation set for clip parameter fit, will switch to training set in the future" + ) + + # mask = np.argwhere(dataset_idx == val_set_index)[:, 0] + # val_features = features[mask] + clip = torch.tensor(np.quantile(train_features[:, :-1], clip_quantile / 100)) + + w, b = last_layer + w = torch.tensor(w, dtype=torch.float) + w = torch.tensor(w, dtype=torch.float) + + logits = ( + torch.matmul( + torch.clip(torch.tensor(features, dtype=torch.float), min=None, max=clip), + w.T, + ) + + b + ) + return logits.numpy() + + +def _maha_dist( + train_features: npt.NDArray[np.float_] | None, + features: npt.NDArray[np.float_], + labels: npt.NDArray[np.int_], + predicted: npt.NDArray[np.int_], + dataset_idx: npt.NDArray[np.int_], + val_set_index=0, +): + logger.info("Compute Mahalanobis distance") + + # mask = np.argwhere(dataset_idx == val_set_index)[:, 0] + val_features = train_features[:, :-1] + val_labels = train_features[:, -1] + + means = torch.tensor( + np.array( + [val_features[val_labels == i].mean(axis=0) for i in np.unique(val_labels)] + ) + ) + icov = torch.pinverse(torch.cov(torch.tensor(val_features).float().T)) + + tpredicted = torch.tensor(predicted).long() + zm = torch.tensor(features) - means[tpredicted] + zm = zm.float() + + maha = -(torch.einsum("ij,jk,ik->i", zm, icov, zm)) + maha = maha.numpy() + return maha + + +def _vim( + last_layer: tuple[npt.NDArray[np.float_], npt.NDArray[np.float_]], + train_features: npt.NDArray[np.float_] | None, + features: npt.NDArray[np.float_], + logits: npt.NDArray[np.float_], +): + logger.info("Compute ViM score") + D = 512 + w, b = last_layer + w = torch.tensor(w, dtype=torch.float) + b = torch.tensor(b, dtype=torch.float) + + logger.debug("ViM: Compute NS") + u = -torch.pinverse(w) @ b + train_f = torch.tensor(train_features[:1000, :-1], dtype=torch.float) + cov = torch.cov((train_f - u).T) + eig_vals, eigen_vectors = torch.linalg.eig(cov) + eig_vals = eig_vals.real + eigen_vectors = eigen_vectors.real + NS = (eigen_vectors.T[torch.argsort(eig_vals * -1)[D:]]).T + + logger.debug("ViM: Compute alpha") + logit_train = torch.matmul(train_f, w.T) + b + + vlogit_train = torch.linalg.norm(torch.matmul(train_f - u, NS), dim=-1) + alpha = logit_train.max(dim=-1)[0].mean() / vlogit_train.mean() + + tlogits = torch.tensor(logits, dtype=torch.float) + tfeatures = torch.tensor(features, dtype=torch.float) + + logger.debug("ViM: Compute score") + energy = torch.logsumexp(tlogits, dim=-1) + vlogit = torch.linalg.norm(torch.matmul(tfeatures - u, NS), dim=-1) * alpha + score = -vlogit + energy + return score.numpy() + + +def _deep_knn( + train_features: npt.NDArray[np.float_] | None, + features: npt.NDArray[np.float_], + labels: npt.NDArray[np.int_], + predicted: npt.NDArray[np.int_], + dataset_idx: npt.NDArray[np.int_], + val_set_index=0, +): + logger.info("Compute DeepKNN distance") + # index = faiss.IndexFlatL2(ftrain.shape[1]) + # index.add(ftrain) + K = 50 + # neigh = neighbors.NearestNeighbors(n_neighbors=K, metric="euclidean", n_jobs=-1) + # neigh.fit(train_features[:, :-1]) + # D, _ = neigh.kneighbors(features, return_distance=True) + + train_features = train_features[:1000, :-1] + index = faiss.IndexFlatL2(train_features.shape[1]) + index.add(train_features.astype(np.float32)) + D, _ = index.search(features.astype(np.float32), K) + + score = -D[:, -1] + return score + + @dataclass class QuantileScaling: """Quantile scaling normalization function""" @@ -312,13 +556,11 @@ def __init__( if self.experiment_data.mcd_softmax_dist is None: self.method_dict["query_confids"] = list( filter( - lambda confid: "mcd" not in confid, + lambda confid: "mcd" not in confid and "waic" not in confid, self.method_dict["query_confids"], ) ) - self.method_dict["query_confids"].append("temp_logits") - self.secondary_confids = [] if ( @@ -337,11 +579,25 @@ def __init__( if self.experiment_data.logits is not None: self.method_dict["query_confids"].append("det_mls") + self.method_dict["query_confids"].append("temp_mls") + self.method_dict["query_confids"].append("energy_mls") + + if ( + self.experiment_data.features is not None + and self.experiment_data.last_layer is not None + ): + self.method_dict["query_confids"].append("maha") + self.method_dict["query_confids"].append("dknn") + # self.method_dict["query_confids"].append("vim") + self.method_dict["query_confids"].append("react_det_mcp") + self.method_dict["query_confids"].append("react_det_mls") + self.method_dict["query_confids"].append("react_temp_mls") + self.method_dict["query_confids"].append("react_energy_mls") if self.experiment_data.mcd_logits_dist is not None: self.method_dict["query_confids"].append("mcd_mls") - logger.debug("CHECK QUERY CONFIDS\n{}", self.method_dict["query_confids"]) + logger.debug("CSFs: {}", ", ".join(self.method_dict["query_confids"])) self.query_performance_metrics = query_performance_metrics self.query_confid_metrics = query_confid_metrics @@ -391,6 +647,7 @@ def register_and_perform_studies(self): def _perform_study(self, study_name, study_data: ExperimentData): self.study_name = study_name + logger.info("Performing study {}", study_name) self._get_confidence_scores(study_data) self._compute_confid_metrics() self._create_results_csv(study_data) @@ -413,6 +670,7 @@ def _fix_external_confid_name(self, name: str): def _get_confidence_scores(self, study_data: ExperimentData): for query_confid in self.method_dict["query_confids"]: + logger.debug(f"Compute score {query_confid}") if query_confid in self.secondary_confids: continue @@ -431,7 +689,7 @@ def _get_confidence_scores(self, study_data: ExperimentData): self.normalization_functions[query_confid] = QuantileScaling( confids ) - elif query_confid == "temp_logits": + elif "temp_mls" in query_confid: self.normalization_functions[query_confid] = TemperatureScaling( confids, study_data.labels ) @@ -505,27 +763,8 @@ def _compute_performance_metrics(self, softmax, labels, correct): def _compute_confid_metrics(self): for confid_key in self.method_dict["query_confids"]: - logger.debug("{}\n{}", self.study_name, confid_key) + logger.debug("{}: evaluating {}", self.study_name, confid_key) confid_dict = self.method_dict[confid_key] - if confid_key == "bpd" or confid_key == "maha": - logger.debug( - "CHECK BEFORE NORM VALUES CORRECT\n{}", - np.median(confid_dict["confids"][confid_dict["correct"] == 1]), - ) - logger.debug( - "CHECK BEFORE NORM VALUES INCORRECT\n{}", - np.median(confid_dict["confids"][confid_dict["correct"] == 0]), - ) - - if confid_key == "bpd" or confid_key == "maha": - logger.debug( - "CHECK AFTER NORM VALUES CORRECT\n{}", - np.median(confid_dict["confids"][confid_dict["correct"] == 1]), - ) - logger.debug( - "CHECK AFTER NORM VALUES INCORRECT\n{}", - np.median(confid_dict["confids"][confid_dict["correct"] == 0]), - ) eval = ConfidEvaluator( confids=confid_dict["confids"], @@ -579,7 +818,6 @@ def _compute_confid_metrics(self): ] ) - logger.debug("checking in\n{}\n{}", self.threshold_plot_confid, confid_key) if ( self.threshold_plot_confid is not None and confid_key == self.threshold_plot_confid @@ -596,19 +834,11 @@ def _compute_confid_metrics(self): self.threshold_plot_dict = {} self.plot_threshs = [] self.true_covs = [] - logger.debug("creating threshold_plot_dict....") plot_val_risk_scores = eval.get_val_risk_scores( self.rstar, self.rdelta ) self.plot_threshs.append(plot_val_risk_scores["theta"]) self.true_covs.append(plot_val_risk_scores["val_cov"]) - logger.debug( - "{}\n{}\n{}\n{}", - self.rstar, - self.rdelta, - plot_val_risk_scores["theta"], - plot_val_risk_scores["val_risk"], - ) plot_string = "r*: {:.2f} \n".format(self.rstar) for ix, thresh in enumerate(self.plot_threshs): @@ -643,7 +873,6 @@ def _compute_confid_metrics(self): self.rstar, 0.1, no_bound_mode=True )["theta"] - logger.debug("creating new dict entry\n{}", self.study_name) self.threshold_plot_dict[self.study_name] = {} self.threshold_plot_dict[self.study_name]["confids"] = confid_dict[ "confids" @@ -751,9 +980,7 @@ def _compute_confid_metrics(self): corr_ix = self.dummy_noise_ixs[ix] % 50000 corr_ix = corr_ix // 10000 logger.debug( - "noise sanity check\n{}\n{}", - corr_ix, - self.dummy_noise_ixs[ix], + f"Noise sanity check: {corr_ix=}, {self.dummy_noise_ixs[ix]=}" ) out_path = os.path.join( @@ -804,22 +1031,22 @@ def _create_results_csv(self, study_data: ExperimentData): float_format="%.5f", decimal=".", ) - logger.debug( - "saved csv to {}", + logger.info( + "Saved csv to {}", os.path.join( self.analysis_out_dir, "analysis_metrics_{}.csv".format(self.study_name) ), ) - group_file_path = os.path.join( - self.cfg.exp.group_dir, "group_analysis_metrics.csv" - ) - if os.path.exists(group_file_path): - with open(group_file_path, "a") as f: - df.to_csv(f, float_format="%.5f", decimal=".", header=False) - else: - with open(group_file_path, "w") as f: - df.to_csv(f, float_format="%.5f", decimal=".") + # group_file_path = os.path.join( + # self.cfg.exp.group_dir, "group_analysis_metrics.csv" + # ) + # if os.path.exists(group_file_path): + # with open(group_file_path, "a") as f: + # df.to_csv(f, float_format="%.5f", decimal=".", header=False) + # else: + # with open(group_file_path, "w") as f: + # df.to_csv(f, float_format="%.5f", decimal=".") def _create_threshold_plot(self): f = ThresholdPlot(self.threshold_plot_dict) @@ -829,8 +1056,8 @@ def _create_threshold_plot(self): "threshold_plot_{}.png".format(self.threshold_plot_confid), ) ) - logger.debug( - "saved threshold_plot to {}", + logger.info( + "Saved threshold_plot to {}", os.path.join( self.analysis_out_dir, "threshold_plot_{}.png".format(self.threshold_plot_confid), @@ -851,8 +1078,8 @@ def _create_master_plot(self): self.analysis_out_dir, "master_plot_{}.png".format(self.study_name) ) ) - logger.debug( - "saved masterplot to {}", + logger.info( + "Saved masterplot to {}", os.path.join( self.analysis_out_dir, "master_plot_{}.png".format(self.study_name) ), @@ -905,8 +1132,8 @@ def main( if not os.path.exists(analysis_out_dir): os.mkdir(analysis_out_dir) - logger.debug( - "starting analysis with in_path {}, out_path {}, and query studies {}".format( + logger.info( + "Starting analysis with in_path {}, out_path {}, and query studies {}".format( path_to_test_dir, analysis_out_dir, query_studies ) ) diff --git a/fd_shifts/analysis/confid_scores.py b/fd_shifts/analysis/confid_scores.py index 795d25a..9b5145e 100644 --- a/fd_shifts/analysis/confid_scores.py +++ b/fd_shifts/analysis/confid_scores.py @@ -5,11 +5,12 @@ import numpy as np import numpy.typing as npt +from scipy import special as scpspecial if TYPE_CHECKING: from fd_shifts.analysis import Analysis, ExperimentData -EXTERNAL_CONFIDS = ["ext", "bpd", "maha", "tcp", "dg", "devries"] +EXTERNAL_CONFIDS = ["ext", "bpd", "tcp", "dg", "devries"] ArrayType = npt.NDArray[np.floating] T = TypeVar( @@ -112,6 +113,8 @@ def get_confid_function(confid_name) -> Callable: @register_confid_func("det_mcp") @validate_softmax @register_confid_func("det_mls") +@register_confid_func("react_det_mcp") +@register_confid_func("react_det_mls") def maximum_softmax_probability( softmax: ArrayType, ) -> ArrayType: @@ -126,6 +129,14 @@ def maximum_softmax_probability( return np.max(softmax, axis=1) +@register_confid_func("energy_mls") +@register_confid_func("react_energy_mls") +def energy( + softmax: ArrayType, +) -> ArrayType: + return scpspecial.logsumexp(softmax, axis=1) + + @register_confid_func("mcd_mcp") @validate_softmax @register_confid_func("mcd_mls") @@ -263,8 +274,11 @@ def mcd_ext(mcd_softmax_mean: ArrayType, _: ArrayType) -> ArrayType: @register_confid_func("ext") @register_confid_func("bpd") @register_confid_func("maha") +@register_confid_func("vim") +@register_confid_func("dknn") @register_confid_func("maha_qt") -@register_confid_func("temp_logits") +@register_confid_func("temp_mls") +@register_confid_func("react_temp_mls") @register_confid_func("ext_qt") @register_confid_func("tcp") @register_confid_func("dg") @@ -296,6 +310,7 @@ def __init__( analysis: Analysis, ) -> None: if is_mcd_confid(query_confid): + print(query_confid) assert study_data.mcd_softmax_mean is not None assert study_data.mcd_softmax_dist is not None self.softmax = study_data.mcd_softmax_mean @@ -330,7 +345,10 @@ def __init__( self.softmax = study_data.softmax_output self.correct = study_data.correct self.labels = study_data.labels - self.confid_args = (study_data.softmax_output,) + if "react" in query_confid: + self.confid_args = (study_data.react_softmax,) + else: + self.confid_args = (study_data.softmax_output,) self.performance_args = ( study_data.softmax_output, study_data.labels, @@ -340,10 +358,18 @@ def __init__( if is_external_confid(query_confid): assert study_data.external_confids is not None self.confid_args = (study_data.external_confids,) - + elif "maha" in query_confid: + self.confid_args = (study_data.maha_dist,) + elif "vim" in query_confid: + self.confid_args = (study_data.vim_score,) + elif "dknn" in query_confid: + self.confid_args = (study_data.dknn_dist,) elif "mls" in query_confid: assert study_data.logits is not None - self.confid_args = (study_data.logits,) + if "react" in query_confid: + self.confid_args = (study_data.react_logits,) + else: + self.confid_args = (study_data.logits,) self.confid_func = get_confid_function(query_confid) self.analysis = analysis diff --git a/fd_shifts/analysis/eval_utils.py b/fd_shifts/analysis/eval_utils.py index 9f8c2a6..f706d3d 100644 --- a/fd_shifts/analysis/eval_utils.py +++ b/fd_shifts/analysis/eval_utils.py @@ -201,9 +201,6 @@ def get_metrics_per_confid(self): if "fail-NLL" in self.query_metrics: out_metrics["fail-NLL"] = get_metric_function("fail-NLL")(self.stats_cache) - logger.debug( - "CHECK FAIL NLL: \n{}\n{}", self.confids.max(), self.confids.min() - ) return out_metrics @@ -240,14 +237,8 @@ def get_roc_curve_stats(self): try: self.fpr_list, self.tpr_list, _ = skm.roc_curve(self.correct, self.confids) except: - logger.debug( - "FAIL CHECK\n{}\n{}\n{}\n{}\n{}\n{}", - self.correct.shape, - self.confids.shape, - np.min(self.correct), - np.max(self.correct), - np.min(self.confids), - np.max(self.confids), + logger.error( + f"ROC Curve Failed: {self.correct.shape=}, {self.confids.shape=}, {np.min(self.correct)=}, {np.max(self.correct)=}, {np.min(self.confids)=}, {np.max(self.confids)=}" ) def get_rc_curve_stats(self): @@ -333,15 +324,6 @@ def get_val_risk_scores(self, rstar, delta, no_bound_mode=False): val_risk_scores["val_risk"] = risk val_risk_scores["val_cov"] = coverage val_risk_scores["theta"] = theta - logger.debug( - "STRAIGHT FROM THRESH CALCULATION\n{}\n{}\n{}\n{}\n{}\n{}", - risk, - coverage, - theta, - rstar, - delta, - bound, - ) return val_risk_scores @@ -666,7 +648,7 @@ def RC_curve(residuals, confidence): idx_sorted = np.argsort(confidence) cov = n error_sum = sum(residuals[idx_sorted]) - coverages.append(cov / n), + (coverages.append(cov / n),) risks.append(error_sum / n) weights = [] tmp_weight = 0 @@ -730,17 +712,10 @@ def clean_logging(log_dir): df = df.groupby("step").max().round(3) df.to_csv(log_dir / "metrics.csv") except: - logger.warning("no metrics.csv found in clean logging!") + logger.warning("No metrics.csv found in clean logging!") def plot_input_imgs(x, y, out_path): - logger.debug( - "{}\n{}\n{}\n{}", - x.mean().item(), - x.std().item(), - x.min().item(), - x.max().item(), - ) f, axs = plt.subplots(nrows=4, ncols=4, figsize=(10, 10)) for ix in range(len(f.axes)): ax = f.axes[ix] @@ -782,7 +757,7 @@ def qual_plot(fp_dict, fn_dict, out_path): plt.subplots_adjust(wspace=0.23, hspace=0.4) f.savefig(out_path) plt.close() - logger.debug("saved qual_plot to {}", out_path) + logger.debug("Saved qual_plot to {}", out_path) def ThresholdPlot(plot_dict): @@ -794,9 +769,8 @@ def ThresholdPlot(plot_dict): nrows=n_rows, ncols=n_cols, figsize=(n_cols * scale * 0.6, n_rows * scale * 0.4) ) - logger.debug("plot in {}", len(plot_dict)) for ix, (study, study_dict) in enumerate(plot_dict.items()): - logger.debug("threshold plot {} {}", study, len(study_dict["confids"])) + logger.debug("Threshold plot {} {}", study, len(study_dict["confids"])) confids = study_dict["confids"] correct = study_dict["correct"] delta_threshs = study_dict["delta_threshs"] @@ -824,7 +798,6 @@ def ThresholdPlot(plot_dict): ) for idx, dt in enumerate(delta_threshs): - logger.debug("drawing line", idx, dt, delta_threshs, deltas) axs[ix].vlines( dt, ymin=0, diff --git a/fd_shifts/analysis/studies.py b/fd_shifts/analysis/studies.py index ad641fd..e3940d0 100644 --- a/fd_shifts/analysis/studies.py +++ b/fd_shifts/analysis/studies.py @@ -218,6 +218,11 @@ def __filter_if_exists(data: npt.NDArray[Any] | None, mask): _correct=__filter_if_exists(correct, select_ix_all), _mcd_correct=__filter_if_exists(mcd_correct, select_ix_all_mcd), _mcd_labels=__filter_if_exists(labels, select_ix_all_mcd), + _react_logits=__filter_if_exists(data.react_logits, select_ix_all), + _maha_dist=__filter_if_exists(data.maha_dist, select_ix_all), + _vim_score=__filter_if_exists(data.vim_score, select_ix_all), + _dknn_dist=__filter_if_exists(data.dknn_dist, select_ix_all), + _train_features=data._train_features, ) @@ -443,8 +448,8 @@ def iterate_noise_study_data( filter_func: Callable[..., "ExperimentData"] = get_filter_function(study_name) for noise_set in getattr(analysis.query_studies, study_name): for intensity_level in range(5): - logger.debug( - "starting noise study with intensitiy level %s", + logger.info( + "Starting noise study with intensitiy level %s", intensity_level + 1, ) From 5af8c0392338f29b4104c65d4027778dda0a3db8 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 7 Dec 2023 15:05:43 +0100 Subject: [PATCH 020/136] feat: add medshifts and more csfs to reporting --- fd_shifts/reporting/__init__.py | 1 + fd_shifts/reporting/tables.py | 37 ++++++++++++++++++++++++++++----- 2 files changed, 33 insertions(+), 5 deletions(-) diff --git a/fd_shifts/reporting/__init__.py b/fd_shifts/reporting/__init__.py index f86a8ae..4f8c30e 100644 --- a/fd_shifts/reporting/__init__.py +++ b/fd_shifts/reporting/__init__.py @@ -401,6 +401,7 @@ def _filter_row(row, selection_df, optimization_columns, fixed_columns): def _confid_string_to_name(confid: pd.Series) -> pd.Series: confid = ( confid.str.replace("vit_model", "vit") + .str.replace("medshifts/", "") .str.replace("confidnet_", "") .str.replace("_dg", "_res") .str.replace("_det", "") diff --git a/fd_shifts/reporting/tables.py b/fd_shifts/reporting/tables.py index 4d87334..2977157 100644 --- a/fd_shifts/reporting/tables.py +++ b/fd_shifts/reporting/tables.py @@ -92,14 +92,21 @@ def aggregate_over_runs(data: pd.DataFrame) -> pd.DataFrame: fixed_columns = ["study", "confid"] metrics_columns = ["accuracy", "aurc", "ece", "failauc", "fail-NLL"] - data = ( + mean = ( data[fixed_columns + metrics_columns] .groupby(by=fixed_columns) .mean() .sort_values("confid") .reset_index() ) - return data + std = ( + data[fixed_columns + metrics_columns] + .groupby(by=fixed_columns) + .std() + .sort_values("confid") + .reset_index() + ) + return mean, std def _create_results_pivot(data: pd.DataFrame, metric: str, original_mode: bool = False): @@ -190,9 +197,29 @@ def _study_name_to_multilabel(study_name): "MCD-MI", "ConfidNet", "DG-MCD-MSR", + "DG-MSR", "DG-Res", "Devries et al.", "MAHA", + "TEMP-MLS", + "ENERGY-MLS", + "REACT-MLS", + "REACT-MSR", + "REACT-TEMP-MLS", + "REACT-ENERGY-MLS", + "DKNN", + "VIM", + "DG-PE", + "DG-MLS", + "DG-TEMP-MLS", + "DG-ENERGY-MLS", + "DG-MAHA", + "DG-DKNN", + "DG-VIM", + "DG-REACT-MSR", + "DG-REACT-MLS", + "DG-REACT-TEMP-MLS", + "DG-REACT-ENERGY-MLS", ] @@ -245,7 +272,7 @@ def _reorder_studies( return table -def _dataset_to_display_name(dataset_name: str) -> str: +def _dataset_to_display_name(dataset_name: str) -> str | None: mapping = { "animals": "iWildCam", "breeds": "BREEDS", @@ -254,7 +281,7 @@ def _dataset_to_display_name(dataset_name: str) -> str: "cifar100": "CIFAR-100", "svhn": "SVHN", } - return mapping[dataset_name] + return mapping.get(dataset_name) def _build_multilabel(table: pd.DataFrame, paper_filter: bool = True) -> pd.DataFrame: @@ -402,7 +429,7 @@ def paper_results( level=0, ) - sanity_check(results_table, metric) + # sanity_check(results_table, metric) # Render table results_table = results_table.astype(float).applymap( From 19b66ae3437b3c6c23765124fd4750a8317639e6 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 9 Jan 2024 17:01:24 +0100 Subject: [PATCH 021/136] feat: ignore missing test outputs --- fd_shifts/models/callbacks/confid_monitor.py | 35 ++++++++++++-------- 1 file changed, 21 insertions(+), 14 deletions(-) diff --git a/fd_shifts/models/callbacks/confid_monitor.py b/fd_shifts/models/callbacks/confid_monitor.py index 5d04407..8acde26 100644 --- a/fd_shifts/models/callbacks/confid_monitor.py +++ b/fd_shifts/models/callbacks/confid_monitor.py @@ -476,10 +476,13 @@ def on_train_end(self, trainer, pl_module): def on_test_batch_end( self, trainer, pl_module, outputs, batch, batch_idx, dataloader_idx ): + if not hasattr(pl_module, "test_results"): + return outputs = pl_module.test_results - self.running_test_encoded.extend( - outputs["encoded"].to(dtype=torch.float16).cpu() - ) + if outputs["encoded"] is not None: + self.running_test_encoded.extend( + outputs["encoded"].to(dtype=torch.float16).cpu() + ) self.running_test_softmax.extend( outputs["logits"].to(dtype=self.output_dtype).cpu() ) @@ -498,7 +501,9 @@ def on_test_batch_end( ) def on_test_end(self, trainer, pl_module): - stacked_encoded = torch.stack(self.running_test_encoded, dim=0) + if not hasattr(pl_module, "test_results"): + return + stacked_softmax = torch.stack(self.running_test_softmax, dim=0) stacked_labels = torch.stack(self.running_test_labels, dim=0).unsqueeze(1) stacked_dataset_idx = torch.stack( @@ -512,13 +517,18 @@ def on_test_end(self, trainer, pl_module): ], dim=1, ) - encoded_output = torch.cat( - [ - stacked_encoded, - stacked_dataset_idx, - ], - dim=1, - ) + if len(self.running_test_encoded) > 0: + stacked_encoded = torch.stack(self.running_test_encoded, dim=0) + encoded_output = torch.cat( + [ + stacked_encoded, + stacked_dataset_idx, + ], + dim=1, + ) + np.savez_compressed( + self.output_paths.test.encoded_output, encoded_output.cpu().data.numpy() + ) # try: # trainer.datamodule.test_datasets[0].csv.to_csv( # self.output_paths.test.attributions_output @@ -531,9 +541,6 @@ def on_test_end(self, trainer, pl_module): except: pass - np.savez_compressed( - self.output_paths.test.encoded_output, encoded_output.cpu().data.numpy() - ) np.savez_compressed( self.output_paths.test.raw_output, raw_output.cpu().data.numpy() ) From a469eb836bd4abc143669c04690ab08953897d09 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 9 Jan 2024 17:05:27 +0100 Subject: [PATCH 022/136] feat: allow running without model checkpoint for pretrained stuff --- fd_shifts/exec.py | 4 +++- fd_shifts/utils/exp_utils.py | 5 +++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/fd_shifts/exec.py b/fd_shifts/exec.py index d393908..312d568 100644 --- a/fd_shifts/exec.py +++ b/fd_shifts/exec.py @@ -292,7 +292,9 @@ def _fix_metadata(cfg: DictConfig) -> None: ) else: logger.info("CHECK conf.exp.dir", conf.exp.dir) - conf.exp.version = exp_utils.get_most_recent_version(conf.exp.dir) + version = exp_utils.get_most_recent_version(conf.exp.dir) + if version is not None: + conf.exp.version = version ckpt_path = exp_utils._get_resume_ckpt_path(conf) conf.__pydantic_validate_values__() # type: ignore logger.info(OmegaConf.to_yaml(conf)) diff --git a/fd_shifts/utils/exp_utils.py b/fd_shifts/utils/exp_utils.py index 446bda3..0c75fb6 100644 --- a/fd_shifts/utils/exp_utils.py +++ b/fd_shifts/utils/exp_utils.py @@ -45,7 +45,7 @@ def get_next_version(exp_dir: str | Path) -> int: return max_ver + 1 -def get_most_recent_version(exp_dir: str | Path) -> int: +def get_most_recent_version(exp_dir: str | Path) -> int | None: """get best.ckpt of experiment. if split over multiple runs (e.g. due to resuming), still find the best.ckpt. if there are multiple overall runs in the folder select the latest. @@ -58,7 +58,8 @@ def get_most_recent_version(exp_dir: str | Path) -> int: ver_list = [int(x.split("_")[1]) for x in os.listdir(exp_dir) if "version_" in x] logger.debug(ver_list) if len(ver_list) == 0: - RuntimeError("No checkpoints exist in this experiment dir!") + logger.warning("No checkpoints exist in this experiment dir!") + return None max_ver = max(ver_list) return max_ver From b4bfa51ae6f377309c25bb27688c1bd68f28cd3b Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 9 Jan 2024 17:06:12 +0100 Subject: [PATCH 023/136] feat: add clip model --- fd_shifts/models/__init__.py | 3 +- fd_shifts/models/clip_model.py | 86 ++++++++++++++++++++++++++++++++++ 2 files changed, 88 insertions(+), 1 deletion(-) create mode 100644 fd_shifts/models/clip_model.py diff --git a/fd_shifts/models/__init__.py b/fd_shifts/models/__init__.py index 37356bf..6313a28 100644 --- a/fd_shifts/models/__init__.py +++ b/fd_shifts/models/__init__.py @@ -1,11 +1,12 @@ import pytorch_lightning as pl -from fd_shifts.models import confidnet_model, devries_model, vit_model +from fd_shifts.models import clip_model, confidnet_model, devries_model, vit_model _model_factory: dict[str, type[pl.LightningModule]] = { "confidnet_model": confidnet_model.Module, "devries_model": devries_model.net, "vit_model": vit_model.net, + "clip_model": clip_model.ClipOodModel, } diff --git a/fd_shifts/models/clip_model.py b/fd_shifts/models/clip_model.py new file mode 100644 index 0000000..aec98b5 --- /dev/null +++ b/fd_shifts/models/clip_model.py @@ -0,0 +1,86 @@ +from __future__ import annotations + +from pathlib import Path +from typing import TYPE_CHECKING + +import open_clip as oc +import pytorch_lightning as pl +from torchmetrics import Accuracy +from torchvision import transforms + +from fd_shifts import logger +from fd_shifts.utils import to_dict + +if TYPE_CHECKING: + from fd_shifts import configs + + +class ClipOodModel(pl.LightningModule): + def __init__(self, cfg: configs.Config): + super().__init__() + self.save_hyperparameters(to_dict(cfg)) + self.conf = cfg + + self.class_prefix = None + self.model, _, self.preprocess = oc.create_model_and_transforms( + "ViT-B-16", + pretrained="laion2b_s34b_b88k", + ) + self.tokenizer = oc.get_tokenizer("ViT-B-16") + + # example for directly logging metrics + # self.accuracy = Accuracy( + # task="multiclass", + # num_classes=self.conf.data.num_classes, + # validate_args=False, + # ) + + def on_test_start(self): + self.datasets = list( + map(lambda d: d.dataset, self.trainer.datamodule.test_dataloader()) + ) + + if hasattr(self.datasets[0], "classes"): + classes = self.datasets[0].classes + else: + classes = list(map(str, range(self.conf.data.num_classes))) + + if self.class_prefix is not None: + classes = list(map(lambda c: f"{self.class_prefix} {c}", classes)) + + logger.debug(f"{classes=}") + + text = self.tokenizer(classes).to(self.device) + self.text_features = self.model.encode_text(text) + self.text_features /= self.text_features.norm(dim=-1, keepdim=True) + + def test_step(self, batch, batch_idx, dataset_idx): + x, y = batch + x = transforms.functional.resize(x, 224) + + image_features = self.model.encode_image(x) + image_features /= image_features.norm(dim=-1, keepdim=True) + + logits = image_features @ self.text_features.T + + # example for directly logging metrics + # text_probs = torch.softmax(logits, dim=-1) + # preds = torch.argmax(text_probs, dim=-1) + # self.accuracy(preds, y) + # self.log( + # f"accuracy", + # self.accuracy, + # ) + + # only set this if you want to write this to disk, complains if test_results exists and is anything but a dict with these keys + self.test_results = { + "logits": logits, + "logits_dist": None, + "labels": y, + "confid": None, + "confid_dist": None, + "encoded": None, + } + + def load_only_state_dict(self, path: str | Path) -> None: + pass From 81f33e2b9f5ce858684b25ce49132b3ccf64f056 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 10 Jan 2024 23:48:54 +0100 Subject: [PATCH 024/136] deps: add open_clip and faiss --- pyproject.toml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 72e88eb..ff2831e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -9,6 +9,7 @@ requires-python = ">=3.10" dependencies = [ "albumentations>=1.0.3", "deepdiff", + "faiss-gpu", "hydra-colorlog>=1.1.0", "hydra-core>=1.1.1", "hydra-zen", @@ -20,6 +21,7 @@ dependencies = [ "numpy>=1.22.2", "ogb>=1.3.1", "omegaconf>=2.1.1", + "open_clip_torch", "opencv-python-headless", "pandas>=1.2.3", "Pillow==9.5.0", @@ -41,9 +43,9 @@ dependencies = [ "torchvision>=0.12.0", "tqdm>=4.62.0", "typing_extensions>=4.1.1", + "wandb", "warmup_scheduler", "wilds>=1.1.0", - "wandb", ] [project.optional-dependencies] From 8199ba724281815c95f1f525e4758602bd7417d4 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 25 Jan 2024 17:24:25 +0100 Subject: [PATCH 025/136] fix(data): remove legacy reduced animals id_test size --- fd_shifts/loaders/data_loader.py | 38 +++++++++----------------------- 1 file changed, 11 insertions(+), 27 deletions(-) diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index 7e14f3b..45c40ae 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -194,47 +194,31 @@ def setup(self, stage=None): kwargs=self.dataset_kwargs, ) if "wilds" in self.dataset_name: - self.iid_test_set.indices = self.iid_test_set.indices[100:150] + self.iid_test_set.indices = self.iid_test_set.indices[1000:] self.iid_test_set.__len__ = len(self.iid_test_set.indices) + self.val_dataset.indices = self.val_dataset.indices[:1000] + self.val_dataset.__len__ = len(self.val_dataset.indices) else: try: self.iid_test_set.imgs = self.iid_test_set.imgs[1000:] self.iid_test_set.samples = self.iid_test_set.samples[1000:] self.iid_test_set.targets = self.iid_test_set.targets[1000:] self.iid_test_set.__len__ = len(self.iid_test_set.imgs) + self.val_dataset.imgs = self.val_dataset.imgs[:1000] + self.val_dataset.samples = self.val_dataset.samples[:1000] + self.val_dataset.targets = self.val_dataset.targets[:1000] + self.val_dataset.__len__ = len(self.val_dataset.imgs) except: self.iid_test_set.data = self.iid_test_set.data[1000:] + self.val_dataset.data = self.val_dataset.data[:1000] try: self.iid_test_set.targets = self.iid_test_set.targets[1000:] + self.val_dataset.targets = self.val_dataset.targets[:1000] except: self.iid_test_set.labels = self.iid_test_set.labels[1000:] + self.val_dataset.labels = self.val_dataset.labels[:1000] self.iid_test_set.__len__ = len(self.iid_test_set.data) - if self.val_split == "devries": - self.val_dataset = get_dataset( - name=self.dataset_name, - root=self.data_dir, - train=False, - download=True, - target_transform=self.target_transforms.get("val"), - transform=self.augmentations["val"], - kwargs=self.dataset_kwargs, - ) - if "wilds" in self.dataset_name: - self.val_dataset.indices = self.val_dataset.indices[:1000] - self.val_dataset.__len__ = len(self.val_dataset.indices) - else: - try: - self.val_dataset.imgs = self.val_dataset.imgs[:1000] - self.val_dataset.samples = self.val_dataset.samples[:1000] - self.val_dataset.targets = self.val_dataset.targets[:1000] - self.val_dataset.__len__ = len(self.val_dataset.imgs) - except: - self.val_dataset.data = self.val_dataset.data[:1000] - try: - self.val_dataset.targets = self.val_dataset.targets[:1000] - except: - self.val_dataset.labels = self.val_dataset.labels[:1000] - self.val_dataset.__len__ = len(self.val_dataset.data) + self.val_dataset.__len__ = len(self.val_dataset.data) else: self.val_dataset = get_dataset( From acd564709198c0aad7e9303de6924f5340d73e5c Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 10 Jan 2024 23:47:09 +0100 Subject: [PATCH 026/136] wip: fix: use builtin dataclass asdict --- fd_shifts/utils/__init__.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/fd_shifts/utils/__init__.py b/fd_shifts/utils/__init__.py index 24fc4b8..d383fbd 100644 --- a/fd_shifts/utils/__init__.py +++ b/fd_shifts/utils/__init__.py @@ -1,5 +1,6 @@ import importlib import json +from dataclasses import asdict from omegaconf import DictConfig, ListConfig, OmegaConf from pydantic.json import pydantic_encoder @@ -12,8 +13,9 @@ def __to_dict(obj): def to_dict(obj): - s = json.dumps(obj, default=__to_dict) - return json.loads(s) + # s = json.dumps(obj, default=__to_dict) + # return json.loads(s) + return asdict(obj) def instantiate_from_str(name, *args, **kwargs): From 849e0a5da8067543bea6cf7de26f855ea07915de Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 10 Jan 2024 23:54:28 +0100 Subject: [PATCH 027/136] wip: feat: switch to jsonarparse, experiments are now complete Config objects --- fd_shifts/configs/__init__.py | 171 +++++++------- fd_shifts/configs/iterable_mixin.py | 10 + fd_shifts/exec.py | 2 +- fd_shifts/experiments/configs.py | 244 ++++++++++++++++++++ fd_shifts/main.py | 345 ++++++++++++++++++++++++++++ fd_shifts/models/devries_model.py | 23 +- pyproject.toml | 1 + 7 files changed, 706 insertions(+), 90 deletions(-) create mode 100644 fd_shifts/configs/iterable_mixin.py create mode 100644 fd_shifts/experiments/configs.py create mode 100644 fd_shifts/main.py diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index eb33319..8b9c4e4 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -6,24 +6,27 @@ from dataclasses import field from enum import Enum, auto from pathlib import Path -from typing import TYPE_CHECKING, Any, Iterator, Optional, TypeVar +from random import randint +from typing import TYPE_CHECKING, Any, Callable, Iterable, Iterator, Optional, TypeVar import pl_bolts import torch from hydra.core.config_store import ConfigStore from hydra_zen import builds # type: ignore -from omegaconf import DictConfig, OmegaConf +from omegaconf import SI, DictConfig, OmegaConf from omegaconf.omegaconf import MISSING from pydantic import ConfigDict, validator from pydantic.dataclasses import dataclass from typing_extensions import dataclass_transform +import fd_shifts from fd_shifts import models from fd_shifts.analysis import confid_scores, metrics from fd_shifts.loaders import dataset_collection from fd_shifts.utils import exp_utils from ..models import networks +from .iterable_mixin import _IterableMixin if TYPE_CHECKING: from pydantic.dataclasses import Dataclass @@ -58,13 +61,6 @@ class ValSplit(StrEnum): zhang = auto() -class _IterableMixin: # pylint: disable=too-few-public-methods - def __iter__(self) -> Iterator[tuple[str, Any]]: - return filter( - lambda item: not item[0].startswith("__"), self.__dict__.items() - ).__iter__() - - @dataclass_transform() def defer_validation(original_class: type[ConfigT]) -> type[ConfigT]: """Disable validation for a pydantic dataclass @@ -83,13 +79,13 @@ def defer_validation(original_class: type[ConfigT]) -> type[ConfigT]: class OutputPathsConfig(_IterableMixin): """Where outputs are stored""" + raw_output: Path | None = None + raw_output_dist: Path | None = None + external_confids: Path | None = None + external_confids_dist: Path | None = None input_imgs_plot: Optional[Path] = None - raw_output: Path = MISSING encoded_output: Optional[Path] = None attributions_output: Optional[Path] = None - raw_output_dist: Path = MISSING - external_confids: Path = MISSING - external_confids_dist: Path = MISSING @defer_validation @@ -106,23 +102,25 @@ class OutputPathsPerMode(_IterableMixin): class ExperimentConfig(_IterableMixin): """Main experiment config""" - group_name: str = MISSING - name: str = MISSING + group_name: str | None = None + name: str | None = None + mode: Mode = Mode.train_test + work_dir: Path | None = Path.cwd() + fold_dir: Path | None = None + root_dir: Path | None = Path(p) if (p := os.getenv("EXPERIMENT_ROOT_DIR")) else None + data_root_dir: Path | None = ( + Path(p) if (p := os.getenv("DATASET_ROOT_DIR")) else None + ) + group_dir: Path | None = SI("${exp.root_dir}/${exp.group_name}") + dir: Path | None = group_dir / name if group_dir and name else None version: Optional[int] = None - mode: Mode = MISSING - work_dir: Path = MISSING - fold_dir: Path = MISSING - root_dir: Path = MISSING - data_root_dir: Path = MISSING - group_dir: Path = MISSING - dir: Path = MISSING - version_dir: Path = MISSING - fold: int = MISSING - crossval_n_folds: int = MISSING - crossval_ids_path: Path = MISSING + version_dir: Path | None = dir / f"version_{version}" if dir and version else None + fold: int = 0 + crossval_n_folds: int = 10 + crossval_ids_path: Path | None = dir / "crossval_ids.pickle" if dir else None + log_path: Path | None = None + global_seed: int = randint(0, 1_000_000) output_paths: OutputPathsPerMode = OutputPathsPerMode() - log_path: Path = MISSING - global_seed: int = MISSING @defer_validation @@ -189,27 +187,33 @@ class Adam(OptimizerConfig): @defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) +@dataclass(config=ConfigDict(validate_assignment=True, arbitrary_types_allowed=True)) class TrainerConfig(_IterableMixin): """Main configuration for PyTorch Lightning Trainer""" - accumulate_grad_batches: int = 1 - resume_from_ckpt_confidnet: Optional[bool] = None - num_epochs: Optional[int] = None + num_epochs: Optional[int] = 300 num_steps: Optional[int] = None num_epochs_backbone: Optional[int] = None - dg_pretrain_epochs: Optional[int] = None + val_every_n_epoch: int = 5 + do_val: bool = True + batch_size: int = 128 + resume_from_ckpt: bool = False + benchmark: bool = True + fast_dev_run: bool | int = False + lr_scheduler: Callable[ + [torch.optim.Optimizer], torch.optim.lr_scheduler._LRScheduler + ] | None = None + optimizer: Callable[[Iterable], torch.optim.Optimizer] | None = None + # lr_scheduler: LRSchedulerConfig | None = None + # optimizer: OptimizerConfig | None = None + accumulate_grad_batches: int = 1 + resume_from_ckpt_confidnet: bool = False + dg_pretrain_epochs: int | None = 100 dg_pretrain_steps: Optional[int] = None - val_every_n_epoch: int = MISSING - val_split: Optional[ValSplit] = None - do_val: bool = MISSING - batch_size: int = MISSING - resume_from_ckpt: bool = MISSING - benchmark: bool = MISSING - fast_dev_run: bool | int = MISSING + val_split: ValSplit = ValSplit.devries lr_scheduler_interval: str = "epoch" - lr_scheduler: LRSchedulerConfig = LRSchedulerConfig() - optimizer: OptimizerConfig = MISSING + + # TODO: Replace with jsonargparse compatible type hint to lightning.Callback callbacks: dict[str, Optional[dict[Any, Any]]] = field(default_factory=lambda: {}) learning_rate_confidnet: Optional[float] = None @@ -241,7 +245,7 @@ def validate_steps( class NetworkConfig(_IterableMixin): """Model Network configuration""" - name: str = MISSING + name: str = "vgg13" backbone: Optional[str] = None imagenet_weights_path: Optional[Path] = None load_dg_backbone_path: Optional[Path] = None @@ -268,17 +272,17 @@ def validate_network_name(cls: NetworkConfig, name: str) -> str: class ModelConfig(_IterableMixin): """Model Configuration""" - name: str = MISSING - fc_dim: int = MISSING + name: str = "devries_model" + network: NetworkConfig = NetworkConfig() + fc_dim: int = 512 + avg_pool: bool = True + dropout_rate: int = 0 + monitor_mcd_samples: int = 50 + test_mcd_samples: int = 50 confidnet_fc_dim: Optional[int] = None dg_reward: Optional[float] = None - avg_pool: bool = MISSING balanced_sampeling: bool = False - dropout_rate: int = MISSING - monitor_mcd_samples: int = MISSING - test_mcd_samples: int = MISSING - budget: Optional[float] = None - network: NetworkConfig = NetworkConfig() + budget: float = 0.3 # pylint: disable=no-self-argument @validator("name") @@ -397,10 +401,10 @@ def validate(cls: ConfidMeasuresConfig, name: str) -> str: class QueryStudiesConfig(_IterableMixin): """Query Studies Configuration""" - iid_study: str = MISSING - noise_study: list[str] = MISSING - in_class_study: list[str] = MISSING - new_class_study: list[str] = MISSING + iid_study: str | None = None + noise_study: list[str] = field(default_factory=lambda: []) + in_class_study: list[str] = field(default_factory=lambda: []) + new_class_study: list[str] = field(default_factory=lambda: []) # pylint: disable=no-self-argument @validator( @@ -424,6 +428,13 @@ def validate(cls, name: str) -> str: class EvalConfig(_IterableMixin): """Evaluation Configuration container""" + tb_hparams: list[str] = field(default_factory=lambda: ["fold"]) + test_conf_scaling: bool = False + val_tuning: bool = True + r_star: float = 0.25 + r_delta: float = 0.05 + + query_studies: QueryStudiesConfig = QueryStudiesConfig() performance_metrics: PerfMetricsConfig = PerfMetricsConfig() confid_metrics: ConfidMetricsConfig = ConfidMetricsConfig() confidence_measures: ConfidMeasuresConfig = ConfidMeasuresConfig() @@ -434,14 +445,7 @@ class EvalConfig(_IterableMixin): ] ) - tb_hparams: list[str] = MISSING ext_confid_name: Optional[str] = None - test_conf_scaling: bool = MISSING - val_tuning: bool = MISSING - r_star: float = MISSING - r_delta: float = MISSING - - query_studies: QueryStudiesConfig = QueryStudiesConfig() @defer_validation @@ -449,19 +453,19 @@ class EvalConfig(_IterableMixin): class TestConfig(_IterableMixin): """Inference time configuration""" - name: str = MISSING - dir: Path = MISSING - cf_path: Path = MISSING - selection_criterion: str = MISSING - best_ckpt_path: Path = MISSING - only_latest_version: bool = MISSING - devries_repro_ood_split: bool = MISSING - assim_ood_norm_flag: bool = MISSING - iid_set_split: str = MISSING - raw_output_path: str = MISSING - external_confids_output_path: str = MISSING + name: str = "test_results" + dir: Path | None = None + cf_path: Path | None = None + selection_criterion: str | None = None + best_ckpt_path: Path | None = None + only_latest_version: bool | None = None + devries_repro_ood_split: bool | None = None + assim_ood_norm_flag: bool | None = None + iid_set_split: str | None = None + raw_output_path: str | None = None + external_confids_output_path: str | None = None + output_precision: int | None = None selection_mode: Optional[str] = None - output_precision: int = MISSING @defer_validation @@ -469,14 +473,14 @@ class TestConfig(_IterableMixin): class DataConfig(_IterableMixin): """Dataset Configuration""" - dataset: str = MISSING - data_dir: Path = MISSING - pin_memory: bool = MISSING - img_size: tuple[int, int, int] = MISSING - num_workers: int = MISSING - num_classes: int = MISSING - reproduce_confidnet_splits: bool = MISSING - augmentations: Any = MISSING + dataset: str | None = None + data_dir: Path | None = None + pin_memory: bool | None = None + img_size: tuple[int, int, int] | None = None + num_workers: int | None = None + num_classes: int | None = None + reproduce_confidnet_splits: bool | None = None + augmentations: dict[str, dict[str, Any]] | None = None target_transforms: Optional[Any] = None kwargs: Optional[dict[Any, Any]] = None @@ -486,7 +490,8 @@ class DataConfig(_IterableMixin): class Config(_IterableMixin): """Main Configuration Class""" - pkgversion: str = MISSING + pkgversion: str = fd_shifts.get_version() + data: DataConfig = DataConfig() trainer: TrainerConfig = TrainerConfig() diff --git a/fd_shifts/configs/iterable_mixin.py b/fd_shifts/configs/iterable_mixin.py new file mode 100644 index 0000000..b9d59ab --- /dev/null +++ b/fd_shifts/configs/iterable_mixin.py @@ -0,0 +1,10 @@ +from dataclasses import dataclass +from typing import Any, Iterator + + +@dataclass +class _IterableMixin: # pylint: disable=too-few-public-methods + def __iter__(self) -> Iterator[tuple[str, Any]]: + return filter( + lambda item: not item[0].startswith("__"), self.__dict__.items() + ).__iter__() diff --git a/fd_shifts/exec.py b/fd_shifts/exec.py index 312d568..aa7f4d4 100644 --- a/fd_shifts/exec.py +++ b/fd_shifts/exec.py @@ -211,7 +211,7 @@ def main(dconf: DictConfig) -> None: Args: dconf (DictConfig): config passed in by hydra """ - multiprocessing.set_start_method("spawn") + # multiprocessing.set_start_method("spawn") reconfigure(stderr=True, force_terminal=True) progress = RichProgressBar(console_kwargs={"stderr": True, "force_terminal": True}) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py new file mode 100644 index 0000000..509b9ca --- /dev/null +++ b/fd_shifts/experiments/configs.py @@ -0,0 +1,244 @@ +import os +from pathlib import Path + +import pl_bolts +import torch +from omegaconf import SI + +from fd_shifts.configs import ( + ConfidMeasuresConfig, + ConfidMetricsConfig, + Config, + DataConfig, + EvalConfig, + ExperimentConfig, + Mode, + ModelConfig, + NetworkConfig, + OutputPathsConfig, + OutputPathsPerMode, + PerfMetricsConfig, + QueryStudiesConfig, + TestConfig, + TrainerConfig, + ValSplit, +) + +__data_configs = {} + +__data_configs["svhn_384"] = DataConfig( + dataset="svhn", + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/svhn"), + pin_memory=True, + img_size=(384, 384, 3), + num_workers=24, + num_classes=10, + reproduce_confidnet_splits=True, + augmentations={ + "train": { + "to_tensor": None, + "resize": 384, + "normalize": [ + [0.4376821, 0.4437697, 0.47280442], + [0.19803012, 0.20101562, 0.19703614], + ], + }, + "val": { + "to_tensor": None, + "resize": 384, + "normalize": [ + [0.4376821, 0.4437697, 0.47280442], + [0.19803012, 0.20101562, 0.19703614], + ], + }, + "test": { + "to_tensor": None, + "resize": 384, + "normalize": [ + [0.4376821, 0.4437697, 0.47280442], + [0.19803012, 0.20101562, 0.19703614], + ], + }, + }, + target_transforms=None, + kwargs=None, +) + + +def get_data_config(name: str) -> DataConfig: + return __data_configs[name] + + +__experiments = {} + +__experiments["svhn_modeldg_bbvit_lr0.01_bs128_run4_do1_rew10"] = Config( + data=get_data_config("svhn_384"), + trainer=TrainerConfig( + val_every_n_epoch=5, + do_val=True, + batch_size=128, + resume_from_ckpt=False, + benchmark=True, + fast_dev_run=False, + lr_scheduler=lambda optim: pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR( + optim, + warmup_epochs=500, + max_epochs=60000, + warmup_start_lr=0.0, + eta_min=0.0, + last_epoch=-1, + ), + optimizer=lambda params: torch.optim.SGD( + params, + lr=0.01, + dampening=0.0, + momentum=0.9, + nesterov=False, + maximize=False, + weight_decay=0.0, + ), + accumulate_grad_batches=1, + resume_from_ckpt_confidnet=False, + num_epochs=None, + num_steps=60000, + num_epochs_backbone=None, + dg_pretrain_epochs=None, + dg_pretrain_steps=20000, + val_split=ValSplit.devries, + lr_scheduler_interval="step", + callbacks={ + "model_checkpoint": None, + "confid_monitor": None, + "learning_rate_monitor": None, + }, + learning_rate_confidnet=None, + learning_rate_confidnet_finetune=None, + ), + exp=ExperimentConfig( + group_name="vit", + name="svhn_modeldg_bbvit_lr0.01_bs128_run4_do1_rew10", + mode=Mode.analysis, + work_dir=Path.cwd(), + fold_dir=SI("exp/${exp.fold}"), + root_dir=Path(p) + if (p := os.getenv("EXPERIMENT_ROOT_DIR")) is not None + else None, + data_root_dir=Path(p) + if (p := os.getenv("DATASET_ROOT_DIR")) is not None + else None, + group_dir=Path("${exp.root_dir}/${exp.group_name}"), + dir=Path("${exp.group_dir}/${exp.name}"), + version_dir=Path("${exp.dir}/version_${exp.version}"), + fold=0, + crossval_n_folds=10, + crossval_ids_path=Path("${exp.dir}/crossval_ids.pickle"), + log_path=Path("log.txt"), + global_seed=0, + output_paths=OutputPathsPerMode( + fit=OutputPathsConfig( + raw_output=Path("${exp.version_dir}/raw_output.npz"), + raw_output_dist=Path("${exp.version_dir}/raw_output_dist.npz"), + external_confids=Path("${exp.version_dir}/external_confids.npz"), + external_confids_dist=Path( + "${exp.version_dir}/external_confids_dist.npz" + ), + input_imgs_plot=Path("${exp.dir}/input_imgs.png"), + encoded_output=None, + attributions_output=None, + ), + test=OutputPathsConfig( + raw_output=Path("${test.dir}/raw_logits.npz"), + raw_output_dist=Path("${test.dir}/raw_logits_dist.npz"), + external_confids=Path("${test.dir}/external_confids.npz"), + external_confids_dist=Path("${test.dir}/external_confids_dist.npz"), + input_imgs_plot=None, + encoded_output=Path("${test.dir}/encoded_output.npz"), + attributions_output=Path("${test.dir}/attributions.csv"), + ), + ), + version=None, + ), + model=ModelConfig( + name="devries_model", + network=NetworkConfig( + name="vit", + backbone=None, + imagenet_weights_path=None, + load_dg_backbone_path=None, + save_dg_backbone_path=Path("${exp.dir}/dg_backbone.ckpt"), + ), + fc_dim=768, + avg_pool=True, + dropout_rate=1, + monitor_mcd_samples=50, + test_mcd_samples=50, + confidnet_fc_dim=None, + dg_reward=10, + balanced_sampeling=False, + budget=0.3, + ), + eval=EvalConfig( + tb_hparams=["fold"], + test_conf_scaling=False, + val_tuning=True, + r_star=0.25, + r_delta=0.05, + query_studies=QueryStudiesConfig( + iid_study="svhn_384", + noise_study=[], + in_class_study=[], + new_class_study=["cifar10_384", "cifar100_384", "tinyimagenet_384"], + ), + performance_metrics=PerfMetricsConfig( + train=["loss", "nll", "accuracy"], + val=["loss", "nll", "accuracy", "brier_score"], + test=["nll", "accuracy", "brier_score"], + ), + confid_metrics=ConfidMetricsConfig( + train=[ + "failauc", + "failap_suc", + "failap_err", + "fpr@95tpr", + "e-aurc", + "aurc", + ], + val=["failauc", "failap_suc", "failap_err", "fpr@95tpr", "e-aurc", "aurc"], + test=[ + "failauc", + "failap_suc", + "failap_err", + "mce", + "ece", + "b-aurc", + "e-aurc", + "aurc", + "fpr@95tpr", + ], + ), + confidence_measures=ConfidMeasuresConfig( + train=["det_mcp"], val=["det_mcp"], test=["det_mcp", "det_pe", "ext"] + ), + monitor_plots=["hist_per_confid"], + ext_confid_name="dg", + ), + test=TestConfig( + name="test_results", + dir=Path("${exp.dir}/${test.name}"), + cf_path=Path("${exp.dir}/hydra/config.yaml"), + selection_criterion="latest", + best_ckpt_path=Path("${exp.version_dir}/${test.selection_criterion}.ckpt"), + only_latest_version=True, + devries_repro_ood_split=False, + assim_ood_norm_flag=False, + iid_set_split="devries", + raw_output_path="raw_output.npz", + external_confids_output_path="external_confids.npz", + output_precision=16, + selection_mode="max", + ), +) + + +def get_experiment_config(name: str) -> Config: + return __experiments[name] diff --git a/fd_shifts/main.py b/fd_shifts/main.py new file mode 100644 index 0000000..144c58f --- /dev/null +++ b/fd_shifts/main.py @@ -0,0 +1,345 @@ +import types +import typing +from contextlib import contextmanager +from contextvars import ContextVar +from dataclasses import asdict, is_dataclass +from pathlib import Path +from typing import Any, Callable + +import pytorch_lightning as pl +import rich +from jsonargparse import ArgumentParser +from jsonargparse._actions import Action +from omegaconf import OmegaConf +from pytorch_lightning.callbacks.progress.rich_progress import RichProgressBar +from pytorch_lightning.loggers.csv_logs import CSVLogger +from pytorch_lightning.loggers.tensorboard import TensorBoardLogger +from pytorch_lightning.loggers.wandb import WandbLogger +from rich.pretty import pretty_repr + +from fd_shifts import analysis, logger +from fd_shifts.configs import Config +from fd_shifts.experiments.configs import get_experiment_config +from fd_shifts.loaders.data_loader import FDShiftsDataLoader +from fd_shifts.models import get_model +from fd_shifts.models.callbacks import get_callbacks +from fd_shifts.utils import exp_utils + +__subcommands = {} + + +def subcommand(func: Callable): + __subcommands[func.__name__] = func + return func + + +previous_config: ContextVar = ContextVar("previous_config", default=None) + + +@contextmanager +def previous_config_context(cfg): + token = previous_config.set(cfg) + try: + yield + finally: + previous_config.reset(token) + + +class ActionExperiment(Action): + """Action to indicate that an argument is an experiment name.""" + + def __init__(self, **kwargs): + """Initializer for ActionExperiment instance.""" + if "default" in kwargs: + raise ValueError("ActionExperiment does not accept a default.") + opt_name = kwargs["option_strings"] + opt_name = ( + opt_name[0] + if len(opt_name) == 1 + else [x for x in opt_name if x[0:2] == "--"][0] + ) + if "." in opt_name: + raise ValueError("ActionExperiment must be a top level option.") + if "help" not in kwargs: + # TODO: hint to list-experiments + kwargs["help"] = "Name of an experiment." + super().__init__(**kwargs) + + def __call__(self, parser, cfg, values, option_string=None): + """Parses the given experiment configuration and adds all the corresponding keys to the namespace. + + Raises: + TypeError: If there are problems parsing the configuration. + """ + self.apply_experiment_config(parser, cfg, self.dest, values) + + @staticmethod + def apply_experiment_config(parser: ArgumentParser, cfg, dest, value) -> None: + with previous_config_context(cfg): + experiment_cfg = get_experiment_config(value) + tcfg = parser.parse_object( + {"config": asdict(experiment_cfg)}, + env=False, + defaults=False, + _skip_check=True, + ) + cfg_merged = parser.merge_config(tcfg, cfg) + cfg.__dict__.update(cfg_merged.__dict__) + cfg[dest] = value + + +def _path_to_str(cfg) -> dict: + def __path_to_str(cfg): + if isinstance(cfg, dict): + return {k: __path_to_str(v) for k, v in cfg.items()} + if is_dataclass(cfg): + return cfg.__class__( + **{k: __path_to_str(v) for k, v in cfg.__dict__.items()} + ) + if isinstance(cfg, Path): + return str(cfg) + return cfg + + return __path_to_str(cfg) # type: ignore + + +def _dict_to_dataclass(cfg) -> Config: + def __dict_to_dataclass(cfg, cls): + if is_dataclass(cls): + fieldtypes = typing.get_type_hints(cls) + return cls( + **{k: __dict_to_dataclass(v, fieldtypes[k]) for k, v in cfg.items()} + ) + if ( + isinstance(cls, types.UnionType) + and Path in cls.__args__ + and cfg is not None + ): + return Path(cfg) + return cfg + + return __dict_to_dataclass(cfg, Config) # type: ignore + + +def omegaconf_resolve(config: Config): + """Resolve all variable interpolations in config object with OmegaConf + + Args: + config: Config object to resolve + + Returns: + resolved config object + """ + dict_config = asdict(config) + + # convert all paths to string, omegaconf does not do variable interpolation in anything that's not a string + dict_config = _path_to_str(dict_config) + + # omegaconf can't handle callables, may need to extend this list if other callable configs get added + del dict_config["trainer"]["lr_scheduler"] + del dict_config["trainer"]["optimizer"] + + oc_config = OmegaConf.create(dict_config) + dict_config: dict[str, Any] = OmegaConf.to_object(oc_config) # type: ignore + + dict_config["trainer"]["lr_scheduler"] = config.trainer.lr_scheduler + dict_config["trainer"]["optimizer"] = config.trainer.optimizer + + new_config = _dict_to_dataclass(dict_config) + return new_config + + +def setup_logging(): + rich.reconfigure(stderr=True, force_terminal=True) + logger.remove() # Remove default 'stderr' handler + + # We need to specify end=''" as log message already ends with \n (thus the lambda function) + # Also forcing 'colorize=True' otherwise Loguru won't recognize that the sink support colors + logger.add( + lambda m: rich.get_console().print(m, end="", markup=False, highlight=False), + colorize=True, + enqueue=True, + level="DEBUG", + backtrace=True, + diagnose=True, + ) + + +@subcommand +def train(config: Config): + progress = RichProgressBar(console_kwargs={"stderr": True, "force_terminal": True}) + + if config.exp.dir is None: + raise ValueError("Experiment directory must be specified") + config.exp.version = exp_utils.get_next_version(config.exp.dir) + # HACK: This should be automatically linked or not configurable + config.exp.version_dir = config.exp.dir / f"version_{config.exp.version}" + + logger.info(pretty_repr(config)) + + # TODO: Clean the rest of this up + + max_steps = ( + config.trainer.num_steps if hasattr(config.trainer, "num_steps") else None + ) + accumulate_grad_batches = ( + config.trainer.accumulate_grad_batches + if hasattr(config.trainer, "accumulate_grad_batches") + else 1 + ) + + limit_batches: float | int = 1.0 + num_epochs = config.trainer.num_epochs + val_every_n_epoch = config.trainer.val_every_n_epoch + log_every_n_steps = 50 + + if isinstance(config.trainer.fast_dev_run, bool): + limit_batches = 1 if config.trainer.fast_dev_run else 1.0 + num_epochs = 1 if config.trainer.fast_dev_run else num_epochs + max_steps = 1 if config.trainer.fast_dev_run else max_steps + val_every_n_epoch = 1 if config.trainer.fast_dev_run else val_every_n_epoch + elif isinstance(config.trainer.fast_dev_run, int): + limit_batches = config.trainer.fast_dev_run * accumulate_grad_batches + max_steps = config.trainer.fast_dev_run * 2 + config.trainer.dg_pretrain_epochs = None + config.trainer.dg_pretrain_steps = (max_steps * 2) // 3 + val_every_n_epoch = 1 + log_every_n_steps = 1 + num_epochs = None + + datamodule = FDShiftsDataLoader(config) + model = get_model(config.model.name)(config) + csv_logger = CSVLogger( + save_dir=str(config.exp.group_dir), + name=config.exp.name, + version=config.exp.version, + ) + + tb_logger = TensorBoardLogger( + save_dir=str(config.exp.group_dir), + name=config.exp.name, + default_hp_metric=False, + ) + + wandb_logger = WandbLogger( + project="fd_shifts_proto", + name=config.exp.name, + ) + + trainer = pl.Trainer( + accelerator="auto", + devices="auto", + logger=[tb_logger, csv_logger, wandb_logger], + log_every_n_steps=log_every_n_steps, + max_epochs=num_epochs, + max_steps=max_steps, # type: ignore + callbacks=[progress] + get_callbacks(config), + benchmark=config.trainer.benchmark, + precision=16, + check_val_every_n_epoch=val_every_n_epoch, + num_sanity_val_steps=5, + limit_train_batches=limit_batches, + limit_val_batches=0 if config.trainer.do_val is False else limit_batches, + limit_test_batches=limit_batches, + gradient_clip_val=1, + accumulate_grad_batches=accumulate_grad_batches, + ) + + logger.info( + "logging training to: {}, version: {}".format( + config.exp.dir, config.exp.version + ) + ) + trainer.fit(model=model, datamodule=datamodule) + + +@subcommand +def test(config: Config): + progress = RichProgressBar(console_kwargs={"stderr": True, "force_terminal": True}) + + if config.exp.dir is None: + raise ValueError("Experiment directory must be specified") + + config.exp.version = ( + version if (version := exp_utils.get_most_recent_version(config.exp.dir)) else 0 + ) + # HACK: This should be automatically linked or not configurable + config.exp.version_dir = config.exp.dir / f"version_{config.exp.version}" + logger.info(pretty_repr(config)) + + ckpt_path = exp_utils._get_resume_ckpt_path(config) + + logger.info( + "testing model from checkpoint: {} from model selection tpye {}".format( + ckpt_path, config.test.selection_criterion + ) + ) + logger.info("logging testing to: {}".format(config.test.dir)) + + module = get_model(config.model.name)(config) + + # TODO: make common module class with this method + module.load_only_state_dict(ckpt_path) # type: ignore + + datamodule = FDShiftsDataLoader(config) + + if not config.test.dir.exists(): + config.test.dir.mkdir(parents=True) + + limit_batches: float | int = 1.0 + log_every_n_steps = 50 + + if isinstance(config.trainer.fast_dev_run, bool): + limit_batches = 1 if config.trainer.fast_dev_run else 1.0 + elif isinstance(config.trainer.fast_dev_run, int): + limit_batches = config.trainer.fast_dev_run + log_every_n_steps = 1 + + wandb_logger = WandbLogger( + project="fd_shifts_proto", + name=config.exp.name, + ) + + trainer = pl.Trainer( + accelerator="auto", + devices="auto", + logger=wandb_logger, + log_every_n_steps=log_every_n_steps, + callbacks=[progress] + get_callbacks(config), + limit_test_batches=limit_batches, + precision=16, + ) + trainer.test(model=module, datamodule=datamodule) + analysis.main( + in_path=config.test.dir, + out_path=config.test.dir, + query_studies=config.eval.query_studies, + add_val_tuning=config.eval.val_tuning, + threshold_plot_confid=None, + cf=config, + ) + + +def main(): + setup_logging() + + parser = ArgumentParser(parser_mode="omegaconf") + subcommands = parser.add_subcommands(dest="command") + + for name, func in __subcommands.items(): + subparser = ArgumentParser(parser_mode="omegaconf") + subparser.add_argument("--experiment", action=ActionExperiment) + subparser.add_function_arguments(func, sub_configs=True) + subcommands.add_subcommand(name, subparser) + + args = parser.parse_args() + + args = parser.instantiate_classes(args) + + args[args.command].config = omegaconf_resolve(args[args.command].config) + + __subcommands[args.command](config=args[args.command].config) + + +if __name__ == "__main__": + main() diff --git a/fd_shifts/models/devries_model.py b/fd_shifts/models/devries_model.py index bc04640..f887e7e 100644 --- a/fd_shifts/models/devries_model.py +++ b/fd_shifts/models/devries_model.py @@ -312,17 +312,28 @@ def test_step(self, batch, batch_idx, *args): } def configure_optimizers(self): + # optimizers = [ + # hydra.utils.instantiate(self.optimizer_cfgs, _partial_=True)( + # self.model.parameters() + # ) + # ] + + # schedulers = [ + # { + # "scheduler": hydra.utils.instantiate(self.lr_scheduler_cfgs)( + # optimizer=optimizers[0] + # ), + # "interval": self.lr_scheduler_interval, + # }, + # ] + optimizers = [ - hydra.utils.instantiate(self.optimizer_cfgs, _partial_=True)( - self.model.parameters() - ) + self.optimizer_cfgs(self.model.parameters()), ] schedulers = [ { - "scheduler": hydra.utils.instantiate(self.lr_scheduler_cfgs)( - optimizer=optimizers[0] - ), + "scheduler": self.lr_scheduler_cfgs(optimizers[0]), "interval": self.lr_scheduler_interval, }, ] diff --git a/pyproject.toml b/pyproject.toml index ff2831e..45f3d42 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -15,6 +15,7 @@ dependencies = [ "hydra-zen", "imageio>=2.9.0", "ipython", + "jsonargparse[signatures]", "loguru", "matplotlib>=3.3.4", "medmnist", From 73b2bd090e21f63994781d77329136d42f2499df Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 11 Jan 2024 15:36:19 +0100 Subject: [PATCH 028/136] wip: feat: save and load configs --- fd_shifts/configs/__init__.py | 133 ++++++++++++++++++------------- fd_shifts/experiments/configs.py | 43 ++++++---- fd_shifts/main.py | 22 +++-- 3 files changed, 123 insertions(+), 75 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 8b9c4e4..274fd14 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -1,5 +1,6 @@ from __future__ import annotations +import importlib import os from collections.abc import Mapping from copy import deepcopy @@ -123,67 +124,91 @@ class ExperimentConfig(_IterableMixin): output_paths: OutputPathsPerMode = OutputPathsPerMode() -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) -class LRSchedulerConfig: - """Base class for LR scheduler configuration""" +# @defer_validation +# @dataclass(config=ConfigDict(validate_assignment=True)) +# class LRSchedulerConfig: +# """Base class for LR scheduler configuration""" - _target_: str = MISSING - _partial_: Optional[bool] = None +# _target_: str = MISSING +# _partial_: Optional[bool] = None -CosineAnnealingLR = builds( - torch.optim.lr_scheduler.CosineAnnealingLR, - builds_bases=(LRSchedulerConfig,), - zen_partial=True, - populate_full_signature=True, - T_max="${trainer.num_steps}", -) +# CosineAnnealingLR = builds( +# torch.optim.lr_scheduler.CosineAnnealingLR, +# builds_bases=(LRSchedulerConfig,), +# zen_partial=True, +# populate_full_signature=True, +# T_max="${trainer.num_steps}", +# ) -LinearWarmupCosineAnnealingLR = builds( - pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR, - builds_bases=(LRSchedulerConfig,), - zen_partial=True, - populate_full_signature=True, - max_epochs="${trainer.num_steps}", - warmup_epochs=500, -) +# LinearWarmupCosineAnnealingLR = builds( +# pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR, +# builds_bases=(LRSchedulerConfig,), +# zen_partial=True, +# populate_full_signature=True, +# max_epochs="${trainer.num_steps}", +# warmup_epochs=500, +# ) -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) -class OptimizerConfig: - """Base class for optimizer configuration""" +# @defer_validation +# @dataclass(config=ConfigDict(validate_assignment=True)) +# class OptimizerConfig: +# """Base class for optimizer configuration""" - _target_: str = MISSING - _partial_: Optional[bool] = True +# _target_: str = MISSING +# _partial_: Optional[bool] = True -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) -class SGD(OptimizerConfig): - """Configuration for SGD optimizer""" +# @defer_validation +# @dataclass(config=ConfigDict(validate_assignment=True)) +# class SGD(OptimizerConfig): +# """Configuration for SGD optimizer""" - _target_: str = "torch.optim.sgd.SGD" - lr: float = 0.003 # pylint: disable=invalid-name - dampening: float = 0.0 - momentum: float = 0.9 - nesterov: bool = False - maximize: bool = False - weight_decay: float = 0.0 +# _target_: str = "torch.optim.sgd.SGD" +# lr: float = 0.003 # pylint: disable=invalid-name +# dampening: float = 0.0 +# momentum: float = 0.9 +# nesterov: bool = False +# maximize: bool = False +# weight_decay: float = 0.0 -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) -class Adam(OptimizerConfig): - """Configuration for ADAM optimizer""" +# @defer_validation +# @dataclass(config=ConfigDict(validate_assignment=True)) +# class Adam(OptimizerConfig): +# """Configuration for ADAM optimizer""" + +# _target_: str = "torch.optim.adam.Adam" +# lr: float = 0.003 # pylint: disable=invalid-name +# betas: tuple[float, float] = (0.9, 0.999) +# eps: float = 1e-08 +# maximize: bool = False +# weight_decay: float = 0.0 + + +@dataclass +class LRSchedulerConfig: + init_args: dict + class_path: str = "fd_shifts.configs.LRSchedulerConfig" + + def __call__( + self, optim: torch.optim.Optimizer + ) -> torch.optim.lr_scheduler._LRScheduler: + module_name, class_name = self.init_args["class_path"].rsplit(".", 1) + cls = getattr(importlib.import_module(module_name), class_name) + return cls(optim, **self.init_args["init_args"]) + + +@dataclass +class OptimizerConfig: + init_args: dict + class_path: str = "fd_shifts.configs.OptimizerConfig" - _target_: str = "torch.optim.adam.Adam" - lr: float = 0.003 # pylint: disable=invalid-name - betas: tuple[float, float] = (0.9, 0.999) - eps: float = 1e-08 - maximize: bool = False - weight_decay: float = 0.0 + def __call__(self, params: Iterable) -> torch.optim.Optimizer: + module_name, class_name = self.init_args["class_path"].rsplit(".", 1) + cls = getattr(importlib.import_module(module_name), class_name) + return cls(params, **self.init_args["init_args"]) @defer_validation @@ -200,12 +225,12 @@ class TrainerConfig(_IterableMixin): resume_from_ckpt: bool = False benchmark: bool = True fast_dev_run: bool | int = False - lr_scheduler: Callable[ - [torch.optim.Optimizer], torch.optim.lr_scheduler._LRScheduler - ] | None = None - optimizer: Callable[[Iterable], torch.optim.Optimizer] | None = None - # lr_scheduler: LRSchedulerConfig | None = None - # optimizer: OptimizerConfig | None = None + # lr_scheduler: Callable[ + # [torch.optim.Optimizer], torch.optim.lr_scheduler._LRScheduler + # ] | None = None + # optimizer: Callable[[Iterable], torch.optim.Optimizer] | None = None + lr_scheduler: LRSchedulerConfig | None = None + optimizer: OptimizerConfig | None = None accumulate_grad_batches: int = 1 resume_from_ckpt_confidnet: bool = False dg_pretrain_epochs: int | None = 100 diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index 509b9ca..04e21a3 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -1,5 +1,8 @@ +import importlib import os +from dataclasses import dataclass from pathlib import Path +from typing import Iterable import pl_bolts import torch @@ -12,9 +15,11 @@ DataConfig, EvalConfig, ExperimentConfig, + LRSchedulerConfig, Mode, ModelConfig, NetworkConfig, + OptimizerConfig, OutputPathsConfig, OutputPathsPerMode, PerfMetricsConfig, @@ -80,22 +85,30 @@ def get_data_config(name: str) -> DataConfig: resume_from_ckpt=False, benchmark=True, fast_dev_run=False, - lr_scheduler=lambda optim: pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR( - optim, - warmup_epochs=500, - max_epochs=60000, - warmup_start_lr=0.0, - eta_min=0.0, - last_epoch=-1, + lr_scheduler=LRSchedulerConfig( + { + "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", + "init_args": { + "warmup_epochs": 500, + "max_epochs": 60000, + "warmup_start_lr": 0.0, + "eta_min": 0.0, + "last_epoch": -1, + }, + } ), - optimizer=lambda params: torch.optim.SGD( - params, - lr=0.01, - dampening=0.0, - momentum=0.9, - nesterov=False, - maximize=False, - weight_decay=0.0, + optimizer=OptimizerConfig( + { + "class_path": "torch.optim.SGD", + "init_args": { + "lr": 0.01, + "dampening": 0.0, + "momentum": 0.9, + "nesterov": False, + "maximize": False, + "weight_decay": 0.0, + }, + } ), accumulate_grad_batches=1, resume_from_ckpt_confidnet=False, diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 144c58f..13713d7 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -8,7 +8,7 @@ import pytorch_lightning as pl import rich -from jsonargparse import ArgumentParser +from jsonargparse import ActionConfigFile, ArgumentParser from jsonargparse._actions import Action from omegaconf import OmegaConf from pytorch_lightning.callbacks.progress.rich_progress import RichProgressBar @@ -323,22 +323,32 @@ def test(config: Config): def main(): setup_logging() - parser = ArgumentParser(parser_mode="omegaconf") + parser = ArgumentParser() + parser.add_argument("-f", "--overwrite-config-file", action="store_true") subcommands = parser.add_subcommands(dest="command") + subparsers: dict[str, ArgumentParser] = {} for name, func in __subcommands.items(): - subparser = ArgumentParser(parser_mode="omegaconf") + subparser = ArgumentParser() + subparser.add_argument("--config-file", action=ActionConfigFile) subparser.add_argument("--experiment", action=ActionExperiment) subparser.add_function_arguments(func, sub_configs=True) + subparsers[name] = subparser subcommands.add_subcommand(name, subparser) args = parser.parse_args() - args = parser.instantiate_classes(args) + config = parser.instantiate_classes(args)[args.command].config + config = omegaconf_resolve(config) - args[args.command].config = omegaconf_resolve(args[args.command].config) + subparsers[args.command].save( + args[args.command], + config.test.cf_path, + skip_check=True, + overwrite=args.overwrite_config_file, + ) - __subcommands[args.command](config=args[args.command].config) + __subcommands[args.command](config=config) if __name__ == "__main__": From 84d1cb6a55746f5b681f6f7c1126c22ebd3e00bb Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Fri, 12 Jan 2024 12:09:15 +0100 Subject: [PATCH 029/136] wip: feat: handle legacy config files --- fd_shifts/main.py | 102 +++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 100 insertions(+), 2 deletions(-) diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 13713d7..7baf1fc 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -4,10 +4,12 @@ from contextvars import ContextVar from dataclasses import asdict, is_dataclass from pathlib import Path -from typing import Any, Callable +from typing import Any, Callable, Optional +import jsonargparse import pytorch_lightning as pl import rich +import yaml from jsonargparse import ActionConfigFile, ArgumentParser from jsonargparse._actions import Action from omegaconf import OmegaConf @@ -88,6 +90,100 @@ def apply_experiment_config(parser: ArgumentParser, cfg, dest, value) -> None: cfg[dest] = value +class ActionLegacyConfigFile(ActionConfigFile): + """Action to indicate that an argument is a configuration file or a configuration string.""" + + def __init__(self, **kwargs): + """Initializer for ActionLegacyConfigFile instance.""" + if "default" in kwargs: + self.set_default_error() + opt_name = kwargs["option_strings"] + opt_name = ( + opt_name[0] + if len(opt_name) == 1 + else [x for x in opt_name if x[0:2] == "--"][0] + ) + if "." in opt_name: + raise ValueError("ActionLegacyConfigFile must be a top level option.") + if "help" not in kwargs: + kwargs["help"] = "Path to a configuration file." + super().__init__(**kwargs) + + def __call__(self, parser, cfg, values, option_string=None): + """Parses the given configuration and adds all the corresponding keys to the namespace. + + Raises: + TypeError: If there are problems parsing the configuration. + """ + self.apply_config(parser, cfg, self.dest, values, option_string) + + @staticmethod + def set_default_error(): + raise ValueError( + "ActionLegacyConfigFile does not accept a default, use default_config_files." + ) + + @staticmethod + def apply_config(parser, cfg, dest, value, option_string) -> None: + from jsonargparse._link_arguments import skip_apply_links + + with jsonargparse._actions._ActionSubCommands.not_single_subcommand(), previous_config_context( + cfg + ), skip_apply_links(): + kwargs = { + "env": False, + "defaults": False, + "_skip_check": True, + } + cfg_path: Optional[jsonargparse.Path] = jsonargparse.Path( + value, mode=jsonargparse._optionals.get_config_read_mode() + ) + + with cfg_path.open() as f: + cfg_from_file = yaml.unsafe_load(f) + + if option_string == "--config-file": + cfg_file = cfg_from_file + elif option_string == "--legacy-config-file": + cfg_file = {"config": cfg_from_file} + + # hydra instantiate to jsonargparse instantiate format + lr_scheduler_cfg = cfg_file["config"]["trainer"]["lr_scheduler"] + cfg_file["config"]["trainer"]["lr_scheduler"] = { + "class_path": "fd_shifts.configs.LRSchedulerConfig", + "init_args": { + "class_path": lr_scheduler_cfg["_target_"], + "init_args": { + k: v + for k, v in lr_scheduler_cfg.items() + if k not in ["_target_", "_partial_"] + }, + }, + } + optimizer_cfg = cfg_file["config"]["trainer"]["optimizer"] + cfg_file["config"]["trainer"]["optimizer"] = { + "class_path": "fd_shifts.configs.OptimizerConfig", + "init_args": { + "class_path": optimizer_cfg["_target_"], + "init_args": { + k: v + for k, v in optimizer_cfg.items() + if k not in ["_target_", "_partial_"] + }, + }, + } + else: + raise ValueError(f"Unknown option string {option_string}") + + cfg_file = parser.parse_object(cfg_file, **kwargs) + + cfg_merged = parser.merge_config(cfg_file, cfg) + cfg.__dict__.update(cfg_merged.__dict__) + if cfg.get(dest) is None: + cfg[dest] = [] + cfg[dest].append(cfg_path) + + def _path_to_str(cfg) -> dict: def __path_to_str(cfg): if isinstance(cfg, dict): @@ -330,7 +426,9 @@ def main(): for name, func in __subcommands.items(): subparser = ArgumentParser() - subparser.add_argument("--config-file", action=ActionConfigFile) + subparser.add_argument( + "--config-file", "--legacy-config-file", action=ActionLegacyConfigFile + ) subparser.add_argument("--experiment", action=ActionExperiment) subparser.add_function_arguments(func, sub_configs=True) subparsers[name] = subparser From b3f9b6a308766c453718c0c48aefa8ff7dd74a3c Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Fri, 12 Jan 2024 12:10:05 +0100 Subject: [PATCH 030/136] wip: feat: add list-experiments and --version --- fd_shifts/experiments/configs.py | 4 ++++ fd_shifts/main.py | 18 ++++++++++++++++-- 2 files changed, 20 insertions(+), 2 deletions(-) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index 04e21a3..b00385d 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -255,3 +255,7 @@ def get_data_config(name: str) -> DataConfig: def get_experiment_config(name: str) -> Config: return __experiments[name] + + +def list_experiment_configs() -> list[str]: + return list(__experiments.keys()) diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 7baf1fc..2b73c6e 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -21,11 +21,12 @@ from fd_shifts import analysis, logger from fd_shifts.configs import Config -from fd_shifts.experiments.configs import get_experiment_config +from fd_shifts.experiments.configs import get_experiment_config, list_experiment_configs from fd_shifts.loaders.data_loader import FDShiftsDataLoader from fd_shifts.models import get_model from fd_shifts.models.callbacks import get_callbacks from fd_shifts.utils import exp_utils +from fd_shifts.version import get_version __subcommands = {} @@ -416,14 +417,23 @@ def test(config: Config): ) +def _list_experiments(): + rich.print("Available experiments:") + for exp in sorted(list_experiment_configs()): + rich.print(exp) + + def main(): setup_logging() - parser = ArgumentParser() + parser = ArgumentParser(version=get_version()) parser.add_argument("-f", "--overwrite-config-file", action="store_true") subcommands = parser.add_subcommands(dest="command") subparsers: dict[str, ArgumentParser] = {} + subparser = ArgumentParser() + subcommands.add_subcommand("list-experiments", subparser) + for name, func in __subcommands.items(): subparser = ArgumentParser() subparser.add_argument( @@ -436,6 +446,10 @@ def main(): args = parser.parse_args() + if args.command == "list-experiments": + _list_experiments() + return + config = parser.instantiate_classes(args)[args.command].config config = omegaconf_resolve(config) From 8322ba33d2a3fee8813107fe6f8205f71bf25304 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 16 Jan 2024 16:29:52 +0100 Subject: [PATCH 031/136] feat(config): better defaults --- fd_shifts/configs/__init__.py | 75 +++++++++++++++++++++++------------ 1 file changed, 49 insertions(+), 26 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 274fd14..c33b458 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -94,8 +94,24 @@ class OutputPathsConfig(_IterableMixin): class OutputPathsPerMode(_IterableMixin): """Container for per-mode output paths""" - fit: OutputPathsConfig = OutputPathsConfig() - test: OutputPathsConfig = OutputPathsConfig() + fit: OutputPathsConfig = OutputPathsConfig( + raw_output=Path("${exp.version_dir}/raw_output.npz"), + raw_output_dist=Path("${exp.version_dir}/raw_output_dist.npz"), + external_confids=Path("${exp.version_dir}/external_confids.npz"), + external_confids_dist=Path("${exp.version_dir}/external_confids_dist.npz"), + input_imgs_plot=Path("${exp.dir}/input_imgs.png"), + encoded_output=None, + attributions_output=None, + ) + test: OutputPathsConfig = OutputPathsConfig( + raw_output=Path("${test.dir}/raw_logits.npz"), + raw_output_dist=Path("${test.dir}/raw_logits_dist.npz"), + external_confids=Path("${test.dir}/external_confids.npz"), + external_confids_dist=Path("${test.dir}/external_confids_dist.npz"), + input_imgs_plot=None, + encoded_output=Path("${test.dir}/encoded_output.npz"), + attributions_output=Path("${test.dir}/attributions.csv"), + ) @defer_validation @@ -103,23 +119,23 @@ class OutputPathsPerMode(_IterableMixin): class ExperimentConfig(_IterableMixin): """Main experiment config""" - group_name: str | None = None - name: str | None = None + group_name: str + name: str mode: Mode = Mode.train_test - work_dir: Path | None = Path.cwd() - fold_dir: Path | None = None + work_dir: Path = Path.cwd() + fold_dir: Path = Path("exp/${exp.fold}") root_dir: Path | None = Path(p) if (p := os.getenv("EXPERIMENT_ROOT_DIR")) else None data_root_dir: Path | None = ( Path(p) if (p := os.getenv("DATASET_ROOT_DIR")) else None ) - group_dir: Path | None = SI("${exp.root_dir}/${exp.group_name}") - dir: Path | None = group_dir / name if group_dir and name else None - version: Optional[int] = None - version_dir: Path | None = dir / f"version_{version}" if dir and version else None + group_dir: Path = Path("${exp.root_dir}/${exp.group_name}") + dir: Path = Path("${exp.group_dir}/${exp.name}") + version: int | None = None + version_dir: Path = Path("${exp.dir}/version_${exp.version}") fold: int = 0 crossval_n_folds: int = 10 - crossval_ids_path: Path | None = dir / "crossval_ids.pickle" if dir else None - log_path: Path | None = None + crossval_ids_path: Path = Path("${exp.dir}/crossval_ids.pickle") + log_path: Path = Path("log.txt") global_seed: int = randint(0, 1_000_000) output_paths: OutputPathsPerMode = OutputPathsPerMode() @@ -239,7 +255,13 @@ class TrainerConfig(_IterableMixin): lr_scheduler_interval: str = "epoch" # TODO: Replace with jsonargparse compatible type hint to lightning.Callback - callbacks: dict[str, Optional[dict[Any, Any]]] = field(default_factory=lambda: {}) + callbacks: dict[str, Optional[dict[Any, Any]]] = field( + default_factory=lambda: { + "model_checkpoint": None, + "confid_monitor": None, + "learning_rate_monitor": None, + } + ) learning_rate_confidnet: Optional[float] = None learning_rate_confidnet_finetune: Optional[float] = None @@ -405,6 +427,7 @@ class ConfidMeasuresConfig(_IterableMixin): train: list[str] = field(default_factory=lambda: ["det_mcp"]) val: list[str] = field(default_factory=lambda: ["det_mcp"]) test: list[str] = field(default_factory=lambda: ["det_mcp", "det_pe", "ext"]) + test: list[str] = field(default_factory=lambda: ["det_mcp", "det_pe"]) # pylint: disable=no-self-argument @validator("train", "val", "test", each_item=True) @@ -479,18 +502,18 @@ class TestConfig(_IterableMixin): """Inference time configuration""" name: str = "test_results" - dir: Path | None = None - cf_path: Path | None = None - selection_criterion: str | None = None - best_ckpt_path: Path | None = None - only_latest_version: bool | None = None - devries_repro_ood_split: bool | None = None - assim_ood_norm_flag: bool | None = None - iid_set_split: str | None = None - raw_output_path: str | None = None - external_confids_output_path: str | None = None - output_precision: int | None = None - selection_mode: Optional[str] = None + dir: Path = Path("${exp.dir}/${test.name}") + cf_path: Path = Path("${exp.dir}/hydra/config.yaml") + selection_criterion: str = "latest" + best_ckpt_path: Path = Path("${exp.version_dir}/${test.selection_criterion}.ckpt") + only_latest_version: bool = True + devries_repro_ood_split: bool = False + assim_ood_norm_flag: bool = False + iid_set_split: str = "devries" + raw_output_path: str = "raw_output.npz" + external_confids_output_path: str = "external_confids.npz" + output_precision: int = 16 + selection_mode: Optional[str] = "max" @defer_validation @@ -515,13 +538,13 @@ class DataConfig(_IterableMixin): class Config(_IterableMixin): """Main Configuration Class""" + exp: ExperimentConfig pkgversion: str = fd_shifts.get_version() data: DataConfig = DataConfig() trainer: TrainerConfig = TrainerConfig() - exp: ExperimentConfig = ExperimentConfig() model: ModelConfig = ModelConfig() eval: EvalConfig = EvalConfig() From 34edfec2764a0b2df05e78ae2780c731be498aac Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 16 Jan 2024 16:31:15 +0100 Subject: [PATCH 032/136] fix(config): mutable sub-objects are shared references, init as fields --- fd_shifts/configs/__init__.py | 30 +++++++++++++++++++----------- 1 file changed, 19 insertions(+), 11 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index c33b458..c1904ec 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -320,7 +320,7 @@ class ModelConfig(_IterableMixin): """Model Configuration""" name: str = "devries_model" - network: NetworkConfig = NetworkConfig() + network: NetworkConfig = field(default_factory=lambda: NetworkConfig()) fc_dim: int = 512 avg_pool: bool = True dropout_rate: int = 0 @@ -426,7 +426,6 @@ class ConfidMeasuresConfig(_IterableMixin): train: list[str] = field(default_factory=lambda: ["det_mcp"]) val: list[str] = field(default_factory=lambda: ["det_mcp"]) - test: list[str] = field(default_factory=lambda: ["det_mcp", "det_pe", "ext"]) test: list[str] = field(default_factory=lambda: ["det_mcp", "det_pe"]) # pylint: disable=no-self-argument @@ -482,10 +481,18 @@ class EvalConfig(_IterableMixin): r_star: float = 0.25 r_delta: float = 0.05 - query_studies: QueryStudiesConfig = QueryStudiesConfig() - performance_metrics: PerfMetricsConfig = PerfMetricsConfig() - confid_metrics: ConfidMetricsConfig = ConfidMetricsConfig() - confidence_measures: ConfidMeasuresConfig = ConfidMeasuresConfig() + query_studies: QueryStudiesConfig = field( + default_factory=lambda: QueryStudiesConfig() + ) + performance_metrics: PerfMetricsConfig = field( + default_factory=lambda: PerfMetricsConfig() + ) + confid_metrics: ConfidMetricsConfig = field( + default_factory=lambda: ConfidMetricsConfig() + ) + confidence_measures: ConfidMeasuresConfig = field( + default_factory=lambda: ConfidMeasuresConfig() + ) monitor_plots: list[str] = field( default_factory=lambda: [ @@ -539,16 +546,17 @@ class Config(_IterableMixin): """Main Configuration Class""" exp: ExperimentConfig + pkgversion: str = fd_shifts.get_version() - data: DataConfig = DataConfig() + data: DataConfig = field(default_factory=lambda: DataConfig()) - trainer: TrainerConfig = TrainerConfig() + trainer: TrainerConfig = field(default_factory=lambda: TrainerConfig()) - model: ModelConfig = ModelConfig() + model: ModelConfig = field(default_factory=lambda: ModelConfig()) - eval: EvalConfig = EvalConfig() - test: TestConfig = TestConfig() + eval: EvalConfig = field(default_factory=lambda: EvalConfig()) + test: TestConfig = field(default_factory=lambda: TestConfig()) def update_experiment(self, name: str): config = deepcopy(self) From 2dc9a9301e71bcb9cee22003fff41426b20c5164 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 16 Jan 2024 16:33:13 +0100 Subject: [PATCH 033/136] wip: feat(config): make query studies DataConfigs --- fd_shifts/analysis/__init__.py | 10 +++++- fd_shifts/configs/__init__.py | 6 ++-- fd_shifts/loaders/data_loader.py | 60 ++++++++++++++++++-------------- 3 files changed, 46 insertions(+), 30 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 627fa32..2634045 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -192,7 +192,9 @@ def dataset_name_to_idx(self, dataset_name: str) -> int: flat_test_set_list = [] for _, datasets in self.config.eval.query_studies: - if isinstance(datasets, (list, ListConfig)): + if isinstance(datasets, (list, ListConfig)) and len(datasets) > 0: + if isinstance(datasets[0], configs.DataConfig): + datasets = map(lambda d: d.dataset, datasets) flat_test_set_list.extend(list(datasets)) else: flat_test_set_list.append(datasets) @@ -605,6 +607,12 @@ def __init__( self.query_studies = ( self.cfg.eval.query_studies if query_studies is None else query_studies ) + for study_name, datasets in self.query_studies: + if isinstance(datasets, (list, ListConfig)) and len(datasets) > 0: + if isinstance(datasets[0], configs.DataConfig): + self.query_studies.__dict__[study_name] = list( + map(lambda d: d.dataset, datasets) + ) self.analysis_out_dir = analysis_out_dir self.calibration_bins = 20 self.val_risk_scores = {} diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index c1904ec..b850cdc 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -449,9 +449,9 @@ class QueryStudiesConfig(_IterableMixin): """Query Studies Configuration""" iid_study: str | None = None - noise_study: list[str] = field(default_factory=lambda: []) - in_class_study: list[str] = field(default_factory=lambda: []) - new_class_study: list[str] = field(default_factory=lambda: []) + noise_study: list[DataConfig] = field(default_factory=lambda: []) + in_class_study: list[DataConfig] = field(default_factory=lambda: []) + new_class_study: list[DataConfig] = field(default_factory=lambda: []) # pylint: disable=no-self-argument @validator( diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index 45c40ae..35ddf21 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -2,6 +2,8 @@ import os import pickle from copy import deepcopy +from dataclasses import asdict +from pathlib import Path import numpy as np import pytorch_lightning as pl @@ -25,9 +27,9 @@ def __init__(self, cf: configs.Config, no_norm_flag=False): self.crossval_ids_path = cf.exp.crossval_ids_path self.crossval_n_folds = cf.exp.crossval_n_folds self.fold = cf.exp.fold - self.data_dir = cf.data.data_dir - self.data_root_dir = cf.exp.data_root_dir - self.dataset_name = cf.data.dataset + self.data_dir: Path = cf.data.data_dir + self.data_root_dir: Path = cf.exp.data_root_dir + self.dataset_name: str = cf.data.dataset self.batch_size = cf.trainer.batch_size self.pin_memory = cf.data.pin_memory self.num_workers = cf.data.num_workers @@ -43,10 +45,11 @@ def __init__(self, cf: configs.Config, no_norm_flag=False): self.assim_ood_norm_flag = cf.test.assim_ood_norm_flag self.balanced_sampeling = cf.model.balanced_sampeling self.add_val_tuning = cf.eval.val_tuning - self.query_studies = dict(cf.eval.query_studies) + self.query_studies = cf.eval.query_studies + print(f"{self.query_studies=}") if self.query_studies is not None: self.external_test_sets = [] - for key, values in self.query_studies.items(): + for key, values in self.query_studies: if key != "iid_study" and values is not None: self.external_test_sets.extend(list(values)) logging.debug( @@ -55,28 +58,33 @@ def __init__(self, cf: configs.Config, no_norm_flag=False): if len(self.external_test_sets) > 0: self.external_test_configs = {} - for ext_set in self.external_test_sets: + for i, ext_set in enumerate(self.external_test_sets): overwrite_dataset = False - if ext_set.startswith("dermoscopyall"): - file_set = "dermoscopyall" - overwrite_dataset = False - elif ext_set.startswith("rxrx1all"): - file_set = "rxrx1all" - overwrite_dataset = False - elif ext_set.startswith("lidc_idriall"): - file_set = "lidc_idriall" - overwrite_dataset = False - elif ext_set.startswith("xray_chestall"): - file_set = "xray_chestall" - overwrite_dataset = False - else: - file_set = ext_set - self.external_test_configs[ext_set] = OmegaConf.load( - os.path.join( - os.path.abspath(os.path.dirname(data_configs.__file__)), - "{}_data.yaml".format(file_set), - ) - ).data + if isinstance(ext_set, str): + if ext_set.startswith("dermoscopyall"): + file_set = "dermoscopyall" + overwrite_dataset = False + elif ext_set.startswith("rxrx1all"): + file_set = "rxrx1all" + overwrite_dataset = False + elif ext_set.startswith("lidc_idriall"): + file_set = "lidc_idriall" + overwrite_dataset = False + elif ext_set.startswith("xray_chestall"): + file_set = "xray_chestall" + overwrite_dataset = False + else: + file_set = ext_set + self.external_test_configs[ext_set] = OmegaConf.load( + os.path.join( + os.path.abspath(os.path.dirname(data_configs.__file__)), + "{}_data.yaml".format(file_set), + ) + ).data + + elif isinstance(ext_set, configs.DataConfig): + self.external_test_configs[ext_set.dataset] = deepcopy(ext_set) + self.external_test_sets[i] = ext_set.dataset if overwrite_dataset: self.external_test_configs[ext_set].dataset = ext_set # set up target transforms From 5b4d390ee8ee971cb1693fbced1ab81016a23bc5 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 16 Jan 2024 16:33:58 +0100 Subject: [PATCH 034/136] fix(analysis): last_layer can be none --- fd_shifts/analysis/__init__.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 2634045..4a581df 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -107,10 +107,8 @@ def features(self) -> npt.NDArray[Any] | None: return self._features @property - def last_layer(self) -> tuple[npt.NDArray[Any], npt.NDArray[Any]]: - if self._last_layer is not None: - return self._last_layer - raise NotImplementedError("TODO: Load last layer") + def last_layer(self) -> tuple[npt.NDArray[Any], npt.NDArray[Any]] | None: + return self._last_layer @property def vim_score(self): From 3863feda26da01cc1575316c3e8184e86587e252 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 16 Jan 2024 16:34:44 +0100 Subject: [PATCH 035/136] fix(main): make list elements to dataclass if the type demands it --- fd_shifts/main.py | 32 +++++++++++++++++++++++++------- 1 file changed, 25 insertions(+), 7 deletions(-) diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 2b73c6e..e9027af 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -20,7 +20,7 @@ from rich.pretty import pretty_repr from fd_shifts import analysis, logger -from fd_shifts.configs import Config +from fd_shifts.configs import Config, TestConfig from fd_shifts.experiments.configs import get_experiment_config, list_experiment_configs from fd_shifts.loaders.data_loader import FDShiftsDataLoader from fd_shifts.models import get_model @@ -202,12 +202,15 @@ def __path_to_str(cfg): def _dict_to_dataclass(cfg) -> Config: def __dict_to_dataclass(cfg, cls): + print(f"{cls=}", cls == list) if is_dataclass(cls): fieldtypes = typing.get_type_hints(cls) return cls( **{k: __dict_to_dataclass(v, fieldtypes[k]) for k, v in cfg.items()} ) - if ( + if typing.get_origin(cls) == list: + return [__dict_to_dataclass(v, typing.get_args(cls)[0]) for v in cfg] + if cls == Path or ( isinstance(cls, types.UnionType) and Path in cls.__args__ and cfg is not None @@ -423,9 +426,7 @@ def _list_experiments(): rich.print(exp) -def main(): - setup_logging() - +def get_parser(): parser = ArgumentParser(version=get_version()) parser.add_argument("-f", "--overwrite-config-file", action="store_true") subcommands = parser.add_subcommands(dest="command") @@ -444,15 +445,32 @@ def main(): subparsers[name] = subparser subcommands.add_subcommand(name, subparser) + return parser, subparsers + + +def config_from_parser(parser, args): + config = parser.instantiate_classes(args)[args.command].config + config = omegaconf_resolve(config) + return config + + +def main(): + setup_logging() + + parser, subparsers = get_parser() + args = parser.parse_args() if args.command == "list-experiments": _list_experiments() return - config = parser.instantiate_classes(args)[args.command].config - config = omegaconf_resolve(config) + config = config_from_parser(parser, args) + + rich.print(config) + # TODO: Check if configs are the same + config.test.cf_path.parent.mkdir(parents=True, exist_ok=True) subparsers[args.command].save( args[args.command], config.test.cf_path, From d1a36326d64d88fcdf0358403b015bd3d85dd95e Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 16 Jan 2024 16:40:06 +0100 Subject: [PATCH 036/136] wip: feat(config): add some experiment configs --- fd_shifts/experiments/configs.py | 512 ++++++++++++++++++------------- 1 file changed, 304 insertions(+), 208 deletions(-) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index b00385d..046011c 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -1,11 +1,6 @@ -import importlib -import os -from dataclasses import dataclass from pathlib import Path -from typing import Iterable +from typing import Callable, Literal -import pl_bolts -import torch from omegaconf import SI from fd_shifts.configs import ( @@ -29,228 +24,329 @@ ValSplit, ) -__data_configs = {} - -__data_configs["svhn_384"] = DataConfig( - dataset="svhn", - data_dir=SI("${oc.env:DATASET_ROOT_DIR}/svhn"), - pin_memory=True, - img_size=(384, 384, 3), - num_workers=24, - num_classes=10, - reproduce_confidnet_splits=True, - augmentations={ - "train": { - "to_tensor": None, - "resize": 384, - "normalize": [ - [0.4376821, 0.4437697, 0.47280442], - [0.19803012, 0.20101562, 0.19703614], - ], - }, - "val": { - "to_tensor": None, - "resize": 384, - "normalize": [ - [0.4376821, 0.4437697, 0.47280442], - [0.19803012, 0.20101562, 0.19703614], - ], + +def svhn_data_config( + dataset: Literal["svhn", "svhn_openset"], img_size: int | tuple[int, int] +) -> DataConfig: + augmentations = { + "to_tensor": None, + "resize": img_size, + "normalize": [ + [0.4376821, 0.4437697, 0.47280442], + [0.19803012, 0.20101562, 0.19703614], + ], + } + + if isinstance(img_size, int): + img_size = (img_size, img_size) + + return DataConfig( + dataset="svhn" + + ("_384" if img_size[0] == 384 else "") + + ("_openset" if dataset == "svhn_openset" else ""), + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/svhn"), + pin_memory=True, + img_size=(img_size[0], img_size[1], 3), + num_workers=12, + num_classes=10, + reproduce_confidnet_splits=True, + augmentations={ + "train": augmentations, + "val": augmentations, + "test": augmentations, }, - "test": { - "to_tensor": None, - "resize": 384, - "normalize": [ - [0.4376821, 0.4437697, 0.47280442], - [0.19803012, 0.20101562, 0.19703614], - ], + target_transforms=None, + kwargs=None, + ) + + +def svhn_query_config( + dataset: Literal["svhn", "svhn_openset"], img_size: int | tuple[int, int] +) -> QueryStudiesConfig: + return QueryStudiesConfig( + iid_study="svhn_384", + noise_study=[], + in_class_study=[], + new_class_study=[ + cifar10_data_config(img_size) + ], # , "cifar100_384", "tinyimagenet_384"], + ) + + +def cifar10_data_config(img_size: int | tuple[int, int]) -> DataConfig: + augmentations = { + "to_tensor": None, + "resize": img_size, + "normalize": [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.201]], + } + + if isinstance(img_size, int): + img_size = (img_size, img_size) + + return DataConfig( + dataset="cifar10" + ("_384" if img_size[0] == 384 else ""), + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/cifar10"), + pin_memory=True, + img_size=(img_size[0], img_size[1], 3), + num_workers=12, + num_classes=10, + reproduce_confidnet_splits=True, + augmentations={ + "train": augmentations, + "val": augmentations, + "test": augmentations, }, - }, - target_transforms=None, - kwargs=None, -) + target_transforms=None, + kwargs=None, + ) -def get_data_config(name: str) -> DataConfig: - return __data_configs[name] - - -__experiments = {} - -__experiments["svhn_modeldg_bbvit_lr0.01_bs128_run4_do1_rew10"] = Config( - data=get_data_config("svhn_384"), - trainer=TrainerConfig( - val_every_n_epoch=5, - do_val=True, - batch_size=128, - resume_from_ckpt=False, - benchmark=True, - fast_dev_run=False, - lr_scheduler=LRSchedulerConfig( - { - "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", - "init_args": { - "warmup_epochs": 500, - "max_epochs": 60000, - "warmup_start_lr": 0.0, - "eta_min": 0.0, - "last_epoch": -1, - }, - } +__experiments: dict[str, Config] = {} + + +def svhn_modelvit_bbvit(lr: float, run: int, do: int, **kwargs) -> Config: + return Config( + exp=ExperimentConfig( + group_name="vit", + name=f"svhn_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", ), - optimizer=OptimizerConfig( - { - "class_path": "torch.optim.SGD", - "init_args": { - "lr": 0.01, - "dampening": 0.0, - "momentum": 0.9, - "nesterov": False, - "maximize": False, - "weight_decay": 0.0, + pkgversion="0.0.1+f85760e", + data=svhn_data_config("svhn", 384), + trainer=TrainerConfig( + num_epochs=None, + num_steps=40000, + batch_size=128, + lr_scheduler=LRSchedulerConfig( + init_args={ + "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", + "init_args": { + "warmup_epochs": 500, + "warmup_start_lr": 0, + "eta_min": 0, + "max_epochs": 40000, + }, }, - } - ), - accumulate_grad_batches=1, - resume_from_ckpt_confidnet=False, - num_epochs=None, - num_steps=60000, - num_epochs_backbone=None, - dg_pretrain_epochs=None, - dg_pretrain_steps=20000, - val_split=ValSplit.devries, - lr_scheduler_interval="step", - callbacks={ - "model_checkpoint": None, - "confid_monitor": None, - "learning_rate_monitor": None, - }, - learning_rate_confidnet=None, - learning_rate_confidnet_finetune=None, - ), - exp=ExperimentConfig( - group_name="vit", - name="svhn_modeldg_bbvit_lr0.01_bs128_run4_do1_rew10", - mode=Mode.analysis, - work_dir=Path.cwd(), - fold_dir=SI("exp/${exp.fold}"), - root_dir=Path(p) - if (p := os.getenv("EXPERIMENT_ROOT_DIR")) is not None - else None, - data_root_dir=Path(p) - if (p := os.getenv("DATASET_ROOT_DIR")) is not None - else None, - group_dir=Path("${exp.root_dir}/${exp.group_name}"), - dir=Path("${exp.group_dir}/${exp.name}"), - version_dir=Path("${exp.dir}/version_${exp.version}"), - fold=0, - crossval_n_folds=10, - crossval_ids_path=Path("${exp.dir}/crossval_ids.pickle"), - log_path=Path("log.txt"), - global_seed=0, - output_paths=OutputPathsPerMode( - fit=OutputPathsConfig( - raw_output=Path("${exp.version_dir}/raw_output.npz"), - raw_output_dist=Path("${exp.version_dir}/raw_output_dist.npz"), - external_confids=Path("${exp.version_dir}/external_confids.npz"), - external_confids_dist=Path( - "${exp.version_dir}/external_confids_dist.npz" - ), - input_imgs_plot=Path("${exp.dir}/input_imgs.png"), - encoded_output=None, - attributions_output=None, + class_path="fd_shifts.configs.LRSchedulerConfig", + ), + optimizer=OptimizerConfig( + init_args={ + "class_path": "torch.optim.SGD", + "init_args": { + "lr": 0.01, + "dampening": 0.0, + "momentum": 0.9, + "nesterov": False, + "maximize": False, + "weight_decay": 0.0, + }, + }, + class_path="fd_shifts.configs.OptimizerConfig", ), - test=OutputPathsConfig( - raw_output=Path("${test.dir}/raw_logits.npz"), - raw_output_dist=Path("${test.dir}/raw_logits_dist.npz"), - external_confids=Path("${test.dir}/external_confids.npz"), - external_confids_dist=Path("${test.dir}/external_confids_dist.npz"), - input_imgs_plot=None, - encoded_output=Path("${test.dir}/encoded_output.npz"), - attributions_output=Path("${test.dir}/attributions.csv"), + lr_scheduler_interval="epoch", + ), + model=ModelConfig( + name="vit_model", + network=NetworkConfig( + name="vit", ), + fc_dim=512, + avg_pool=True, + dropout_rate=0, + ), + eval=EvalConfig( + val_tuning=True, + query_studies=svhn_query_config("svhn", 384), ), - version=None, - ), - model=ModelConfig( + ) + + +def svhn_modeldg_bbvit(lr: float, run: int, do: int, rew: int | float) -> Config: + config = svhn_modelvit_bbvit(lr=lr, run=run, do=do) + config.trainer.num_steps = 60000 + config.trainer.lr_scheduler = LRSchedulerConfig( + { + "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", + "init_args": { + "warmup_epochs": 500, + "max_epochs": 60000, + "warmup_start_lr": 0.0, + "eta_min": 0.0, + "last_epoch": -1, + }, + } + ) + config.trainer.optimizer = OptimizerConfig( + { + "class_path": "torch.optim.SGD", + "init_args": { + "lr": lr, + "dampening": 0.0, + "momentum": 0.9, + "nesterov": False, + "maximize": False, + "weight_decay": 0.0, + }, + } + ) + config.trainer.dg_pretrain_epochs = None + config.trainer.dg_pretrain_steps = 20000 + config.trainer.lr_scheduler_interval = "step" + config.exp.name = f"svhn_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}" + config.model = ModelConfig( name="devries_model", network=NetworkConfig( name="vit", - backbone=None, - imagenet_weights_path=None, - load_dg_backbone_path=None, save_dg_backbone_path=Path("${exp.dir}/dg_backbone.ckpt"), ), fc_dim=768, avg_pool=True, dropout_rate=1, - monitor_mcd_samples=50, - test_mcd_samples=50, - confidnet_fc_dim=None, - dg_reward=10, - balanced_sampeling=False, - budget=0.3, - ), - eval=EvalConfig( - tb_hparams=["fold"], - test_conf_scaling=False, - val_tuning=True, - r_star=0.25, - r_delta=0.05, - query_studies=QueryStudiesConfig( - iid_study="svhn_384", - noise_study=[], - in_class_study=[], - new_class_study=["cifar10_384", "cifar100_384", "tinyimagenet_384"], + dg_reward=rew, + ) + config.eval.ext_confid_name = "dg" + config.eval.confidence_measures.test.append("ext") + + return config + + +def cifar10_modelvit_bbvit(lr: float, run: int, do: Literal[0, 1], **kwargs) -> Config: + return Config( + exp=ExperimentConfig( + group_name="vit", + name=f"cifar10_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", ), - performance_metrics=PerfMetricsConfig( - train=["loss", "nll", "accuracy"], - val=["loss", "nll", "accuracy", "brier_score"], - test=["nll", "accuracy", "brier_score"], + data=cifar10_data_config(384), + trainer=TrainerConfig( + num_epochs=None, + num_steps=40000, + batch_size=128, + lr_scheduler=LRSchedulerConfig( + init_args={ + "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", + "init_args": { + "warmup_epochs": 500, + "warmup_start_lr": 0, + "eta_min": 0, + "max_epochs": 40000, + }, + }, + class_path="fd_shifts.configs.LRSchedulerConfig", + ), + optimizer=OptimizerConfig( + init_args={ + "class_path": "torch.optim.SGD", + "init_args": { + "lr": lr, + "dampening": 0.0, + "momentum": 0.9, + "nesterov": False, + "maximize": False, + "weight_decay": 0.0, + }, + }, + class_path="fd_shifts.configs.OptimizerConfig", + ), ), - confid_metrics=ConfidMetricsConfig( - train=[ - "failauc", - "failap_suc", - "failap_err", - "fpr@95tpr", - "e-aurc", - "aurc", - ], - val=["failauc", "failap_suc", "failap_err", "fpr@95tpr", "e-aurc", "aurc"], - test=[ - "failauc", - "failap_suc", - "failap_err", - "mce", - "ece", - "b-aurc", - "e-aurc", - "aurc", - "fpr@95tpr", - ], + model=ModelConfig( + name="vit_model", + network=NetworkConfig( + name="vit", + ), + fc_dim=512, + avg_pool=True, + dropout_rate=do, ), - confidence_measures=ConfidMeasuresConfig( - train=["det_mcp"], val=["det_mcp"], test=["det_mcp", "det_pe", "ext"] + eval=EvalConfig( + query_studies=QueryStudiesConfig( + iid_study="cifar10_384", + noise_study=["corrupt_cifar10_384"], + in_class_study=[], + new_class_study=["cifar100_384", "svhn_384", "tinyimagenet_384"], + ), + ext_confid_name="maha", ), - monitor_plots=["hist_per_confid"], - ext_confid_name="dg", - ), - test=TestConfig( - name="test_results", - dir=Path("${exp.dir}/${test.name}"), - cf_path=Path("${exp.dir}/hydra/config.yaml"), - selection_criterion="latest", - best_ckpt_path=Path("${exp.version_dir}/${test.selection_criterion}.ckpt"), - only_latest_version=True, - devries_repro_ood_split=False, - assim_ood_norm_flag=False, - iid_set_split="devries", - raw_output_path="raw_output.npz", - external_confids_output_path="external_confids.npz", - output_precision=16, - selection_mode="max", - ), -) + ) + + +def cifar10_modeldg_bbvit( + lr: float, run: int, do: Literal[0, 1], rew: int | float +) -> Config: + config = cifar10_modelvit_bbvit(lr=lr, run=run, do=do) + config.trainer.num_steps = 60000 + config.trainer.lr_scheduler = LRSchedulerConfig( + { + "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", + "init_args": { + "warmup_epochs": 500, + "max_epochs": 60000, + "warmup_start_lr": 0.0, + "eta_min": 0.0, + "last_epoch": -1, + }, + } + ) + config.trainer.optimizer = OptimizerConfig( + { + "class_path": "torch.optim.SGD", + "init_args": { + "lr": lr, + "dampening": 0.0, + "momentum": 0.9, + "nesterov": False, + "maximize": False, + "weight_decay": 0.0, + }, + } + ) + config.trainer.dg_pretrain_epochs = None + config.trainer.dg_pretrain_steps = 20000 + config.trainer.lr_scheduler_interval = "step" + config.exp.name = f"cifar10_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}" + config.model = ModelConfig( + name="devries_model", + network=NetworkConfig( + name="vit", + save_dg_backbone_path=Path("${exp.dir}/dg_backbone.ckpt"), + ), + fc_dim=768, + avg_pool=True, + dropout_rate=1, + dg_reward=rew, + ) + config.eval.ext_confid_name = "dg" + config.eval.confidence_measures.test.append("ext") + + return config + + +def register(config_fn: Callable[..., Config], n_runs: int = 5, **kwargs): + for run in range(n_runs): + config = config_fn(**kwargs, run=run) + __experiments[config.exp.name] = config + + +register(svhn_modelvit_bbvit, lr=0.03, do=1, rew=2.2) +register(svhn_modelvit_bbvit, lr=0.01, do=0, rew=2.2) +register(svhn_modelvit_bbvit, lr=0.01, do=1, rew=2.2) +register(svhn_modeldg_bbvit, lr=0.01, do=1, rew=2.2) +register(svhn_modeldg_bbvit, lr=0.01, do=1, rew=3) +register(svhn_modeldg_bbvit, lr=0.01, do=1, rew=6) +register(svhn_modeldg_bbvit, lr=0.01, do=1, rew=10) +register(svhn_modeldg_bbvit, lr=0.03, do=1, rew=2.2) +register(svhn_modeldg_bbvit, lr=0.03, do=1, rew=3) +register(svhn_modeldg_bbvit, lr=0.03, do=1, rew=6) +register(svhn_modeldg_bbvit, lr=0.03, do=1, rew=10) + +register(cifar10_modelvit_bbvit, lr=3e-4, do=0, rew=2.2) +register(cifar10_modelvit_bbvit, lr=0.01, do=1, rew=2.2) +register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=2.2) +register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=2.2) +register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=3) +register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=3) +register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=6) +register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=6) +register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=10) +register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=10) def get_experiment_config(name: str) -> Config: @@ -258,4 +354,4 @@ def get_experiment_config(name: str) -> Config: def list_experiment_configs() -> list[str]: - return list(__experiments.keys()) + return list(sorted(__experiments.keys())) From 4fa9a3ff781b9589fef48dec24742bca11c6f87f Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 17 Jan 2024 13:36:48 +0100 Subject: [PATCH 037/136] fix(analysis): don't add empty lists do flat dataset list --- fd_shifts/analysis/__init__.py | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 4a581df..4f8fed1 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -190,13 +190,16 @@ def dataset_name_to_idx(self, dataset_name: str) -> int: flat_test_set_list = [] for _, datasets in self.config.eval.query_studies: - if isinstance(datasets, (list, ListConfig)) and len(datasets) > 0: - if isinstance(datasets[0], configs.DataConfig): - datasets = map(lambda d: d.dataset, datasets) - flat_test_set_list.extend(list(datasets)) + if isinstance(datasets, (list, ListConfig)): + if len(datasets) > 0: + if isinstance(datasets[0], configs.DataConfig): + datasets = map(lambda d: d.dataset, datasets) + flat_test_set_list.extend(list(datasets)) else: flat_test_set_list.append(datasets) + logger.error(f"{flat_test_set_list=}") + dataset_idx = flat_test_set_list.index(dataset_name) if self.config.eval.val_tuning: From a7ca82af7c20de1ad94a4a25e478291de0265f23 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 17 Jan 2024 13:37:30 +0100 Subject: [PATCH 038/136] fix(data): query_studies does not support in operator --- fd_shifts/loaders/data_loader.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index 35ddf21..66d21b1 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -250,9 +250,7 @@ def setup(self, stage=None): "Adding tuning data. (preliminary) len: %s", len(self.test_datasets[-1]) ) - if not ( - self.query_studies is not None and "iid_study" not in self.query_studies - ): + if self.query_studies is None or self.query_studies.iid_study is not None: self.test_datasets.append(self.iid_test_set) logging.debug( "Adding internal test dataset. %s", len(self.test_datasets[-1]) From 313def5170f4a0e77df3a3860dc1dde215e2560d Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 17 Jan 2024 13:38:23 +0100 Subject: [PATCH 039/136] feat: make clip class prefix configurable --- fd_shifts/configs/__init__.py | 1 + fd_shifts/models/clip_model.py | 21 +-------------------- 2 files changed, 2 insertions(+), 20 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index b850cdc..4a7c7c1 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -330,6 +330,7 @@ class ModelConfig(_IterableMixin): dg_reward: Optional[float] = None balanced_sampeling: bool = False budget: float = 0.3 + clip_class_prefix: Optional[str] = None # pylint: disable=no-self-argument @validator("name") diff --git a/fd_shifts/models/clip_model.py b/fd_shifts/models/clip_model.py index aec98b5..7a6c794 100644 --- a/fd_shifts/models/clip_model.py +++ b/fd_shifts/models/clip_model.py @@ -5,7 +5,6 @@ import open_clip as oc import pytorch_lightning as pl -from torchmetrics import Accuracy from torchvision import transforms from fd_shifts import logger @@ -21,20 +20,13 @@ def __init__(self, cfg: configs.Config): self.save_hyperparameters(to_dict(cfg)) self.conf = cfg - self.class_prefix = None + self.class_prefix = cfg.model.clip_class_prefix self.model, _, self.preprocess = oc.create_model_and_transforms( "ViT-B-16", pretrained="laion2b_s34b_b88k", ) self.tokenizer = oc.get_tokenizer("ViT-B-16") - # example for directly logging metrics - # self.accuracy = Accuracy( - # task="multiclass", - # num_classes=self.conf.data.num_classes, - # validate_args=False, - # ) - def on_test_start(self): self.datasets = list( map(lambda d: d.dataset, self.trainer.datamodule.test_dataloader()) @@ -56,23 +48,12 @@ def on_test_start(self): def test_step(self, batch, batch_idx, dataset_idx): x, y = batch - x = transforms.functional.resize(x, 224) image_features = self.model.encode_image(x) image_features /= image_features.norm(dim=-1, keepdim=True) logits = image_features @ self.text_features.T - # example for directly logging metrics - # text_probs = torch.softmax(logits, dim=-1) - # preds = torch.argmax(text_probs, dim=-1) - # self.accuracy(preds, y) - # self.log( - # f"accuracy", - # self.accuracy, - # ) - - # only set this if you want to write this to disk, complains if test_results exists and is anything but a dict with these keys self.test_results = { "logits": logits, "logits_dist": None, From 83ef05e6f41e4a6c6d4b6814440b60c2a1666fd4 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 17 Jan 2024 13:39:27 +0100 Subject: [PATCH 040/136] feat(config): add clip configs for svhn and cifar --- fd_shifts/experiments/configs.py | 88 ++++++++++++++++++++++++++++---- 1 file changed, 78 insertions(+), 10 deletions(-) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index 046011c..aac4417 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -64,12 +64,13 @@ def svhn_query_config( dataset: Literal["svhn", "svhn_openset"], img_size: int | tuple[int, int] ) -> QueryStudiesConfig: return QueryStudiesConfig( - iid_study="svhn_384", + iid_study="svhn", noise_study=[], in_class_study=[], new_class_study=[ - cifar10_data_config(img_size) - ], # , "cifar100_384", "tinyimagenet_384"], + cifar10_data_config(img_size), + cifar100_data_config(img_size), + ], # , "tinyimagenet_384"], ) @@ -101,6 +102,46 @@ def cifar10_data_config(img_size: int | tuple[int, int]) -> DataConfig: ) +def cifar10_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: + return QueryStudiesConfig( + iid_study="cifar10", + noise_study=[], + in_class_study=[], + new_class_study=[ + cifar100_data_config(img_size), + svhn_data_config("svhn", img_size), + ], # , "tinyimagenet_384"], + ) + + +def cifar100_data_config(img_size: int | tuple[int, int]) -> DataConfig: + augmentations = { + "to_tensor": None, + "resize": img_size, + "normalize": [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.201]], + } + + if isinstance(img_size, int): + img_size = (img_size, img_size) + + return DataConfig( + dataset="cifar100" + ("_384" if img_size[0] == 384 else ""), + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/cifar100"), + pin_memory=True, + img_size=(img_size[0], img_size[1], 3), + num_workers=12, + num_classes=100, + reproduce_confidnet_splits=True, + augmentations={ + "train": augmentations, + "val": augmentations, + "test": augmentations, + }, + target_transforms=None, + kwargs=None, + ) + + __experiments: dict[str, Config] = {} @@ -257,13 +298,7 @@ def cifar10_modelvit_bbvit(lr: float, run: int, do: Literal[0, 1], **kwargs) -> dropout_rate=do, ), eval=EvalConfig( - query_studies=QueryStudiesConfig( - iid_study="cifar10_384", - noise_study=["corrupt_cifar10_384"], - in_class_study=[], - new_class_study=["cifar100_384", "svhn_384", "tinyimagenet_384"], - ), - ext_confid_name="maha", + query_studies=cifar10_query_config(384), ), ) @@ -319,6 +354,25 @@ def cifar10_modeldg_bbvit( return config +def clip(dataset: DataConfig, class_prefix: str | None = None, **kwargs): + return Config( + data=dataset, + exp=ExperimentConfig( + group_name="clip", + name=f"{dataset.dataset}_modelclip_prefix{class_prefix.replace(' ', '-') if class_prefix else ''}", + ), + model=ModelConfig( + name="clip_model", + clip_class_prefix=class_prefix, + ), + eval=EvalConfig( + query_studies=svhn_query_config("svhn", 224) + if "svhn" == dataset.dataset + else cifar10_query_config(224), + ), + ) + + def register(config_fn: Callable[..., Config], n_runs: int = 5, **kwargs): for run in range(n_runs): config = config_fn(**kwargs, run=run) @@ -348,6 +402,20 @@ def register(config_fn: Callable[..., Config], n_runs: int = 5, **kwargs): register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=10) register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=10) +register(clip, n_runs=1, dataset=cifar10_data_config(img_size=224), class_prefix=None) +register(clip, n_runs=1, dataset=cifar10_data_config(img_size=224), class_prefix="a") +register( + clip, + n_runs=1, + dataset=cifar10_data_config(img_size=224), + class_prefix="a picture of a", +) +register(clip, n_runs=1, dataset=svhn_data_config("svhn", 224), class_prefix=None) +register(clip, n_runs=1, dataset=svhn_data_config("svhn", 224), class_prefix="a") +register( + clip, n_runs=1, dataset=svhn_data_config("svhn", 224), class_prefix="a picture of a" +) + def get_experiment_config(name: str) -> Config: return __experiments[name] From 686f8dd67f7bb456d44d108e9a43c423133ef307 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 18 Jan 2024 14:28:27 +0100 Subject: [PATCH 041/136] fix(data): data dir is already a path --- fd_shifts/loaders/data_loader.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index 66d21b1..80aa22a 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -261,9 +261,7 @@ def setup(self, stage=None): logging.debug("Adding external test dataset: %s", ext_set) tmp_external_set = get_dataset( name=ext_set, - root=os.path.join( - self.data_root_dir, self.external_test_configs[ext_set].dataset - ), + root=self.external_test_configs[ext_set].data_dir, train=False, download=True, target_transform=self.target_transforms, From a34ed759ac562fcb287b2081018153b005fbfba2 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 18 Jan 2024 14:29:02 +0100 Subject: [PATCH 042/136] feat(config): add new iwildcam and breeds clip experiments --- fd_shifts/experiments/configs.py | 178 ++++++++++++++++++++++-- fd_shifts/loaders/dataset_collection.py | 8 ++ 2 files changed, 177 insertions(+), 9 deletions(-) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index aac4417..281c50f 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -142,6 +142,92 @@ def cifar100_data_config(img_size: int | tuple[int, int]) -> DataConfig: ) +def wilds_animals_data_config( + dataset: Literal["wilds_animals", "wilds_animals_ood_test"] = "wilds_animals", + img_size: int | tuple[int, int] = 448, +) -> DataConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + + augmentations = { + "to_tensor": None, + "resize": img_size, + "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], + } + + return DataConfig( + dataset=dataset, + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/wilds_animals"), + pin_memory=True, + img_size=(img_size[0], img_size[1], 3), + num_workers=8, + num_classes=182, + reproduce_confidnet_splits=False, + augmentations={ + "train": augmentations, + "val": augmentations, + "test": augmentations, + }, + target_transforms=None, + kwargs=None, + ) + + +def wilds_animals_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: + return QueryStudiesConfig( + iid_study="wilds_animals", + noise_study=[], + in_class_study=[wilds_animals_data_config("wilds_animals_ood_test", img_size)], + new_class_study=[], + ) + + +def breeds_data_config( + dataset: Literal["breeds", "breeds_ood_test"] = "breeds", + img_size: int | tuple[int, int] = 224, +) -> DataConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + + return DataConfig( + dataset=dataset, + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/breeds"), + img_size=(img_size[0], img_size[1], 3), + num_classes=13, + augmentations={ + "train": { + "randomresized_crop": img_size, + "hflip": True, + "color_jitter": [0.1, 0.1, 0.1], + "to_tensor": None, + "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], + }, + "val": { + "resize": 256 if img_size[0] == 224 else img_size, + "center_crop": img_size, + "to_tensor": None, + "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], + }, + "test": { + "resize": 256 if img_size[0] == 224 else img_size, + "center_crop": img_size, + "to_tensor": None, + "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], + }, + }, + kwargs={"info_dir_path": "loaders/breeds_hierarchies"}, + ) + + +def breeds_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: + return QueryStudiesConfig( + iid_study="breeds", + noise_study=[], + in_class_study=[breeds_data_config("breeds_ood_test", img_size)], + new_class_study=[], + ) + + __experiments: dict[str, Config] = {} @@ -354,7 +440,12 @@ def cifar10_modeldg_bbvit( return config -def clip(dataset: DataConfig, class_prefix: str | None = None, **kwargs): +def clip( + dataset: DataConfig, + query_studies: QueryStudiesConfig, + class_prefix: str | None = None, + **kwargs, +): return Config( data=dataset, exp=ExperimentConfig( @@ -366,9 +457,7 @@ def clip(dataset: DataConfig, class_prefix: str | None = None, **kwargs): clip_class_prefix=class_prefix, ), eval=EvalConfig( - query_studies=svhn_query_config("svhn", 224) - if "svhn" == dataset.dataset - else cifar10_query_config(224), + query_studies=query_studies, ), ) @@ -402,18 +491,89 @@ def register(config_fn: Callable[..., Config], n_runs: int = 5, **kwargs): register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=10) register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=10) -register(clip, n_runs=1, dataset=cifar10_data_config(img_size=224), class_prefix=None) -register(clip, n_runs=1, dataset=cifar10_data_config(img_size=224), class_prefix="a") register( clip, n_runs=1, dataset=cifar10_data_config(img_size=224), + query_studies=cifar10_query_config(224), + class_prefix=None, +) +register( + clip, + n_runs=1, + dataset=cifar10_data_config(img_size=224), + query_studies=cifar10_query_config(224), + class_prefix="a", +) +register( + clip, + n_runs=1, + dataset=cifar10_data_config(img_size=224), + query_studies=cifar10_query_config(224), + class_prefix="a picture of a", +) +register( + clip, + n_runs=1, + dataset=svhn_data_config("svhn", 224), + query_studies=svhn_query_config("svhn", 224), + class_prefix=None, +) +register( + clip, + n_runs=1, + dataset=svhn_data_config("svhn", 224), + query_studies=svhn_query_config("svhn", 224), + class_prefix="a", +) +register( + clip, + n_runs=1, + dataset=svhn_data_config("svhn", 224), + query_studies=svhn_query_config("svhn", 224), + class_prefix="a picture of a", +) +register( + clip, + n_runs=1, + dataset=wilds_animals_data_config("wilds_animals", 224), + query_studies=wilds_animals_query_config(224), + class_prefix=None, +) +register( + clip, + n_runs=1, + dataset=wilds_animals_data_config("wilds_animals", 224), + query_studies=wilds_animals_query_config(224), + class_prefix="a", +) +register( + clip, + n_runs=1, + dataset=wilds_animals_data_config("wilds_animals", 224), + query_studies=wilds_animals_query_config(224), class_prefix="a picture of a", ) -register(clip, n_runs=1, dataset=svhn_data_config("svhn", 224), class_prefix=None) -register(clip, n_runs=1, dataset=svhn_data_config("svhn", 224), class_prefix="a") register( - clip, n_runs=1, dataset=svhn_data_config("svhn", 224), class_prefix="a picture of a" + clip, + n_runs=1, + dataset=breeds_data_config("breeds", 224), + query_studies=breeds_query_config(224), + class_prefix=None, +) +register( + clip, + n_runs=1, + dataset=breeds_data_config("breeds", 224), + query_studies=breeds_query_config(224), + class_prefix="a", +) +register( + clip, + n_runs=1, + dataset=breeds_data_config("breeds", 224), + query_studies=breeds_query_config(224), + class_prefix="a picture of a", ) diff --git a/fd_shifts/loaders/dataset_collection.py b/fd_shifts/loaders/dataset_collection.py index 1114545..0239552 100644 --- a/fd_shifts/loaders/dataset_collection.py +++ b/fd_shifts/loaders/dataset_collection.py @@ -963,6 +963,13 @@ def __init__(self, root, train, download, transform): ) logger.debug("CHECK ROOT !!! {}", root) + categories = { + r[1]: r[2] + for r in pd.read_csv(root / "iwildcam_v2.0" / "categories.csv")[ + ["y", "name"] + ].to_records() + } + self.classes = [categories[i] for i in range(self.n_classes)] def get_subset(self, split, frac=1.0, transform=None): """ @@ -990,6 +997,7 @@ def get_subset(self, split, frac=1.0, transform=None): class myWILDSSubset(WILDSSubset): def __init__(self, dataset, indices, transform): super().__init__(dataset, indices, transform) + self.classes = dataset.classes def __getitem__(self, idx): x, y, metadata = self.dataset[self.indices[idx]] From 64648b0c3c3c3043a56ee9f77780135113535284 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 18 Jan 2024 14:30:04 +0100 Subject: [PATCH 043/136] fix(main): also turn paths in lists into str for omegaconf --- fd_shifts/main.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fd_shifts/main.py b/fd_shifts/main.py index e9027af..ddc69a3 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -193,6 +193,8 @@ def __path_to_str(cfg): return cfg.__class__( **{k: __path_to_str(v) for k, v in cfg.__dict__.items()} ) + if isinstance(cfg, list): + return [__path_to_str(v) for v in cfg] if isinstance(cfg, Path): return str(cfg) return cfg @@ -202,7 +204,6 @@ def __path_to_str(cfg): def _dict_to_dataclass(cfg) -> Config: def __dict_to_dataclass(cfg, cls): - print(f"{cls=}", cls == list) if is_dataclass(cls): fieldtypes = typing.get_type_hints(cls) return cls( From aab058c8df9629df69184f9364de460773e4cc58 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 18 Jan 2024 14:30:55 +0100 Subject: [PATCH 044/136] feat(config): some default values for dataconfig --- fd_shifts/configs/__init__.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 4a7c7c1..02e80b0 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -531,11 +531,11 @@ class DataConfig(_IterableMixin): dataset: str | None = None data_dir: Path | None = None - pin_memory: bool | None = None + pin_memory: bool = True img_size: tuple[int, int, int] | None = None - num_workers: int | None = None + num_workers: int = 12 num_classes: int | None = None - reproduce_confidnet_splits: bool | None = None + reproduce_confidnet_splits: bool = False augmentations: dict[str, dict[str, Any]] | None = None target_transforms: Optional[Any] = None kwargs: Optional[dict[Any, Any]] = None From 47f59544711473cb4a10f94fb89d61c2241e8193 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 31 Jan 2024 17:27:08 +0100 Subject: [PATCH 045/136] test: skip broken tests and try to fix working tests in ci --- .gitlab-ci.yml | 4 ++++ fd_shifts/tests/test_config.py | 2 ++ fd_shifts/tests/test_experiment_integration.py | 1 + fd_shifts/tests/test_register_model.py | 1 + fd_shifts/tests/test_reproducible.py | 3 +++ 5 files changed, 11 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index a95c126..0fd2404 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -12,10 +12,14 @@ image: "python:3.10" test:package: stage: test + tags: + - fd-shifts before_script: - python --version + - pip install -U pip wheel - pip install .[dev] script: + - python -c 'import numpy as np; print(np.version.full_version)' - python -m pytest -W ignore -m "not slow" test:notebooks: diff --git a/fd_shifts/tests/test_config.py b/fd_shifts/tests/test_config.py index 2368879..4958c6d 100644 --- a/fd_shifts/tests/test_config.py +++ b/fd_shifts/tests/test_config.py @@ -30,6 +30,7 @@ def to_dict(obj): return json.loads(json.dumps(obj, default=lambda o: getattr(o, "__dict__", str(o)))) +@pytest.mark.skip("TODO: not compatible with new configs yet") def test_api_and_main_same(mock_env_if_missing) -> None: study = "deepgamblers" data = "svhn" @@ -65,6 +66,7 @@ def test_api_and_main_same(mock_env_if_missing) -> None: ms_experiments = {str(exp.to_path()): exp for exp in get_ms_experiments()} +@pytest.mark.skip("TODO: not compatible with new configs yet") @pytest.mark.slow @pytest.mark.parametrize( "exp_name", diff --git a/fd_shifts/tests/test_experiment_integration.py b/fd_shifts/tests/test_experiment_integration.py index 774b8d6..6f394af 100644 --- a/fd_shifts/tests/test_experiment_integration.py +++ b/fd_shifts/tests/test_experiment_integration.py @@ -23,6 +23,7 @@ def _update_overrides_fast(overrides: dict[str, Any]) -> dict[str, Any]: return overrides +@pytest.mark.skip("TODO: not compatible with new configs yet") @pytest.mark.slow @pytest.mark.parametrize( "exp_name", diff --git a/fd_shifts/tests/test_register_model.py b/fd_shifts/tests/test_register_model.py index 7fb6d89..dfc7871 100644 --- a/fd_shifts/tests/test_register_model.py +++ b/fd_shifts/tests/test_register_model.py @@ -14,6 +14,7 @@ class MyModel(pl.LightningModule): pass +@pytest.mark.skip("TODO: does nothing, remove or improve") def test_register_model(mock_env_if_missing): configs.init() diff --git a/fd_shifts/tests/test_reproducible.py b/fd_shifts/tests/test_reproducible.py index 0ee50ac..85235bc 100644 --- a/fd_shifts/tests/test_reproducible.py +++ b/fd_shifts/tests/test_reproducible.py @@ -25,6 +25,9 @@ def _update_overrides_fast(overrides: dict[str, Any]) -> dict[str, Any]: return overrides +@pytest.mark.skip( + "TODO: does nothing, remove or improve, also not compatible with new configs yet" +) @pytest.mark.slow def test_small_heuristic_run(mock_env_if_missing): # TODO: Test multiple with fixture From 2b2723844f4532fede312c6b9f2eb4f1156158ec Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Fri, 2 Feb 2024 21:17:35 +0100 Subject: [PATCH 046/136] test CI runners test ci amd runner From 53eed38d734c440295f90c241717f841bf5075ee Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 13 Feb 2024 14:32:36 +0100 Subject: [PATCH 047/136] feat: add new configs --- fd_shifts/experiments/configs.py | 1222 ++++++++++++++++++++++++------ fd_shifts/main.py | 44 +- 2 files changed, 1017 insertions(+), 249 deletions(-) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index 281c50f..d0344c3 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -1,36 +1,26 @@ +from copy import deepcopy from pathlib import Path from typing import Callable, Literal from omegaconf import SI from fd_shifts.configs import ( - ConfidMeasuresConfig, - ConfidMetricsConfig, Config, DataConfig, EvalConfig, ExperimentConfig, LRSchedulerConfig, - Mode, ModelConfig, - NetworkConfig, OptimizerConfig, - OutputPathsConfig, - OutputPathsPerMode, - PerfMetricsConfig, QueryStudiesConfig, - TestConfig, - TrainerConfig, - ValSplit, ) def svhn_data_config( - dataset: Literal["svhn", "svhn_openset"], img_size: int | tuple[int, int] + dataset: Literal["svhn", "svhn_openset"], img_size: int | tuple[int, int] = 32 ) -> DataConfig: augmentations = { "to_tensor": None, - "resize": img_size, "normalize": [ [0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614], @@ -40,10 +30,11 @@ def svhn_data_config( if isinstance(img_size, int): img_size = (img_size, img_size) + if img_size[0] != 32: + augmentations["resize"] = img_size[0] + return DataConfig( - dataset="svhn" - + ("_384" if img_size[0] == 384 else "") - + ("_openset" if dataset == "svhn_openset" else ""), + dataset="svhn" + ("_openset" if dataset == "svhn_openset" else ""), data_dir=SI("${oc.env:DATASET_ROOT_DIR}/svhn"), pin_memory=True, img_size=(img_size[0], img_size[1], 3), @@ -63,37 +54,58 @@ def svhn_data_config( def svhn_query_config( dataset: Literal["svhn", "svhn_openset"], img_size: int | tuple[int, int] ) -> QueryStudiesConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + return QueryStudiesConfig( - iid_study="svhn", + iid_study="svhn" + ("_384" if img_size[0] == 384 else ""), noise_study=[], in_class_study=[], new_class_study=[ - cifar10_data_config(img_size), - cifar100_data_config(img_size), - ], # , "tinyimagenet_384"], + cifar10_data_config(img_size=img_size), + cifar100_data_config(img_size=img_size), + tinyimagenet_data_config(img_size), + ], ) -def cifar10_data_config(img_size: int | tuple[int, int]) -> DataConfig: +def cifar10_data_config( + dataset: Literal["cifar10", "corrupt_cifar10"] = "cifar10", + img_size: int | tuple[int, int] = 32, +) -> DataConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + augmentations = { "to_tensor": None, - "resize": img_size, "normalize": [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.201]], } + if img_size[0] != 32: + augmentations["resize"] = img_size[0] + + train_augmentations = deepcopy(augmentations) + + if img_size[0] != 384: + train_augmentations["random_crop"] = [32, 4] + train_augmentations["hflip"] = True + if dataset == "corrupt_cifar10": + train_augmentations["rotate"] = 15 + else: + train_augmentations["cutout"] = 16 if isinstance(img_size, int): img_size = (img_size, img_size) return DataConfig( - dataset="cifar10" + ("_384" if img_size[0] == 384 else ""), - data_dir=SI("${oc.env:DATASET_ROOT_DIR}/cifar10"), + dataset=dataset, + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/" + dataset), pin_memory=True, img_size=(img_size[0], img_size[1], 3), num_workers=12, num_classes=10, reproduce_confidnet_splits=True, augmentations={ - "train": augmentations, + "train": train_augmentations, "val": augmentations, "test": augmentations, }, @@ -103,37 +115,57 @@ def cifar10_data_config(img_size: int | tuple[int, int]) -> DataConfig: def cifar10_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + return QueryStudiesConfig( - iid_study="cifar10", - noise_study=[], + iid_study="cifar10" + ("_384" if img_size[0] == 384 else ""), + noise_study=[ + cifar10_data_config("corrupt_cifar10", img_size), + ], in_class_study=[], new_class_study=[ - cifar100_data_config(img_size), + cifar100_data_config(img_size=img_size), svhn_data_config("svhn", img_size), - ], # , "tinyimagenet_384"], + tinyimagenet_data_config(img_size), + ], ) -def cifar100_data_config(img_size: int | tuple[int, int]) -> DataConfig: +def cifar100_data_config( + dataset: Literal["cifar100", "corrupt_cifar100"] = "cifar100", + img_size: int | tuple[int, int] = 32, +) -> DataConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + augmentations = { "to_tensor": None, - "resize": img_size, "normalize": [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.201]], } + if img_size[0] != 32: + augmentations["resize"] = img_size[0] - if isinstance(img_size, int): - img_size = (img_size, img_size) + train_augmentations = deepcopy(augmentations) + + if img_size[0] != 384: + train_augmentations["random_crop"] = [32, 4] + train_augmentations["hflip"] = True + if dataset == "corrupt_cifar100": + train_augmentations["rotate"] = 15 + else: + train_augmentations["cutout"] = 16 return DataConfig( - dataset="cifar100" + ("_384" if img_size[0] == 384 else ""), - data_dir=SI("${oc.env:DATASET_ROOT_DIR}/cifar100"), + dataset=dataset, + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/" + dataset), pin_memory=True, img_size=(img_size[0], img_size[1], 3), num_workers=12, num_classes=100, reproduce_confidnet_splits=True, augmentations={ - "train": augmentations, + "train": train_augmentations, "val": augmentations, "test": augmentations, }, @@ -142,6 +174,24 @@ def cifar100_data_config(img_size: int | tuple[int, int]) -> DataConfig: ) +def cifar100_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + + return QueryStudiesConfig( + iid_study="cifar100" + ("_384" if img_size[0] == 384 else ""), + noise_study=[ + cifar100_data_config("corrupt_cifar100", img_size), + ], + in_class_study=[], + new_class_study=[ + cifar10_data_config(img_size=img_size), + svhn_data_config("svhn", img_size), + tinyimagenet_data_config(img_size), + ], + ) + + def wilds_animals_data_config( dataset: Literal["wilds_animals", "wilds_animals_ood_test"] = "wilds_animals", img_size: int | tuple[int, int] = 448, @@ -151,10 +201,13 @@ def wilds_animals_data_config( augmentations = { "to_tensor": None, - "resize": img_size, + "resize": img_size[0] if img_size[0] == 384 else img_size, "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], } + if img_size[0] == 384: + augmentations["center_crop"] = 384 + return DataConfig( dataset=dataset, data_dir=SI("${oc.env:DATASET_ROOT_DIR}/wilds_animals"), @@ -173,15 +226,72 @@ def wilds_animals_data_config( ) -def wilds_animals_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: +def wilds_animals_query_config( + img_size: int | tuple[int, int] = 448 +) -> QueryStudiesConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + return QueryStudiesConfig( - iid_study="wilds_animals", + iid_study="wilds_animals" + ("_384" if img_size[0] == 384 else ""), noise_study=[], in_class_study=[wilds_animals_data_config("wilds_animals_ood_test", img_size)], new_class_study=[], ) +def wilds_camelyon_data_config( + dataset: Literal["wilds_camelyon", "wilds_camelyon_ood_test"] = "wilds_camelyon", + img_size: int | tuple[int, int] = 96, +) -> DataConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + + augmentations = { + "to_tensor": None, + "normalize": [ + [0.485, 0.456, 0.406], + [0.229, 0.384 if img_size[0] == 384 else 0.224, 0.225], + ], + } + + if img_size[0] != 96: + augmentations["resize"] = img_size[0] + + return DataConfig( + dataset=dataset, + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/wilds_camelyon"), + pin_memory=True, + img_size=(img_size[0], img_size[1], 3), + num_workers=8, + num_classes=2, + reproduce_confidnet_splits=False, + augmentations={ + "train": augmentations, + "val": augmentations, + "test": augmentations, + }, + target_transforms=None, + kwargs=None, + ) + + +def wilds_camelyon_query_config( + img_size: int | tuple[int, int] = 96 +) -> QueryStudiesConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + + return QueryStudiesConfig( + iid_study="wilds_camelyon" + ("_384" if img_size[0] == 384 else ""), + noise_study=[], + in_class_study=[ + wilds_camelyon_data_config("wilds_camelyon_ood_test", img_size) + ], + new_class_study=[], + ) + + def breeds_data_config( dataset: Literal["breeds", "breeds_ood_test"] = "breeds", img_size: int | tuple[int, int] = 224, @@ -189,254 +299,710 @@ def breeds_data_config( if isinstance(img_size, int): img_size = (img_size, img_size) + augmentations = { + "resize": 256 if img_size[0] == 224 else img_size[0], + "center_crop": img_size[0], + "to_tensor": None, + "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], + } + + train_augmentations = deepcopy(augmentations) + + if img_size[0] != 384: + train_augmentations["randomresized_crop"] = img_size[0] + train_augmentations["hflip"] = True + train_augmentations["color_jitter"] = [0.1, 0.1, 0.1] + del train_augmentations["resize"] + del train_augmentations["center_crop"] + return DataConfig( dataset=dataset, data_dir=SI("${oc.env:DATASET_ROOT_DIR}/breeds"), img_size=(img_size[0], img_size[1], 3), num_classes=13, augmentations={ - "train": { - "randomresized_crop": img_size, - "hflip": True, - "color_jitter": [0.1, 0.1, 0.1], - "to_tensor": None, - "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], - }, - "val": { - "resize": 256 if img_size[0] == 224 else img_size, - "center_crop": img_size, - "to_tensor": None, - "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], - }, - "test": { - "resize": 256 if img_size[0] == 224 else img_size, - "center_crop": img_size, - "to_tensor": None, - "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], - }, + "train": train_augmentations, + "val": augmentations, + "test": augmentations, }, kwargs={"info_dir_path": "loaders/breeds_hierarchies"}, ) -def breeds_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: +def breeds_query_config(img_size: int | tuple[int, int] = 224) -> QueryStudiesConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + return QueryStudiesConfig( - iid_study="breeds", + iid_study="breeds" + ("_384" if img_size[0] == 384 else ""), noise_study=[], in_class_study=[breeds_data_config("breeds_ood_test", img_size)], new_class_study=[], ) -__experiments: dict[str, Config] = {} +def tinyimagenet_data_config(img_size: int | tuple[int, int] = 64) -> DataConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + augmentations = { + "to_tensor": None, + "normalize": [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]], + } -def svhn_modelvit_bbvit(lr: float, run: int, do: int, **kwargs) -> Config: - return Config( - exp=ExperimentConfig( - group_name="vit", - name=f"svhn_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", - ), - pkgversion="0.0.1+f85760e", - data=svhn_data_config("svhn", 384), - trainer=TrainerConfig( - num_epochs=None, - num_steps=40000, - batch_size=128, - lr_scheduler=LRSchedulerConfig( - init_args={ - "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", - "init_args": { - "warmup_epochs": 500, - "warmup_start_lr": 0, - "eta_min": 0, - "max_epochs": 40000, - }, - }, - class_path="fd_shifts.configs.LRSchedulerConfig", - ), - optimizer=OptimizerConfig( - init_args={ - "class_path": "torch.optim.SGD", - "init_args": { - "lr": 0.01, - "dampening": 0.0, - "momentum": 0.9, - "nesterov": False, - "maximize": False, - "weight_decay": 0.0, - }, - }, - class_path="fd_shifts.configs.OptimizerConfig", - ), - lr_scheduler_interval="epoch", - ), - model=ModelConfig( - name="vit_model", - network=NetworkConfig( - name="vit", - ), - fc_dim=512, - avg_pool=True, - dropout_rate=0, - ), - eval=EvalConfig( - val_tuning=True, - query_studies=svhn_query_config("svhn", 384), + if img_size[0] != 64: + augmentations["resize"] = img_size + + return DataConfig( + dataset="tinyimagenet" + ("" if img_size[0] == 384 else "_resize"), + data_dir=SI( + "${oc.env:DATASET_ROOT_DIR}/" + + "tinyimagenet" + + ("" if img_size[0] == 384 else "_resize") ), + img_size=(img_size[0], img_size[1], 3), + num_classes=200, + augmentations={ + "train": augmentations, + "val": augmentations, + "test": augmentations, + }, + kwargs={}, ) -def svhn_modeldg_bbvit(lr: float, run: int, do: int, rew: int | float) -> Config: - config = svhn_modelvit_bbvit(lr=lr, run=run, do=do) - config.trainer.num_steps = 60000 +__dataset_configs: dict[str, DataConfig] = { + "svhn": svhn_data_config("svhn"), + "svhn_384": svhn_data_config("svhn", 384), + "cifar10": cifar10_data_config(), + "cifar10_384": cifar10_data_config(img_size=384), + "cifar100": cifar100_data_config(), + "cifar100_384": cifar100_data_config(img_size=384), + "corrupt_cifar10": cifar10_data_config(dataset="corrupt_cifar10"), + "corrupt_cifar10_384": cifar10_data_config(dataset="corrupt_cifar10", img_size=384), + "corrupt_cifar100": cifar100_data_config(dataset="corrupt_cifar100"), + "corrupt_cifar100_384": cifar100_data_config( + dataset="corrupt_cifar100", img_size=384 + ), + "wilds_animals_ood_test": wilds_animals_data_config("wilds_animals_ood_test"), + "wilds_animals_ood_test_384": wilds_animals_data_config( + "wilds_animals_ood_test", 384 + ), + "wilds_camelyon_ood_test": wilds_camelyon_data_config("wilds_camelyon_ood_test"), + "wilds_camelyon_ood_test_384": wilds_camelyon_data_config( + "wilds_camelyon_ood_test", 384 + ), + "breeds_ood_test": breeds_data_config("breeds_ood_test"), + "breeds_ood_test_384": breeds_data_config("breeds_ood_test", 384), + "tinyimagenet_384": tinyimagenet_data_config(384), + "tinyimagenet_resize": tinyimagenet_data_config(32), +} + + +def get_dataset_config(name: str) -> DataConfig: + return __dataset_configs[name] + + +__experiments: dict[str, Config] = {} + + +def cnn(group_name: str, name: str): + config = Config(exp=ExperimentConfig(group_name=group_name, name=name)) + config.trainer.batch_size = 128 config.trainer.lr_scheduler = LRSchedulerConfig( - { - "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", - "init_args": { - "warmup_epochs": 500, - "max_epochs": 60000, - "warmup_start_lr": 0.0, - "eta_min": 0.0, - "last_epoch": -1, - }, - } + init_args={ + "class_path": "torch.optim.lr_scheduler.CosineAnnealingLR", + "init_args": {}, + }, + class_path="fd_shifts.configs.LRSchedulerConfig", ) config.trainer.optimizer = OptimizerConfig( - { + init_args={ "class_path": "torch.optim.SGD", "init_args": { - "lr": lr, "dampening": 0.0, "momentum": 0.9, "nesterov": False, "maximize": False, "weight_decay": 0.0, }, - } - ) - config.trainer.dg_pretrain_epochs = None - config.trainer.dg_pretrain_steps = 20000 - config.trainer.lr_scheduler_interval = "step" - config.exp.name = f"svhn_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}" - config.model = ModelConfig( - name="devries_model", - network=NetworkConfig( - name="vit", - save_dg_backbone_path=Path("${exp.dir}/dg_backbone.ckpt"), - ), - fc_dim=768, - avg_pool=True, - dropout_rate=1, - dg_reward=rew, + }, + class_path="fd_shifts.configs.OptimizerConfig", ) + config.model.confidnet_fc_dim = 400 + return config + + +def cnn_animals(name: str): + config = cnn("animals_paper_sweep", name=name) + config.data = wilds_animals_data_config() + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.001 + config.model.fc_dim = 2048 + config.model.avg_pool = True + config.eval.query_studies = wilds_animals_query_config() + return config + + +def cnn_animals_modelconfidnet(run: int, do: int, **kwargs): + config = cnn_animals(name=f"confidnet_bbresnet50_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 20 + config.trainer.num_epochs_backbone = 12 + config.trainer.learning_rate_confidnet = 0.0001 + config.trainer.learning_rate_confidnet_finetune = 1e-06 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 12 + config.trainer.callbacks["training_stages"] = {} + config.trainer.callbacks["training_stages"]["milestones"] = [12, 17] + config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True + config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.model.name = "confidnet_model" + config.model.dropout_rate = do + config.model.network.name = "confidnet_and_enc" + config.model.network.backbone = "resnet50" + config.eval.ext_confid_name = "tcp" + return config + + +def cnn_animals_modeldevries(run: int, do: int, **kwargs): + config = cnn_animals(name=f"devries_bbresnet50_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 12 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 12 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.model.name = "devries_model" + config.model.dg_reward = -1 + config.model.dropout_rate = do + config.model.network.name = "devries_and_enc" + config.model.network.backbone = "resnet50" + config.eval.ext_confid_name = "devries" + return config + + +def cnn_animals_modeldg(run: int, do: int, rew: float): + config = cnn_animals(name=f"dg_bbresnet50_do{do}_run{run + 1}_rew{rew}") + config.trainer.num_epochs = 18 + config.trainer.dg_pretrain_epochs = 6 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 18 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.model.name = "devries_model" + config.model.dropout_rate = do + config.model.dg_reward = rew + config.model.network.name = "resnet50" config.eval.ext_confid_name = "dg" - config.eval.confidence_measures.test.append("ext") + return config + +def cnn_camelyon(name: str): + config = cnn("camelyon_paper_sweep", name=name) + config.data = wilds_camelyon_data_config() + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.01 + config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.01 + config.model.fc_dim = 2048 + config.model.avg_pool = True + config.eval.query_studies = wilds_camelyon_query_config() return config -def cifar10_modelvit_bbvit(lr: float, run: int, do: Literal[0, 1], **kwargs) -> Config: - return Config( - exp=ExperimentConfig( - group_name="vit", - name=f"cifar10_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", - ), - data=cifar10_data_config(384), - trainer=TrainerConfig( - num_epochs=None, - num_steps=40000, - batch_size=128, - lr_scheduler=LRSchedulerConfig( - init_args={ - "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", - "init_args": { - "warmup_epochs": 500, - "warmup_start_lr": 0, - "eta_min": 0, - "max_epochs": 40000, - }, - }, - class_path="fd_shifts.configs.LRSchedulerConfig", - ), - optimizer=OptimizerConfig( - init_args={ - "class_path": "torch.optim.SGD", - "init_args": { - "lr": lr, - "dampening": 0.0, - "momentum": 0.9, - "nesterov": False, - "maximize": False, - "weight_decay": 0.0, - }, - }, - class_path="fd_shifts.configs.OptimizerConfig", - ), - ), - model=ModelConfig( - name="vit_model", - network=NetworkConfig( - name="vit", - ), - fc_dim=512, - avg_pool=True, - dropout_rate=do, - ), - eval=EvalConfig( - query_studies=cifar10_query_config(384), - ), - ) +def cnn_camelyon_modelconfidnet(run: int, do: int, **kwargs): + config = cnn_camelyon(f"confidnet_bbresnet50_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 9 + config.trainer.num_epochs_backbone = 5 + config.trainer.learning_rate_confidnet = 0.0001 + config.trainer.learning_rate_confidnet_finetune = 1e-06 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 5 + config.trainer.callbacks["training_stages"] = {} + config.trainer.callbacks["training_stages"]["milestones"] = [5, 8] + config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True + config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.model.name = "confidnet_model" + config.model.dropout_rate = do + config.model.network.name = "confidnet_and_enc" + config.model.network.backbone = "resnet50" + config.eval.ext_confid_name = "tcp" + return config -def cifar10_modeldg_bbvit( - lr: float, run: int, do: Literal[0, 1], rew: int | float -) -> Config: - config = cifar10_modelvit_bbvit(lr=lr, run=run, do=do) - config.trainer.num_steps = 60000 +def cnn_camelyon_modeldevries(run: int, do: int, **kwargs): + config = cnn_camelyon(f"devries_bbresnet50_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 5 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 5 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.model.name = "devries_model" + config.model.dropout_rate = do + config.model.dg_reward = -1 + config.model.network.name = "devries_and_enc" + config.model.network.backbone = "resnet50" + config.eval.ext_confid_name = "devries" + return config + + +def cnn_camelyon_modeldg(run: int, do: int, rew: float): + config = cnn_camelyon(f"dg_bbresnet50_do{do}_run{run + 1}_rew{rew}") + config.trainer.num_epochs = 8 + config.trainer.dg_pretrain_epochs = 3 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 8 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.model.name = "devries_model" + config.model.dg_reward = rew + config.model.dropout_rate = do + config.model.network.name = "resnet50" + config.eval.ext_confid_name = "dg" + return config + + +def cnn_svhn(name: str): + config = cnn("svhn_paper_sweep", name=name) + config.data = svhn_data_config("svhn", img_size=32) + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.01 + config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.0005 + config.model.fc_dim = 512 + config.model.avg_pool = True + config.eval.query_studies = svhn_query_config("svhn", img_size=32) + return config + + +def cnn_svhn_modelconfidnet(run: int, do: int, **kwargs): + config = cnn_svhn(f"confidnet_bbsvhn_small_conv_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 320 + config.trainer.num_epochs_backbone = 100 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 100 + config.trainer.learning_rate_confidnet = 0.0001 + config.trainer.learning_rate_confidnet_finetune = 1e-06 + config.trainer.callbacks["training_stages"] = {} + config.trainer.callbacks["training_stages"]["milestones"] = [100, 300] + config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True + config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.model.name = "confidnet_model" + config.model.dropout_rate = do + config.model.network.name = "confidnet_and_enc" + config.model.network.backbone = "svhn_small_conv" + config.eval.ext_confid_name = "tcp" + return config + + +def cnn_svhn_modeldevries(run: int, do: int, **kwargs): + config = cnn_svhn(f"devries_bbsvhn_small_conv_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 100 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 100 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.model.name = "devries_model" + config.model.dropout_rate = do + config.model.dg_reward = -1 + config.model.network.name = "devries_and_enc" + config.model.network.backbone = "svhn_small_conv" + config.eval.ext_confid_name = "devries" + return config + + +def cnn_svhn_modeldg(run: int, do: int, rew: float): + config = cnn_svhn(f"dg_bbsvhn_small_conv_do{do}_run{run + 1}_rew{rew}") + config.trainer.num_epochs = 150 + config.trainer.dg_pretrain_epochs = 50 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 150 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.model.name = "devries_model" + config.model.dg_reward = rew + config.model.dropout_rate = do + config.model.network.name = "svhn_small_conv" + config.eval.ext_confid_name = "dg" + return config + + +def cnn_cifar10(name: str): + config = cnn("cifar10_paper_sweep", name=name) + config.data = cifar10_data_config(img_size=32) + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.1 + config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.0005 + config.model.fc_dim = 512 + config.eval.query_studies = cifar10_query_config(img_size=32) + return config + + +def cnn_cifar10_modelconfidnet(run: int, do: int, **kwargs): + config = cnn_cifar10(f"confidnet_bbvgg13_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 470 + config.trainer.num_epochs_backbone = 250 + config.trainer.learning_rate_confidnet = 0.0001 + config.trainer.learning_rate_confidnet_finetune = 1e-06 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 + config.trainer.callbacks["training_stages"] = {} + config.trainer.callbacks["training_stages"]["milestones"] = [250, 450] + config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True + config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.model.name = "confidnet_model" + config.model.dropout_rate = do + config.model.avg_pool = do == 0 + config.model.network.name = "confidnet_and_enc" + config.model.network.backbone = "vgg13" + config.eval.ext_confid_name = "tcp" + return config + + +def cnn_cifar10_modeldevries(run: int, do: int, **kwargs): + config = cnn_cifar10(f"devries_bbvgg13_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 250 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.model.name = "devries_model" + config.model.dropout_rate = do + config.model.avg_pool = do == 0 + config.model.dg_reward = -1 + config.model.network.name = "devries_and_enc" + config.model.network.backbone = "vgg13" + config.eval.ext_confid_name = "devries" + return config + + +def cnn_cifar10_modeldg(run: int, do: int, rew: float): + config = cnn_cifar10(f"dg_bbvgg13_do{do}_run{run + 1}_rew{rew}") + config.trainer.num_epochs = 300 + config.trainer.dg_pretrain_epochs = 100 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.model.name = "devries_model" + config.model.dg_reward = rew + config.model.dropout_rate = do + config.model.avg_pool = do == 0 + config.model.network.name = "vgg13" + config.eval.ext_confid_name = "dg" + return config + + +def cnn_cifar100(name: str): + config = cnn("cifar100_paper_sweep", name=name) + config.data = cifar100_data_config(img_size=32) + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.1 + config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.0005 + config.model.fc_dim = 512 + config.eval.query_studies = cifar100_query_config(img_size=32) + return config + + +def cnn_cifar100_modelconfidnet(run: int, do: int, **kwargs): + config = cnn_cifar100(f"confidnet_bbvgg13_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 470 + config.trainer.num_epochs_backbone = 250 + config.trainer.learning_rate_confidnet = 0.0001 + config.trainer.learning_rate_confidnet_finetune = 1e-06 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 + config.trainer.callbacks["training_stages"] = {} + config.trainer.callbacks["training_stages"]["milestones"] = [250, 450] + config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True + config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.model.name = "confidnet_model" + config.model.avg_pool = do == 0 + config.model.dropout_rate = do + config.model.network.name = "confidnet_and_enc" + config.model.network.backbone = "vgg13" + config.eval.ext_confid_name = "tcp" + return config + + +def cnn_cifar100_modeldevries(run: int, do: int, **kwargs): + config = cnn_cifar100(f"devries_bbvgg13_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 250 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.model.name = "devries_model" + config.model.dropout_rate = do + config.model.dg_reward = -1 + config.model.avg_pool = do == 0 + config.model.network.name = "devries_and_enc" + config.model.network.backbone = "vgg13" + config.eval.ext_confid_name = "devries" + return config + + +def cnn_cifar100_modeldg(run: int, do: int, rew: float): + config = cnn_cifar100(f"dg_bbvgg13_do{do}_run{run + 1}_rew{rew}") + config.trainer.num_epochs = 300 + config.trainer.dg_pretrain_epochs = 100 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.model.name = "devries_model" + config.model.dg_reward = rew + config.model.dropout_rate = do + config.model.avg_pool = do == 0 + config.model.network.name = "vgg13" + config.eval.ext_confid_name = "dg" + return config + + +def cnn_breeds(name: str): + config = cnn("breeds_paper_sweep", name=name) + config.data = breeds_data_config() + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.1 + config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.0001 + config.model.fc_dim = 2048 + config.model.avg_pool = True + config.eval.query_studies = breeds_query_config() + return config + + +def cnn_breeds_modelconfidnet(run: int, do: int, **kwargs): + config = cnn_breeds(f"confidnet_bbresnet50_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 520 + config.trainer.num_epochs_backbone = 300 + config.trainer.learning_rate_confidnet = 0.0001 + config.trainer.learning_rate_confidnet_finetune = 1e-06 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 + config.trainer.callbacks["training_stages"] = {} + config.trainer.callbacks["training_stages"]["milestones"] = [300, 500] + config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True + config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.model.name = "confidnet_model" + config.model.dropout_rate = do + config.model.network.name = "confidnet_and_enc" + config.model.network.backbone = "resnet50" + config.eval.ext_confid_name = "tcp" + return config + + +def cnn_breeds_modeldevries(run: int, do: int, **kwargs): + config = cnn_breeds(f"devries_bbresnet50_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 300 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.model.name = "devries_model" + config.model.dropout_rate = do + config.model.dg_reward = -1 + config.model.network.name = "devries_and_enc" + config.model.network.backbone = "resnet50" + config.eval.ext_confid_name = "devries" + return config + + +def cnn_breeds_modeldg(run: int, do: int, rew: float): + config = cnn_breeds(f"dg_bbresnet50_do{do}_run{run + 1}_rew{rew}") + config.trainer.num_epochs = 350 + config.trainer.dg_pretrain_epochs = 50 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 350 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.model.name = "devries_model" + config.model.dg_reward = rew + config.model.dropout_rate = do + config.model.network.name = "resnet50" + config.eval.ext_confid_name = "dg" + return config + + +def vit(name: str): + config = Config(exp=ExperimentConfig(group_name="vit", name=name)) + config.trainer.num_epochs = None + config.trainer.num_steps = 40000 + config.trainer.lr_scheduler_interval = "epoch" config.trainer.lr_scheduler = LRSchedulerConfig( - { + init_args={ "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", "init_args": { "warmup_epochs": 500, - "max_epochs": 60000, - "warmup_start_lr": 0.0, - "eta_min": 0.0, - "last_epoch": -1, + "warmup_start_lr": 0, + "eta_min": 0, + "max_epochs": 40000, }, - } + }, + class_path="fd_shifts.configs.LRSchedulerConfig", ) config.trainer.optimizer = OptimizerConfig( - { + init_args={ "class_path": "torch.optim.SGD", "init_args": { - "lr": lr, "dampening": 0.0, "momentum": 0.9, "nesterov": False, "maximize": False, "weight_decay": 0.0, }, - } + }, + class_path="fd_shifts.configs.OptimizerConfig", ) + config.trainer.batch_size = 128 + config.model.name = "vit_model" + config.model.network.name = "vit" + config.model.fc_dim = 512 + config.model.avg_pool = True + config.eval.ext_confid_name = "maha" + return config + + +def vit_modeldg(name: str): + config = vit(name) + config.model.name = "devries_model" + config.trainer.lr_scheduler_interval = "step" + config.model.fc_dim = 768 config.trainer.dg_pretrain_epochs = None + config.eval.ext_confid_name = "dg" + return config + + +def vit_wilds_animals_modeldg(run: int, lr: float, do: int, rew: float): + config = vit_modeldg( + name=f"wilds_animals_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", + ) + config.data = wilds_animals_data_config("wilds_animals", 384) + config.trainer.num_steps = 60000 + config.trainer.batch_size = 512 config.trainer.dg_pretrain_steps = 20000 - config.trainer.lr_scheduler_interval = "step" - config.exp.name = f"cifar10_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}" - config.model = ModelConfig( - name="devries_model", - network=NetworkConfig( - name="vit", - save_dg_backbone_path=Path("${exp.dir}/dg_backbone.ckpt"), - ), - fc_dim=768, - avg_pool=True, - dropout_rate=1, - dg_reward=rew, + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.model.dg_reward = rew + config.eval.query_studies = wilds_animals_query_config(384) + return config + + +def vit_wilds_camelyon_modeldg(run: int, lr: float, do: int, rew: float): + config = vit_modeldg( + name=f"wilds_camelyon_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", ) - config.eval.ext_confid_name = "dg" - config.eval.confidence_measures.test.append("ext") + config.data = wilds_camelyon_data_config("wilds_camelyon", 384) + config.trainer.num_steps = 60000 + config.trainer.dg_pretrain_steps = 20000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.model.dg_reward = rew + config.eval.query_studies = wilds_camelyon_query_config(384) + return config + +def vit_svhn_modeldg(run: int, lr: float, do: int, rew: float): + config = vit_modeldg( + name=f"svhn_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", + ) + config.data = svhn_data_config("svhn", 384) + config.trainer.num_steps = 60000 + config.trainer.dg_pretrain_steps = 20000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.model.dg_reward = rew + config.eval.query_studies = svhn_query_config("svhn", 384) + return config + + +def vit_cifar10_modeldg(run: int, lr: float, do: int, rew: float): + config = vit_modeldg( + name=f"cifar10_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", + ) + config.data = cifar10_data_config(img_size=384) + config.trainer.num_steps = 60000 + config.trainer.dg_pretrain_steps = 20000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.model.dg_reward = rew + config.model.avg_pool = do == 0 + config.eval.query_studies = cifar10_query_config(384) + return config + + +def vit_cifar100_modeldg(run: int, lr: float, do: int, rew: float): + config = vit_modeldg( + name=f"cifar100_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", + ) + config.data = cifar100_data_config(img_size=384) + config.trainer.num_steps = 15000 + config.trainer.batch_size = 512 + config.trainer.dg_pretrain_steps = 5000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 15000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.model.dg_reward = rew + config.eval.query_studies = cifar100_query_config(384) + return config + + +def vit_breeds_modeldg(run: int, lr: float, do: int, rew: float): + config = vit_modeldg( + name=f"breeds_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", + ) + config.data = breeds_data_config("breeds", 384) + config.trainer.num_steps = 60000 + config.trainer.dg_pretrain_steps = 20000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.model.dg_reward = rew + config.eval.query_studies = breeds_query_config(384) + return config + + +def vit_wilds_animals_modelvit(run: int, lr: float, do: int, **kwargs): + config = vit( + name=f"wilds_animals_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", + ) + config.data = wilds_animals_data_config("wilds_animals", 384) + config.trainer.num_steps = 40000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.eval.query_studies = wilds_animals_query_config(384) + return config + + +def vit_wilds_camelyon_modelvit(run: int, lr: float, do: int, **kwargs): + config = vit( + name=f"wilds_camelyon_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", + ) + config.data = wilds_camelyon_data_config("wilds_camelyon", 384) + config.trainer.num_steps = 40000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.eval.query_studies = wilds_camelyon_query_config(384) + return config + + +def vit_svhn_modelvit(run: int, lr: float, do: int, **kwargs): + config = vit( + name=f"svhn_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", + ) + config.data = svhn_data_config("svhn", 384) + config.trainer.num_steps = 40000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.eval.query_studies = svhn_query_config("svhn", 384) + return config + + +def vit_cifar10_modelvit(run: int, lr: float, do: int, **kwargs): + config = vit( + name=f"cifar10_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", + ) + config.data = cifar10_data_config(img_size=384) + config.trainer.num_steps = 40000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.model.avg_pool = do == 0 + config.eval.query_studies = cifar10_query_config(384) + return config + + +def vit_cifar100_modelvit(run: int, lr: float, do: int, **kwargs): + config = vit( + name=f"cifar100_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", + ) + config.data = cifar100_data_config(img_size=384) + config.trainer.num_steps = 10000 + config.trainer.batch_size = 512 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 10000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.eval.query_studies = cifar100_query_config(384) + return config + + +def vit_breeds_modelvit(run: int, lr: float, do: int, **kwargs): + config = vit( + name=f"breeds_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", + ) + config.data = breeds_data_config("breeds", 384) + config.trainer.num_steps = 40000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.eval.query_studies = breeds_query_config(384) return config @@ -465,31 +1031,191 @@ def clip( def register(config_fn: Callable[..., Config], n_runs: int = 5, **kwargs): for run in range(n_runs): config = config_fn(**kwargs, run=run) - __experiments[config.exp.name] = config - - -register(svhn_modelvit_bbvit, lr=0.03, do=1, rew=2.2) -register(svhn_modelvit_bbvit, lr=0.01, do=0, rew=2.2) -register(svhn_modelvit_bbvit, lr=0.01, do=1, rew=2.2) -register(svhn_modeldg_bbvit, lr=0.01, do=1, rew=2.2) -register(svhn_modeldg_bbvit, lr=0.01, do=1, rew=3) -register(svhn_modeldg_bbvit, lr=0.01, do=1, rew=6) -register(svhn_modeldg_bbvit, lr=0.01, do=1, rew=10) -register(svhn_modeldg_bbvit, lr=0.03, do=1, rew=2.2) -register(svhn_modeldg_bbvit, lr=0.03, do=1, rew=3) -register(svhn_modeldg_bbvit, lr=0.03, do=1, rew=6) -register(svhn_modeldg_bbvit, lr=0.03, do=1, rew=10) - -register(cifar10_modelvit_bbvit, lr=3e-4, do=0, rew=2.2) -register(cifar10_modelvit_bbvit, lr=0.01, do=1, rew=2.2) -register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=2.2) -register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=2.2) -register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=3) -register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=3) -register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=6) -register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=6) -register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=10) -register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=10) + __experiments[f"{config.exp.group_name}/{config.exp.name}"] = config + + +register(vit_svhn_modelvit, lr=0.03, do=1, rew=0) +register(vit_svhn_modelvit, lr=0.01, do=0, rew=0) +register(vit_svhn_modelvit, lr=0.01, do=1, rew=0) +register(vit_svhn_modeldg, lr=0.01, do=1, rew=2.2) +register(vit_svhn_modeldg, lr=0.01, do=1, rew=3) +register(vit_svhn_modeldg, lr=0.01, do=1, rew=6) +register(vit_svhn_modeldg, lr=0.01, do=1, rew=10) +register(vit_svhn_modeldg, lr=0.01, do=0, rew=2.2) +register(vit_svhn_modeldg, lr=0.01, do=0, rew=3) +register(vit_svhn_modeldg, lr=0.01, do=0, rew=6) +register(vit_svhn_modeldg, lr=0.01, do=0, rew=10) +register(vit_svhn_modeldg, lr=0.03, do=1, rew=2.2) +register(vit_svhn_modeldg, lr=0.03, do=1, rew=3) +register(vit_svhn_modeldg, lr=0.03, do=1, rew=6) +register(vit_svhn_modeldg, lr=0.03, do=1, rew=10) + +register(vit_cifar10_modelvit, lr=3e-4, do=0, rew=0) +register(vit_cifar10_modelvit, lr=0.01, do=1, rew=0) +register(vit_cifar10_modeldg, lr=3e-4, do=0, rew=2.2) +register(vit_cifar10_modeldg, lr=0.01, do=1, rew=2.2) +register(vit_cifar10_modeldg, lr=3e-4, do=0, rew=3) +register(vit_cifar10_modeldg, lr=0.01, do=1, rew=3) +register(vit_cifar10_modeldg, lr=3e-4, do=0, rew=6) +register(vit_cifar10_modeldg, lr=0.01, do=1, rew=6) +register(vit_cifar10_modeldg, lr=3e-4, do=0, rew=10) +register(vit_cifar10_modeldg, lr=0.01, do=1, rew=10) + +register(vit_cifar100_modelvit, lr=1e-2, do=0, rew=0) +register(vit_cifar100_modelvit, lr=1e-2, do=1, rew=0) +register(vit_cifar100_modeldg, lr=1e-2, do=0, rew=2.2) +register(vit_cifar100_modeldg, lr=1e-2, do=1, rew=2.2) +register(vit_cifar100_modeldg, lr=1e-2, do=0, rew=3) +register(vit_cifar100_modeldg, lr=1e-2, do=1, rew=3) +register(vit_cifar100_modeldg, lr=1e-2, do=0, rew=6) +register(vit_cifar100_modeldg, lr=1e-2, do=1, rew=6) +register(vit_cifar100_modeldg, lr=1e-2, do=0, rew=10) +register(vit_cifar100_modeldg, lr=1e-2, do=1, rew=10) +register(vit_cifar100_modeldg, lr=1e-2, do=0, rew=12) +register(vit_cifar100_modeldg, lr=1e-2, do=1, rew=12) +register(vit_cifar100_modeldg, lr=1e-2, do=0, rew=15) +register(vit_cifar100_modeldg, lr=1e-2, do=1, rew=15) +register(vit_cifar100_modeldg, lr=1e-2, do=0, rew=20) +register(vit_cifar100_modeldg, lr=1e-2, do=1, rew=20) + +register(vit_wilds_animals_modelvit, lr=1e-3, do=0, rew=0) +register(vit_wilds_animals_modelvit, lr=1e-2, do=0, rew=0) +register(vit_wilds_animals_modelvit, lr=1e-2, do=1, rew=0) +register(vit_wilds_animals_modelvit, lr=3e-3, do=0, rew=0) +register(vit_wilds_animals_modelvit, lr=3e-3, do=1, rew=0) +register(vit_wilds_animals_modeldg, lr=1e-3, do=0, rew=2.2) +register(vit_wilds_animals_modeldg, lr=1e-3, do=0, rew=3) +register(vit_wilds_animals_modeldg, lr=1e-3, do=0, rew=6) +register(vit_wilds_animals_modeldg, lr=1e-3, do=0, rew=10) +register(vit_wilds_animals_modeldg, lr=1e-3, do=0, rew=15) +register(vit_wilds_animals_modeldg, lr=3e-3, do=0, rew=2.2) +register(vit_wilds_animals_modeldg, lr=3e-3, do=0, rew=3) +register(vit_wilds_animals_modeldg, lr=3e-3, do=0, rew=6) +register(vit_wilds_animals_modeldg, lr=3e-3, do=0, rew=10) +register(vit_wilds_animals_modeldg, lr=3e-3, do=0, rew=15) +register(vit_wilds_animals_modeldg, lr=3e-3, do=1, rew=2.2) +register(vit_wilds_animals_modeldg, lr=3e-3, do=1, rew=3) +register(vit_wilds_animals_modeldg, lr=3e-3, do=1, rew=6) +register(vit_wilds_animals_modeldg, lr=3e-3, do=1, rew=10) +register(vit_wilds_animals_modeldg, lr=3e-3, do=1, rew=15) + +register(vit_wilds_camelyon_modelvit, lr=1e-3, do=0, rew=0) +register(vit_wilds_camelyon_modelvit, lr=3e-3, do=1, rew=0) +register(vit_wilds_camelyon_modeldg, lr=1e-3, do=0, rew=2.2) +register(vit_wilds_camelyon_modeldg, lr=1e-3, do=0, rew=3) +register(vit_wilds_camelyon_modeldg, lr=1e-3, do=0, rew=6) +register(vit_wilds_camelyon_modeldg, lr=1e-3, do=0, rew=10) +register(vit_wilds_camelyon_modeldg, lr=3e-3, do=1, rew=2.2) +register(vit_wilds_camelyon_modeldg, lr=3e-3, do=1, rew=3) +register(vit_wilds_camelyon_modeldg, lr=3e-3, do=1, rew=6) +register(vit_wilds_camelyon_modeldg, lr=3e-3, do=1, rew=10) + +register(vit_breeds_modelvit, lr=3e-3, do=0, rew=0, n_runs=2) +register(vit_breeds_modelvit, lr=1e-3, do=0, rew=0, n_runs=2) +register(vit_breeds_modelvit, lr=1e-2, do=1, rew=0, n_runs=2) +register(vit_breeds_modeldg, lr=3e-3, do=0, rew=2.2, n_runs=2) +register(vit_breeds_modeldg, lr=3e-3, do=0, rew=3, n_runs=2) +register(vit_breeds_modeldg, lr=3e-3, do=0, rew=6, n_runs=2) +register(vit_breeds_modeldg, lr=3e-3, do=0, rew=10, n_runs=2) +register(vit_breeds_modeldg, lr=3e-3, do=0, rew=15, n_runs=2) +register(vit_breeds_modeldg, lr=1e-3, do=0, rew=2.2, n_runs=2) +register(vit_breeds_modeldg, lr=1e-3, do=0, rew=3, n_runs=2) +register(vit_breeds_modeldg, lr=1e-3, do=0, rew=6, n_runs=2) +register(vit_breeds_modeldg, lr=1e-3, do=0, rew=10, n_runs=2) +register(vit_breeds_modeldg, lr=1e-3, do=0, rew=15, n_runs=2) +register(vit_breeds_modeldg, lr=1e-2, do=1, rew=2.2, n_runs=2) +register(vit_breeds_modeldg, lr=1e-2, do=1, rew=3, n_runs=2) +register(vit_breeds_modeldg, lr=1e-2, do=1, rew=6, n_runs=2) +register(vit_breeds_modeldg, lr=1e-2, do=1, rew=10, n_runs=2) +register(vit_breeds_modeldg, lr=1e-2, do=1, rew=15, n_runs=2) + +register(cnn_svhn_modeldevries, do=0) +register(cnn_svhn_modeldevries, do=1) +register(cnn_svhn_modelconfidnet, do=0) +register(cnn_svhn_modelconfidnet, do=1) +register(cnn_svhn_modeldg, do=0, rew=2.2) +register(cnn_svhn_modeldg, do=1, rew=2.2) +register(cnn_svhn_modeldg, do=0, rew=3) +register(cnn_svhn_modeldg, do=1, rew=3) +register(cnn_svhn_modeldg, do=0, rew=6) +register(cnn_svhn_modeldg, do=1, rew=6) +register(cnn_svhn_modeldg, do=0, rew=10) +register(cnn_svhn_modeldg, do=1, rew=10) + +register(cnn_cifar10_modeldevries, do=0) +register(cnn_cifar10_modeldevries, do=1) +register(cnn_cifar10_modelconfidnet, do=0) +register(cnn_cifar10_modelconfidnet, do=1) +register(cnn_cifar10_modeldg, do=0, rew=2.2) +register(cnn_cifar10_modeldg, do=1, rew=2.2) +register(cnn_cifar10_modeldg, do=0, rew=3) +register(cnn_cifar10_modeldg, do=1, rew=3) +register(cnn_cifar10_modeldg, do=0, rew=6) +register(cnn_cifar10_modeldg, do=1, rew=6) +register(cnn_cifar10_modeldg, do=0, rew=10) +register(cnn_cifar10_modeldg, do=1, rew=10) + +register(cnn_cifar100_modeldevries, do=0) +register(cnn_cifar100_modeldevries, do=1) +register(cnn_cifar100_modelconfidnet, do=0) +register(cnn_cifar100_modelconfidnet, do=1) +register(cnn_cifar100_modeldg, do=0, rew=2.2) +register(cnn_cifar100_modeldg, do=1, rew=2.2) +register(cnn_cifar100_modeldg, do=0, rew=3) +register(cnn_cifar100_modeldg, do=1, rew=3) +register(cnn_cifar100_modeldg, do=0, rew=6) +register(cnn_cifar100_modeldg, do=1, rew=6) +register(cnn_cifar100_modeldg, do=0, rew=10) +register(cnn_cifar100_modeldg, do=1, rew=10) +register(cnn_cifar100_modeldg, do=0, rew=12) +register(cnn_cifar100_modeldg, do=1, rew=12) +register(cnn_cifar100_modeldg, do=0, rew=15) +register(cnn_cifar100_modeldg, do=1, rew=15) +register(cnn_cifar100_modeldg, do=0, rew=20) +register(cnn_cifar100_modeldg, do=1, rew=20) + +register(cnn_animals_modeldevries, do=0) +register(cnn_animals_modeldevries, do=1) +register(cnn_animals_modelconfidnet, do=0) +register(cnn_animals_modelconfidnet, do=1) +register(cnn_animals_modeldg, do=0, rew=2.2) +register(cnn_animals_modeldg, do=1, rew=2.2) +register(cnn_animals_modeldg, do=0, rew=3) +register(cnn_animals_modeldg, do=1, rew=3) +register(cnn_animals_modeldg, do=0, rew=6) +register(cnn_animals_modeldg, do=1, rew=6) +register(cnn_animals_modeldg, do=0, rew=10) +register(cnn_animals_modeldg, do=1, rew=10) +register(cnn_animals_modeldg, do=0, rew=15) +register(cnn_animals_modeldg, do=1, rew=15) + +register(cnn_camelyon_modeldevries, do=0, n_runs=10) +register(cnn_camelyon_modeldevries, do=1, n_runs=10) +register(cnn_camelyon_modelconfidnet, do=0, n_runs=10) +register(cnn_camelyon_modelconfidnet, do=1, n_runs=10) +register(cnn_camelyon_modeldg, do=0, rew=2.2, n_runs=10) +register(cnn_camelyon_modeldg, do=1, rew=2.2, n_runs=10) +register(cnn_camelyon_modeldg, do=0, rew=3, n_runs=10) +register(cnn_camelyon_modeldg, do=1, rew=3, n_runs=10) +register(cnn_camelyon_modeldg, do=0, rew=6, n_runs=10) +register(cnn_camelyon_modeldg, do=1, rew=6, n_runs=10) +register(cnn_camelyon_modeldg, do=0, rew=10, n_runs=10) +register(cnn_camelyon_modeldg, do=1, rew=10, n_runs=10) + +register(cnn_breeds_modeldevries, do=0, n_runs=2) +register(cnn_breeds_modeldevries, do=1, n_runs=2) +register(cnn_breeds_modelconfidnet, do=0, n_runs=2) +register(cnn_breeds_modelconfidnet, do=1, n_runs=2) +register(cnn_breeds_modeldg, do=0, rew=2.2, n_runs=2) +register(cnn_breeds_modeldg, do=1, rew=2.2, n_runs=2) +register(cnn_breeds_modeldg, do=0, rew=3, n_runs=2) +register(cnn_breeds_modeldg, do=1, rew=3, n_runs=2) +register(cnn_breeds_modeldg, do=0, rew=6, n_runs=2) +register(cnn_breeds_modeldg, do=1, rew=6, n_runs=2) +register(cnn_breeds_modeldg, do=0, rew=10, n_runs=2) +register(cnn_breeds_modeldg, do=1, rew=10, n_runs=2) +register(cnn_breeds_modeldg, do=0, rew=15, n_runs=2) +register(cnn_breeds_modeldg, do=1, rew=15, n_runs=2) register( clip, diff --git a/fd_shifts/main.py b/fd_shifts/main.py index ddc69a3..2bf866d 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -1,5 +1,7 @@ +import re import types import typing +import warnings from contextlib import contextmanager from contextvars import ContextVar from dataclasses import asdict, is_dataclass @@ -21,7 +23,13 @@ from fd_shifts import analysis, logger from fd_shifts.configs import Config, TestConfig -from fd_shifts.experiments.configs import get_experiment_config, list_experiment_configs +from fd_shifts.experiments.configs import ( + get_dataset_config, + get_experiment_config, + list_experiment_configs, + wilds_animals_query_config, +) +from fd_shifts.experiments.tracker import get_path from fd_shifts.loaders.data_loader import FDShiftsDataLoader from fd_shifts.models import get_model from fd_shifts.models.callbacks import get_callbacks @@ -173,6 +181,40 @@ def apply_config(parser, cfg, dest, value, option_string) -> None: }, }, } + + # query_studies contain DataConfig objects now, not just names + for k, v in cfg_file["config"]["eval"]["query_studies"].items(): + if k == "iid_study": + pass + elif k in ["in_class_study", "noise_study", "new_class_study"]: + cfg_file["config"]["eval"]["query_studies"][k] = [ + asdict(get_dataset_config(v2)) for v2 in v + ] + else: + raise ValueError(f"Unknown query study {k}") + + # for specific experiments, the seed should be fixed, if "random_seed" was written fix it + if isinstance(cfg_file["config"]["exp"]["global_seed"], str): + warnings.warn( + "global_seed is set to random in file, setting it to -1" + ) + cfg_file["config"]["exp"]["global_seed"] = -1 + + # hydra is gone + if cfg_file["config"]["exp"]["work_dir"] == "${hydra:runtime.cwd}": + cfg_file["config"]["exp"]["work_dir"] = Path.cwd() + + # resolve everything else + oc_config = OmegaConf.create(cfg_file["config"]) + dict_config: dict[str, Any] = OmegaConf.to_object(oc_config) # type: ignore + cfg_file["config"] = dict_config + + # don't need to comply with accumulate_grad_batches, that's runtime env dependent + cfg_file["config"]["trainer"]["batch_size"] *= cfg_file["config"][ + "trainer" + ].get("accumulate_grad_batches", 1) + cfg_file["config"]["trainer"]["accumulate_grad_batches"] = 1 + else: raise ValueError(f"Unknown option string {option_string}") From f2f107657095bc138ce8a4c224a857416262ebb7 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 20 Feb 2024 00:05:09 +0100 Subject: [PATCH 048/136] feat(main): add analysis subcommand --- fd_shifts/configs/__init__.py | 1 + fd_shifts/main.py | 20 ++++++++++++++------ 2 files changed, 15 insertions(+), 6 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 02e80b0..84a051e 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -112,6 +112,7 @@ class OutputPathsPerMode(_IterableMixin): encoded_output=Path("${test.dir}/encoded_output.npz"), attributions_output=Path("${test.dir}/attributions.csv"), ) + analysis: Path = SI("${test.dir}") @defer_validation diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 2bf866d..3292927 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -1,4 +1,3 @@ -import re import types import typing import warnings @@ -21,13 +20,13 @@ from pytorch_lightning.loggers.wandb import WandbLogger from rich.pretty import pretty_repr -from fd_shifts import analysis, logger -from fd_shifts.configs import Config, TestConfig +from fd_shifts import analysis as ana +from fd_shifts import logger +from fd_shifts.configs import Config from fd_shifts.experiments.configs import ( get_dataset_config, get_experiment_config, list_experiment_configs, - wilds_animals_query_config, ) from fd_shifts.experiments.tracker import get_path from fd_shifts.loaders.data_loader import FDShiftsDataLoader @@ -453,9 +452,13 @@ def test(config: Config): precision=16, ) trainer.test(model=module, datamodule=datamodule) - analysis.main( + + +@subcommand +def analysis(config: Config): + ana.main( in_path=config.test.dir, - out_path=config.test.dir, + out_path=config.exp.output_paths.analysis, query_studies=config.eval.query_studies, add_val_tuning=config.eval.val_tuning, threshold_plot_confid=None, @@ -463,6 +466,11 @@ def test(config: Config): ) +@subcommand +def debug(config: Config): + pass + + def _list_experiments(): rich.print("Available experiments:") for exp in sorted(list_experiment_configs()): From 0bb0a3eebc186e4f0f43c080baf467997161717f Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 20 Feb 2024 14:10:01 +0100 Subject: [PATCH 049/136] perf(main): delay imports for faster cli startup --- fd_shifts/analysis/__init__.py | 15 +++++--- fd_shifts/analysis/eval_utils.py | 60 +++++++++++++++++++++----------- fd_shifts/configs/__init__.py | 28 ++++++++------- fd_shifts/main.py | 56 +++++++++++++++++++---------- 4 files changed, 103 insertions(+), 56 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 4f8fed1..631c9d9 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -10,17 +10,14 @@ import numpy as np import numpy.typing as npt import pandas as pd -import torch from loguru import logger -from omegaconf import DictConfig, ListConfig, OmegaConf +from omegaconf import ListConfig from rich import inspect from scipy import special as scpspecial -from sklearn import neighbors from sklearn.calibration import _sigmoid_calibration as calib from fd_shifts import configs -from . import metrics from .confid_scores import ConfidScore, SecondaryConfidScore, is_external_confid from .eval_utils import ( ConfidEvaluator, @@ -361,6 +358,8 @@ def __call__(self, confids: npt.NDArray[Any]) -> npt.NDArray[Any]: class TemperatureScaling: def __init__(self, val_logits: npt.NDArray[Any], val_labels: npt.NDArray[Any]): + import torch + logger.info("Fit temperature to validation logits") self.temperature = torch.ones(1).requires_grad_(True) @@ -380,6 +379,8 @@ def _eval(): self.temperature = self.temperature.item() def __call__(self, logits: npt.NDArray[Any]) -> npt.NDArray[Any]: + import torch + return np.max( torch.softmax(torch.tensor(logits) / self.temperature, dim=1).numpy(), axis=1, @@ -394,6 +395,8 @@ def _react( clip_quantile=99, val_set_index=0, ): + import torch + logger.info("Compute REACT logits") logger.warning( "Currently uses validation set for clip parameter fit, will switch to training set in the future" @@ -425,6 +428,8 @@ def _maha_dist( dataset_idx: npt.NDArray[np.int_], val_set_index=0, ): + import torch + logger.info("Compute Mahalanobis distance") # mask = np.argwhere(dataset_idx == val_set_index)[:, 0] @@ -453,6 +458,8 @@ def _vim( features: npt.NDArray[np.float_], logits: npt.NDArray[np.float_], ): + import torch + logger.info("Compute ViM score") D = 512 w, b = last_layer diff --git a/fd_shifts/analysis/eval_utils.py b/fd_shifts/analysis/eval_utils.py index f706d3d..50a3d7b 100644 --- a/fd_shifts/analysis/eval_utils.py +++ b/fd_shifts/analysis/eval_utils.py @@ -1,19 +1,25 @@ +from __future__ import annotations + import math import os +from typing import TYPE_CHECKING -import matplotlib.pyplot as plt import numpy as np import pandas as pd import scipy import seaborn -import torch from sklearn import metrics as skm from sklearn.calibration import calibration_curve -from torchmetrics import Metric from . import logger from .metrics import StatsCache, get_metric_function +# from torchmetrics import Metric + + +if TYPE_CHECKING: + import torch + def _get_tb_hparams(cf): hparams_collection = {"fold": cf.exp.fold} @@ -29,6 +35,8 @@ def monitor_eval( do_plot=True, ext_confid_name=None, ): + import torch + out_metrics = {} out_plots = {} bins = 20 @@ -367,6 +375,8 @@ def __init__( self.threshold = None def compose_plot(self): + import matplotlib.pyplot as plt + seaborn.set(font_scale=self.fig_scale, style="whitegrid") self.colors_list = seaborn.hls_palette(len(self.confid_keys_list)).as_hex() n_columns = 2 @@ -681,29 +691,31 @@ def RC_curve(residuals, confidence): return curve, aurc, e_aurc -class BrierScore(Metric): - def __init__(self, num_classes, dist_sync_on_step=False): - # call `self.add_state`for every internal state that is needed for the metrics computations - # dist_reduce_fx indicates the function that should be used to reduce - # state from multiple processes - super().__init__(dist_sync_on_step=dist_sync_on_step) +# class BrierScore(Metric): +# def __init__(self, num_classes, dist_sync_on_step=False): +# import torch +# # call `self.add_state`for every internal state that is needed for the metrics computations +# # dist_reduce_fx indicates the function that should be used to reduce +# # state from multiple processes +# super().__init__(dist_sync_on_step=dist_sync_on_step) - self.num_classes = num_classes - self.add_state("brier_score", default=torch.tensor(0.0), dist_reduce_fx="sum") - self.add_state("total", default=torch.tensor(0), dist_reduce_fx="sum") +# self.num_classes = num_classes +# self.add_state("brier_score", default=torch.tensor(0.0), dist_reduce_fx="sum") +# self.add_state("total", default=torch.tensor(0), dist_reduce_fx="sum") - def update(self, preds: torch.Tensor, target: torch.Tensor): - # update metric states +# def update(self, preds: torch.Tensor, target: torch.Tensor): +# import torch +# # update metric states - y_one_hot = torch.nn.functional.one_hot(target, num_classes=self.num_classes) - assert preds.shape == y_one_hot.shape +# y_one_hot = torch.nn.functional.one_hot(target, num_classes=self.num_classes) +# assert preds.shape == y_one_hot.shape - self.brier_score += ((preds - y_one_hot) ** 2).sum(1).mean() - self.total += 1 +# self.brier_score += ((preds - y_one_hot) ** 2).sum(1).mean() +# self.total += 1 - def compute(self): - # compute final result - return self.brier_score.float() / self.total +# def compute(self): +# # compute final result +# return self.brier_score.float() / self.total def clean_logging(log_dir): @@ -716,6 +728,8 @@ def clean_logging(log_dir): def plot_input_imgs(x, y, out_path): + import matplotlib.pyplot as plt + f, axs = plt.subplots(nrows=4, ncols=4, figsize=(10, 10)) for ix in range(len(f.axes)): ax = f.axes[ix] @@ -728,6 +742,8 @@ def plot_input_imgs(x, y, out_path): def qual_plot(fp_dict, fn_dict, out_path): + import matplotlib.pyplot as plt + n_rows = len(fp_dict["images"]) f, axs = plt.subplots(nrows=n_rows, ncols=2, figsize=(6, 13)) title_pad = 0.85 @@ -761,6 +777,8 @@ def qual_plot(fp_dict, fn_dict, out_path): def ThresholdPlot(plot_dict): + import matplotlib.pyplot as plt + scale = 10 n_cols = len(plot_dict) n_rows = 1 diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 84a051e..fb87e90 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -8,28 +8,20 @@ from enum import Enum, auto from pathlib import Path from random import randint -from typing import TYPE_CHECKING, Any, Callable, Iterable, Iterator, Optional, TypeVar +from typing import TYPE_CHECKING, Any, Iterable, Optional, TypeVar -import pl_bolts -import torch from hydra.core.config_store import ConfigStore -from hydra_zen import builds # type: ignore from omegaconf import SI, DictConfig, OmegaConf -from omegaconf.omegaconf import MISSING from pydantic import ConfigDict, validator from pydantic.dataclasses import dataclass from typing_extensions import dataclass_transform -import fd_shifts -from fd_shifts import models -from fd_shifts.analysis import confid_scores, metrics -from fd_shifts.loaders import dataset_collection -from fd_shifts.utils import exp_utils +from fd_shifts import get_version -from ..models import networks from .iterable_mixin import _IterableMixin if TYPE_CHECKING: + import torch from pydantic.dataclasses import Dataclass ConfigT = TypeVar("ConfigT", bound=Dataclass) @@ -310,6 +302,8 @@ def validate_network_name(cls: NetworkConfig, name: str) -> str: Returns: name """ + from ..models import networks + if name is not None and not networks.network_exists(name): raise ValueError(f'Network "{name}" does not exist.') return name @@ -344,6 +338,8 @@ def validate_network_name(cls: ModelConfig, name: str) -> str: Returns: name """ + from fd_shifts import models + if name is not None and not models.model_exists(name): raise ValueError(f'Model "{name}" does not exist.') return name @@ -416,6 +412,8 @@ def validate(cls: ConfidMetricsConfig, name: str) -> str: Returns: name """ + from fd_shifts.analysis import metrics + if not metrics.metric_function_exists(name): raise ValueError(f'Confid metric function "{name}" does not exist.') return name @@ -440,6 +438,8 @@ def validate(cls: ConfidMeasuresConfig, name: str) -> str: Returns: name """ + from fd_shifts.analysis import confid_scores + if not confid_scores.confid_function_exists(name): raise ValueError(f'Confid function "{name}" does not exist.') return name @@ -467,6 +467,8 @@ def validate(cls, name: str) -> str: Returns: name """ + from fd_shifts.loaders import dataset_collection + if not dataset_collection.dataset_exists(name): raise ValueError(f'Dataset "{name}" does not exist.') return name @@ -549,7 +551,7 @@ class Config(_IterableMixin): exp: ExperimentConfig - pkgversion: str = fd_shifts.get_version() + pkgversion: str = get_version() data: DataConfig = field(default_factory=lambda: DataConfig()) @@ -561,6 +563,8 @@ class Config(_IterableMixin): test: TestConfig = field(default_factory=lambda: TestConfig()) def update_experiment(self, name: str): + from fd_shifts.utils import exp_utils + config = deepcopy(self) group_name = config.data.dataset group_dir = config.exp.group_dir.parent / group_name diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 3292927..ae69175 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -1,3 +1,5 @@ +from __future__ import annotations + import types import typing import warnings @@ -5,35 +7,17 @@ from contextvars import ContextVar from dataclasses import asdict, is_dataclass from pathlib import Path -from typing import Any, Callable, Optional +from typing import TYPE_CHECKING, Any, Callable, Optional import jsonargparse -import pytorch_lightning as pl import rich import yaml from jsonargparse import ActionConfigFile, ArgumentParser from jsonargparse._actions import Action from omegaconf import OmegaConf -from pytorch_lightning.callbacks.progress.rich_progress import RichProgressBar -from pytorch_lightning.loggers.csv_logs import CSVLogger -from pytorch_lightning.loggers.tensorboard import TensorBoardLogger -from pytorch_lightning.loggers.wandb import WandbLogger from rich.pretty import pretty_repr -from fd_shifts import analysis as ana -from fd_shifts import logger from fd_shifts.configs import Config -from fd_shifts.experiments.configs import ( - get_dataset_config, - get_experiment_config, - list_experiment_configs, -) -from fd_shifts.experiments.tracker import get_path -from fd_shifts.loaders.data_loader import FDShiftsDataLoader -from fd_shifts.models import get_model -from fd_shifts.models.callbacks import get_callbacks -from fd_shifts.utils import exp_utils -from fd_shifts.version import get_version __subcommands = {} @@ -85,6 +69,8 @@ def __call__(self, parser, cfg, values, option_string=None): @staticmethod def apply_experiment_config(parser: ArgumentParser, cfg, dest, value) -> None: + from fd_shifts.experiments.configs import get_experiment_config + with previous_config_context(cfg): experiment_cfg = get_experiment_config(value) tcfg = parser.parse_object( @@ -135,6 +121,8 @@ def set_default_error(): def apply_config(parser, cfg, dest, value, option_string) -> None: from jsonargparse._link_arguments import skip_apply_links + from fd_shifts.experiments.configs import get_dataset_config + with jsonargparse._actions._ActionSubCommands.not_single_subcommand(), previous_config_context( cfg ), skip_apply_links(): @@ -292,6 +280,8 @@ def omegaconf_resolve(config: Config): def setup_logging(): + from fd_shifts import logger + rich.reconfigure(stderr=True, force_terminal=True) logger.remove() # Remove default 'stderr' handler @@ -309,6 +299,18 @@ def setup_logging(): @subcommand def train(config: Config): + import pytorch_lightning as pl + from pytorch_lightning.callbacks.progress.rich_progress import RichProgressBar + from pytorch_lightning.loggers.csv_logs import CSVLogger + from pytorch_lightning.loggers.tensorboard import TensorBoardLogger + from pytorch_lightning.loggers.wandb import WandbLogger + + from fd_shifts import logger + from fd_shifts.loaders.data_loader import FDShiftsDataLoader + from fd_shifts.models import get_model + from fd_shifts.models.callbacks import get_callbacks + from fd_shifts.utils import exp_utils + progress = RichProgressBar(console_kwargs={"stderr": True, "force_terminal": True}) if config.exp.dir is None: @@ -397,6 +399,16 @@ def train(config: Config): @subcommand def test(config: Config): + import pytorch_lightning as pl + from pytorch_lightning.callbacks.progress.rich_progress import RichProgressBar + from pytorch_lightning.loggers.wandb import WandbLogger + + from fd_shifts import logger + from fd_shifts.loaders.data_loader import FDShiftsDataLoader + from fd_shifts.models import get_model + from fd_shifts.models.callbacks import get_callbacks + from fd_shifts.utils import exp_utils + progress = RichProgressBar(console_kwargs={"stderr": True, "force_terminal": True}) if config.exp.dir is None: @@ -456,6 +468,8 @@ def test(config: Config): @subcommand def analysis(config: Config): + from fd_shifts import analysis as ana + ana.main( in_path=config.test.dir, out_path=config.exp.output_paths.analysis, @@ -472,12 +486,16 @@ def debug(config: Config): def _list_experiments(): + from fd_shifts.experiments.configs import list_experiment_configs + rich.print("Available experiments:") for exp in sorted(list_experiment_configs()): rich.print(exp) def get_parser(): + from fd_shifts import get_version + parser = ArgumentParser(version=get_version()) parser.add_argument("-f", "--overwrite-config-file", action="store_true") subcommands = parser.add_subcommands(dest="command") From a944bef1764c6904f6a4d8f588d32de971c1538b Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 20 Feb 2024 18:20:07 +0100 Subject: [PATCH 050/136] fix(config): make noise_study a singular entry --- fd_shifts/configs/__init__.py | 18 +++++++++--------- fd_shifts/loaders/data_loader.py | 6 +++++- fd_shifts/main.py | 22 +++++++++++++++++++++- 3 files changed, 35 insertions(+), 11 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index fb87e90..ab91df0 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -72,13 +72,13 @@ def defer_validation(original_class: type[ConfigT]) -> type[ConfigT]: class OutputPathsConfig(_IterableMixin): """Where outputs are stored""" - raw_output: Path | None = None - raw_output_dist: Path | None = None - external_confids: Path | None = None - external_confids_dist: Path | None = None + raw_output: Path + raw_output_dist: Path + external_confids: Path + external_confids_dist: Path + encoded_output: Path + attributions_output: Path input_imgs_plot: Optional[Path] = None - encoded_output: Optional[Path] = None - attributions_output: Optional[Path] = None @defer_validation @@ -92,8 +92,8 @@ class OutputPathsPerMode(_IterableMixin): external_confids=Path("${exp.version_dir}/external_confids.npz"), external_confids_dist=Path("${exp.version_dir}/external_confids_dist.npz"), input_imgs_plot=Path("${exp.dir}/input_imgs.png"), - encoded_output=None, - attributions_output=None, + encoded_output=Path("${test.dir}/encoded_output.npz"), + attributions_output=Path("${test.dir}/attributions.csv"), ) test: OutputPathsConfig = OutputPathsConfig( raw_output=Path("${test.dir}/raw_logits.npz"), @@ -451,7 +451,7 @@ class QueryStudiesConfig(_IterableMixin): """Query Studies Configuration""" iid_study: str | None = None - noise_study: list[DataConfig] = field(default_factory=lambda: []) + noise_study: DataConfig = field(default_factory=lambda: DataConfig()) in_class_study: list[DataConfig] = field(default_factory=lambda: []) new_class_study: list[DataConfig] = field(default_factory=lambda: []) diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index 80aa22a..2e10bcd 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -51,7 +51,10 @@ def __init__(self, cf: configs.Config, no_norm_flag=False): self.external_test_sets = [] for key, values in self.query_studies: if key != "iid_study" and values is not None: - self.external_test_sets.extend(list(values)) + if key == "noise_study" and values.dataset is not None: + self.external_test_sets.append(values) + else: + self.external_test_sets.extend(list(values)) logging.debug( "CHECK flat list of external datasets %s", self.external_test_sets ) @@ -267,6 +270,7 @@ def setup(self, stage=None): target_transform=self.target_transforms, transform=self.augmentations["external_{}".format(ext_set)], kwargs=self.dataset_kwargs, + config=self.external_test_configs[ext_set], ) if ( self.devries_repro_ood_split diff --git a/fd_shifts/main.py b/fd_shifts/main.py index ae69175..35c880c 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -173,7 +173,16 @@ def apply_config(parser, cfg, dest, value, option_string) -> None: for k, v in cfg_file["config"]["eval"]["query_studies"].items(): if k == "iid_study": pass - elif k in ["in_class_study", "noise_study", "new_class_study"]: + elif k == "noise_study": + if len(v) == 0: + cfg_file["config"]["eval"]["query_studies"][k] = None + elif len(v) == 1: + cfg_file["config"]["eval"]["query_studies"][k] = asdict( + get_dataset_config(v[0]) + ) + else: + raise ValueError(f"Too many noise studies {v}") + elif k in ["in_class_study", "new_class_study"]: cfg_file["config"]["eval"]["query_studies"][k] = [ asdict(get_dataset_config(v2)) for v2 in v ] @@ -238,6 +247,17 @@ def __dict_to_dataclass(cfg, cls): return cls( **{k: __dict_to_dataclass(v, fieldtypes[k]) for k, v in cfg.items()} ) + if ( + isinstance(cls, types.UnionType) + and len(cls.__args__) == 2 + and cls.__args__[1] == type(None) + and is_dataclass(cls.__args__[0]) + and isinstance(cfg, dict) + ): + fieldtypes = typing.get_type_hints(cls.__args__[0]) + return cls.__args__[0]( + **{k: __dict_to_dataclass(v, fieldtypes[k]) for k, v in cfg.items()} + ) if typing.get_origin(cls) == list: return [__dict_to_dataclass(v, typing.get_args(cls)[0]) for v in cfg] if cls == Path or ( From a02015ab159d0ad59706fa059854c5366a2db961 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 20 Feb 2024 19:04:06 +0100 Subject: [PATCH 051/136] feat: save train encodings on test --- fd_shifts/configs/__init__.py | 4 ++ fd_shifts/loaders/data_loader.py | 8 ++++ fd_shifts/models/callbacks/confid_monitor.py | 41 +++++++++++++++++--- fd_shifts/models/clip_model.py | 2 +- fd_shifts/models/confidnet_model.py | 4 +- fd_shifts/models/devries_model.py | 2 +- fd_shifts/models/vit_model.py | 2 +- 7 files changed, 52 insertions(+), 11 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index ab91df0..bca68d4 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -77,6 +77,7 @@ class OutputPathsConfig(_IterableMixin): external_confids: Path external_confids_dist: Path encoded_output: Path + encoded_train: Path attributions_output: Path input_imgs_plot: Optional[Path] = None @@ -93,6 +94,7 @@ class OutputPathsPerMode(_IterableMixin): external_confids_dist=Path("${exp.version_dir}/external_confids_dist.npz"), input_imgs_plot=Path("${exp.dir}/input_imgs.png"), encoded_output=Path("${test.dir}/encoded_output.npz"), + encoded_train=Path("${test.dir}/train_features.npz"), attributions_output=Path("${test.dir}/attributions.csv"), ) test: OutputPathsConfig = OutputPathsConfig( @@ -102,6 +104,7 @@ class OutputPathsPerMode(_IterableMixin): external_confids_dist=Path("${test.dir}/external_confids_dist.npz"), input_imgs_plot=None, encoded_output=Path("${test.dir}/encoded_output.npz"), + encoded_train=Path("${test.dir}/train_features.npz"), attributions_output=Path("${test.dir}/attributions.csv"), ) analysis: Path = SI("${test.dir}") @@ -525,6 +528,7 @@ class TestConfig(_IterableMixin): external_confids_output_path: str = "external_confids.npz" output_precision: int = 16 selection_mode: Optional[str] = "max" + compute_train_encodings: bool = False @defer_validation diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index 2e10bcd..d9f3cab 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -24,6 +24,7 @@ class FDShiftsDataLoader(pl.LightningDataModule): def __init__(self, cf: configs.Config, no_norm_flag=False): super().__init__() + self.cf = cf self.crossval_ids_path = cf.exp.crossval_ids_path self.crossval_n_folds = cf.exp.crossval_n_folds self.fold = cf.exp.fold @@ -247,6 +248,13 @@ def setup(self, stage=None): self.test_datasets = [] + if self.cf.test.compute_train_encodings: + self.test_datasets.append(self.train_dataset) + logging.debug( + "Adding training data. (preliminary) len: %s", + len(self.test_datasets[-1]), + ) + if self.add_val_tuning: self.test_datasets.append(self.val_dataset) logging.debug( diff --git a/fd_shifts/models/callbacks/confid_monitor.py b/fd_shifts/models/callbacks/confid_monitor.py index 8acde26..90d42a0 100644 --- a/fd_shifts/models/callbacks/confid_monitor.py +++ b/fd_shifts/models/callbacks/confid_monitor.py @@ -7,7 +7,7 @@ from rich import print from tqdm import tqdm -from fd_shifts import configs +from fd_shifts import configs, logger from fd_shifts.analysis import eval_utils DTYPES = { @@ -70,6 +70,8 @@ def __init__(self, cf: configs.Config): self.output_paths = cf.exp.output_paths self.version_dir = cf.exp.version_dir self.val_every_n_epoch = cf.trainer.val_every_n_epoch + self.running_test_train_encoded = [] + self.running_test_train_labels = [] self.running_test_encoded = [] self.running_test_softmax = [] self.running_test_softmax_dist = [] @@ -476,9 +478,20 @@ def on_train_end(self, trainer, pl_module): def on_test_batch_end( self, trainer, pl_module, outputs, batch, batch_idx, dataloader_idx ): - if not hasattr(pl_module, "test_results"): + if not isinstance(outputs, dict): + return + + if self.cfg.test.compute_train_encodings and dataloader_idx == 0: + if outputs["encoded"] is not None: + self.running_test_train_encoded.extend( + outputs["encoded"].to(dtype=torch.float16).cpu() + ) + self.running_test_train_labels.extend(outputs["labels"].cpu()) return - outputs = pl_module.test_results + + if self.cfg.test.compute_train_encodings: + dataloader_idx -= 1 + if outputs["encoded"] is not None: self.running_test_encoded.extend( outputs["encoded"].to(dtype=torch.float16).cpu() @@ -501,6 +514,7 @@ def on_test_batch_end( ) def on_test_end(self, trainer, pl_module): + logger.info("Saving test outputs to disk") if not hasattr(pl_module, "test_results"): return @@ -529,6 +543,22 @@ def on_test_end(self, trainer, pl_module): np.savez_compressed( self.output_paths.test.encoded_output, encoded_output.cpu().data.numpy() ) + if len(self.running_test_train_encoded) > 0: + stacked_train_encoded = torch.stack(self.running_test_train_encoded, dim=0) + stacked_train_labels = torch.stack( + self.running_test_train_labels, dim=0 + ).unsqueeze(1) + encoded_train_output = torch.cat( + [ + stacked_train_encoded, + stacked_train_labels, + ], + dim=1, + ) + np.savez_compressed( + self.output_paths.test.encoded_train, + encoded_train_output.cpu().data.numpy(), + ) # try: # trainer.datamodule.test_datasets[0].csv.to_csv( # self.output_paths.test.attributions_output @@ -538,14 +568,13 @@ def on_test_end(self, trainer, pl_module): test_ds.csv.to_csv( f"{self.output_paths.test.attributions_output[:-4]}{ds_idx}.csv" ) - except: pass np.savez_compressed( self.output_paths.test.raw_output, raw_output.cpu().data.numpy() ) - tqdm.write( - "saved raw test outputs to {}".format(self.output_paths.test.raw_output) + logger.info( + "Saved raw test outputs to {}".format(self.output_paths.test.raw_output) ) if len(self.running_test_softmax_dist) > 0: diff --git a/fd_shifts/models/clip_model.py b/fd_shifts/models/clip_model.py index 7a6c794..5fa8812 100644 --- a/fd_shifts/models/clip_model.py +++ b/fd_shifts/models/clip_model.py @@ -54,7 +54,7 @@ def test_step(self, batch, batch_idx, dataset_idx): logits = image_features @ self.text_features.T - self.test_results = { + return { "logits": logits, "logits_dist": None, "labels": y, diff --git a/fd_shifts/models/confidnet_model.py b/fd_shifts/models/confidnet_model.py index d1910b0..87dad61 100644 --- a/fd_shifts/models/confidnet_model.py +++ b/fd_shifts/models/confidnet_model.py @@ -256,7 +256,7 @@ def test_step( batch: tuple[torch.Tensor, torch.Tensor], batch_idx: int, dataloader_id: int | None = None, - ) -> None: + ) -> dict[str, torch.Tensor | None]: x, y = batch z = self.backbone.forward_features(x) @@ -272,7 +272,7 @@ def test_step( x=x, n_samples=self.test_mcd_samples ) - self.test_results = { + return { "logits": logits, "logits_dist": logits_dist, "labels": y, diff --git a/fd_shifts/models/devries_model.py b/fd_shifts/models/devries_model.py index f887e7e..7c8c73c 100644 --- a/fd_shifts/models/devries_model.py +++ b/fd_shifts/models/devries_model.py @@ -302,7 +302,7 @@ def test_step(self, batch, batch_idx, *args): x=x, n_samples=self.test_mcd_samples ) - self.test_results = { + return { "logits": logits, "labels": y, "confid": confidence, diff --git a/fd_shifts/models/vit_model.py b/fd_shifts/models/vit_model.py index a01678f..631888b 100644 --- a/fd_shifts/models/vit_model.py +++ b/fd_shifts/models/vit_model.py @@ -213,7 +213,7 @@ def test_step(self, batch, batch_idx, *args): x=x, n_samples=self.test_mcd_samples ) - self.test_results = { + return { "logits": probs, "labels": y, "confid": maha, From c12d74289780e0b90bf12854cacd24d379ac4d74 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 20 Feb 2024 19:05:05 +0100 Subject: [PATCH 052/136] feat: subsample corruption dataset --- fd_shifts/configs/__init__.py | 1 + fd_shifts/loaders/dataset_collection.py | 48 +++++++++++++++++++++++++ 2 files changed, 49 insertions(+) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index bca68d4..54dc04b 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -545,6 +545,7 @@ class DataConfig(_IterableMixin): reproduce_confidnet_splits: bool = False augmentations: dict[str, dict[str, Any]] | None = None target_transforms: Optional[Any] = None + subsample_corruptions: int = 10 kwargs: Optional[dict[Any, Any]] = None diff --git a/fd_shifts/loaders/dataset_collection.py b/fd_shifts/loaders/dataset_collection.py index 0239552..f331920 100644 --- a/fd_shifts/loaders/dataset_collection.py +++ b/fd_shifts/loaders/dataset_collection.py @@ -29,6 +29,7 @@ from fd_shifts import logger from fd_shifts.analysis import eval_utils +from fd_shifts.configs import Config, DataConfig from fd_shifts.data import SVHN from fd_shifts.loaders import breeds_hierarchies @@ -802,6 +803,7 @@ def __init__( download: bool, transform: Optional[Callable] = None, target_transform: Optional[Callable] = None, + subsample: int = 1, kwargs: Optional[Callable] = None, ) -> None: super(CorruptCIFAR, self).__init__( @@ -840,8 +842,43 @@ def __init__( self.targets.extend(labels) self.data = np.vstack(self.data) + self.targets = np.array(self.targets) + + if subsample > 1: + self.data, self.targets = self.subsample(self.data, self.targets, subsample) self.classes = eval_utils.cifar100_classes + @staticmethod + def subsample(data, targets, subsample): + n_classes = len(np.unique(targets)) + n_cor_kinds = 15 + n_cor_levels = 5 + n_samples_per_cor = len(targets) // n_cor_kinds // n_cor_levels + n_samples_per_class_per_cor = n_samples_per_cor // n_classes + + single_targets = targets[:n_samples_per_cor] + + sort_idx = np.argsort(single_targets, kind="stable") + single_idx = np.sort( + np.concatenate( + [ + i * n_samples_per_class_per_cor + + np.arange(n_samples_per_class_per_cor // subsample) + for i in range(n_classes) + ] + ) + ) + idx = np.concatenate( + [ + cor_kind_idx * n_samples_per_cor * n_cor_levels + + cor_level_idx * n_samples_per_cor + + single_idx + for cor_kind_idx in range(n_cor_kinds) + for cor_level_idx in range(n_cor_levels) + ] + ) + return data[idx, :], targets[idx] + def __getitem__(self, index: int) -> Tuple[Any, Any]: """ Args: @@ -963,6 +1000,8 @@ def __init__(self, root, train, download, transform): ) logger.debug("CHECK ROOT !!! {}", root) + if isinstance(root, str): + root = Path(root) categories = { r[1]: r[2] for r in pd.read_csv(root / "iwildcam_v2.0" / "categories.csv")[ @@ -1253,6 +1292,7 @@ def get_dataset( transform: Callable, target_transform: Callable | None, kwargs: dict[str, Any], + config: DataConfig | None = None, ) -> Any: """Return a new instance of a dataset @@ -1274,6 +1314,14 @@ def get_dataset( "download": download, "transform": transform, } + if name.startswith("corrupt_cifar"): + pass_kwargs = { + "root": root, + "train": train, + "download": download, + "transform": transform, + "subsample": config.subsample_corruptions if config else 1, + } if name.startswith("svhn"): pass_kwargs = { "root": root, From 4e30e65314bf4f9223c8010fc0fe463e2e8c54f1 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 20 Feb 2024 19:10:08 +0100 Subject: [PATCH 053/136] feat: write config file only if not exists or overwrite --- fd_shifts/main.py | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 35c880c..84c0456 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -559,13 +559,14 @@ def main(): rich.print(config) # TODO: Check if configs are the same - config.test.cf_path.parent.mkdir(parents=True, exist_ok=True) - subparsers[args.command].save( - args[args.command], - config.test.cf_path, - skip_check=True, - overwrite=args.overwrite_config_file, - ) + if not config.test.cf_path.is_file() or args.overwrite_config_file: + config.test.cf_path.parent.mkdir(parents=True, exist_ok=True) + subparsers[args.command].save( + args[args.command], + config.test.cf_path, + skip_check=True, + overwrite=args.overwrite_config_file, + ) __subcommands[args.command](config=config) From 5b58267bde6e813fde022f3345572ea5897d072c Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 10:49:13 +0100 Subject: [PATCH 054/136] fix: some fixes for noise study handling --- fd_shifts/analysis/__init__.py | 20 ++++--- fd_shifts/analysis/studies.py | 38 +++++++++++++- fd_shifts/loaders/data_loader.py | 16 +++--- fd_shifts/main.py | 90 ++++++++++++++++++++++---------- 4 files changed, 119 insertions(+), 45 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 631c9d9..bd70921 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -192,7 +192,12 @@ def dataset_name_to_idx(self, dataset_name: str) -> int: if isinstance(datasets[0], configs.DataConfig): datasets = map(lambda d: d.dataset, datasets) flat_test_set_list.extend(list(datasets)) - else: + elif ( + isinstance(datasets, configs.DataConfig) + and datasets.dataset is not None + ): + flat_test_set_list.append(datasets.dataset) + elif isinstance(datasets, str): flat_test_set_list.append(datasets) logger.error(f"{flat_test_set_list=}") @@ -398,12 +403,7 @@ def _react( import torch logger.info("Compute REACT logits") - logger.warning( - "Currently uses validation set for clip parameter fit, will switch to training set in the future" - ) - # mask = np.argwhere(dataset_idx == val_set_index)[:, 0] - # val_features = features[mask] clip = torch.tensor(np.quantile(train_features[:, :-1], clip_quantile / 100)) w, b = last_layer @@ -426,13 +426,11 @@ def _maha_dist( labels: npt.NDArray[np.int_], predicted: npt.NDArray[np.int_], dataset_idx: npt.NDArray[np.int_], - val_set_index=0, ): import torch logger.info("Compute Mahalanobis distance") - # mask = np.argwhere(dataset_idx == val_set_index)[:, 0] val_features = train_features[:, :-1] val_labels = train_features[:, -1] @@ -621,6 +619,12 @@ def __init__( self.query_studies.__dict__[study_name] = list( map(lambda d: d.dataset, datasets) ) + if isinstance(datasets, configs.DataConfig): + if datasets.dataset is not None: + self.query_studies.__dict__[study_name] = [datasets.dataset] + else: + self.query_studies.__dict__[study_name] = [] + self.analysis_out_dir = analysis_out_dir self.calibration_bins = 20 self.val_risk_scores = {} diff --git a/fd_shifts/analysis/studies.py b/fd_shifts/analysis/studies.py index e3940d0..3a7f8c8 100644 --- a/fd_shifts/analysis/studies.py +++ b/fd_shifts/analysis/studies.py @@ -1,7 +1,7 @@ from __future__ import annotations from copy import deepcopy -from typing import TYPE_CHECKING, Any, Callable, Iterator, Tuple +from typing import TYPE_CHECKING, Any, Callable, Iterator, Tuple, overload import numpy as np import numpy.typing as npt @@ -385,7 +385,21 @@ def __filter_intensity_3d(data, mask, noise_level): :, noise_level ].reshape(-1, data.shape[-2], data.shape[-1]) - def __filter_intensity_2d(data, mask, noise_level): + @overload + def __filter_intensity_2d( + data: npt.NDArray[Any], mask: npt.NDArray[Any], noise_level: int + ) -> npt.NDArray[Any]: + ... + + @overload + def __filter_intensity_2d( + data: None, mask: npt.NDArray[Any], noise_level: int + ) -> None: + ... + + def __filter_intensity_2d( + data: npt.NDArray[Any] | None, mask: npt.NDArray[Any], noise_level: int + ) -> npt.NDArray[Any] | None: if data is None: return None @@ -398,6 +412,18 @@ def __filter_intensity_2d(data, mask, noise_level): -1, data.shape[-1] ) + @overload + def __filter_intensity_1d( + data: npt.NDArray[Any], mask: npt.NDArray[Any], noise_level: int + ) -> npt.NDArray[Any]: + ... + + @overload + def __filter_intensity_1d( + data: None, mask: npt.NDArray[Any], noise_level: int + ) -> None: + ... + def __filter_intensity_1d(data, mask, noise_level): if data is None: return None @@ -429,6 +455,14 @@ def __filter_intensity_1d(data, mask, noise_level): data.mcd_logits_dist, select_ix, noise_level ), config=data.config, + _correct=__filter_intensity_1d(data._correct, select_ix, noise_level), + _mcd_correct=__filter_intensity_1d(data._mcd_correct, select_ix, noise_level), + _mcd_labels=__filter_intensity_1d(data._mcd_labels, select_ix, noise_level), + _react_logits=__filter_intensity_2d(data._react_logits, select_ix, noise_level), + _maha_dist=__filter_intensity_1d(data._maha_dist, select_ix, noise_level), + _vim_score=__filter_intensity_1d(data._vim_score, select_ix, noise_level), + _dknn_dist=__filter_intensity_1d(data._dknn_dist, select_ix, noise_level), + _train_features=data._train_features, ) diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index d9f3cab..41f0844 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -51,13 +51,15 @@ def __init__(self, cf: configs.Config, no_norm_flag=False): if self.query_studies is not None: self.external_test_sets = [] for key, values in self.query_studies: - if key != "iid_study" and values is not None: - if key == "noise_study" and values.dataset is not None: - self.external_test_sets.append(values) - else: - self.external_test_sets.extend(list(values)) - logging.debug( - "CHECK flat list of external datasets %s", self.external_test_sets + if ( + isinstance(values, configs.DataConfig) + and values.dataset is not None + ): + self.external_test_sets.append(values) + elif isinstance(values, list): + self.external_test_sets.extend(list(values)) + logger.debug( + f"CHECK flat list of external datasets {self.external_test_sets}" ) if len(self.external_test_sets) > 0: diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 84c0456..01abe7f 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -17,7 +17,7 @@ from omegaconf import OmegaConf from rich.pretty import pretty_repr -from fd_shifts.configs import Config +from fd_shifts.configs import Config, DataConfig, OutputPathsPerMode __subcommands = {} @@ -175,7 +175,9 @@ def apply_config(parser, cfg, dest, value, option_string) -> None: pass elif k == "noise_study": if len(v) == 0: - cfg_file["config"]["eval"]["query_studies"][k] = None + cfg_file["config"]["eval"]["query_studies"][k] = asdict( + DataConfig() + ) elif len(v) == 1: cfg_file["config"]["eval"]["query_studies"][k] = asdict( get_dataset_config(v[0]) @@ -200,6 +202,26 @@ def apply_config(parser, cfg, dest, value, option_string) -> None: if cfg_file["config"]["exp"]["work_dir"] == "${hydra:runtime.cwd}": cfg_file["config"]["exp"]["work_dir"] = Path.cwd() + # some paths could previously be none + if ( + cfg_file["config"]["exp"]["output_paths"]["fit"].get( + "encoded_output", "" + ) + is None + ): + cfg_file["config"]["exp"]["output_paths"]["fit"][ + "encoded_output" + ] = OutputPathsPerMode().fit.encoded_output + if ( + cfg_file["config"]["exp"]["output_paths"]["fit"].get( + "attributions_output", "" + ) + is None + ): + cfg_file["config"]["exp"]["output_paths"]["fit"][ + "attributions_output" + ] = OutputPathsPerMode().fit.attributions_output + # resolve everything else oc_config = OmegaConf.create(cfg_file["config"]) dict_config: dict[str, Any] = OmegaConf.to_object(oc_config) # type: ignore @@ -241,34 +263,46 @@ def __path_to_str(cfg): def _dict_to_dataclass(cfg) -> Config: - def __dict_to_dataclass(cfg, cls): - if is_dataclass(cls): - fieldtypes = typing.get_type_hints(cls) - return cls( - **{k: __dict_to_dataclass(v, fieldtypes[k]) for k, v in cfg.items()} - ) - if ( - isinstance(cls, types.UnionType) - and len(cls.__args__) == 2 - and cls.__args__[1] == type(None) - and is_dataclass(cls.__args__[0]) - and isinstance(cfg, dict) - ): - fieldtypes = typing.get_type_hints(cls.__args__[0]) - return cls.__args__[0]( - **{k: __dict_to_dataclass(v, fieldtypes[k]) for k, v in cfg.items()} - ) - if typing.get_origin(cls) == list: - return [__dict_to_dataclass(v, typing.get_args(cls)[0]) for v in cfg] - if cls == Path or ( - isinstance(cls, types.UnionType) - and Path in cls.__args__ - and cfg is not None - ): - return Path(cfg) + def __dict_to_dataclass(cfg, cls, key): + try: + if is_dataclass(cls): + fieldtypes = typing.get_type_hints(cls) + return cls( + **{ + k: __dict_to_dataclass(v, fieldtypes[k], k) + for k, v in cfg.items() + } + ) + if ( + isinstance(cls, types.UnionType) + and len(cls.__args__) == 2 + and cls.__args__[1] == type(None) + and is_dataclass(cls.__args__[0]) + and isinstance(cfg, dict) + ): + fieldtypes = typing.get_type_hints(cls.__args__[0]) + return cls.__args__[0]( + **{ + k: __dict_to_dataclass(v, fieldtypes[k], k) + for k, v in cfg.items() + } + ) + if typing.get_origin(cls) == list: + return [ + __dict_to_dataclass(v, typing.get_args(cls)[0], key) for v in cfg + ] + if cls == Path or ( + isinstance(cls, types.UnionType) + and Path in cls.__args__ + and cfg is not None + ): + return Path(cfg) + except: + print(key) + raise return cfg - return __dict_to_dataclass(cfg, Config) # type: ignore + return __dict_to_dataclass(cfg, Config, "") # type: ignore def omegaconf_resolve(config: Config): From 3a13dd3a328c45848356eec3059b65138f22ce82 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 10:50:19 +0100 Subject: [PATCH 055/136] feat: add super_cifar configs --- fd_shifts/experiments/configs.py | 88 +++++++++++++++++++++++++------- 1 file changed, 69 insertions(+), 19 deletions(-) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index d0344c3..7454699 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -59,8 +59,6 @@ def svhn_query_config( return QueryStudiesConfig( iid_study="svhn" + ("_384" if img_size[0] == 384 else ""), - noise_study=[], - in_class_study=[], new_class_study=[ cifar10_data_config(img_size=img_size), cifar100_data_config(img_size=img_size), @@ -120,10 +118,7 @@ def cifar10_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: return QueryStudiesConfig( iid_study="cifar10" + ("_384" if img_size[0] == 384 else ""), - noise_study=[ - cifar10_data_config("corrupt_cifar10", img_size), - ], - in_class_study=[], + noise_study=cifar10_data_config("corrupt_cifar10", img_size), new_class_study=[ cifar100_data_config(img_size=img_size), svhn_data_config("svhn", img_size), @@ -133,7 +128,7 @@ def cifar10_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: def cifar100_data_config( - dataset: Literal["cifar100", "corrupt_cifar100"] = "cifar100", + dataset: Literal["cifar100", "corrupt_cifar100", "super_cifar100"] = "cifar100", img_size: int | tuple[int, int] = 32, ) -> DataConfig: if isinstance(img_size, int): @@ -158,11 +153,14 @@ def cifar100_data_config( return DataConfig( dataset=dataset, - data_dir=SI("${oc.env:DATASET_ROOT_DIR}/" + dataset), + data_dir=SI( + "${oc.env:DATASET_ROOT_DIR}/" + + ("cifar100" if dataset in ["cifar100", "super_cifar100"] else dataset) + ), pin_memory=True, img_size=(img_size[0], img_size[1], 3), num_workers=12, - num_classes=100, + num_classes=19 if dataset == "super_cifar100" else 100, reproduce_confidnet_splits=True, augmentations={ "train": train_augmentations, @@ -174,21 +172,26 @@ def cifar100_data_config( ) -def cifar100_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: +def cifar100_query_config( + img_size: int | tuple[int, int], + dataset: Literal["cifar100", "super_cifar100"] = "cifar100", +) -> QueryStudiesConfig: if isinstance(img_size, int): img_size = (img_size, img_size) return QueryStudiesConfig( - iid_study="cifar100" + ("_384" if img_size[0] == 384 else ""), - noise_study=[ - cifar100_data_config("corrupt_cifar100", img_size), - ], + iid_study=dataset + ("_384" if img_size[0] == 384 else ""), + noise_study=cifar100_data_config("corrupt_cifar100", img_size) + if dataset == "cifar100" + else DataConfig(), in_class_study=[], new_class_study=[ cifar10_data_config(img_size=img_size), svhn_data_config("svhn", img_size), tinyimagenet_data_config(img_size), - ], + ] + if dataset == "cifar100" + else [], ) @@ -234,7 +237,6 @@ def wilds_animals_query_config( return QueryStudiesConfig( iid_study="wilds_animals" + ("_384" if img_size[0] == 384 else ""), - noise_study=[], in_class_study=[wilds_animals_data_config("wilds_animals_ood_test", img_size)], new_class_study=[], ) @@ -284,7 +286,6 @@ def wilds_camelyon_query_config( return QueryStudiesConfig( iid_study="wilds_camelyon" + ("_384" if img_size[0] == 384 else ""), - noise_study=[], in_class_study=[ wilds_camelyon_data_config("wilds_camelyon_ood_test", img_size) ], @@ -335,9 +336,7 @@ def breeds_query_config(img_size: int | tuple[int, int] = 224) -> QueryStudiesCo return QueryStudiesConfig( iid_study="breeds" + ("_384" if img_size[0] == 384 else ""), - noise_study=[], in_class_study=[breeds_data_config("breeds_ood_test", img_size)], - new_class_study=[], ) @@ -378,6 +377,8 @@ def tinyimagenet_data_config(img_size: int | tuple[int, int] = 64) -> DataConfig "cifar10_384": cifar10_data_config(img_size=384), "cifar100": cifar100_data_config(), "cifar100_384": cifar100_data_config(img_size=384), + "super_cifar100": cifar100_data_config(dataset="super_cifar100"), + "super_cifar100_384": cifar100_data_config(img_size=384, dataset="super_cifar100"), "corrupt_cifar10": cifar10_data_config(dataset="corrupt_cifar10"), "corrupt_cifar10_384": cifar10_data_config(dataset="corrupt_cifar10", img_size=384), "corrupt_cifar100": cifar100_data_config(dataset="corrupt_cifar100"), @@ -726,6 +727,36 @@ def cnn_cifar100_modeldg(run: int, do: int, rew: float): return config +def cnn_super_cifar100_modelconfidnet(run: int, do: int, **kwargs): + config = cnn_cifar100_modelconfidnet(run, do, **kwargs) + config.exp.group_name = "supercifar_paper_sweep" + config.data = cifar100_data_config(dataset="super_cifar100", img_size=32) + config.eval.query_studies = cifar100_query_config( + dataset="super_cifar100", img_size=32 + ) + return config + + +def cnn_super_cifar100_modeldevries(run: int, do: int, **kwargs): + config = cnn_cifar100_modeldevries(run, do, **kwargs) + config.exp.group_name = "supercifar_paper_sweep" + config.data = cifar100_data_config(dataset="super_cifar100", img_size=32) + config.eval.query_studies = cifar100_query_config( + dataset="super_cifar100", img_size=32 + ) + return config + + +def cnn_super_cifar100_modeldg(run: int, do: int, rew: float): + config = cnn_cifar100_modeldg(run, do, rew) + config.exp.group_name = "supercifar_paper_sweep" + config.data = cifar100_data_config(dataset="super_cifar100", img_size=32) + config.eval.query_studies = cifar100_query_config( + dataset="super_cifar100", img_size=32 + ) + return config + + def cnn_breeds(name: str): config = cnn("breeds_paper_sweep", name=name) config.data = breeds_data_config() @@ -1174,6 +1205,25 @@ def register(config_fn: Callable[..., Config], n_runs: int = 5, **kwargs): register(cnn_cifar100_modeldg, do=0, rew=20) register(cnn_cifar100_modeldg, do=1, rew=20) +register(cnn_super_cifar100_modeldevries, do=0) +register(cnn_super_cifar100_modeldevries, do=1) +register(cnn_super_cifar100_modelconfidnet, do=0) +register(cnn_super_cifar100_modelconfidnet, do=1) +register(cnn_super_cifar100_modeldg, do=0, rew=2.2) +register(cnn_super_cifar100_modeldg, do=1, rew=2.2) +register(cnn_super_cifar100_modeldg, do=0, rew=3) +register(cnn_super_cifar100_modeldg, do=1, rew=3) +register(cnn_super_cifar100_modeldg, do=0, rew=6) +register(cnn_super_cifar100_modeldg, do=1, rew=6) +register(cnn_super_cifar100_modeldg, do=0, rew=10) +register(cnn_super_cifar100_modeldg, do=1, rew=10) +register(cnn_super_cifar100_modeldg, do=0, rew=12) +register(cnn_super_cifar100_modeldg, do=1, rew=12) +register(cnn_super_cifar100_modeldg, do=0, rew=15) +register(cnn_super_cifar100_modeldg, do=1, rew=15) +register(cnn_super_cifar100_modeldg, do=0, rew=20) +register(cnn_super_cifar100_modeldg, do=1, rew=20) + register(cnn_animals_modeldevries, do=0) register(cnn_animals_modeldevries, do=1) register(cnn_animals_modelconfidnet, do=0) From 81733211cf9e26e8b85d262355c909cb373be4e5 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 10:51:51 +0100 Subject: [PATCH 056/136] fix: write out last_layer, fix vim --- fd_shifts/analysis/__init__.py | 10 ++++++-- fd_shifts/models/callbacks/confid_monitor.py | 7 ++++-- fd_shifts/models/confidnet_model.py | 22 ++++++++++++++++- fd_shifts/models/devries_model.py | 26 ++++++++++++++++++-- 4 files changed, 58 insertions(+), 7 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index bd70921..84c68b2 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -459,7 +459,13 @@ def _vim( import torch logger.info("Compute ViM score") - D = 512 + if features.shape[-1] >= 2048: + D = 1000 + elif features.shape[-1] >= 768: + D = 512 + else: + D = features.shape[-1] // 2 + w, b = last_layer w = torch.tensor(w, dtype=torch.float) b = torch.tensor(b, dtype=torch.float) @@ -596,7 +602,7 @@ def __init__( ): self.method_dict["query_confids"].append("maha") self.method_dict["query_confids"].append("dknn") - # self.method_dict["query_confids"].append("vim") + self.method_dict["query_confids"].append("vim") self.method_dict["query_confids"].append("react_det_mcp") self.method_dict["query_confids"].append("react_det_mls") self.method_dict["query_confids"].append("react_temp_mls") diff --git a/fd_shifts/models/callbacks/confid_monitor.py b/fd_shifts/models/callbacks/confid_monitor.py index 90d42a0..dcc86f5 100644 --- a/fd_shifts/models/callbacks/confid_monitor.py +++ b/fd_shifts/models/callbacks/confid_monitor.py @@ -515,8 +515,6 @@ def on_test_batch_end( def on_test_end(self, trainer, pl_module): logger.info("Saving test outputs to disk") - if not hasattr(pl_module, "test_results"): - return stacked_softmax = torch.stack(self.running_test_softmax, dim=0) stacked_labels = torch.stack(self.running_test_labels, dim=0).unsqueeze(1) @@ -559,6 +557,11 @@ def on_test_end(self, trainer, pl_module): self.output_paths.test.encoded_train, encoded_train_output.cpu().data.numpy(), ) + w, b = pl_module.last_layer() + w = w.cpu().numpy() + b = b.cpu().numpy() + np.savez_compressed(self.cfg.test.dir / "last_layer.npz", w=w, b=b) + # try: # trainer.datamodule.test_datasets[0].csv.to_csv( # self.output_paths.test.attributions_output diff --git a/fd_shifts/models/confidnet_model.py b/fd_shifts/models/confidnet_model.py index 87dad61..620155e 100644 --- a/fd_shifts/models/confidnet_model.py +++ b/fd_shifts/models/confidnet_model.py @@ -267,7 +267,9 @@ def test_step( logits_dist = None pred_confid_dist = None - if any("mcd" in cfd for cfd in self.query_confids.test): + if any("mcd" in cfd for cfd in self.query_confids.test) and ( + not (self.conf.test.compute_train_encodings and dataloader_id == 0) + ): logits_dist, pred_confid_dist = self.mcd_eval_forward( x=x, n_samples=self.test_mcd_samples ) @@ -330,3 +332,21 @@ def load_only_state_dict(self, path: str | Path) -> None: logger.info("loading checkpoint from epoch {}".format(ckpt["epoch"])) self.load_state_dict(ckpt["state_dict"], strict=False) + + def last_layer(self): + state = self.state_dict() + model_prefix = "backbone" + if f"{model_prefix}._classifier.module.weight" in state: + w = state[f"{model_prefix}._classifier.module.weight"] + b = state[f"{model_prefix}._classifier.module.bias"] + elif f"{model_prefix}._classifier.fc.weight" in state: + w = state[f"{model_prefix}._classifier.fc.weight"] + b = state[f"{model_prefix}._classifier.fc.bias"] + elif f"{model_prefix}._classifier.fc2.weight" in state: + w = state[f"{model_prefix}._classifier.fc2.weight"] + b = state[f"{model_prefix}._classifier.fc2.bias"] + else: + print(list(state.keys())) + raise RuntimeError("No classifier weights found") + + return w, b diff --git a/fd_shifts/models/devries_model.py b/fd_shifts/models/devries_model.py index 7c8c73c..075e3d6 100644 --- a/fd_shifts/models/devries_model.py +++ b/fd_shifts/models/devries_model.py @@ -47,6 +47,8 @@ def __init__(self, cf: configs.Config): self.save_hyperparameters(to_dict(cf)) + self.cf = cf + self.optimizer_cfgs = cf.trainer.optimizer self.lr_scheduler_cfgs = cf.trainer.lr_scheduler self.lr_scheduler_interval = cf.trainer.lr_scheduler_interval @@ -280,7 +282,7 @@ def validation_step(self, batch, batch_idx): def validation_step_end(self, batch_parts): return batch_parts - def test_step(self, batch, batch_idx, *args): + def test_step(self, batch, batch_idx, dataloader_idx, *args): x, y = batch z = self.model.forward_features(x) if self.ext_confid_name == "devries": @@ -297,7 +299,9 @@ def test_step(self, batch, batch_idx, *args): logits_dist = None confid_dist = None - if any("mcd" in cfd for cfd in self.query_confids.test): + if any("mcd" in cfd for cfd in self.query_confids.test) and ( + not (self.cf.test.compute_train_encodings and dataloader_idx == 0) + ): logits_dist, confid_dist = self.mcd_eval_forward( x=x, n_samples=self.test_mcd_samples ) @@ -366,3 +370,21 @@ def load_only_state_dict(self, path: str | Path) -> None: logger.info("loading checkpoint from epoch {}".format(ckpt["epoch"])) self.load_state_dict(ckpt["state_dict"], strict=True) + + def last_layer(self): + state = self.state_dict() + model_prefix = "model" + if f"{model_prefix}._classifier.module.weight" in state: + w = state[f"{model_prefix}._classifier.module.weight"] + b = state[f"{model_prefix}._classifier.module.bias"] + elif f"{model_prefix}._classifier.fc.weight" in state: + w = state[f"{model_prefix}._classifier.fc.weight"] + b = state[f"{model_prefix}._classifier.fc.bias"] + elif f"{model_prefix}._classifier.fc2.weight" in state: + w = state[f"{model_prefix}._classifier.fc2.weight"] + b = state[f"{model_prefix}._classifier.fc2.bias"] + else: + print(list(state.keys())) + raise RuntimeError("No classifier weights found") + + return w, b From c79644018d8baf1578ca31bac9bc0d39aa6d51fc Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 10:52:50 +0100 Subject: [PATCH 057/136] feat: analysis load data from store path --- fd_shifts/analysis/__init__.py | 88 +++++++++++++++++++++++----------- 1 file changed, 60 insertions(+), 28 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 84c68b2..d28a8b0 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -4,7 +4,7 @@ from dataclasses import dataclass, field from numbers import Number from pathlib import Path -from typing import Any +from typing import Any, Literal, overload import faiss import numpy as np @@ -246,6 +246,39 @@ def __load_npz_if_exists(path: Path) -> npt.NDArray[np.float64] | None: with np.load(path) as npz: return npz.f.arr_0 + @overload + @staticmethod + def __load_from_store( + config: configs.Config, file: str + ) -> npt.NDArray[np.float64] | None: + ... + + @overload + @staticmethod + def __load_from_store( + config: configs.Config, file: str, unpack: Literal[False] + ) -> dict[str, npt.NDArray[np.float64]] | None: + ... + + @staticmethod + def __load_from_store( + config: configs.Config, file: str, unpack: bool = True + ) -> npt.NDArray[np.float64] | dict[str, npt.NDArray[np.float64]] | None: + store_paths = map(Path, os.getenv("FD_SHIFTS_STORE_PATH", "").split(":")) + + test_dir = config.test.dir.relative_to(os.getenv("EXPERIMENT_ROOT_DIR", "")) + + for store_path in store_paths: + if (store_path / test_dir / file).is_file(): + logger.debug(f"Loading {store_path / test_dir / file}") + with np.load(store_path / test_dir / file) as npz: + if unpack: + return npz.f.arr_0.astype(np.float64) + else: + return dict(npz.items()) + + return None + @staticmethod def from_experiment( test_dir: Path, @@ -255,10 +288,9 @@ def from_experiment( if not isinstance(test_dir, Path): test_dir = Path(test_dir) - if (test_dir / "raw_logits.npz").is_file(): - with np.load(test_dir / "raw_logits.npz") as npz: - raw_output = npz.f.arr_0.astype(np.float64) - + if ( + raw_output := ExperimentData.__load_from_store(config, "raw_logits.npz") + ) is not None: logits = raw_output[:, :-2] softmax = scpspecial.softmax(logits, axis=1) @@ -266,8 +298,8 @@ def from_experiment( "mcd" in confid for confid in config.eval.confidence_measures.test ) and ( ( - mcd_logits_dist := ExperimentData.__load_npz_if_exists( - test_dir / "raw_logits_dist.npz" + mcd_logits_dist := ExperimentData.__load_from_store( + config, "raw_logits_dist.npz" ) ) is not None @@ -277,15 +309,14 @@ def from_experiment( mcd_logits_dist = None mcd_softmax_dist = None - elif (test_dir / "raw_output.npz").is_file(): - with np.load(test_dir / "raw_output.npz") as npz: - raw_output = npz.f.arr_0 - + elif ( + raw_output := ExperimentData.__load_from_store(config, "raw_output.npz") + ) is not None: logits = None mcd_logits_dist = None softmax = raw_output[:, :-2] - mcd_softmax_dist = ExperimentData.__load_npz_if_exists( - test_dir / "raw_output_dist.npz" + mcd_softmax_dist = ExperimentData.__load_from_store( + config, "raw_output_dist.npz" ) else: raise FileNotFoundError(f"Could not find model output in {test_dir}") @@ -304,29 +335,30 @@ def from_experiment( mcd_logits_dist[:, holdout_classes, :] = -np.inf mcd_softmax_dist = scpspecial.softmax(mcd_logits_dist, axis=1) - external_confids = ExperimentData.__load_npz_if_exists( - test_dir / "external_confids.npz" + external_confids = ExperimentData.__load_from_store( + config, "external_confids.npz" ) if any("mcd" in confid for confid in config.eval.confidence_measures.test): - mcd_external_confids_dist = ExperimentData.__load_npz_if_exists( - test_dir / "external_confids_dist.npz" + mcd_external_confids_dist = ExperimentData.__load_from_store( + config, "external_confids_dist.npz" ) else: mcd_external_confids_dist = None if ( - features := ExperimentData.__load_npz_if_exists( - test_dir / "encoded_output.npz" - ) + features := ExperimentData.__load_from_store(config, "encoded_output.npz") ) is not None: features = features[:, :-1] - last_layer: tuple[npt.NDArray[np.float_], npt.NDArray[np.float_]] | None = None - if (test_dir / "last_layer.npz").is_file(): - last_layer = tuple(np.load(test_dir / "last_layer.npz").values()) # type: ignore - train_features = None - if (test_dir / "train_features.npz").is_file(): - with np.load(test_dir / "train_features.npz") as npz: - train_features = npz.f.arr_0 + + if ( + last_layer := ExperimentData.__load_from_store( + config, "last_layer.npz", unpack=False + ) + ) is not None: + last_layer = tuple(last_layer.values()) + + train_features = ExperimentData.__load_from_store(config, "train_features.npz") + return ExperimentData( softmax_output=softmax, logits=logits, @@ -339,7 +371,7 @@ def from_experiment( config=config, _features=features, _train_features=train_features, - _last_layer=last_layer, + _last_layer=last_layer, # type: ignore ) From 25035ebcdce89ef9552633402608dfb181f10ed1 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 16:23:02 +0100 Subject: [PATCH 058/136] fix: subsample mcd results that are already done --- fd_shifts/analysis/__init__.py | 52 +++++++++++++++++++++++++ fd_shifts/loaders/dataset_collection.py | 7 +++- 2 files changed, 58 insertions(+), 1 deletion(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index d28a8b0..caf7fa5 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -17,6 +17,7 @@ from sklearn.calibration import _sigmoid_calibration as calib from fd_shifts import configs +from fd_shifts.loaders.dataset_collection import CorruptCIFAR from .confid_scores import ConfidScore, SecondaryConfidScore, is_external_confid from .eval_utils import ( @@ -304,6 +305,30 @@ def from_experiment( ) is not None ): + if mcd_logits_dist.shape[0] > logits.shape[0]: + dset = CorruptCIFAR( + config.eval.query_studies.noise_study.data_dir, + train=False, + download=False, + ) + idx = ( + CorruptCIFAR.subsample_idx( + dset.data, + dset.targets, + config.eval.query_studies.noise_study.subsample_corruptions, + ) + + raw_output[raw_output[:, -1] < 2].shape[0] + ) + idx = np.concatenate( + [ + np.argwhere(raw_output[:, -1] < 2).flatten(), + idx, + np.argwhere(raw_output[:, -1] > 2).flatten() + + mcd_logits_dist.shape[0] + - raw_output.shape[0], + ] + ) + mcd_logits_dist = mcd_logits_dist[idx] mcd_softmax_dist = scpspecial.softmax(mcd_logits_dist, axis=1) else: mcd_logits_dist = None @@ -342,6 +367,33 @@ def from_experiment( mcd_external_confids_dist = ExperimentData.__load_from_store( config, "external_confids_dist.npz" ) + if ( + mcd_external_confids_dist is not None + and mcd_external_confids_dist.shape[0] > logits.shape[0] + ): + dset = CorruptCIFAR( + config.eval.query_studies.noise_study.data_dir, + train=False, + download=False, + ) + idx = ( + CorruptCIFAR.subsample_idx( + dset.data, + dset.targets, + config.eval.query_studies.noise_study.subsample_corruptions, + ) + + raw_output[raw_output[:, -1] < 2].shape[0] + ) + idx = np.concatenate( + [ + np.argwhere(raw_output[:, -1] < 2).flatten(), + idx, + np.argwhere(raw_output[:, -1] > 2).flatten() + + mcd_logits_dist.shape[0] + - raw_output.shape[0], + ] + ) + mcd_external_confids_dist = mcd_external_confids_dist[idx] else: mcd_external_confids_dist = None diff --git a/fd_shifts/loaders/dataset_collection.py b/fd_shifts/loaders/dataset_collection.py index f331920..48667f6 100644 --- a/fd_shifts/loaders/dataset_collection.py +++ b/fd_shifts/loaders/dataset_collection.py @@ -849,7 +849,7 @@ def __init__( self.classes = eval_utils.cifar100_classes @staticmethod - def subsample(data, targets, subsample): + def subsample_idx(data, targets, subsample): n_classes = len(np.unique(targets)) n_cor_kinds = 15 n_cor_levels = 5 @@ -877,6 +877,11 @@ def subsample(data, targets, subsample): for cor_level_idx in range(n_cor_levels) ] ) + return idx + + @staticmethod + def subsample(data, targets, subsample): + idx = CorruptCIFAR.subsample_idx(data, targets, subsample) return data[idx, :], targets[idx] def __getitem__(self, index: int) -> Tuple[Any, Any]: From 2de945453a5c49f5527efa601dea722e65924a36 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 16:23:31 +0100 Subject: [PATCH 059/136] fix(analysis): handle dg class in new confids --- fd_shifts/analysis/__init__.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index caf7fa5..ebf80fd 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -483,6 +483,7 @@ def _react( dataset_idx: npt.NDArray[np.integer], clip_quantile=99, val_set_index=0, + is_dg=False, ): import torch @@ -501,6 +502,8 @@ def _react( ) + b ) + if is_dg: + logits = logits[:, :-1] return logits.numpy() @@ -539,6 +542,7 @@ def _vim( train_features: npt.NDArray[np.float_] | None, features: npt.NDArray[np.float_], logits: npt.NDArray[np.float_], + is_dg=False, ): import torch @@ -556,7 +560,7 @@ def _vim( logger.debug("ViM: Compute NS") u = -torch.pinverse(w) @ b - train_f = torch.tensor(train_features[:1000, :-1], dtype=torch.float) + train_f = torch.tensor(train_features[:, :-1], dtype=torch.float) cov = torch.cov((train_f - u).T) eig_vals, eigen_vectors = torch.linalg.eig(cov) eig_vals = eig_vals.real @@ -566,6 +570,9 @@ def _vim( logger.debug("ViM: Compute alpha") logit_train = torch.matmul(train_f, w.T) + b + if is_dg: + logit_train = logit_train[:, :-1] + vlogit_train = torch.linalg.norm(torch.matmul(train_f - u, NS), dim=-1) alpha = logit_train.max(dim=-1)[0].mean() / vlogit_train.mean() From 79e59c9057f4bf821ca9a173bbd279cea8415d27 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 16:25:32 +0100 Subject: [PATCH 060/136] feat: add back reporting --- fd_shifts/experiments/tracker.py | 53 +++++++ fd_shifts/main.py | 23 ++- fd_shifts/reporting/__init__.py | 264 +++++++++++-------------------- fd_shifts/reporting/tables.py | 62 ++++---- pyproject.toml | 2 + 5 files changed, 203 insertions(+), 201 deletions(-) create mode 100644 fd_shifts/experiments/tracker.py diff --git a/fd_shifts/experiments/tracker.py b/fd_shifts/experiments/tracker.py new file mode 100644 index 0000000..8b203e9 --- /dev/null +++ b/fd_shifts/experiments/tracker.py @@ -0,0 +1,53 @@ +import os +from pathlib import Path + +from fd_shifts.configs import Config, DataConfig + + +def get_path(config: Config) -> Path | None: + paths = os.getenv("FD_SHIFTS_STORE_PATH", "").split(":") + for path in paths: + path = Path(path) + exp_path = path / config.exp.group_name / config.exp.name + if (exp_path / "hydra" / "config.yaml").exists(): + return exp_path + + +def list_analysis_output_files(config: Config) -> list: + files = [] + for study_name, testset in config.eval.query_studies: + if study_name == "iid_study": + files.append("analysis_metrics_iid_study.csv") + continue + if study_name == "noise_study": + if isinstance(testset, DataConfig) and testset.dataset is not None: + files.extend( + f"analysis_metrics_noise_study_{i}.csv" for i in range(1, 6) + ) + continue + + if isinstance(testset, list): + if len(testset) > 0: + if isinstance(testset[0], DataConfig): + testset = map( + lambda d: d.dataset + ("_384" if d.img_size[0] == 384 else ""), + testset, + ) + + testset = [f"analysis_metrics_{study_name}_{d}.csv" for d in testset] + if study_name == "new_class_study": + testset = [ + d.replace(".csv", f"_{mode}.csv") + for d in testset + for mode in ["original_mode", "proposed_mode"] + ] + files.extend(list(testset)) + elif isinstance(testset, DataConfig) and testset.dataset is not None: + files.append(testset.dataset) + elif isinstance(testset, str): + files.append(testset) + + if config.eval.val_tuning: + files.append("analysis_metrics_val_tuning.csv") + + return files diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 01abe7f..3faea50 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -11,12 +11,14 @@ import jsonargparse import rich +import shtab import yaml from jsonargparse import ActionConfigFile, ArgumentParser from jsonargparse._actions import Action from omegaconf import OmegaConf from rich.pretty import pretty_repr +from fd_shifts import reporting from fd_shifts.configs import Config, DataConfig, OutputPathsPerMode __subcommands = {} @@ -542,15 +544,15 @@ def debug(config: Config): def _list_experiments(): from fd_shifts.experiments.configs import list_experiment_configs - rich.print("Available experiments:") for exp in sorted(list_experiment_configs()): - rich.print(exp) + print(exp) def get_parser(): from fd_shifts import get_version parser = ArgumentParser(version=get_version()) + shtab.add_argument_to(parser, ["-s", "--print-completion"]) parser.add_argument("-f", "--overwrite-config-file", action="store_true") subcommands = parser.add_subcommands(dest="command") subparsers: dict[str, ArgumentParser] = {} @@ -558,11 +560,16 @@ def get_parser(): subparser = ArgumentParser() subcommands.add_subcommand("list-experiments", subparser) + subparser = ArgumentParser() + subparser.add_function_arguments(reporting.main) + subparsers["report"] = subparser + subcommands.add_subcommand("report", subparser) + for name, func in __subcommands.items(): subparser = ArgumentParser() subparser.add_argument( "--config-file", "--legacy-config-file", action=ActionLegacyConfigFile - ) + ).complete = shtab.FILE # type: ignore subparser.add_argument("--experiment", action=ActionExperiment) subparser.add_function_arguments(func, sub_configs=True) subparsers[name] = subparser @@ -578,6 +585,8 @@ def config_from_parser(parser, args): def main(): + from fd_shifts import logger + setup_logging() parser, subparsers = get_parser() @@ -588,6 +597,10 @@ def main(): _list_experiments() return + if args.command == "report": + reporting.main(**args.report) + return + config = config_from_parser(parser, args) rich.print(config) @@ -601,6 +614,10 @@ def main(): skip_check=True, overwrite=args.overwrite_config_file, ) + else: + logger.warning( + "Config file already exists, use --overwrite-config-file to force" + ) __subcommands[args.command](config=config) diff --git a/fd_shifts/reporting/__init__.py b/fd_shifts/reporting/__init__.py index 4f8c30e..2ce1d1c 100644 --- a/fd_shifts/reporting/__init__.py +++ b/fd_shifts/reporting/__init__.py @@ -1,10 +1,16 @@ +import concurrent.futures +import functools import os from pathlib import Path from typing import cast import pandas as pd +from fd_shifts import logger +from fd_shifts.configs import Config from fd_shifts.experiments import Experiment, get_all_experiments +from fd_shifts.experiments.configs import get_experiment_config, list_experiment_configs +from fd_shifts.experiments.tracker import list_analysis_output_files DATASETS = ( "svhn", @@ -17,162 +23,75 @@ ) -def _filter_experiment_by_dataset(experiments: list[Experiment], dataset: str): - match dataset: - case "super_cifar100": - _experiments = list( - filter( - lambda exp: exp.dataset in ("super_cifar100", "supercifar"), - experiments, - ) - ) - case "animals": - _experiments = list( - filter( - lambda exp: exp.dataset in ("animals", "wilds_animals"), experiments - ) - ) - case "animals_openset": - _experiments = list( - filter( - lambda exp: exp.dataset - in ("animals_openset", "wilds_animals_openset"), - experiments, - ) - ) - case "camelyon": - _experiments = list( - filter( - lambda exp: exp.dataset in ("camelyon", "wilds_camelyon"), - experiments, - ) - ) - case _: - _experiments = list(filter(lambda exp: exp.dataset == dataset, experiments)) +def __find_in_store(config: Config, file: str) -> Path | None: + store_paths = map(Path, os.getenv("FD_SHIFTS_STORE_PATH", "").split(":")) + test_dir = config.test.dir.relative_to(os.getenv("EXPERIMENT_ROOT_DIR", "")) + for store_path in store_paths: + if (store_path / test_dir / file).is_file(): + logger.info(f"Loading {store_path / test_dir / file}") + return store_path / test_dir / file - return _experiments +def __load_file(config: Config, name: str, file: str): + if f := __find_in_store(config, file): + return pd.read_csv(f) + else: + logger.error(f"Could not find {name}: {file} in store") + return None -def gather_data(data_dir: Path): - """Collect all csv files from experiments into one location - Args: - data_dir (Path): where to collect to - """ - experiment_dirs = [ - Path(os.environ["EXPERIMENT_ROOT_DIR"]), - ] +def __load_experiment(name: str) -> pd.DataFrame | None: + from fd_shifts.main import omegaconf_resolve - if add_dirs := os.getenv("EXPERIMENT_ADD_DIRS"): - ( - experiment_dirs.extend( - map( - lambda path: Path(path), - add_dirs.split(os.pathsep), - ) - ), - ) + config = get_experiment_config(name) + config = omegaconf_resolve(config) - experiments = get_all_experiments( - with_ms_runs=False, with_precision_study=False, with_vit_special_runs=False + # data = list(executor.map(functools.partial(__load_file, config, name), list_analysis_output_files(config))) + data = list( + map( + functools.partial(__load_file, config, name), + list_analysis_output_files(config), + ) ) - - for dataset in DATASETS + ("animals_openset", "svhn_openset"): - print(dataset) - _experiments = _filter_experiment_by_dataset(experiments, dataset) - - _paths = [] - _vit_paths = [] - - for experiment_dir in experiment_dirs: - for experiment in _experiments: - if experiment.model == "vit": - _vit_paths.extend( - (experiment_dir / experiment.to_path() / "test_results").glob( - "*.csv" - ) - ) - else: - _paths.extend( - (experiment_dir / experiment.to_path() / "test_results").glob( - "*.csv" - ) - ) - - if len(_paths) > 0: - dframe: pd.DataFrame = pd.concat( - [cast(pd.DataFrame, pd.read_csv(p)) for p in _paths] - ) - dframe.to_csv(data_dir / f"{dataset}.csv") - - if len(_vit_paths) > 0: - dframe: pd.DataFrame = pd.concat( - [cast(pd.DataFrame, pd.read_csv(p)) for p in _vit_paths] - ) - dframe.to_csv(data_dir / f"{dataset}vit.csv") - - -def load_file(path: Path, experiment_override: str | None = None) -> pd.DataFrame: - """Load experiment result csv into dataframe and set experiment accordingly - - Args: - path (Path): path to csv file - experiment_override (str | None): use this experiment instead of inferring it from the file - - Returns: - Dataframe created from csv including some cleanup - - Raises: - FileNotFoundError: if the file at path does not exist - RuntimeError: if loading does not result in a dataframe - """ - result = pd.read_csv(path) - - if not isinstance(result, pd.DataFrame): - raise FileNotFoundError - - result = ( - result.assign( - experiment=experiment_override - if experiment_override is not None - else path.stem + if len(data) == 0 or any(map(lambda d: d is None, data)): + return + data = pd.concat(data) # type: ignore + data = ( + data.assign( + experiment=config.data.dataset + ("vit" if "vit" in name else ""), + run=int(name.split("run")[1].split("_")[0]), + dropout=config.model.dropout_rate, + rew=config.model.dg_reward if config.model.dg_reward is not None else 0, + lr=config.trainer.optimizer.init_args["init_args"]["lr"], ) .dropna(subset=["name", "model"]) .drop_duplicates(subset=["name", "study", "model", "network", "confid"]) ) + return data - if not isinstance(result, pd.DataFrame): - raise RuntimeError - - return result - - -def load_data(data_dir: Path) -> tuple[pd.DataFrame, list[str]]: - """ - Args: - data_dir (Path): the directory where all experiment results are - - Returns: - dataframe with all experiments and list of experiments that were loaded - """ - data = pd.concat( - [ - load_file(path) - for path in filter( - lambda path: str(path.stem).startswith(DATASETS), - data_dir.glob("*.csv"), +def load_all(): + dataframes = [] + # TODO: make this async + with concurrent.futures.ProcessPoolExecutor(max_workers=12) as executor: + dataframes = list( + filter( + lambda d: d is not None, + executor.map( + __load_experiment, + filter(lambda exp: "clip" not in exp, list_experiment_configs()), + ), ) - ] - ) + ) + data = pd.concat(dataframes) # type: ignore data = data.loc[~data["study"].str.contains("tinyimagenet_original")] data = data.loc[~data["study"].str.contains("tinyimagenet_proposed")] - data = data.query( - 'not (experiment in ["cifar10", "cifar100", "super_cifar100"]' - 'and not name.str.contains("vgg13"))' - ) + # data = data.query( + # 'not (experiment in ["cifar10", "cifar100", "super_cifar100"]' + # 'and not name.str.contains("vgg13"))' + # ) data = data.query( 'not ((experiment.str.contains("super_cifar100")' @@ -208,14 +127,7 @@ def load_data(data_dir: Path) -> tuple[pd.DataFrame, list[str]]: data = data.assign(ece=data.ece.mask(data.ece < 0)) - exp_names = list( - filter( - lambda exp: not exp.startswith("super_cifar100"), - data.experiment.unique(), - ) - ) - - return data, exp_names + return data def _extract_hparam( @@ -234,6 +146,7 @@ def assign_hparams_from_names(data: pd.DataFrame) -> pd.DataFrame: Returns: experiment data with additional columns """ + logger.info("Assigning hyperparameters from experiment names") data = data.assign( backbone=lambda data: _extract_hparam( data.name, r"bb([a-z0-9]+)(_small_conv)?" @@ -245,20 +158,19 @@ def assign_hparams_from_names(data: pd.DataFrame) -> pd.DataFrame: .mask(data["backbone"] == "vit", "vit_") + data.model.where( data.backbone == "vit", data.name.str.split("_", expand=True)[0] + ).mask( + data.backbone == "vit", + data.name.str.split("model", expand=True)[1].str.split("_", expand=True)[0], ), - run=lambda data: _extract_hparam(data.name, r"run([0-9]+)"), - dropout=lambda data: _extract_hparam(data.name, r"do([01])"), - rew=lambda data: _extract_hparam(data.name, r"rew([0-9.]+)"), - lr=lambda data: _extract_hparam(data.name, r"lr([0-9.]+)", "0.1"), # Encode every detail into confid name _confid=data.confid, confid=lambda data: data.model + "_" + data.confid + "_" - + data.dropout + + data.dropout.astype(str) + "_" - + data.rew, + + data.rew.astype(str), ) return data @@ -276,6 +188,7 @@ def filter_best_lr(data: pd.DataFrame, metric: str = "aurc") -> pd.DataFrame: Returns: filtered data """ + logger.info("Filtering best learning rates") def _filter_row(row, selection_df, optimization_columns, fixed_columns): if "openset" in row["study"]: @@ -347,6 +260,8 @@ def filter_best_hparams(data: pd.DataFrame, metric: str = "aurc") -> pd.DataFram filtered data """ + logger.info("Filtering best hyperparameters") + def _filter_row(row, selection_df, optimization_columns, fixed_columns): if "openset" in row["study"]: return True @@ -355,10 +270,19 @@ def _filter_row(row, selection_df, optimization_columns, fixed_columns): & (row._confid == selection_df._confid) & (row.model == selection_df.model) ] + if len(temp) > 1: + print(f"{len(temp)=}") + raise ValueError("More than one row") + + if len(temp) == 0: + return False + + temp = temp.iloc[0] result = row[optimization_columns] == temp[optimization_columns] - if result.all(axis=1).any().item(): - return True + # if result.all(axis=1).any().item(): + # return True + return result.all() return False @@ -489,7 +413,7 @@ def str_format_metrics(data: pd.DataFrame) -> pd.DataFrame: return data -def main(base_path: str | Path): +def main(out_path: str | Path): """Main entrypoint for CLI report generation Args: @@ -508,12 +432,10 @@ def main(base_path: str | Path): pd.set_option("display.width", None) pd.set_option("display.max_colwidth", None) - data_dir: Path = Path(base_path).expanduser().resolve() + data_dir: Path = Path(out_path).expanduser().resolve() data_dir.mkdir(exist_ok=True, parents=True) - gather_data(data_dir) - - data, exp_names = load_data(data_dir) + data = load_all() data = assign_hparams_from_names(data) @@ -524,19 +446,19 @@ def main(base_path: str | Path): data = rename_confids(data) data = rename_studies(data) - plot_rank_style(data, "cifar10", "aurc", data_dir) - vit_v_cnn_box(data, data_dir) + # plot_rank_style(data, "cifar10", "aurc", data_dir) + # vit_v_cnn_box(data, data_dir) - data = tables.aggregate_over_runs(data) + data, std = tables.aggregate_over_runs(data) data = str_format_metrics(data) paper_results(data, "aurc", False, data_dir) - paper_results(data, "aurc", False, data_dir, True) - paper_results(data, "ece", False, data_dir) - paper_results(data, "failauc", True, data_dir) - paper_results(data, "accuracy", True, data_dir) - paper_results(data, "fail-NLL", False, data_dir) - - rank_comparison_metric(data, data_dir) - rank_comparison_mode(data, data_dir) - rank_comparison_mode(data, data_dir, False) + # paper_results(data, "aurc", False, data_dir, rank_cols=True) + # paper_results(data, "ece", False, data_dir) + # paper_results(data, "failauc", True, data_dir) + # paper_results(data, "accuracy", True, data_dir) + # paper_results(data, "fail-NLL", False, data_dir) + + # rank_comparison_metric(data, data_dir) + # rank_comparison_mode(data, data_dir) + # rank_comparison_mode(data, data_dir, False) diff --git a/fd_shifts/reporting/tables.py b/fd_shifts/reporting/tables.py index 2977157..9812147 100644 --- a/fd_shifts/reporting/tables.py +++ b/fd_shifts/reporting/tables.py @@ -8,6 +8,8 @@ import numpy as np import pandas as pd +from fd_shifts import logger + LATEX_TABLE_TEMPLATE = r""" \documentclass{article} % For LaTeX2e \usepackage[table]{xcolor} @@ -89,6 +91,7 @@ def aggregate_over_runs(data: pd.DataFrame) -> pd.DataFrame: Returns: aggregated experiment data """ + logger.info("Aggregating over runs") fixed_columns = ["study", "confid"] metrics_columns = ["accuracy", "aurc", "ece", "failauc", "fail-NLL"] @@ -167,6 +170,9 @@ def _study_name_to_multilabel(study_name): if study_name in ["confid", "classifier"]: return (study_name, "", "") + if study_name.startswith("wilds_"): + study_name = study_name.replace("wilds_", "") + return ( study_name.split("_")[0], study_name.split("_")[1] @@ -230,7 +236,7 @@ def _reorder_studies( ordered_columns = [ ("animals", "iid", ""), ("animals", "sub", ""), - ("animals", "s-ncs", ""), + # ("animals", "s-ncs", ""), ("animals", "rank", ""), ("breeds", "iid", ""), ("breeds", "sub", ""), @@ -252,7 +258,7 @@ def _reorder_studies( ("cifar10", "ns-ncs", "ti"), ("cifar10", "rank", ""), ("svhn", "iid", ""), - ("svhn", "s-ncs", ""), + # ("svhn", "s-ncs", ""), ("svhn", "ns-ncs", "c10"), ("svhn", "ns-ncs", "c100"), ("svhn", "ns-ncs", "ti"), @@ -411,16 +417,17 @@ def paper_results( out_dir (Path): where to save the output to rank_cols: (bool): whether to report ranks instead of absolute values """ + logger.info(f"Creating results table for {metric}") + _formatter = ( lambda x: f"{x:>3.2f}"[:4] if "." in f"{x:>3.2f}"[:3] else f"{x:>3.2f}"[:3] ) + results_table = build_results_table(data, metric) cmap = "Oranges_r" if invert else "Oranges" if rank_cols: results_table = _add_rank_columns(results_table) - print(f"{metric}") - print(results_table) _formatter = lambda x: f"{int(x):>3d}" cmap = "Oranges" @@ -436,63 +443,65 @@ def paper_results( lambda val: round(val, 2) if val < 10 else round(val, 1) ) - gmap_vit = _compute_gmap( + gmap_cnn = _compute_gmap( results_table.loc[ results_table.index[ - results_table.index.get_level_values(1).str.contains("ViT") + ~results_table.index.get_level_values(1).str.contains("ViT") ], results_table.columns, ], invert, ) - gmap_cnn = _compute_gmap( - results_table.loc[ + + ltex = results_table.style.background_gradient( + cmap, + axis=None, + subset=( results_table.index[ ~results_table.index.get_level_values(1).str.contains("ViT") ], results_table.columns, - ], - invert, + ), + gmap=gmap_cnn, ) - ltex = ( - results_table.style.background_gradient( - cmap, - axis=None, - subset=( + if results_table.index.get_level_values(1).str.contains("ViT").any(): + gmap_vit = _compute_gmap( + results_table.loc[ results_table.index[ results_table.index.get_level_values(1).str.contains("ViT") ], results_table.columns, - ), - gmap=gmap_vit, + ], + invert, ) - .background_gradient( + ltex = ltex.background_gradient( cmap, axis=None, subset=( results_table.index[ - ~results_table.index.get_level_values(1).str.contains("ViT") + results_table.index.get_level_values(1).str.contains("ViT") ], results_table.columns, ), - gmap=gmap_cnn, - ) - .highlight_null(props="background-color: white;color: black") - .format( - _formatter, - na_rep="*", + gmap=gmap_vit, ) + + ltex = ltex.highlight_null(props="background-color: white;color: black").format( + _formatter, + na_rep="*", ) ltex.data.columns = ltex.data.columns.set_names( ["\\multicolumn{1}{c}{}", "study", "ncs-data set"] ) + print(ltex.data) ltex = ltex.to_latex( convert_css=True, hrules=True, multicol_align="c?", - column_format="ll?rrr?xx?xx?rrrrrr?rrrrr?rrrrr", + # column_format="ll?rrr?xx?xx?rrrrrr?rrrrr?rrrrr", + column_format="ll?rr?xx?xx?rrrrrr?rrrrr?rrrr", ) # Remove toprule @@ -782,7 +791,6 @@ def rank_comparison_mode(data: pd.DataFrame, out_dir: Path, rank: bool = True): ltex.data.columns = ltex.data.columns.set_names( ["\\multicolumn{1}{c}{}", "study", "ncs-data set", "ood protocol"] ) - print(len(results_table.columns)) ltex = ltex.to_latex( convert_css=True, hrules=True, diff --git a/pyproject.toml b/pyproject.toml index 45f3d42..c3ee165 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -36,6 +36,7 @@ dependencies = [ "scikit-learn>=0.24.2", "scipy>=1.6.1", "seaborn>=0.11.1", + "shtab", "tensorboard>=2.4.1", "timm==0.5.4", "toml>=0.10.2", @@ -71,6 +72,7 @@ launcher = [ [project.scripts] fd_shifts = "fd_shifts.cli:main" +fd-shifts = "fd_shifts.main:main" _fd_shifts_exec = "fd_shifts.exec:main" [tool.setuptools_scm] From cea9c1e35425228e3b7297c0cb20643b8487c9ba Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 16:25:50 +0100 Subject: [PATCH 061/136] feat(configs): add supercifar configs --- fd_shifts/experiments/configs.py | 39 ++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index 7454699..23b3023 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -942,6 +942,16 @@ def vit_cifar100_modeldg(run: int, lr: float, do: int, rew: float): return config +def vit_super_cifar100_modeldg(run: int, lr: float, do: int, rew: float): + config = vit_cifar100_modeldg(run, lr, do, rew) + config.exp.name = "super_" + config.exp.name + config.data = cifar100_data_config(dataset="super_cifar100", img_size=384) + config.eval.query_studies = cifar100_query_config( + dataset="super_cifar100", img_size=384 + ) + return config + + def vit_breeds_modeldg(run: int, lr: float, do: int, rew: float): config = vit_modeldg( name=f"breeds_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", @@ -1024,6 +1034,18 @@ def vit_cifar100_modelvit(run: int, lr: float, do: int, **kwargs): return config +def vit_super_cifar100_modelvit(run: int, lr: float, do: int, **kwargs): + config = vit_cifar100_modelvit(run, lr, do, **kwargs) + config.exp.name = "super_" + config.exp.name + config.data = cifar100_data_config(dataset="super_cifar100", img_size=384) + config.eval.query_studies = cifar100_query_config( + dataset="super_cifar100", img_size=384 + ) + config.trainer.num_steps = 40000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 + return config + + def vit_breeds_modelvit(run: int, lr: float, do: int, **kwargs): config = vit( name=f"breeds_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", @@ -1109,6 +1131,23 @@ def register(config_fn: Callable[..., Config], n_runs: int = 5, **kwargs): register(vit_cifar100_modeldg, lr=1e-2, do=0, rew=20) register(vit_cifar100_modeldg, lr=1e-2, do=1, rew=20) +register(vit_super_cifar100_modelvit, lr=3e-3, do=0, rew=0) +register(vit_super_cifar100_modelvit, lr=1e-3, do=1, rew=0) +register(vit_super_cifar100_modeldg, lr=3e-3, do=0, rew=2.2) +register(vit_super_cifar100_modeldg, lr=1e-3, do=1, rew=2.2) +register(vit_super_cifar100_modeldg, lr=3e-3, do=0, rew=3) +register(vit_super_cifar100_modeldg, lr=1e-3, do=1, rew=3) +register(vit_super_cifar100_modeldg, lr=3e-3, do=0, rew=6) +register(vit_super_cifar100_modeldg, lr=1e-3, do=1, rew=6) +register(vit_super_cifar100_modeldg, lr=3e-3, do=0, rew=10) +register(vit_super_cifar100_modeldg, lr=1e-3, do=1, rew=10) +register(vit_super_cifar100_modeldg, lr=3e-3, do=0, rew=12) +register(vit_super_cifar100_modeldg, lr=1e-3, do=1, rew=12) +register(vit_super_cifar100_modeldg, lr=3e-3, do=0, rew=15) +register(vit_super_cifar100_modeldg, lr=1e-3, do=1, rew=15) +register(vit_super_cifar100_modeldg, lr=3e-3, do=0, rew=20) +register(vit_super_cifar100_modeldg, lr=1e-3, do=1, rew=20) + register(vit_wilds_animals_modelvit, lr=1e-3, do=0, rew=0) register(vit_wilds_animals_modelvit, lr=1e-2, do=0, rew=0) register(vit_wilds_animals_modelvit, lr=1e-2, do=1, rew=0) From 1289f383530457632d880cce46b3945baa1cf5a7 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 16:34:52 +0100 Subject: [PATCH 062/136] fix: tinyimagenet name --- fd_shifts/analysis/__init__.py | 3 ++- fd_shifts/experiments/configs.py | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index ebf80fd..86b60d8 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -17,7 +17,6 @@ from sklearn.calibration import _sigmoid_calibration as calib from fd_shifts import configs -from fd_shifts.loaders.dataset_collection import CorruptCIFAR from .confid_scores import ConfidScore, SecondaryConfidScore, is_external_confid from .eval_utils import ( @@ -286,6 +285,8 @@ def from_experiment( config: configs.Config, holdout_classes: list | None = None, ) -> ExperimentData: + from fd_shifts.loaders.dataset_collection import CorruptCIFAR + if not isinstance(test_dir, Path): test_dir = Path(test_dir) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index 23b3023..ed88372 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -353,7 +353,7 @@ def tinyimagenet_data_config(img_size: int | tuple[int, int] = 64) -> DataConfig augmentations["resize"] = img_size return DataConfig( - dataset="tinyimagenet" + ("" if img_size[0] == 384 else "_resize"), + dataset="tinyimagenet" + ("_384" if img_size[0] == 384 else "_resize"), data_dir=SI( "${oc.env:DATASET_ROOT_DIR}/" + "tinyimagenet" From f7c1d02de5c1315f850098dd6320b2062f3ed7a3 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Mon, 4 Mar 2024 14:30:11 +0100 Subject: [PATCH 063/136] fix: subsample old mcd results before converting to 64bit --- fd_shifts/analysis/__init__.py | 53 +++++++++++++++++++++++++--------- 1 file changed, 40 insertions(+), 13 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 86b60d8..2c44579 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -256,13 +256,20 @@ def __load_from_store( @overload @staticmethod def __load_from_store( - config: configs.Config, file: str, unpack: Literal[False] + config: configs.Config, file: str, dtype: type, unpack: Literal[False] ) -> dict[str, npt.NDArray[np.float64]] | None: ... + @overload @staticmethod def __load_from_store( - config: configs.Config, file: str, unpack: bool = True + config: configs.Config, file: str, dtype: type + ) -> npt.NDArray[np.float64] | None: + ... + + @staticmethod + def __load_from_store( + config: configs.Config, file: str, dtype: type = np.float64, unpack: bool = True ) -> npt.NDArray[np.float64] | dict[str, npt.NDArray[np.float64]] | None: store_paths = map(Path, os.getenv("FD_SHIFTS_STORE_PATH", "").split(":")) @@ -273,7 +280,7 @@ def __load_from_store( logger.debug(f"Loading {store_path / test_dir / file}") with np.load(store_path / test_dir / file) as npz: if unpack: - return npz.f.arr_0.astype(np.float64) + return npz.f.arr_0.astype(dtype) else: return dict(npz.items()) @@ -301,7 +308,7 @@ def from_experiment( ) and ( ( mcd_logits_dist := ExperimentData.__load_from_store( - config, "raw_logits_dist.npz" + config, "raw_logits_dist.npz", dtype=np.float16 ) ) is not None @@ -330,6 +337,7 @@ def from_experiment( ] ) mcd_logits_dist = mcd_logits_dist[idx] + mcd_logits_dist = mcd_logits_dist.astype(np.float64) mcd_softmax_dist = scpspecial.softmax(mcd_logits_dist, axis=1) else: mcd_logits_dist = None @@ -364,14 +372,16 @@ def from_experiment( external_confids = ExperimentData.__load_from_store( config, "external_confids.npz" ) - if any("mcd" in confid for confid in config.eval.confidence_measures.test): - mcd_external_confids_dist = ExperimentData.__load_from_store( - config, "external_confids_dist.npz" + if ( + any("mcd" in confid for confid in config.eval.confidence_measures.test) + and ( + mcd_external_confids_dist := ExperimentData.__load_from_store( + config, "external_confids_dist.npz", dtype=np.float16 + ) ) - if ( - mcd_external_confids_dist is not None - and mcd_external_confids_dist.shape[0] > logits.shape[0] - ): + is not None + ): + if mcd_external_confids_dist.shape[0] > logits.shape[0]: dset = CorruptCIFAR( config.eval.query_studies.noise_study.data_dir, train=False, @@ -395,6 +405,7 @@ def from_experiment( ] ) mcd_external_confids_dist = mcd_external_confids_dist[idx] + mcd_external_confids_dist = mcd_external_confids_dist.astype(np.float64) else: mcd_external_confids_dist = None @@ -715,11 +726,27 @@ def __init__( if isinstance(datasets, (list, ListConfig)) and len(datasets) > 0: if isinstance(datasets[0], configs.DataConfig): self.query_studies.__dict__[study_name] = list( - map(lambda d: d.dataset, datasets) + map( + lambda d: d.dataset + + ( + "_384" + if d.img_size[0] == 384 and "384" not in d.dataset + else "" + ), + datasets, + ) ) if isinstance(datasets, configs.DataConfig): if datasets.dataset is not None: - self.query_studies.__dict__[study_name] = [datasets.dataset] + self.query_studies.__dict__[study_name] = [ + datasets.dataset + + ( + "_384" + if datasets.img_size[0] == 384 + and "384" not in datasets.dataset + else "" + ) + ] else: self.query_studies.__dict__[study_name] = [] From 23a72802dd8faa8f4eb2942478473afebfb9a05b Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 25 Jan 2024 17:24:25 +0100 Subject: [PATCH 064/136] fix(data): remove legacy reduced animals id_test size --- fd_shifts/loaders/data_loader.py | 38 +++++++++----------------------- 1 file changed, 11 insertions(+), 27 deletions(-) diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index 7e14f3b..45c40ae 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -194,47 +194,31 @@ def setup(self, stage=None): kwargs=self.dataset_kwargs, ) if "wilds" in self.dataset_name: - self.iid_test_set.indices = self.iid_test_set.indices[100:150] + self.iid_test_set.indices = self.iid_test_set.indices[1000:] self.iid_test_set.__len__ = len(self.iid_test_set.indices) + self.val_dataset.indices = self.val_dataset.indices[:1000] + self.val_dataset.__len__ = len(self.val_dataset.indices) else: try: self.iid_test_set.imgs = self.iid_test_set.imgs[1000:] self.iid_test_set.samples = self.iid_test_set.samples[1000:] self.iid_test_set.targets = self.iid_test_set.targets[1000:] self.iid_test_set.__len__ = len(self.iid_test_set.imgs) + self.val_dataset.imgs = self.val_dataset.imgs[:1000] + self.val_dataset.samples = self.val_dataset.samples[:1000] + self.val_dataset.targets = self.val_dataset.targets[:1000] + self.val_dataset.__len__ = len(self.val_dataset.imgs) except: self.iid_test_set.data = self.iid_test_set.data[1000:] + self.val_dataset.data = self.val_dataset.data[:1000] try: self.iid_test_set.targets = self.iid_test_set.targets[1000:] + self.val_dataset.targets = self.val_dataset.targets[:1000] except: self.iid_test_set.labels = self.iid_test_set.labels[1000:] + self.val_dataset.labels = self.val_dataset.labels[:1000] self.iid_test_set.__len__ = len(self.iid_test_set.data) - if self.val_split == "devries": - self.val_dataset = get_dataset( - name=self.dataset_name, - root=self.data_dir, - train=False, - download=True, - target_transform=self.target_transforms.get("val"), - transform=self.augmentations["val"], - kwargs=self.dataset_kwargs, - ) - if "wilds" in self.dataset_name: - self.val_dataset.indices = self.val_dataset.indices[:1000] - self.val_dataset.__len__ = len(self.val_dataset.indices) - else: - try: - self.val_dataset.imgs = self.val_dataset.imgs[:1000] - self.val_dataset.samples = self.val_dataset.samples[:1000] - self.val_dataset.targets = self.val_dataset.targets[:1000] - self.val_dataset.__len__ = len(self.val_dataset.imgs) - except: - self.val_dataset.data = self.val_dataset.data[:1000] - try: - self.val_dataset.targets = self.val_dataset.targets[:1000] - except: - self.val_dataset.labels = self.val_dataset.labels[:1000] - self.val_dataset.__len__ = len(self.val_dataset.data) + self.val_dataset.__len__ = len(self.val_dataset.data) else: self.val_dataset = get_dataset( From d6fe4bc9ae6699d348e260aad047ed65c85a1083 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 10 Jan 2024 23:47:09 +0100 Subject: [PATCH 065/136] wip: fix: use builtin dataclass asdict --- fd_shifts/utils/__init__.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/fd_shifts/utils/__init__.py b/fd_shifts/utils/__init__.py index 24fc4b8..d383fbd 100644 --- a/fd_shifts/utils/__init__.py +++ b/fd_shifts/utils/__init__.py @@ -1,5 +1,6 @@ import importlib import json +from dataclasses import asdict from omegaconf import DictConfig, ListConfig, OmegaConf from pydantic.json import pydantic_encoder @@ -12,8 +13,9 @@ def __to_dict(obj): def to_dict(obj): - s = json.dumps(obj, default=__to_dict) - return json.loads(s) + # s = json.dumps(obj, default=__to_dict) + # return json.loads(s) + return asdict(obj) def instantiate_from_str(name, *args, **kwargs): From 0fa7f007e2e2b485ae74ff5520a3d52fa95b1112 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 10 Jan 2024 23:54:28 +0100 Subject: [PATCH 066/136] wip: feat: switch to jsonarparse, experiments are now complete Config objects --- fd_shifts/configs/__init__.py | 171 +++++++------- fd_shifts/configs/iterable_mixin.py | 10 + fd_shifts/exec.py | 2 +- fd_shifts/experiments/configs.py | 244 ++++++++++++++++++++ fd_shifts/main.py | 345 ++++++++++++++++++++++++++++ fd_shifts/models/devries_model.py | 23 +- pyproject.toml | 1 + 7 files changed, 706 insertions(+), 90 deletions(-) create mode 100644 fd_shifts/configs/iterable_mixin.py create mode 100644 fd_shifts/experiments/configs.py create mode 100644 fd_shifts/main.py diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index eb33319..8b9c4e4 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -6,24 +6,27 @@ from dataclasses import field from enum import Enum, auto from pathlib import Path -from typing import TYPE_CHECKING, Any, Iterator, Optional, TypeVar +from random import randint +from typing import TYPE_CHECKING, Any, Callable, Iterable, Iterator, Optional, TypeVar import pl_bolts import torch from hydra.core.config_store import ConfigStore from hydra_zen import builds # type: ignore -from omegaconf import DictConfig, OmegaConf +from omegaconf import SI, DictConfig, OmegaConf from omegaconf.omegaconf import MISSING from pydantic import ConfigDict, validator from pydantic.dataclasses import dataclass from typing_extensions import dataclass_transform +import fd_shifts from fd_shifts import models from fd_shifts.analysis import confid_scores, metrics from fd_shifts.loaders import dataset_collection from fd_shifts.utils import exp_utils from ..models import networks +from .iterable_mixin import _IterableMixin if TYPE_CHECKING: from pydantic.dataclasses import Dataclass @@ -58,13 +61,6 @@ class ValSplit(StrEnum): zhang = auto() -class _IterableMixin: # pylint: disable=too-few-public-methods - def __iter__(self) -> Iterator[tuple[str, Any]]: - return filter( - lambda item: not item[0].startswith("__"), self.__dict__.items() - ).__iter__() - - @dataclass_transform() def defer_validation(original_class: type[ConfigT]) -> type[ConfigT]: """Disable validation for a pydantic dataclass @@ -83,13 +79,13 @@ def defer_validation(original_class: type[ConfigT]) -> type[ConfigT]: class OutputPathsConfig(_IterableMixin): """Where outputs are stored""" + raw_output: Path | None = None + raw_output_dist: Path | None = None + external_confids: Path | None = None + external_confids_dist: Path | None = None input_imgs_plot: Optional[Path] = None - raw_output: Path = MISSING encoded_output: Optional[Path] = None attributions_output: Optional[Path] = None - raw_output_dist: Path = MISSING - external_confids: Path = MISSING - external_confids_dist: Path = MISSING @defer_validation @@ -106,23 +102,25 @@ class OutputPathsPerMode(_IterableMixin): class ExperimentConfig(_IterableMixin): """Main experiment config""" - group_name: str = MISSING - name: str = MISSING + group_name: str | None = None + name: str | None = None + mode: Mode = Mode.train_test + work_dir: Path | None = Path.cwd() + fold_dir: Path | None = None + root_dir: Path | None = Path(p) if (p := os.getenv("EXPERIMENT_ROOT_DIR")) else None + data_root_dir: Path | None = ( + Path(p) if (p := os.getenv("DATASET_ROOT_DIR")) else None + ) + group_dir: Path | None = SI("${exp.root_dir}/${exp.group_name}") + dir: Path | None = group_dir / name if group_dir and name else None version: Optional[int] = None - mode: Mode = MISSING - work_dir: Path = MISSING - fold_dir: Path = MISSING - root_dir: Path = MISSING - data_root_dir: Path = MISSING - group_dir: Path = MISSING - dir: Path = MISSING - version_dir: Path = MISSING - fold: int = MISSING - crossval_n_folds: int = MISSING - crossval_ids_path: Path = MISSING + version_dir: Path | None = dir / f"version_{version}" if dir and version else None + fold: int = 0 + crossval_n_folds: int = 10 + crossval_ids_path: Path | None = dir / "crossval_ids.pickle" if dir else None + log_path: Path | None = None + global_seed: int = randint(0, 1_000_000) output_paths: OutputPathsPerMode = OutputPathsPerMode() - log_path: Path = MISSING - global_seed: int = MISSING @defer_validation @@ -189,27 +187,33 @@ class Adam(OptimizerConfig): @defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) +@dataclass(config=ConfigDict(validate_assignment=True, arbitrary_types_allowed=True)) class TrainerConfig(_IterableMixin): """Main configuration for PyTorch Lightning Trainer""" - accumulate_grad_batches: int = 1 - resume_from_ckpt_confidnet: Optional[bool] = None - num_epochs: Optional[int] = None + num_epochs: Optional[int] = 300 num_steps: Optional[int] = None num_epochs_backbone: Optional[int] = None - dg_pretrain_epochs: Optional[int] = None + val_every_n_epoch: int = 5 + do_val: bool = True + batch_size: int = 128 + resume_from_ckpt: bool = False + benchmark: bool = True + fast_dev_run: bool | int = False + lr_scheduler: Callable[ + [torch.optim.Optimizer], torch.optim.lr_scheduler._LRScheduler + ] | None = None + optimizer: Callable[[Iterable], torch.optim.Optimizer] | None = None + # lr_scheduler: LRSchedulerConfig | None = None + # optimizer: OptimizerConfig | None = None + accumulate_grad_batches: int = 1 + resume_from_ckpt_confidnet: bool = False + dg_pretrain_epochs: int | None = 100 dg_pretrain_steps: Optional[int] = None - val_every_n_epoch: int = MISSING - val_split: Optional[ValSplit] = None - do_val: bool = MISSING - batch_size: int = MISSING - resume_from_ckpt: bool = MISSING - benchmark: bool = MISSING - fast_dev_run: bool | int = MISSING + val_split: ValSplit = ValSplit.devries lr_scheduler_interval: str = "epoch" - lr_scheduler: LRSchedulerConfig = LRSchedulerConfig() - optimizer: OptimizerConfig = MISSING + + # TODO: Replace with jsonargparse compatible type hint to lightning.Callback callbacks: dict[str, Optional[dict[Any, Any]]] = field(default_factory=lambda: {}) learning_rate_confidnet: Optional[float] = None @@ -241,7 +245,7 @@ def validate_steps( class NetworkConfig(_IterableMixin): """Model Network configuration""" - name: str = MISSING + name: str = "vgg13" backbone: Optional[str] = None imagenet_weights_path: Optional[Path] = None load_dg_backbone_path: Optional[Path] = None @@ -268,17 +272,17 @@ def validate_network_name(cls: NetworkConfig, name: str) -> str: class ModelConfig(_IterableMixin): """Model Configuration""" - name: str = MISSING - fc_dim: int = MISSING + name: str = "devries_model" + network: NetworkConfig = NetworkConfig() + fc_dim: int = 512 + avg_pool: bool = True + dropout_rate: int = 0 + monitor_mcd_samples: int = 50 + test_mcd_samples: int = 50 confidnet_fc_dim: Optional[int] = None dg_reward: Optional[float] = None - avg_pool: bool = MISSING balanced_sampeling: bool = False - dropout_rate: int = MISSING - monitor_mcd_samples: int = MISSING - test_mcd_samples: int = MISSING - budget: Optional[float] = None - network: NetworkConfig = NetworkConfig() + budget: float = 0.3 # pylint: disable=no-self-argument @validator("name") @@ -397,10 +401,10 @@ def validate(cls: ConfidMeasuresConfig, name: str) -> str: class QueryStudiesConfig(_IterableMixin): """Query Studies Configuration""" - iid_study: str = MISSING - noise_study: list[str] = MISSING - in_class_study: list[str] = MISSING - new_class_study: list[str] = MISSING + iid_study: str | None = None + noise_study: list[str] = field(default_factory=lambda: []) + in_class_study: list[str] = field(default_factory=lambda: []) + new_class_study: list[str] = field(default_factory=lambda: []) # pylint: disable=no-self-argument @validator( @@ -424,6 +428,13 @@ def validate(cls, name: str) -> str: class EvalConfig(_IterableMixin): """Evaluation Configuration container""" + tb_hparams: list[str] = field(default_factory=lambda: ["fold"]) + test_conf_scaling: bool = False + val_tuning: bool = True + r_star: float = 0.25 + r_delta: float = 0.05 + + query_studies: QueryStudiesConfig = QueryStudiesConfig() performance_metrics: PerfMetricsConfig = PerfMetricsConfig() confid_metrics: ConfidMetricsConfig = ConfidMetricsConfig() confidence_measures: ConfidMeasuresConfig = ConfidMeasuresConfig() @@ -434,14 +445,7 @@ class EvalConfig(_IterableMixin): ] ) - tb_hparams: list[str] = MISSING ext_confid_name: Optional[str] = None - test_conf_scaling: bool = MISSING - val_tuning: bool = MISSING - r_star: float = MISSING - r_delta: float = MISSING - - query_studies: QueryStudiesConfig = QueryStudiesConfig() @defer_validation @@ -449,19 +453,19 @@ class EvalConfig(_IterableMixin): class TestConfig(_IterableMixin): """Inference time configuration""" - name: str = MISSING - dir: Path = MISSING - cf_path: Path = MISSING - selection_criterion: str = MISSING - best_ckpt_path: Path = MISSING - only_latest_version: bool = MISSING - devries_repro_ood_split: bool = MISSING - assim_ood_norm_flag: bool = MISSING - iid_set_split: str = MISSING - raw_output_path: str = MISSING - external_confids_output_path: str = MISSING + name: str = "test_results" + dir: Path | None = None + cf_path: Path | None = None + selection_criterion: str | None = None + best_ckpt_path: Path | None = None + only_latest_version: bool | None = None + devries_repro_ood_split: bool | None = None + assim_ood_norm_flag: bool | None = None + iid_set_split: str | None = None + raw_output_path: str | None = None + external_confids_output_path: str | None = None + output_precision: int | None = None selection_mode: Optional[str] = None - output_precision: int = MISSING @defer_validation @@ -469,14 +473,14 @@ class TestConfig(_IterableMixin): class DataConfig(_IterableMixin): """Dataset Configuration""" - dataset: str = MISSING - data_dir: Path = MISSING - pin_memory: bool = MISSING - img_size: tuple[int, int, int] = MISSING - num_workers: int = MISSING - num_classes: int = MISSING - reproduce_confidnet_splits: bool = MISSING - augmentations: Any = MISSING + dataset: str | None = None + data_dir: Path | None = None + pin_memory: bool | None = None + img_size: tuple[int, int, int] | None = None + num_workers: int | None = None + num_classes: int | None = None + reproduce_confidnet_splits: bool | None = None + augmentations: dict[str, dict[str, Any]] | None = None target_transforms: Optional[Any] = None kwargs: Optional[dict[Any, Any]] = None @@ -486,7 +490,8 @@ class DataConfig(_IterableMixin): class Config(_IterableMixin): """Main Configuration Class""" - pkgversion: str = MISSING + pkgversion: str = fd_shifts.get_version() + data: DataConfig = DataConfig() trainer: TrainerConfig = TrainerConfig() diff --git a/fd_shifts/configs/iterable_mixin.py b/fd_shifts/configs/iterable_mixin.py new file mode 100644 index 0000000..b9d59ab --- /dev/null +++ b/fd_shifts/configs/iterable_mixin.py @@ -0,0 +1,10 @@ +from dataclasses import dataclass +from typing import Any, Iterator + + +@dataclass +class _IterableMixin: # pylint: disable=too-few-public-methods + def __iter__(self) -> Iterator[tuple[str, Any]]: + return filter( + lambda item: not item[0].startswith("__"), self.__dict__.items() + ).__iter__() diff --git a/fd_shifts/exec.py b/fd_shifts/exec.py index 312d568..aa7f4d4 100644 --- a/fd_shifts/exec.py +++ b/fd_shifts/exec.py @@ -211,7 +211,7 @@ def main(dconf: DictConfig) -> None: Args: dconf (DictConfig): config passed in by hydra """ - multiprocessing.set_start_method("spawn") + # multiprocessing.set_start_method("spawn") reconfigure(stderr=True, force_terminal=True) progress = RichProgressBar(console_kwargs={"stderr": True, "force_terminal": True}) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py new file mode 100644 index 0000000..509b9ca --- /dev/null +++ b/fd_shifts/experiments/configs.py @@ -0,0 +1,244 @@ +import os +from pathlib import Path + +import pl_bolts +import torch +from omegaconf import SI + +from fd_shifts.configs import ( + ConfidMeasuresConfig, + ConfidMetricsConfig, + Config, + DataConfig, + EvalConfig, + ExperimentConfig, + Mode, + ModelConfig, + NetworkConfig, + OutputPathsConfig, + OutputPathsPerMode, + PerfMetricsConfig, + QueryStudiesConfig, + TestConfig, + TrainerConfig, + ValSplit, +) + +__data_configs = {} + +__data_configs["svhn_384"] = DataConfig( + dataset="svhn", + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/svhn"), + pin_memory=True, + img_size=(384, 384, 3), + num_workers=24, + num_classes=10, + reproduce_confidnet_splits=True, + augmentations={ + "train": { + "to_tensor": None, + "resize": 384, + "normalize": [ + [0.4376821, 0.4437697, 0.47280442], + [0.19803012, 0.20101562, 0.19703614], + ], + }, + "val": { + "to_tensor": None, + "resize": 384, + "normalize": [ + [0.4376821, 0.4437697, 0.47280442], + [0.19803012, 0.20101562, 0.19703614], + ], + }, + "test": { + "to_tensor": None, + "resize": 384, + "normalize": [ + [0.4376821, 0.4437697, 0.47280442], + [0.19803012, 0.20101562, 0.19703614], + ], + }, + }, + target_transforms=None, + kwargs=None, +) + + +def get_data_config(name: str) -> DataConfig: + return __data_configs[name] + + +__experiments = {} + +__experiments["svhn_modeldg_bbvit_lr0.01_bs128_run4_do1_rew10"] = Config( + data=get_data_config("svhn_384"), + trainer=TrainerConfig( + val_every_n_epoch=5, + do_val=True, + batch_size=128, + resume_from_ckpt=False, + benchmark=True, + fast_dev_run=False, + lr_scheduler=lambda optim: pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR( + optim, + warmup_epochs=500, + max_epochs=60000, + warmup_start_lr=0.0, + eta_min=0.0, + last_epoch=-1, + ), + optimizer=lambda params: torch.optim.SGD( + params, + lr=0.01, + dampening=0.0, + momentum=0.9, + nesterov=False, + maximize=False, + weight_decay=0.0, + ), + accumulate_grad_batches=1, + resume_from_ckpt_confidnet=False, + num_epochs=None, + num_steps=60000, + num_epochs_backbone=None, + dg_pretrain_epochs=None, + dg_pretrain_steps=20000, + val_split=ValSplit.devries, + lr_scheduler_interval="step", + callbacks={ + "model_checkpoint": None, + "confid_monitor": None, + "learning_rate_monitor": None, + }, + learning_rate_confidnet=None, + learning_rate_confidnet_finetune=None, + ), + exp=ExperimentConfig( + group_name="vit", + name="svhn_modeldg_bbvit_lr0.01_bs128_run4_do1_rew10", + mode=Mode.analysis, + work_dir=Path.cwd(), + fold_dir=SI("exp/${exp.fold}"), + root_dir=Path(p) + if (p := os.getenv("EXPERIMENT_ROOT_DIR")) is not None + else None, + data_root_dir=Path(p) + if (p := os.getenv("DATASET_ROOT_DIR")) is not None + else None, + group_dir=Path("${exp.root_dir}/${exp.group_name}"), + dir=Path("${exp.group_dir}/${exp.name}"), + version_dir=Path("${exp.dir}/version_${exp.version}"), + fold=0, + crossval_n_folds=10, + crossval_ids_path=Path("${exp.dir}/crossval_ids.pickle"), + log_path=Path("log.txt"), + global_seed=0, + output_paths=OutputPathsPerMode( + fit=OutputPathsConfig( + raw_output=Path("${exp.version_dir}/raw_output.npz"), + raw_output_dist=Path("${exp.version_dir}/raw_output_dist.npz"), + external_confids=Path("${exp.version_dir}/external_confids.npz"), + external_confids_dist=Path( + "${exp.version_dir}/external_confids_dist.npz" + ), + input_imgs_plot=Path("${exp.dir}/input_imgs.png"), + encoded_output=None, + attributions_output=None, + ), + test=OutputPathsConfig( + raw_output=Path("${test.dir}/raw_logits.npz"), + raw_output_dist=Path("${test.dir}/raw_logits_dist.npz"), + external_confids=Path("${test.dir}/external_confids.npz"), + external_confids_dist=Path("${test.dir}/external_confids_dist.npz"), + input_imgs_plot=None, + encoded_output=Path("${test.dir}/encoded_output.npz"), + attributions_output=Path("${test.dir}/attributions.csv"), + ), + ), + version=None, + ), + model=ModelConfig( + name="devries_model", + network=NetworkConfig( + name="vit", + backbone=None, + imagenet_weights_path=None, + load_dg_backbone_path=None, + save_dg_backbone_path=Path("${exp.dir}/dg_backbone.ckpt"), + ), + fc_dim=768, + avg_pool=True, + dropout_rate=1, + monitor_mcd_samples=50, + test_mcd_samples=50, + confidnet_fc_dim=None, + dg_reward=10, + balanced_sampeling=False, + budget=0.3, + ), + eval=EvalConfig( + tb_hparams=["fold"], + test_conf_scaling=False, + val_tuning=True, + r_star=0.25, + r_delta=0.05, + query_studies=QueryStudiesConfig( + iid_study="svhn_384", + noise_study=[], + in_class_study=[], + new_class_study=["cifar10_384", "cifar100_384", "tinyimagenet_384"], + ), + performance_metrics=PerfMetricsConfig( + train=["loss", "nll", "accuracy"], + val=["loss", "nll", "accuracy", "brier_score"], + test=["nll", "accuracy", "brier_score"], + ), + confid_metrics=ConfidMetricsConfig( + train=[ + "failauc", + "failap_suc", + "failap_err", + "fpr@95tpr", + "e-aurc", + "aurc", + ], + val=["failauc", "failap_suc", "failap_err", "fpr@95tpr", "e-aurc", "aurc"], + test=[ + "failauc", + "failap_suc", + "failap_err", + "mce", + "ece", + "b-aurc", + "e-aurc", + "aurc", + "fpr@95tpr", + ], + ), + confidence_measures=ConfidMeasuresConfig( + train=["det_mcp"], val=["det_mcp"], test=["det_mcp", "det_pe", "ext"] + ), + monitor_plots=["hist_per_confid"], + ext_confid_name="dg", + ), + test=TestConfig( + name="test_results", + dir=Path("${exp.dir}/${test.name}"), + cf_path=Path("${exp.dir}/hydra/config.yaml"), + selection_criterion="latest", + best_ckpt_path=Path("${exp.version_dir}/${test.selection_criterion}.ckpt"), + only_latest_version=True, + devries_repro_ood_split=False, + assim_ood_norm_flag=False, + iid_set_split="devries", + raw_output_path="raw_output.npz", + external_confids_output_path="external_confids.npz", + output_precision=16, + selection_mode="max", + ), +) + + +def get_experiment_config(name: str) -> Config: + return __experiments[name] diff --git a/fd_shifts/main.py b/fd_shifts/main.py new file mode 100644 index 0000000..144c58f --- /dev/null +++ b/fd_shifts/main.py @@ -0,0 +1,345 @@ +import types +import typing +from contextlib import contextmanager +from contextvars import ContextVar +from dataclasses import asdict, is_dataclass +from pathlib import Path +from typing import Any, Callable + +import pytorch_lightning as pl +import rich +from jsonargparse import ArgumentParser +from jsonargparse._actions import Action +from omegaconf import OmegaConf +from pytorch_lightning.callbacks.progress.rich_progress import RichProgressBar +from pytorch_lightning.loggers.csv_logs import CSVLogger +from pytorch_lightning.loggers.tensorboard import TensorBoardLogger +from pytorch_lightning.loggers.wandb import WandbLogger +from rich.pretty import pretty_repr + +from fd_shifts import analysis, logger +from fd_shifts.configs import Config +from fd_shifts.experiments.configs import get_experiment_config +from fd_shifts.loaders.data_loader import FDShiftsDataLoader +from fd_shifts.models import get_model +from fd_shifts.models.callbacks import get_callbacks +from fd_shifts.utils import exp_utils + +__subcommands = {} + + +def subcommand(func: Callable): + __subcommands[func.__name__] = func + return func + + +previous_config: ContextVar = ContextVar("previous_config", default=None) + + +@contextmanager +def previous_config_context(cfg): + token = previous_config.set(cfg) + try: + yield + finally: + previous_config.reset(token) + + +class ActionExperiment(Action): + """Action to indicate that an argument is an experiment name.""" + + def __init__(self, **kwargs): + """Initializer for ActionExperiment instance.""" + if "default" in kwargs: + raise ValueError("ActionExperiment does not accept a default.") + opt_name = kwargs["option_strings"] + opt_name = ( + opt_name[0] + if len(opt_name) == 1 + else [x for x in opt_name if x[0:2] == "--"][0] + ) + if "." in opt_name: + raise ValueError("ActionExperiment must be a top level option.") + if "help" not in kwargs: + # TODO: hint to list-experiments + kwargs["help"] = "Name of an experiment." + super().__init__(**kwargs) + + def __call__(self, parser, cfg, values, option_string=None): + """Parses the given experiment configuration and adds all the corresponding keys to the namespace. + + Raises: + TypeError: If there are problems parsing the configuration. + """ + self.apply_experiment_config(parser, cfg, self.dest, values) + + @staticmethod + def apply_experiment_config(parser: ArgumentParser, cfg, dest, value) -> None: + with previous_config_context(cfg): + experiment_cfg = get_experiment_config(value) + tcfg = parser.parse_object( + {"config": asdict(experiment_cfg)}, + env=False, + defaults=False, + _skip_check=True, + ) + cfg_merged = parser.merge_config(tcfg, cfg) + cfg.__dict__.update(cfg_merged.__dict__) + cfg[dest] = value + + +def _path_to_str(cfg) -> dict: + def __path_to_str(cfg): + if isinstance(cfg, dict): + return {k: __path_to_str(v) for k, v in cfg.items()} + if is_dataclass(cfg): + return cfg.__class__( + **{k: __path_to_str(v) for k, v in cfg.__dict__.items()} + ) + if isinstance(cfg, Path): + return str(cfg) + return cfg + + return __path_to_str(cfg) # type: ignore + + +def _dict_to_dataclass(cfg) -> Config: + def __dict_to_dataclass(cfg, cls): + if is_dataclass(cls): + fieldtypes = typing.get_type_hints(cls) + return cls( + **{k: __dict_to_dataclass(v, fieldtypes[k]) for k, v in cfg.items()} + ) + if ( + isinstance(cls, types.UnionType) + and Path in cls.__args__ + and cfg is not None + ): + return Path(cfg) + return cfg + + return __dict_to_dataclass(cfg, Config) # type: ignore + + +def omegaconf_resolve(config: Config): + """Resolve all variable interpolations in config object with OmegaConf + + Args: + config: Config object to resolve + + Returns: + resolved config object + """ + dict_config = asdict(config) + + # convert all paths to string, omegaconf does not do variable interpolation in anything that's not a string + dict_config = _path_to_str(dict_config) + + # omegaconf can't handle callables, may need to extend this list if other callable configs get added + del dict_config["trainer"]["lr_scheduler"] + del dict_config["trainer"]["optimizer"] + + oc_config = OmegaConf.create(dict_config) + dict_config: dict[str, Any] = OmegaConf.to_object(oc_config) # type: ignore + + dict_config["trainer"]["lr_scheduler"] = config.trainer.lr_scheduler + dict_config["trainer"]["optimizer"] = config.trainer.optimizer + + new_config = _dict_to_dataclass(dict_config) + return new_config + + +def setup_logging(): + rich.reconfigure(stderr=True, force_terminal=True) + logger.remove() # Remove default 'stderr' handler + + # We need to specify end=''" as log message already ends with \n (thus the lambda function) + # Also forcing 'colorize=True' otherwise Loguru won't recognize that the sink support colors + logger.add( + lambda m: rich.get_console().print(m, end="", markup=False, highlight=False), + colorize=True, + enqueue=True, + level="DEBUG", + backtrace=True, + diagnose=True, + ) + + +@subcommand +def train(config: Config): + progress = RichProgressBar(console_kwargs={"stderr": True, "force_terminal": True}) + + if config.exp.dir is None: + raise ValueError("Experiment directory must be specified") + config.exp.version = exp_utils.get_next_version(config.exp.dir) + # HACK: This should be automatically linked or not configurable + config.exp.version_dir = config.exp.dir / f"version_{config.exp.version}" + + logger.info(pretty_repr(config)) + + # TODO: Clean the rest of this up + + max_steps = ( + config.trainer.num_steps if hasattr(config.trainer, "num_steps") else None + ) + accumulate_grad_batches = ( + config.trainer.accumulate_grad_batches + if hasattr(config.trainer, "accumulate_grad_batches") + else 1 + ) + + limit_batches: float | int = 1.0 + num_epochs = config.trainer.num_epochs + val_every_n_epoch = config.trainer.val_every_n_epoch + log_every_n_steps = 50 + + if isinstance(config.trainer.fast_dev_run, bool): + limit_batches = 1 if config.trainer.fast_dev_run else 1.0 + num_epochs = 1 if config.trainer.fast_dev_run else num_epochs + max_steps = 1 if config.trainer.fast_dev_run else max_steps + val_every_n_epoch = 1 if config.trainer.fast_dev_run else val_every_n_epoch + elif isinstance(config.trainer.fast_dev_run, int): + limit_batches = config.trainer.fast_dev_run * accumulate_grad_batches + max_steps = config.trainer.fast_dev_run * 2 + config.trainer.dg_pretrain_epochs = None + config.trainer.dg_pretrain_steps = (max_steps * 2) // 3 + val_every_n_epoch = 1 + log_every_n_steps = 1 + num_epochs = None + + datamodule = FDShiftsDataLoader(config) + model = get_model(config.model.name)(config) + csv_logger = CSVLogger( + save_dir=str(config.exp.group_dir), + name=config.exp.name, + version=config.exp.version, + ) + + tb_logger = TensorBoardLogger( + save_dir=str(config.exp.group_dir), + name=config.exp.name, + default_hp_metric=False, + ) + + wandb_logger = WandbLogger( + project="fd_shifts_proto", + name=config.exp.name, + ) + + trainer = pl.Trainer( + accelerator="auto", + devices="auto", + logger=[tb_logger, csv_logger, wandb_logger], + log_every_n_steps=log_every_n_steps, + max_epochs=num_epochs, + max_steps=max_steps, # type: ignore + callbacks=[progress] + get_callbacks(config), + benchmark=config.trainer.benchmark, + precision=16, + check_val_every_n_epoch=val_every_n_epoch, + num_sanity_val_steps=5, + limit_train_batches=limit_batches, + limit_val_batches=0 if config.trainer.do_val is False else limit_batches, + limit_test_batches=limit_batches, + gradient_clip_val=1, + accumulate_grad_batches=accumulate_grad_batches, + ) + + logger.info( + "logging training to: {}, version: {}".format( + config.exp.dir, config.exp.version + ) + ) + trainer.fit(model=model, datamodule=datamodule) + + +@subcommand +def test(config: Config): + progress = RichProgressBar(console_kwargs={"stderr": True, "force_terminal": True}) + + if config.exp.dir is None: + raise ValueError("Experiment directory must be specified") + + config.exp.version = ( + version if (version := exp_utils.get_most_recent_version(config.exp.dir)) else 0 + ) + # HACK: This should be automatically linked or not configurable + config.exp.version_dir = config.exp.dir / f"version_{config.exp.version}" + logger.info(pretty_repr(config)) + + ckpt_path = exp_utils._get_resume_ckpt_path(config) + + logger.info( + "testing model from checkpoint: {} from model selection tpye {}".format( + ckpt_path, config.test.selection_criterion + ) + ) + logger.info("logging testing to: {}".format(config.test.dir)) + + module = get_model(config.model.name)(config) + + # TODO: make common module class with this method + module.load_only_state_dict(ckpt_path) # type: ignore + + datamodule = FDShiftsDataLoader(config) + + if not config.test.dir.exists(): + config.test.dir.mkdir(parents=True) + + limit_batches: float | int = 1.0 + log_every_n_steps = 50 + + if isinstance(config.trainer.fast_dev_run, bool): + limit_batches = 1 if config.trainer.fast_dev_run else 1.0 + elif isinstance(config.trainer.fast_dev_run, int): + limit_batches = config.trainer.fast_dev_run + log_every_n_steps = 1 + + wandb_logger = WandbLogger( + project="fd_shifts_proto", + name=config.exp.name, + ) + + trainer = pl.Trainer( + accelerator="auto", + devices="auto", + logger=wandb_logger, + log_every_n_steps=log_every_n_steps, + callbacks=[progress] + get_callbacks(config), + limit_test_batches=limit_batches, + precision=16, + ) + trainer.test(model=module, datamodule=datamodule) + analysis.main( + in_path=config.test.dir, + out_path=config.test.dir, + query_studies=config.eval.query_studies, + add_val_tuning=config.eval.val_tuning, + threshold_plot_confid=None, + cf=config, + ) + + +def main(): + setup_logging() + + parser = ArgumentParser(parser_mode="omegaconf") + subcommands = parser.add_subcommands(dest="command") + + for name, func in __subcommands.items(): + subparser = ArgumentParser(parser_mode="omegaconf") + subparser.add_argument("--experiment", action=ActionExperiment) + subparser.add_function_arguments(func, sub_configs=True) + subcommands.add_subcommand(name, subparser) + + args = parser.parse_args() + + args = parser.instantiate_classes(args) + + args[args.command].config = omegaconf_resolve(args[args.command].config) + + __subcommands[args.command](config=args[args.command].config) + + +if __name__ == "__main__": + main() diff --git a/fd_shifts/models/devries_model.py b/fd_shifts/models/devries_model.py index bc04640..f887e7e 100644 --- a/fd_shifts/models/devries_model.py +++ b/fd_shifts/models/devries_model.py @@ -312,17 +312,28 @@ def test_step(self, batch, batch_idx, *args): } def configure_optimizers(self): + # optimizers = [ + # hydra.utils.instantiate(self.optimizer_cfgs, _partial_=True)( + # self.model.parameters() + # ) + # ] + + # schedulers = [ + # { + # "scheduler": hydra.utils.instantiate(self.lr_scheduler_cfgs)( + # optimizer=optimizers[0] + # ), + # "interval": self.lr_scheduler_interval, + # }, + # ] + optimizers = [ - hydra.utils.instantiate(self.optimizer_cfgs, _partial_=True)( - self.model.parameters() - ) + self.optimizer_cfgs(self.model.parameters()), ] schedulers = [ { - "scheduler": hydra.utils.instantiate(self.lr_scheduler_cfgs)( - optimizer=optimizers[0] - ), + "scheduler": self.lr_scheduler_cfgs(optimizers[0]), "interval": self.lr_scheduler_interval, }, ] diff --git a/pyproject.toml b/pyproject.toml index 72e88eb..ed61e77 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -14,6 +14,7 @@ dependencies = [ "hydra-zen", "imageio>=2.9.0", "ipython", + "jsonargparse[signatures]", "loguru", "matplotlib>=3.3.4", "medmnist", From b24f6c437d41cb87c5bf5989cbbc00f3577c32be Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 11 Jan 2024 15:36:19 +0100 Subject: [PATCH 067/136] wip: feat: save and load configs --- fd_shifts/configs/__init__.py | 133 ++++++++++++++++++------------- fd_shifts/experiments/configs.py | 43 ++++++---- fd_shifts/main.py | 22 +++-- 3 files changed, 123 insertions(+), 75 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 8b9c4e4..274fd14 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -1,5 +1,6 @@ from __future__ import annotations +import importlib import os from collections.abc import Mapping from copy import deepcopy @@ -123,67 +124,91 @@ class ExperimentConfig(_IterableMixin): output_paths: OutputPathsPerMode = OutputPathsPerMode() -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) -class LRSchedulerConfig: - """Base class for LR scheduler configuration""" +# @defer_validation +# @dataclass(config=ConfigDict(validate_assignment=True)) +# class LRSchedulerConfig: +# """Base class for LR scheduler configuration""" - _target_: str = MISSING - _partial_: Optional[bool] = None +# _target_: str = MISSING +# _partial_: Optional[bool] = None -CosineAnnealingLR = builds( - torch.optim.lr_scheduler.CosineAnnealingLR, - builds_bases=(LRSchedulerConfig,), - zen_partial=True, - populate_full_signature=True, - T_max="${trainer.num_steps}", -) +# CosineAnnealingLR = builds( +# torch.optim.lr_scheduler.CosineAnnealingLR, +# builds_bases=(LRSchedulerConfig,), +# zen_partial=True, +# populate_full_signature=True, +# T_max="${trainer.num_steps}", +# ) -LinearWarmupCosineAnnealingLR = builds( - pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR, - builds_bases=(LRSchedulerConfig,), - zen_partial=True, - populate_full_signature=True, - max_epochs="${trainer.num_steps}", - warmup_epochs=500, -) +# LinearWarmupCosineAnnealingLR = builds( +# pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR, +# builds_bases=(LRSchedulerConfig,), +# zen_partial=True, +# populate_full_signature=True, +# max_epochs="${trainer.num_steps}", +# warmup_epochs=500, +# ) -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) -class OptimizerConfig: - """Base class for optimizer configuration""" +# @defer_validation +# @dataclass(config=ConfigDict(validate_assignment=True)) +# class OptimizerConfig: +# """Base class for optimizer configuration""" - _target_: str = MISSING - _partial_: Optional[bool] = True +# _target_: str = MISSING +# _partial_: Optional[bool] = True -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) -class SGD(OptimizerConfig): - """Configuration for SGD optimizer""" +# @defer_validation +# @dataclass(config=ConfigDict(validate_assignment=True)) +# class SGD(OptimizerConfig): +# """Configuration for SGD optimizer""" - _target_: str = "torch.optim.sgd.SGD" - lr: float = 0.003 # pylint: disable=invalid-name - dampening: float = 0.0 - momentum: float = 0.9 - nesterov: bool = False - maximize: bool = False - weight_decay: float = 0.0 +# _target_: str = "torch.optim.sgd.SGD" +# lr: float = 0.003 # pylint: disable=invalid-name +# dampening: float = 0.0 +# momentum: float = 0.9 +# nesterov: bool = False +# maximize: bool = False +# weight_decay: float = 0.0 -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) -class Adam(OptimizerConfig): - """Configuration for ADAM optimizer""" +# @defer_validation +# @dataclass(config=ConfigDict(validate_assignment=True)) +# class Adam(OptimizerConfig): +# """Configuration for ADAM optimizer""" + +# _target_: str = "torch.optim.adam.Adam" +# lr: float = 0.003 # pylint: disable=invalid-name +# betas: tuple[float, float] = (0.9, 0.999) +# eps: float = 1e-08 +# maximize: bool = False +# weight_decay: float = 0.0 + + +@dataclass +class LRSchedulerConfig: + init_args: dict + class_path: str = "fd_shifts.configs.LRSchedulerConfig" + + def __call__( + self, optim: torch.optim.Optimizer + ) -> torch.optim.lr_scheduler._LRScheduler: + module_name, class_name = self.init_args["class_path"].rsplit(".", 1) + cls = getattr(importlib.import_module(module_name), class_name) + return cls(optim, **self.init_args["init_args"]) + + +@dataclass +class OptimizerConfig: + init_args: dict + class_path: str = "fd_shifts.configs.OptimizerConfig" - _target_: str = "torch.optim.adam.Adam" - lr: float = 0.003 # pylint: disable=invalid-name - betas: tuple[float, float] = (0.9, 0.999) - eps: float = 1e-08 - maximize: bool = False - weight_decay: float = 0.0 + def __call__(self, params: Iterable) -> torch.optim.Optimizer: + module_name, class_name = self.init_args["class_path"].rsplit(".", 1) + cls = getattr(importlib.import_module(module_name), class_name) + return cls(params, **self.init_args["init_args"]) @defer_validation @@ -200,12 +225,12 @@ class TrainerConfig(_IterableMixin): resume_from_ckpt: bool = False benchmark: bool = True fast_dev_run: bool | int = False - lr_scheduler: Callable[ - [torch.optim.Optimizer], torch.optim.lr_scheduler._LRScheduler - ] | None = None - optimizer: Callable[[Iterable], torch.optim.Optimizer] | None = None - # lr_scheduler: LRSchedulerConfig | None = None - # optimizer: OptimizerConfig | None = None + # lr_scheduler: Callable[ + # [torch.optim.Optimizer], torch.optim.lr_scheduler._LRScheduler + # ] | None = None + # optimizer: Callable[[Iterable], torch.optim.Optimizer] | None = None + lr_scheduler: LRSchedulerConfig | None = None + optimizer: OptimizerConfig | None = None accumulate_grad_batches: int = 1 resume_from_ckpt_confidnet: bool = False dg_pretrain_epochs: int | None = 100 diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index 509b9ca..04e21a3 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -1,5 +1,8 @@ +import importlib import os +from dataclasses import dataclass from pathlib import Path +from typing import Iterable import pl_bolts import torch @@ -12,9 +15,11 @@ DataConfig, EvalConfig, ExperimentConfig, + LRSchedulerConfig, Mode, ModelConfig, NetworkConfig, + OptimizerConfig, OutputPathsConfig, OutputPathsPerMode, PerfMetricsConfig, @@ -80,22 +85,30 @@ def get_data_config(name: str) -> DataConfig: resume_from_ckpt=False, benchmark=True, fast_dev_run=False, - lr_scheduler=lambda optim: pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR( - optim, - warmup_epochs=500, - max_epochs=60000, - warmup_start_lr=0.0, - eta_min=0.0, - last_epoch=-1, + lr_scheduler=LRSchedulerConfig( + { + "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", + "init_args": { + "warmup_epochs": 500, + "max_epochs": 60000, + "warmup_start_lr": 0.0, + "eta_min": 0.0, + "last_epoch": -1, + }, + } ), - optimizer=lambda params: torch.optim.SGD( - params, - lr=0.01, - dampening=0.0, - momentum=0.9, - nesterov=False, - maximize=False, - weight_decay=0.0, + optimizer=OptimizerConfig( + { + "class_path": "torch.optim.SGD", + "init_args": { + "lr": 0.01, + "dampening": 0.0, + "momentum": 0.9, + "nesterov": False, + "maximize": False, + "weight_decay": 0.0, + }, + } ), accumulate_grad_batches=1, resume_from_ckpt_confidnet=False, diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 144c58f..13713d7 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -8,7 +8,7 @@ import pytorch_lightning as pl import rich -from jsonargparse import ArgumentParser +from jsonargparse import ActionConfigFile, ArgumentParser from jsonargparse._actions import Action from omegaconf import OmegaConf from pytorch_lightning.callbacks.progress.rich_progress import RichProgressBar @@ -323,22 +323,32 @@ def test(config: Config): def main(): setup_logging() - parser = ArgumentParser(parser_mode="omegaconf") + parser = ArgumentParser() + parser.add_argument("-f", "--overwrite-config-file", action="store_true") subcommands = parser.add_subcommands(dest="command") + subparsers: dict[str, ArgumentParser] = {} for name, func in __subcommands.items(): - subparser = ArgumentParser(parser_mode="omegaconf") + subparser = ArgumentParser() + subparser.add_argument("--config-file", action=ActionConfigFile) subparser.add_argument("--experiment", action=ActionExperiment) subparser.add_function_arguments(func, sub_configs=True) + subparsers[name] = subparser subcommands.add_subcommand(name, subparser) args = parser.parse_args() - args = parser.instantiate_classes(args) + config = parser.instantiate_classes(args)[args.command].config + config = omegaconf_resolve(config) - args[args.command].config = omegaconf_resolve(args[args.command].config) + subparsers[args.command].save( + args[args.command], + config.test.cf_path, + skip_check=True, + overwrite=args.overwrite_config_file, + ) - __subcommands[args.command](config=args[args.command].config) + __subcommands[args.command](config=config) if __name__ == "__main__": From 314f7dce99dcfcd01d05e31185508bbc6332c9ce Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Fri, 12 Jan 2024 12:09:15 +0100 Subject: [PATCH 068/136] wip: feat: handle legacy config files --- fd_shifts/main.py | 102 +++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 100 insertions(+), 2 deletions(-) diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 13713d7..7baf1fc 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -4,10 +4,12 @@ from contextvars import ContextVar from dataclasses import asdict, is_dataclass from pathlib import Path -from typing import Any, Callable +from typing import Any, Callable, Optional +import jsonargparse import pytorch_lightning as pl import rich +import yaml from jsonargparse import ActionConfigFile, ArgumentParser from jsonargparse._actions import Action from omegaconf import OmegaConf @@ -88,6 +90,100 @@ def apply_experiment_config(parser: ArgumentParser, cfg, dest, value) -> None: cfg[dest] = value +class ActionLegacyConfigFile(ActionConfigFile): + """Action to indicate that an argument is a configuration file or a configuration string.""" + + def __init__(self, **kwargs): + """Initializer for ActionLegacyConfigFile instance.""" + if "default" in kwargs: + self.set_default_error() + opt_name = kwargs["option_strings"] + opt_name = ( + opt_name[0] + if len(opt_name) == 1 + else [x for x in opt_name if x[0:2] == "--"][0] + ) + if "." in opt_name: + raise ValueError("ActionLegacyConfigFile must be a top level option.") + if "help" not in kwargs: + kwargs["help"] = "Path to a configuration file." + super().__init__(**kwargs) + + def __call__(self, parser, cfg, values, option_string=None): + """Parses the given configuration and adds all the corresponding keys to the namespace. + + Raises: + TypeError: If there are problems parsing the configuration. + """ + self.apply_config(parser, cfg, self.dest, values, option_string) + + @staticmethod + def set_default_error(): + raise ValueError( + "ActionLegacyConfigFile does not accept a default, use default_config_files." + ) + + @staticmethod + def apply_config(parser, cfg, dest, value, option_string) -> None: + from jsonargparse._link_arguments import skip_apply_links + + with jsonargparse._actions._ActionSubCommands.not_single_subcommand(), previous_config_context( + cfg + ), skip_apply_links(): + kwargs = { + "env": False, + "defaults": False, + "_skip_check": True, + } + cfg_path: Optional[jsonargparse.Path] = jsonargparse.Path( + value, mode=jsonargparse._optionals.get_config_read_mode() + ) + + with cfg_path.open() as f: + cfg_from_file = yaml.unsafe_load(f) + + if option_string == "--config-file": + cfg_file = cfg_from_file + elif option_string == "--legacy-config-file": + cfg_file = {"config": cfg_from_file} + + # hydra instantiate to jsonargparse instantiate format + lr_scheduler_cfg = cfg_file["config"]["trainer"]["lr_scheduler"] + cfg_file["config"]["trainer"]["lr_scheduler"] = { + "class_path": "fd_shifts.configs.LRSchedulerConfig", + "init_args": { + "class_path": lr_scheduler_cfg["_target_"], + "init_args": { + k: v + for k, v in lr_scheduler_cfg.items() + if k not in ["_target_", "_partial_"] + }, + }, + } + optimizer_cfg = cfg_file["config"]["trainer"]["optimizer"] + cfg_file["config"]["trainer"]["optimizer"] = { + "class_path": "fd_shifts.configs.OptimizerConfig", + "init_args": { + "class_path": optimizer_cfg["_target_"], + "init_args": { + k: v + for k, v in optimizer_cfg.items() + if k not in ["_target_", "_partial_"] + }, + }, + } + else: + raise ValueError(f"Unknown option string {option_string}") + + cfg_file = parser.parse_object(cfg_file, **kwargs) + + cfg_merged = parser.merge_config(cfg_file, cfg) + cfg.__dict__.update(cfg_merged.__dict__) + if cfg.get(dest) is None: + cfg[dest] = [] + cfg[dest].append(cfg_path) + + def _path_to_str(cfg) -> dict: def __path_to_str(cfg): if isinstance(cfg, dict): @@ -330,7 +426,9 @@ def main(): for name, func in __subcommands.items(): subparser = ArgumentParser() - subparser.add_argument("--config-file", action=ActionConfigFile) + subparser.add_argument( + "--config-file", "--legacy-config-file", action=ActionLegacyConfigFile + ) subparser.add_argument("--experiment", action=ActionExperiment) subparser.add_function_arguments(func, sub_configs=True) subparsers[name] = subparser From de97f715f036259a5a1a293db54f3be8d2319d6e Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Fri, 12 Jan 2024 12:10:05 +0100 Subject: [PATCH 069/136] wip: feat: add list-experiments and --version --- fd_shifts/experiments/configs.py | 4 ++++ fd_shifts/main.py | 18 ++++++++++++++++-- 2 files changed, 20 insertions(+), 2 deletions(-) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index 04e21a3..b00385d 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -255,3 +255,7 @@ def get_data_config(name: str) -> DataConfig: def get_experiment_config(name: str) -> Config: return __experiments[name] + + +def list_experiment_configs() -> list[str]: + return list(__experiments.keys()) diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 7baf1fc..2b73c6e 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -21,11 +21,12 @@ from fd_shifts import analysis, logger from fd_shifts.configs import Config -from fd_shifts.experiments.configs import get_experiment_config +from fd_shifts.experiments.configs import get_experiment_config, list_experiment_configs from fd_shifts.loaders.data_loader import FDShiftsDataLoader from fd_shifts.models import get_model from fd_shifts.models.callbacks import get_callbacks from fd_shifts.utils import exp_utils +from fd_shifts.version import get_version __subcommands = {} @@ -416,14 +417,23 @@ def test(config: Config): ) +def _list_experiments(): + rich.print("Available experiments:") + for exp in sorted(list_experiment_configs()): + rich.print(exp) + + def main(): setup_logging() - parser = ArgumentParser() + parser = ArgumentParser(version=get_version()) parser.add_argument("-f", "--overwrite-config-file", action="store_true") subcommands = parser.add_subcommands(dest="command") subparsers: dict[str, ArgumentParser] = {} + subparser = ArgumentParser() + subcommands.add_subcommand("list-experiments", subparser) + for name, func in __subcommands.items(): subparser = ArgumentParser() subparser.add_argument( @@ -436,6 +446,10 @@ def main(): args = parser.parse_args() + if args.command == "list-experiments": + _list_experiments() + return + config = parser.instantiate_classes(args)[args.command].config config = omegaconf_resolve(config) From a0f7c99a3cfb333b8de8061d636dc8f58e8b5fba Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 16 Jan 2024 16:29:52 +0100 Subject: [PATCH 070/136] feat(config): better defaults --- fd_shifts/configs/__init__.py | 75 +++++++++++++++++++++++------------ 1 file changed, 49 insertions(+), 26 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 274fd14..c33b458 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -94,8 +94,24 @@ class OutputPathsConfig(_IterableMixin): class OutputPathsPerMode(_IterableMixin): """Container for per-mode output paths""" - fit: OutputPathsConfig = OutputPathsConfig() - test: OutputPathsConfig = OutputPathsConfig() + fit: OutputPathsConfig = OutputPathsConfig( + raw_output=Path("${exp.version_dir}/raw_output.npz"), + raw_output_dist=Path("${exp.version_dir}/raw_output_dist.npz"), + external_confids=Path("${exp.version_dir}/external_confids.npz"), + external_confids_dist=Path("${exp.version_dir}/external_confids_dist.npz"), + input_imgs_plot=Path("${exp.dir}/input_imgs.png"), + encoded_output=None, + attributions_output=None, + ) + test: OutputPathsConfig = OutputPathsConfig( + raw_output=Path("${test.dir}/raw_logits.npz"), + raw_output_dist=Path("${test.dir}/raw_logits_dist.npz"), + external_confids=Path("${test.dir}/external_confids.npz"), + external_confids_dist=Path("${test.dir}/external_confids_dist.npz"), + input_imgs_plot=None, + encoded_output=Path("${test.dir}/encoded_output.npz"), + attributions_output=Path("${test.dir}/attributions.csv"), + ) @defer_validation @@ -103,23 +119,23 @@ class OutputPathsPerMode(_IterableMixin): class ExperimentConfig(_IterableMixin): """Main experiment config""" - group_name: str | None = None - name: str | None = None + group_name: str + name: str mode: Mode = Mode.train_test - work_dir: Path | None = Path.cwd() - fold_dir: Path | None = None + work_dir: Path = Path.cwd() + fold_dir: Path = Path("exp/${exp.fold}") root_dir: Path | None = Path(p) if (p := os.getenv("EXPERIMENT_ROOT_DIR")) else None data_root_dir: Path | None = ( Path(p) if (p := os.getenv("DATASET_ROOT_DIR")) else None ) - group_dir: Path | None = SI("${exp.root_dir}/${exp.group_name}") - dir: Path | None = group_dir / name if group_dir and name else None - version: Optional[int] = None - version_dir: Path | None = dir / f"version_{version}" if dir and version else None + group_dir: Path = Path("${exp.root_dir}/${exp.group_name}") + dir: Path = Path("${exp.group_dir}/${exp.name}") + version: int | None = None + version_dir: Path = Path("${exp.dir}/version_${exp.version}") fold: int = 0 crossval_n_folds: int = 10 - crossval_ids_path: Path | None = dir / "crossval_ids.pickle" if dir else None - log_path: Path | None = None + crossval_ids_path: Path = Path("${exp.dir}/crossval_ids.pickle") + log_path: Path = Path("log.txt") global_seed: int = randint(0, 1_000_000) output_paths: OutputPathsPerMode = OutputPathsPerMode() @@ -239,7 +255,13 @@ class TrainerConfig(_IterableMixin): lr_scheduler_interval: str = "epoch" # TODO: Replace with jsonargparse compatible type hint to lightning.Callback - callbacks: dict[str, Optional[dict[Any, Any]]] = field(default_factory=lambda: {}) + callbacks: dict[str, Optional[dict[Any, Any]]] = field( + default_factory=lambda: { + "model_checkpoint": None, + "confid_monitor": None, + "learning_rate_monitor": None, + } + ) learning_rate_confidnet: Optional[float] = None learning_rate_confidnet_finetune: Optional[float] = None @@ -405,6 +427,7 @@ class ConfidMeasuresConfig(_IterableMixin): train: list[str] = field(default_factory=lambda: ["det_mcp"]) val: list[str] = field(default_factory=lambda: ["det_mcp"]) test: list[str] = field(default_factory=lambda: ["det_mcp", "det_pe", "ext"]) + test: list[str] = field(default_factory=lambda: ["det_mcp", "det_pe"]) # pylint: disable=no-self-argument @validator("train", "val", "test", each_item=True) @@ -479,18 +502,18 @@ class TestConfig(_IterableMixin): """Inference time configuration""" name: str = "test_results" - dir: Path | None = None - cf_path: Path | None = None - selection_criterion: str | None = None - best_ckpt_path: Path | None = None - only_latest_version: bool | None = None - devries_repro_ood_split: bool | None = None - assim_ood_norm_flag: bool | None = None - iid_set_split: str | None = None - raw_output_path: str | None = None - external_confids_output_path: str | None = None - output_precision: int | None = None - selection_mode: Optional[str] = None + dir: Path = Path("${exp.dir}/${test.name}") + cf_path: Path = Path("${exp.dir}/hydra/config.yaml") + selection_criterion: str = "latest" + best_ckpt_path: Path = Path("${exp.version_dir}/${test.selection_criterion}.ckpt") + only_latest_version: bool = True + devries_repro_ood_split: bool = False + assim_ood_norm_flag: bool = False + iid_set_split: str = "devries" + raw_output_path: str = "raw_output.npz" + external_confids_output_path: str = "external_confids.npz" + output_precision: int = 16 + selection_mode: Optional[str] = "max" @defer_validation @@ -515,13 +538,13 @@ class DataConfig(_IterableMixin): class Config(_IterableMixin): """Main Configuration Class""" + exp: ExperimentConfig pkgversion: str = fd_shifts.get_version() data: DataConfig = DataConfig() trainer: TrainerConfig = TrainerConfig() - exp: ExperimentConfig = ExperimentConfig() model: ModelConfig = ModelConfig() eval: EvalConfig = EvalConfig() From 3f8b5692ecf7f4431447d6677d2cc0a70e0b96e6 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 16 Jan 2024 16:31:15 +0100 Subject: [PATCH 071/136] fix(config): mutable sub-objects are shared references, init as fields --- fd_shifts/configs/__init__.py | 30 +++++++++++++++++++----------- 1 file changed, 19 insertions(+), 11 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index c33b458..c1904ec 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -320,7 +320,7 @@ class ModelConfig(_IterableMixin): """Model Configuration""" name: str = "devries_model" - network: NetworkConfig = NetworkConfig() + network: NetworkConfig = field(default_factory=lambda: NetworkConfig()) fc_dim: int = 512 avg_pool: bool = True dropout_rate: int = 0 @@ -426,7 +426,6 @@ class ConfidMeasuresConfig(_IterableMixin): train: list[str] = field(default_factory=lambda: ["det_mcp"]) val: list[str] = field(default_factory=lambda: ["det_mcp"]) - test: list[str] = field(default_factory=lambda: ["det_mcp", "det_pe", "ext"]) test: list[str] = field(default_factory=lambda: ["det_mcp", "det_pe"]) # pylint: disable=no-self-argument @@ -482,10 +481,18 @@ class EvalConfig(_IterableMixin): r_star: float = 0.25 r_delta: float = 0.05 - query_studies: QueryStudiesConfig = QueryStudiesConfig() - performance_metrics: PerfMetricsConfig = PerfMetricsConfig() - confid_metrics: ConfidMetricsConfig = ConfidMetricsConfig() - confidence_measures: ConfidMeasuresConfig = ConfidMeasuresConfig() + query_studies: QueryStudiesConfig = field( + default_factory=lambda: QueryStudiesConfig() + ) + performance_metrics: PerfMetricsConfig = field( + default_factory=lambda: PerfMetricsConfig() + ) + confid_metrics: ConfidMetricsConfig = field( + default_factory=lambda: ConfidMetricsConfig() + ) + confidence_measures: ConfidMeasuresConfig = field( + default_factory=lambda: ConfidMeasuresConfig() + ) monitor_plots: list[str] = field( default_factory=lambda: [ @@ -539,16 +546,17 @@ class Config(_IterableMixin): """Main Configuration Class""" exp: ExperimentConfig + pkgversion: str = fd_shifts.get_version() - data: DataConfig = DataConfig() + data: DataConfig = field(default_factory=lambda: DataConfig()) - trainer: TrainerConfig = TrainerConfig() + trainer: TrainerConfig = field(default_factory=lambda: TrainerConfig()) - model: ModelConfig = ModelConfig() + model: ModelConfig = field(default_factory=lambda: ModelConfig()) - eval: EvalConfig = EvalConfig() - test: TestConfig = TestConfig() + eval: EvalConfig = field(default_factory=lambda: EvalConfig()) + test: TestConfig = field(default_factory=lambda: TestConfig()) def update_experiment(self, name: str): config = deepcopy(self) From 800fd3b531277016db1e3d049c8f6769809d4ed3 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 16 Jan 2024 16:33:13 +0100 Subject: [PATCH 072/136] wip: feat(config): make query studies DataConfigs --- fd_shifts/analysis/__init__.py | 10 +++++- fd_shifts/configs/__init__.py | 6 ++-- fd_shifts/loaders/data_loader.py | 60 ++++++++++++++++++-------------- 3 files changed, 46 insertions(+), 30 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 627fa32..2634045 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -192,7 +192,9 @@ def dataset_name_to_idx(self, dataset_name: str) -> int: flat_test_set_list = [] for _, datasets in self.config.eval.query_studies: - if isinstance(datasets, (list, ListConfig)): + if isinstance(datasets, (list, ListConfig)) and len(datasets) > 0: + if isinstance(datasets[0], configs.DataConfig): + datasets = map(lambda d: d.dataset, datasets) flat_test_set_list.extend(list(datasets)) else: flat_test_set_list.append(datasets) @@ -605,6 +607,12 @@ def __init__( self.query_studies = ( self.cfg.eval.query_studies if query_studies is None else query_studies ) + for study_name, datasets in self.query_studies: + if isinstance(datasets, (list, ListConfig)) and len(datasets) > 0: + if isinstance(datasets[0], configs.DataConfig): + self.query_studies.__dict__[study_name] = list( + map(lambda d: d.dataset, datasets) + ) self.analysis_out_dir = analysis_out_dir self.calibration_bins = 20 self.val_risk_scores = {} diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index c1904ec..b850cdc 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -449,9 +449,9 @@ class QueryStudiesConfig(_IterableMixin): """Query Studies Configuration""" iid_study: str | None = None - noise_study: list[str] = field(default_factory=lambda: []) - in_class_study: list[str] = field(default_factory=lambda: []) - new_class_study: list[str] = field(default_factory=lambda: []) + noise_study: list[DataConfig] = field(default_factory=lambda: []) + in_class_study: list[DataConfig] = field(default_factory=lambda: []) + new_class_study: list[DataConfig] = field(default_factory=lambda: []) # pylint: disable=no-self-argument @validator( diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index 45c40ae..35ddf21 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -2,6 +2,8 @@ import os import pickle from copy import deepcopy +from dataclasses import asdict +from pathlib import Path import numpy as np import pytorch_lightning as pl @@ -25,9 +27,9 @@ def __init__(self, cf: configs.Config, no_norm_flag=False): self.crossval_ids_path = cf.exp.crossval_ids_path self.crossval_n_folds = cf.exp.crossval_n_folds self.fold = cf.exp.fold - self.data_dir = cf.data.data_dir - self.data_root_dir = cf.exp.data_root_dir - self.dataset_name = cf.data.dataset + self.data_dir: Path = cf.data.data_dir + self.data_root_dir: Path = cf.exp.data_root_dir + self.dataset_name: str = cf.data.dataset self.batch_size = cf.trainer.batch_size self.pin_memory = cf.data.pin_memory self.num_workers = cf.data.num_workers @@ -43,10 +45,11 @@ def __init__(self, cf: configs.Config, no_norm_flag=False): self.assim_ood_norm_flag = cf.test.assim_ood_norm_flag self.balanced_sampeling = cf.model.balanced_sampeling self.add_val_tuning = cf.eval.val_tuning - self.query_studies = dict(cf.eval.query_studies) + self.query_studies = cf.eval.query_studies + print(f"{self.query_studies=}") if self.query_studies is not None: self.external_test_sets = [] - for key, values in self.query_studies.items(): + for key, values in self.query_studies: if key != "iid_study" and values is not None: self.external_test_sets.extend(list(values)) logging.debug( @@ -55,28 +58,33 @@ def __init__(self, cf: configs.Config, no_norm_flag=False): if len(self.external_test_sets) > 0: self.external_test_configs = {} - for ext_set in self.external_test_sets: + for i, ext_set in enumerate(self.external_test_sets): overwrite_dataset = False - if ext_set.startswith("dermoscopyall"): - file_set = "dermoscopyall" - overwrite_dataset = False - elif ext_set.startswith("rxrx1all"): - file_set = "rxrx1all" - overwrite_dataset = False - elif ext_set.startswith("lidc_idriall"): - file_set = "lidc_idriall" - overwrite_dataset = False - elif ext_set.startswith("xray_chestall"): - file_set = "xray_chestall" - overwrite_dataset = False - else: - file_set = ext_set - self.external_test_configs[ext_set] = OmegaConf.load( - os.path.join( - os.path.abspath(os.path.dirname(data_configs.__file__)), - "{}_data.yaml".format(file_set), - ) - ).data + if isinstance(ext_set, str): + if ext_set.startswith("dermoscopyall"): + file_set = "dermoscopyall" + overwrite_dataset = False + elif ext_set.startswith("rxrx1all"): + file_set = "rxrx1all" + overwrite_dataset = False + elif ext_set.startswith("lidc_idriall"): + file_set = "lidc_idriall" + overwrite_dataset = False + elif ext_set.startswith("xray_chestall"): + file_set = "xray_chestall" + overwrite_dataset = False + else: + file_set = ext_set + self.external_test_configs[ext_set] = OmegaConf.load( + os.path.join( + os.path.abspath(os.path.dirname(data_configs.__file__)), + "{}_data.yaml".format(file_set), + ) + ).data + + elif isinstance(ext_set, configs.DataConfig): + self.external_test_configs[ext_set.dataset] = deepcopy(ext_set) + self.external_test_sets[i] = ext_set.dataset if overwrite_dataset: self.external_test_configs[ext_set].dataset = ext_set # set up target transforms From cb411b6d66bf902f2b5d567c09f61c92064cc2cf Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 16 Jan 2024 16:33:58 +0100 Subject: [PATCH 073/136] fix(analysis): last_layer can be none --- fd_shifts/analysis/__init__.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 2634045..4a581df 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -107,10 +107,8 @@ def features(self) -> npt.NDArray[Any] | None: return self._features @property - def last_layer(self) -> tuple[npt.NDArray[Any], npt.NDArray[Any]]: - if self._last_layer is not None: - return self._last_layer - raise NotImplementedError("TODO: Load last layer") + def last_layer(self) -> tuple[npt.NDArray[Any], npt.NDArray[Any]] | None: + return self._last_layer @property def vim_score(self): From d9e137c0013dc7606ca551f0440a950127a73d20 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 16 Jan 2024 16:34:44 +0100 Subject: [PATCH 074/136] fix(main): make list elements to dataclass if the type demands it --- fd_shifts/main.py | 32 +++++++++++++++++++++++++------- 1 file changed, 25 insertions(+), 7 deletions(-) diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 2b73c6e..e9027af 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -20,7 +20,7 @@ from rich.pretty import pretty_repr from fd_shifts import analysis, logger -from fd_shifts.configs import Config +from fd_shifts.configs import Config, TestConfig from fd_shifts.experiments.configs import get_experiment_config, list_experiment_configs from fd_shifts.loaders.data_loader import FDShiftsDataLoader from fd_shifts.models import get_model @@ -202,12 +202,15 @@ def __path_to_str(cfg): def _dict_to_dataclass(cfg) -> Config: def __dict_to_dataclass(cfg, cls): + print(f"{cls=}", cls == list) if is_dataclass(cls): fieldtypes = typing.get_type_hints(cls) return cls( **{k: __dict_to_dataclass(v, fieldtypes[k]) for k, v in cfg.items()} ) - if ( + if typing.get_origin(cls) == list: + return [__dict_to_dataclass(v, typing.get_args(cls)[0]) for v in cfg] + if cls == Path or ( isinstance(cls, types.UnionType) and Path in cls.__args__ and cfg is not None @@ -423,9 +426,7 @@ def _list_experiments(): rich.print(exp) -def main(): - setup_logging() - +def get_parser(): parser = ArgumentParser(version=get_version()) parser.add_argument("-f", "--overwrite-config-file", action="store_true") subcommands = parser.add_subcommands(dest="command") @@ -444,15 +445,32 @@ def main(): subparsers[name] = subparser subcommands.add_subcommand(name, subparser) + return parser, subparsers + + +def config_from_parser(parser, args): + config = parser.instantiate_classes(args)[args.command].config + config = omegaconf_resolve(config) + return config + + +def main(): + setup_logging() + + parser, subparsers = get_parser() + args = parser.parse_args() if args.command == "list-experiments": _list_experiments() return - config = parser.instantiate_classes(args)[args.command].config - config = omegaconf_resolve(config) + config = config_from_parser(parser, args) + + rich.print(config) + # TODO: Check if configs are the same + config.test.cf_path.parent.mkdir(parents=True, exist_ok=True) subparsers[args.command].save( args[args.command], config.test.cf_path, From b84159aa409a1558c9823efe3d05dfdd004ff9ee Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 16 Jan 2024 16:40:06 +0100 Subject: [PATCH 075/136] wip: feat(config): add some experiment configs --- fd_shifts/experiments/configs.py | 512 ++++++++++++++++++------------- 1 file changed, 304 insertions(+), 208 deletions(-) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index b00385d..046011c 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -1,11 +1,6 @@ -import importlib -import os -from dataclasses import dataclass from pathlib import Path -from typing import Iterable +from typing import Callable, Literal -import pl_bolts -import torch from omegaconf import SI from fd_shifts.configs import ( @@ -29,228 +24,329 @@ ValSplit, ) -__data_configs = {} - -__data_configs["svhn_384"] = DataConfig( - dataset="svhn", - data_dir=SI("${oc.env:DATASET_ROOT_DIR}/svhn"), - pin_memory=True, - img_size=(384, 384, 3), - num_workers=24, - num_classes=10, - reproduce_confidnet_splits=True, - augmentations={ - "train": { - "to_tensor": None, - "resize": 384, - "normalize": [ - [0.4376821, 0.4437697, 0.47280442], - [0.19803012, 0.20101562, 0.19703614], - ], - }, - "val": { - "to_tensor": None, - "resize": 384, - "normalize": [ - [0.4376821, 0.4437697, 0.47280442], - [0.19803012, 0.20101562, 0.19703614], - ], + +def svhn_data_config( + dataset: Literal["svhn", "svhn_openset"], img_size: int | tuple[int, int] +) -> DataConfig: + augmentations = { + "to_tensor": None, + "resize": img_size, + "normalize": [ + [0.4376821, 0.4437697, 0.47280442], + [0.19803012, 0.20101562, 0.19703614], + ], + } + + if isinstance(img_size, int): + img_size = (img_size, img_size) + + return DataConfig( + dataset="svhn" + + ("_384" if img_size[0] == 384 else "") + + ("_openset" if dataset == "svhn_openset" else ""), + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/svhn"), + pin_memory=True, + img_size=(img_size[0], img_size[1], 3), + num_workers=12, + num_classes=10, + reproduce_confidnet_splits=True, + augmentations={ + "train": augmentations, + "val": augmentations, + "test": augmentations, }, - "test": { - "to_tensor": None, - "resize": 384, - "normalize": [ - [0.4376821, 0.4437697, 0.47280442], - [0.19803012, 0.20101562, 0.19703614], - ], + target_transforms=None, + kwargs=None, + ) + + +def svhn_query_config( + dataset: Literal["svhn", "svhn_openset"], img_size: int | tuple[int, int] +) -> QueryStudiesConfig: + return QueryStudiesConfig( + iid_study="svhn_384", + noise_study=[], + in_class_study=[], + new_class_study=[ + cifar10_data_config(img_size) + ], # , "cifar100_384", "tinyimagenet_384"], + ) + + +def cifar10_data_config(img_size: int | tuple[int, int]) -> DataConfig: + augmentations = { + "to_tensor": None, + "resize": img_size, + "normalize": [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.201]], + } + + if isinstance(img_size, int): + img_size = (img_size, img_size) + + return DataConfig( + dataset="cifar10" + ("_384" if img_size[0] == 384 else ""), + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/cifar10"), + pin_memory=True, + img_size=(img_size[0], img_size[1], 3), + num_workers=12, + num_classes=10, + reproduce_confidnet_splits=True, + augmentations={ + "train": augmentations, + "val": augmentations, + "test": augmentations, }, - }, - target_transforms=None, - kwargs=None, -) + target_transforms=None, + kwargs=None, + ) -def get_data_config(name: str) -> DataConfig: - return __data_configs[name] - - -__experiments = {} - -__experiments["svhn_modeldg_bbvit_lr0.01_bs128_run4_do1_rew10"] = Config( - data=get_data_config("svhn_384"), - trainer=TrainerConfig( - val_every_n_epoch=5, - do_val=True, - batch_size=128, - resume_from_ckpt=False, - benchmark=True, - fast_dev_run=False, - lr_scheduler=LRSchedulerConfig( - { - "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", - "init_args": { - "warmup_epochs": 500, - "max_epochs": 60000, - "warmup_start_lr": 0.0, - "eta_min": 0.0, - "last_epoch": -1, - }, - } +__experiments: dict[str, Config] = {} + + +def svhn_modelvit_bbvit(lr: float, run: int, do: int, **kwargs) -> Config: + return Config( + exp=ExperimentConfig( + group_name="vit", + name=f"svhn_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", ), - optimizer=OptimizerConfig( - { - "class_path": "torch.optim.SGD", - "init_args": { - "lr": 0.01, - "dampening": 0.0, - "momentum": 0.9, - "nesterov": False, - "maximize": False, - "weight_decay": 0.0, + pkgversion="0.0.1+f85760e", + data=svhn_data_config("svhn", 384), + trainer=TrainerConfig( + num_epochs=None, + num_steps=40000, + batch_size=128, + lr_scheduler=LRSchedulerConfig( + init_args={ + "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", + "init_args": { + "warmup_epochs": 500, + "warmup_start_lr": 0, + "eta_min": 0, + "max_epochs": 40000, + }, }, - } - ), - accumulate_grad_batches=1, - resume_from_ckpt_confidnet=False, - num_epochs=None, - num_steps=60000, - num_epochs_backbone=None, - dg_pretrain_epochs=None, - dg_pretrain_steps=20000, - val_split=ValSplit.devries, - lr_scheduler_interval="step", - callbacks={ - "model_checkpoint": None, - "confid_monitor": None, - "learning_rate_monitor": None, - }, - learning_rate_confidnet=None, - learning_rate_confidnet_finetune=None, - ), - exp=ExperimentConfig( - group_name="vit", - name="svhn_modeldg_bbvit_lr0.01_bs128_run4_do1_rew10", - mode=Mode.analysis, - work_dir=Path.cwd(), - fold_dir=SI("exp/${exp.fold}"), - root_dir=Path(p) - if (p := os.getenv("EXPERIMENT_ROOT_DIR")) is not None - else None, - data_root_dir=Path(p) - if (p := os.getenv("DATASET_ROOT_DIR")) is not None - else None, - group_dir=Path("${exp.root_dir}/${exp.group_name}"), - dir=Path("${exp.group_dir}/${exp.name}"), - version_dir=Path("${exp.dir}/version_${exp.version}"), - fold=0, - crossval_n_folds=10, - crossval_ids_path=Path("${exp.dir}/crossval_ids.pickle"), - log_path=Path("log.txt"), - global_seed=0, - output_paths=OutputPathsPerMode( - fit=OutputPathsConfig( - raw_output=Path("${exp.version_dir}/raw_output.npz"), - raw_output_dist=Path("${exp.version_dir}/raw_output_dist.npz"), - external_confids=Path("${exp.version_dir}/external_confids.npz"), - external_confids_dist=Path( - "${exp.version_dir}/external_confids_dist.npz" - ), - input_imgs_plot=Path("${exp.dir}/input_imgs.png"), - encoded_output=None, - attributions_output=None, + class_path="fd_shifts.configs.LRSchedulerConfig", + ), + optimizer=OptimizerConfig( + init_args={ + "class_path": "torch.optim.SGD", + "init_args": { + "lr": 0.01, + "dampening": 0.0, + "momentum": 0.9, + "nesterov": False, + "maximize": False, + "weight_decay": 0.0, + }, + }, + class_path="fd_shifts.configs.OptimizerConfig", ), - test=OutputPathsConfig( - raw_output=Path("${test.dir}/raw_logits.npz"), - raw_output_dist=Path("${test.dir}/raw_logits_dist.npz"), - external_confids=Path("${test.dir}/external_confids.npz"), - external_confids_dist=Path("${test.dir}/external_confids_dist.npz"), - input_imgs_plot=None, - encoded_output=Path("${test.dir}/encoded_output.npz"), - attributions_output=Path("${test.dir}/attributions.csv"), + lr_scheduler_interval="epoch", + ), + model=ModelConfig( + name="vit_model", + network=NetworkConfig( + name="vit", ), + fc_dim=512, + avg_pool=True, + dropout_rate=0, + ), + eval=EvalConfig( + val_tuning=True, + query_studies=svhn_query_config("svhn", 384), ), - version=None, - ), - model=ModelConfig( + ) + + +def svhn_modeldg_bbvit(lr: float, run: int, do: int, rew: int | float) -> Config: + config = svhn_modelvit_bbvit(lr=lr, run=run, do=do) + config.trainer.num_steps = 60000 + config.trainer.lr_scheduler = LRSchedulerConfig( + { + "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", + "init_args": { + "warmup_epochs": 500, + "max_epochs": 60000, + "warmup_start_lr": 0.0, + "eta_min": 0.0, + "last_epoch": -1, + }, + } + ) + config.trainer.optimizer = OptimizerConfig( + { + "class_path": "torch.optim.SGD", + "init_args": { + "lr": lr, + "dampening": 0.0, + "momentum": 0.9, + "nesterov": False, + "maximize": False, + "weight_decay": 0.0, + }, + } + ) + config.trainer.dg_pretrain_epochs = None + config.trainer.dg_pretrain_steps = 20000 + config.trainer.lr_scheduler_interval = "step" + config.exp.name = f"svhn_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}" + config.model = ModelConfig( name="devries_model", network=NetworkConfig( name="vit", - backbone=None, - imagenet_weights_path=None, - load_dg_backbone_path=None, save_dg_backbone_path=Path("${exp.dir}/dg_backbone.ckpt"), ), fc_dim=768, avg_pool=True, dropout_rate=1, - monitor_mcd_samples=50, - test_mcd_samples=50, - confidnet_fc_dim=None, - dg_reward=10, - balanced_sampeling=False, - budget=0.3, - ), - eval=EvalConfig( - tb_hparams=["fold"], - test_conf_scaling=False, - val_tuning=True, - r_star=0.25, - r_delta=0.05, - query_studies=QueryStudiesConfig( - iid_study="svhn_384", - noise_study=[], - in_class_study=[], - new_class_study=["cifar10_384", "cifar100_384", "tinyimagenet_384"], + dg_reward=rew, + ) + config.eval.ext_confid_name = "dg" + config.eval.confidence_measures.test.append("ext") + + return config + + +def cifar10_modelvit_bbvit(lr: float, run: int, do: Literal[0, 1], **kwargs) -> Config: + return Config( + exp=ExperimentConfig( + group_name="vit", + name=f"cifar10_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", ), - performance_metrics=PerfMetricsConfig( - train=["loss", "nll", "accuracy"], - val=["loss", "nll", "accuracy", "brier_score"], - test=["nll", "accuracy", "brier_score"], + data=cifar10_data_config(384), + trainer=TrainerConfig( + num_epochs=None, + num_steps=40000, + batch_size=128, + lr_scheduler=LRSchedulerConfig( + init_args={ + "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", + "init_args": { + "warmup_epochs": 500, + "warmup_start_lr": 0, + "eta_min": 0, + "max_epochs": 40000, + }, + }, + class_path="fd_shifts.configs.LRSchedulerConfig", + ), + optimizer=OptimizerConfig( + init_args={ + "class_path": "torch.optim.SGD", + "init_args": { + "lr": lr, + "dampening": 0.0, + "momentum": 0.9, + "nesterov": False, + "maximize": False, + "weight_decay": 0.0, + }, + }, + class_path="fd_shifts.configs.OptimizerConfig", + ), ), - confid_metrics=ConfidMetricsConfig( - train=[ - "failauc", - "failap_suc", - "failap_err", - "fpr@95tpr", - "e-aurc", - "aurc", - ], - val=["failauc", "failap_suc", "failap_err", "fpr@95tpr", "e-aurc", "aurc"], - test=[ - "failauc", - "failap_suc", - "failap_err", - "mce", - "ece", - "b-aurc", - "e-aurc", - "aurc", - "fpr@95tpr", - ], + model=ModelConfig( + name="vit_model", + network=NetworkConfig( + name="vit", + ), + fc_dim=512, + avg_pool=True, + dropout_rate=do, ), - confidence_measures=ConfidMeasuresConfig( - train=["det_mcp"], val=["det_mcp"], test=["det_mcp", "det_pe", "ext"] + eval=EvalConfig( + query_studies=QueryStudiesConfig( + iid_study="cifar10_384", + noise_study=["corrupt_cifar10_384"], + in_class_study=[], + new_class_study=["cifar100_384", "svhn_384", "tinyimagenet_384"], + ), + ext_confid_name="maha", ), - monitor_plots=["hist_per_confid"], - ext_confid_name="dg", - ), - test=TestConfig( - name="test_results", - dir=Path("${exp.dir}/${test.name}"), - cf_path=Path("${exp.dir}/hydra/config.yaml"), - selection_criterion="latest", - best_ckpt_path=Path("${exp.version_dir}/${test.selection_criterion}.ckpt"), - only_latest_version=True, - devries_repro_ood_split=False, - assim_ood_norm_flag=False, - iid_set_split="devries", - raw_output_path="raw_output.npz", - external_confids_output_path="external_confids.npz", - output_precision=16, - selection_mode="max", - ), -) + ) + + +def cifar10_modeldg_bbvit( + lr: float, run: int, do: Literal[0, 1], rew: int | float +) -> Config: + config = cifar10_modelvit_bbvit(lr=lr, run=run, do=do) + config.trainer.num_steps = 60000 + config.trainer.lr_scheduler = LRSchedulerConfig( + { + "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", + "init_args": { + "warmup_epochs": 500, + "max_epochs": 60000, + "warmup_start_lr": 0.0, + "eta_min": 0.0, + "last_epoch": -1, + }, + } + ) + config.trainer.optimizer = OptimizerConfig( + { + "class_path": "torch.optim.SGD", + "init_args": { + "lr": lr, + "dampening": 0.0, + "momentum": 0.9, + "nesterov": False, + "maximize": False, + "weight_decay": 0.0, + }, + } + ) + config.trainer.dg_pretrain_epochs = None + config.trainer.dg_pretrain_steps = 20000 + config.trainer.lr_scheduler_interval = "step" + config.exp.name = f"cifar10_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}" + config.model = ModelConfig( + name="devries_model", + network=NetworkConfig( + name="vit", + save_dg_backbone_path=Path("${exp.dir}/dg_backbone.ckpt"), + ), + fc_dim=768, + avg_pool=True, + dropout_rate=1, + dg_reward=rew, + ) + config.eval.ext_confid_name = "dg" + config.eval.confidence_measures.test.append("ext") + + return config + + +def register(config_fn: Callable[..., Config], n_runs: int = 5, **kwargs): + for run in range(n_runs): + config = config_fn(**kwargs, run=run) + __experiments[config.exp.name] = config + + +register(svhn_modelvit_bbvit, lr=0.03, do=1, rew=2.2) +register(svhn_modelvit_bbvit, lr=0.01, do=0, rew=2.2) +register(svhn_modelvit_bbvit, lr=0.01, do=1, rew=2.2) +register(svhn_modeldg_bbvit, lr=0.01, do=1, rew=2.2) +register(svhn_modeldg_bbvit, lr=0.01, do=1, rew=3) +register(svhn_modeldg_bbvit, lr=0.01, do=1, rew=6) +register(svhn_modeldg_bbvit, lr=0.01, do=1, rew=10) +register(svhn_modeldg_bbvit, lr=0.03, do=1, rew=2.2) +register(svhn_modeldg_bbvit, lr=0.03, do=1, rew=3) +register(svhn_modeldg_bbvit, lr=0.03, do=1, rew=6) +register(svhn_modeldg_bbvit, lr=0.03, do=1, rew=10) + +register(cifar10_modelvit_bbvit, lr=3e-4, do=0, rew=2.2) +register(cifar10_modelvit_bbvit, lr=0.01, do=1, rew=2.2) +register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=2.2) +register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=2.2) +register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=3) +register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=3) +register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=6) +register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=6) +register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=10) +register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=10) def get_experiment_config(name: str) -> Config: @@ -258,4 +354,4 @@ def get_experiment_config(name: str) -> Config: def list_experiment_configs() -> list[str]: - return list(__experiments.keys()) + return list(sorted(__experiments.keys())) From 10b250def13f423f9efeb13b15d1a6a38e2a9843 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 17 Jan 2024 13:36:48 +0100 Subject: [PATCH 076/136] fix(analysis): don't add empty lists do flat dataset list --- fd_shifts/analysis/__init__.py | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 4a581df..4f8fed1 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -190,13 +190,16 @@ def dataset_name_to_idx(self, dataset_name: str) -> int: flat_test_set_list = [] for _, datasets in self.config.eval.query_studies: - if isinstance(datasets, (list, ListConfig)) and len(datasets) > 0: - if isinstance(datasets[0], configs.DataConfig): - datasets = map(lambda d: d.dataset, datasets) - flat_test_set_list.extend(list(datasets)) + if isinstance(datasets, (list, ListConfig)): + if len(datasets) > 0: + if isinstance(datasets[0], configs.DataConfig): + datasets = map(lambda d: d.dataset, datasets) + flat_test_set_list.extend(list(datasets)) else: flat_test_set_list.append(datasets) + logger.error(f"{flat_test_set_list=}") + dataset_idx = flat_test_set_list.index(dataset_name) if self.config.eval.val_tuning: From fac15256abf76fddb656a7860d40214afd48b533 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 17 Jan 2024 13:37:30 +0100 Subject: [PATCH 077/136] fix(data): query_studies does not support in operator --- fd_shifts/loaders/data_loader.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index 35ddf21..66d21b1 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -250,9 +250,7 @@ def setup(self, stage=None): "Adding tuning data. (preliminary) len: %s", len(self.test_datasets[-1]) ) - if not ( - self.query_studies is not None and "iid_study" not in self.query_studies - ): + if self.query_studies is None or self.query_studies.iid_study is not None: self.test_datasets.append(self.iid_test_set) logging.debug( "Adding internal test dataset. %s", len(self.test_datasets[-1]) From 7003d0e67e5dd78c336a137969e4a00a23a60323 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 4 Jun 2024 17:05:27 +0200 Subject: [PATCH 078/136] feat(config): add svhn and cifar data configs --- fd_shifts/experiments/configs.py | 55 ++++++++++++++++++++++++++------ 1 file changed, 45 insertions(+), 10 deletions(-) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index 046011c..c44d5ef 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -64,12 +64,13 @@ def svhn_query_config( dataset: Literal["svhn", "svhn_openset"], img_size: int | tuple[int, int] ) -> QueryStudiesConfig: return QueryStudiesConfig( - iid_study="svhn_384", + iid_study="svhn", noise_study=[], in_class_study=[], new_class_study=[ - cifar10_data_config(img_size) - ], # , "cifar100_384", "tinyimagenet_384"], + cifar10_data_config(img_size), + cifar100_data_config(img_size), + ], # , "tinyimagenet_384"], ) @@ -101,6 +102,46 @@ def cifar10_data_config(img_size: int | tuple[int, int]) -> DataConfig: ) +def cifar10_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: + return QueryStudiesConfig( + iid_study="cifar10", + noise_study=[], + in_class_study=[], + new_class_study=[ + cifar100_data_config(img_size), + svhn_data_config("svhn", img_size), + ], # , "tinyimagenet_384"], + ) + + +def cifar100_data_config(img_size: int | tuple[int, int]) -> DataConfig: + augmentations = { + "to_tensor": None, + "resize": img_size, + "normalize": [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.201]], + } + + if isinstance(img_size, int): + img_size = (img_size, img_size) + + return DataConfig( + dataset="cifar100" + ("_384" if img_size[0] == 384 else ""), + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/cifar100"), + pin_memory=True, + img_size=(img_size[0], img_size[1], 3), + num_workers=12, + num_classes=100, + reproduce_confidnet_splits=True, + augmentations={ + "train": augmentations, + "val": augmentations, + "test": augmentations, + }, + target_transforms=None, + kwargs=None, + ) + + __experiments: dict[str, Config] = {} @@ -257,13 +298,7 @@ def cifar10_modelvit_bbvit(lr: float, run: int, do: Literal[0, 1], **kwargs) -> dropout_rate=do, ), eval=EvalConfig( - query_studies=QueryStudiesConfig( - iid_study="cifar10_384", - noise_study=["corrupt_cifar10_384"], - in_class_study=[], - new_class_study=["cifar100_384", "svhn_384", "tinyimagenet_384"], - ), - ext_confid_name="maha", + query_studies=cifar10_query_config(384), ), ) From 6a2e8c1c701b1fefc95f58db2d2e4b8a2a119422 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 18 Jan 2024 14:28:27 +0100 Subject: [PATCH 079/136] fix(data): data dir is already a path --- fd_shifts/loaders/data_loader.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index 66d21b1..80aa22a 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -261,9 +261,7 @@ def setup(self, stage=None): logging.debug("Adding external test dataset: %s", ext_set) tmp_external_set = get_dataset( name=ext_set, - root=os.path.join( - self.data_root_dir, self.external_test_configs[ext_set].dataset - ), + root=self.external_test_configs[ext_set].data_dir, train=False, download=True, target_transform=self.target_transforms, From cb6f6ba4f45609d39b692a34d5929f1c48727eb0 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 4 Jun 2024 17:07:27 +0200 Subject: [PATCH 080/136] feat(config): add wilds and breeds data configs --- fd_shifts/experiments/configs.py | 86 ++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index c44d5ef..5443ff5 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -142,6 +142,92 @@ def cifar100_data_config(img_size: int | tuple[int, int]) -> DataConfig: ) +def wilds_animals_data_config( + dataset: Literal["wilds_animals", "wilds_animals_ood_test"] = "wilds_animals", + img_size: int | tuple[int, int] = 448, +) -> DataConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + + augmentations = { + "to_tensor": None, + "resize": img_size, + "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], + } + + return DataConfig( + dataset=dataset, + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/wilds_animals"), + pin_memory=True, + img_size=(img_size[0], img_size[1], 3), + num_workers=8, + num_classes=182, + reproduce_confidnet_splits=False, + augmentations={ + "train": augmentations, + "val": augmentations, + "test": augmentations, + }, + target_transforms=None, + kwargs=None, + ) + + +def wilds_animals_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: + return QueryStudiesConfig( + iid_study="wilds_animals", + noise_study=[], + in_class_study=[wilds_animals_data_config("wilds_animals_ood_test", img_size)], + new_class_study=[], + ) + + +def breeds_data_config( + dataset: Literal["breeds", "breeds_ood_test"] = "breeds", + img_size: int | tuple[int, int] = 224, +) -> DataConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + + return DataConfig( + dataset=dataset, + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/breeds"), + img_size=(img_size[0], img_size[1], 3), + num_classes=13, + augmentations={ + "train": { + "randomresized_crop": img_size, + "hflip": True, + "color_jitter": [0.1, 0.1, 0.1], + "to_tensor": None, + "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], + }, + "val": { + "resize": 256 if img_size[0] == 224 else img_size, + "center_crop": img_size, + "to_tensor": None, + "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], + }, + "test": { + "resize": 256 if img_size[0] == 224 else img_size, + "center_crop": img_size, + "to_tensor": None, + "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], + }, + }, + kwargs={"info_dir_path": "loaders/breeds_hierarchies"}, + ) + + +def breeds_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: + return QueryStudiesConfig( + iid_study="breeds", + noise_study=[], + in_class_study=[breeds_data_config("breeds_ood_test", img_size)], + new_class_study=[], + ) + + __experiments: dict[str, Config] = {} From 1cdfd4f7a78c3d9bb15066053fafc7af9f5c563f Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 18 Jan 2024 14:30:04 +0100 Subject: [PATCH 081/136] fix(main): also turn paths in lists into str for omegaconf --- fd_shifts/main.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fd_shifts/main.py b/fd_shifts/main.py index e9027af..ddc69a3 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -193,6 +193,8 @@ def __path_to_str(cfg): return cfg.__class__( **{k: __path_to_str(v) for k, v in cfg.__dict__.items()} ) + if isinstance(cfg, list): + return [__path_to_str(v) for v in cfg] if isinstance(cfg, Path): return str(cfg) return cfg @@ -202,7 +204,6 @@ def __path_to_str(cfg): def _dict_to_dataclass(cfg) -> Config: def __dict_to_dataclass(cfg, cls): - print(f"{cls=}", cls == list) if is_dataclass(cls): fieldtypes = typing.get_type_hints(cls) return cls( From d00a77cc5c11f10d194862712406468abfea9f19 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 18 Jan 2024 14:30:55 +0100 Subject: [PATCH 082/136] feat(config): some default values for dataconfig --- fd_shifts/configs/__init__.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index b850cdc..814a6a1 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -530,11 +530,11 @@ class DataConfig(_IterableMixin): dataset: str | None = None data_dir: Path | None = None - pin_memory: bool | None = None + pin_memory: bool = True img_size: tuple[int, int, int] | None = None - num_workers: int | None = None + num_workers: int = 12 num_classes: int | None = None - reproduce_confidnet_splits: bool | None = None + reproduce_confidnet_splits: bool = False augmentations: dict[str, dict[str, Any]] | None = None target_transforms: Optional[Any] = None kwargs: Optional[dict[Any, Any]] = None From 8bed0c891d9210fff650ad1d824151732365470e Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 31 Jan 2024 17:27:08 +0100 Subject: [PATCH 083/136] test: skip broken tests and try to fix working tests in ci --- .gitlab-ci.yml | 4 ++++ fd_shifts/tests/test_config.py | 2 ++ fd_shifts/tests/test_experiment_integration.py | 1 + fd_shifts/tests/test_register_model.py | 1 + fd_shifts/tests/test_reproducible.py | 3 +++ 5 files changed, 11 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index a95c126..0fd2404 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -12,10 +12,14 @@ image: "python:3.10" test:package: stage: test + tags: + - fd-shifts before_script: - python --version + - pip install -U pip wheel - pip install .[dev] script: + - python -c 'import numpy as np; print(np.version.full_version)' - python -m pytest -W ignore -m "not slow" test:notebooks: diff --git a/fd_shifts/tests/test_config.py b/fd_shifts/tests/test_config.py index 2368879..4958c6d 100644 --- a/fd_shifts/tests/test_config.py +++ b/fd_shifts/tests/test_config.py @@ -30,6 +30,7 @@ def to_dict(obj): return json.loads(json.dumps(obj, default=lambda o: getattr(o, "__dict__", str(o)))) +@pytest.mark.skip("TODO: not compatible with new configs yet") def test_api_and_main_same(mock_env_if_missing) -> None: study = "deepgamblers" data = "svhn" @@ -65,6 +66,7 @@ def test_api_and_main_same(mock_env_if_missing) -> None: ms_experiments = {str(exp.to_path()): exp for exp in get_ms_experiments()} +@pytest.mark.skip("TODO: not compatible with new configs yet") @pytest.mark.slow @pytest.mark.parametrize( "exp_name", diff --git a/fd_shifts/tests/test_experiment_integration.py b/fd_shifts/tests/test_experiment_integration.py index 774b8d6..6f394af 100644 --- a/fd_shifts/tests/test_experiment_integration.py +++ b/fd_shifts/tests/test_experiment_integration.py @@ -23,6 +23,7 @@ def _update_overrides_fast(overrides: dict[str, Any]) -> dict[str, Any]: return overrides +@pytest.mark.skip("TODO: not compatible with new configs yet") @pytest.mark.slow @pytest.mark.parametrize( "exp_name", diff --git a/fd_shifts/tests/test_register_model.py b/fd_shifts/tests/test_register_model.py index 7fb6d89..dfc7871 100644 --- a/fd_shifts/tests/test_register_model.py +++ b/fd_shifts/tests/test_register_model.py @@ -14,6 +14,7 @@ class MyModel(pl.LightningModule): pass +@pytest.mark.skip("TODO: does nothing, remove or improve") def test_register_model(mock_env_if_missing): configs.init() diff --git a/fd_shifts/tests/test_reproducible.py b/fd_shifts/tests/test_reproducible.py index 0ee50ac..85235bc 100644 --- a/fd_shifts/tests/test_reproducible.py +++ b/fd_shifts/tests/test_reproducible.py @@ -25,6 +25,9 @@ def _update_overrides_fast(overrides: dict[str, Any]) -> dict[str, Any]: return overrides +@pytest.mark.skip( + "TODO: does nothing, remove or improve, also not compatible with new configs yet" +) @pytest.mark.slow def test_small_heuristic_run(mock_env_if_missing): # TODO: Test multiple with fixture From d8aaae83702700d51b2d103de7956af7e65ed018 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 13 Feb 2024 14:32:36 +0100 Subject: [PATCH 084/136] feat: add new configs --- fd_shifts/experiments/configs.py | 1222 ++++++++++++++++++++++++------ fd_shifts/main.py | 44 +- 2 files changed, 1017 insertions(+), 249 deletions(-) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index 5443ff5..ec2d89c 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -1,36 +1,26 @@ +from copy import deepcopy from pathlib import Path from typing import Callable, Literal from omegaconf import SI from fd_shifts.configs import ( - ConfidMeasuresConfig, - ConfidMetricsConfig, Config, DataConfig, EvalConfig, ExperimentConfig, LRSchedulerConfig, - Mode, ModelConfig, - NetworkConfig, OptimizerConfig, - OutputPathsConfig, - OutputPathsPerMode, - PerfMetricsConfig, QueryStudiesConfig, - TestConfig, - TrainerConfig, - ValSplit, ) def svhn_data_config( - dataset: Literal["svhn", "svhn_openset"], img_size: int | tuple[int, int] + dataset: Literal["svhn", "svhn_openset"], img_size: int | tuple[int, int] = 32 ) -> DataConfig: augmentations = { "to_tensor": None, - "resize": img_size, "normalize": [ [0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614], @@ -40,10 +30,11 @@ def svhn_data_config( if isinstance(img_size, int): img_size = (img_size, img_size) + if img_size[0] != 32: + augmentations["resize"] = img_size[0] + return DataConfig( - dataset="svhn" - + ("_384" if img_size[0] == 384 else "") - + ("_openset" if dataset == "svhn_openset" else ""), + dataset="svhn" + ("_openset" if dataset == "svhn_openset" else ""), data_dir=SI("${oc.env:DATASET_ROOT_DIR}/svhn"), pin_memory=True, img_size=(img_size[0], img_size[1], 3), @@ -63,37 +54,58 @@ def svhn_data_config( def svhn_query_config( dataset: Literal["svhn", "svhn_openset"], img_size: int | tuple[int, int] ) -> QueryStudiesConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + return QueryStudiesConfig( - iid_study="svhn", + iid_study="svhn" + ("_384" if img_size[0] == 384 else ""), noise_study=[], in_class_study=[], new_class_study=[ - cifar10_data_config(img_size), - cifar100_data_config(img_size), - ], # , "tinyimagenet_384"], + cifar10_data_config(img_size=img_size), + cifar100_data_config(img_size=img_size), + tinyimagenet_data_config(img_size), + ], ) -def cifar10_data_config(img_size: int | tuple[int, int]) -> DataConfig: +def cifar10_data_config( + dataset: Literal["cifar10", "corrupt_cifar10"] = "cifar10", + img_size: int | tuple[int, int] = 32, +) -> DataConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + augmentations = { "to_tensor": None, - "resize": img_size, "normalize": [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.201]], } + if img_size[0] != 32: + augmentations["resize"] = img_size[0] + + train_augmentations = deepcopy(augmentations) + + if img_size[0] != 384: + train_augmentations["random_crop"] = [32, 4] + train_augmentations["hflip"] = True + if dataset == "corrupt_cifar10": + train_augmentations["rotate"] = 15 + else: + train_augmentations["cutout"] = 16 if isinstance(img_size, int): img_size = (img_size, img_size) return DataConfig( - dataset="cifar10" + ("_384" if img_size[0] == 384 else ""), - data_dir=SI("${oc.env:DATASET_ROOT_DIR}/cifar10"), + dataset=dataset, + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/" + dataset), pin_memory=True, img_size=(img_size[0], img_size[1], 3), num_workers=12, num_classes=10, reproduce_confidnet_splits=True, augmentations={ - "train": augmentations, + "train": train_augmentations, "val": augmentations, "test": augmentations, }, @@ -103,37 +115,57 @@ def cifar10_data_config(img_size: int | tuple[int, int]) -> DataConfig: def cifar10_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + return QueryStudiesConfig( - iid_study="cifar10", - noise_study=[], + iid_study="cifar10" + ("_384" if img_size[0] == 384 else ""), + noise_study=[ + cifar10_data_config("corrupt_cifar10", img_size), + ], in_class_study=[], new_class_study=[ - cifar100_data_config(img_size), + cifar100_data_config(img_size=img_size), svhn_data_config("svhn", img_size), - ], # , "tinyimagenet_384"], + tinyimagenet_data_config(img_size), + ], ) -def cifar100_data_config(img_size: int | tuple[int, int]) -> DataConfig: +def cifar100_data_config( + dataset: Literal["cifar100", "corrupt_cifar100"] = "cifar100", + img_size: int | tuple[int, int] = 32, +) -> DataConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + augmentations = { "to_tensor": None, - "resize": img_size, "normalize": [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.201]], } + if img_size[0] != 32: + augmentations["resize"] = img_size[0] - if isinstance(img_size, int): - img_size = (img_size, img_size) + train_augmentations = deepcopy(augmentations) + + if img_size[0] != 384: + train_augmentations["random_crop"] = [32, 4] + train_augmentations["hflip"] = True + if dataset == "corrupt_cifar100": + train_augmentations["rotate"] = 15 + else: + train_augmentations["cutout"] = 16 return DataConfig( - dataset="cifar100" + ("_384" if img_size[0] == 384 else ""), - data_dir=SI("${oc.env:DATASET_ROOT_DIR}/cifar100"), + dataset=dataset, + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/" + dataset), pin_memory=True, img_size=(img_size[0], img_size[1], 3), num_workers=12, num_classes=100, reproduce_confidnet_splits=True, augmentations={ - "train": augmentations, + "train": train_augmentations, "val": augmentations, "test": augmentations, }, @@ -142,6 +174,24 @@ def cifar100_data_config(img_size: int | tuple[int, int]) -> DataConfig: ) +def cifar100_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + + return QueryStudiesConfig( + iid_study="cifar100" + ("_384" if img_size[0] == 384 else ""), + noise_study=[ + cifar100_data_config("corrupt_cifar100", img_size), + ], + in_class_study=[], + new_class_study=[ + cifar10_data_config(img_size=img_size), + svhn_data_config("svhn", img_size), + tinyimagenet_data_config(img_size), + ], + ) + + def wilds_animals_data_config( dataset: Literal["wilds_animals", "wilds_animals_ood_test"] = "wilds_animals", img_size: int | tuple[int, int] = 448, @@ -151,10 +201,13 @@ def wilds_animals_data_config( augmentations = { "to_tensor": None, - "resize": img_size, + "resize": img_size[0] if img_size[0] == 384 else img_size, "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], } + if img_size[0] == 384: + augmentations["center_crop"] = 384 + return DataConfig( dataset=dataset, data_dir=SI("${oc.env:DATASET_ROOT_DIR}/wilds_animals"), @@ -173,15 +226,72 @@ def wilds_animals_data_config( ) -def wilds_animals_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: +def wilds_animals_query_config( + img_size: int | tuple[int, int] = 448 +) -> QueryStudiesConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + return QueryStudiesConfig( - iid_study="wilds_animals", + iid_study="wilds_animals" + ("_384" if img_size[0] == 384 else ""), noise_study=[], in_class_study=[wilds_animals_data_config("wilds_animals_ood_test", img_size)], new_class_study=[], ) +def wilds_camelyon_data_config( + dataset: Literal["wilds_camelyon", "wilds_camelyon_ood_test"] = "wilds_camelyon", + img_size: int | tuple[int, int] = 96, +) -> DataConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + + augmentations = { + "to_tensor": None, + "normalize": [ + [0.485, 0.456, 0.406], + [0.229, 0.384 if img_size[0] == 384 else 0.224, 0.225], + ], + } + + if img_size[0] != 96: + augmentations["resize"] = img_size[0] + + return DataConfig( + dataset=dataset, + data_dir=SI("${oc.env:DATASET_ROOT_DIR}/wilds_camelyon"), + pin_memory=True, + img_size=(img_size[0], img_size[1], 3), + num_workers=8, + num_classes=2, + reproduce_confidnet_splits=False, + augmentations={ + "train": augmentations, + "val": augmentations, + "test": augmentations, + }, + target_transforms=None, + kwargs=None, + ) + + +def wilds_camelyon_query_config( + img_size: int | tuple[int, int] = 96 +) -> QueryStudiesConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + + return QueryStudiesConfig( + iid_study="wilds_camelyon" + ("_384" if img_size[0] == 384 else ""), + noise_study=[], + in_class_study=[ + wilds_camelyon_data_config("wilds_camelyon_ood_test", img_size) + ], + new_class_study=[], + ) + + def breeds_data_config( dataset: Literal["breeds", "breeds_ood_test"] = "breeds", img_size: int | tuple[int, int] = 224, @@ -189,285 +299,901 @@ def breeds_data_config( if isinstance(img_size, int): img_size = (img_size, img_size) + augmentations = { + "resize": 256 if img_size[0] == 224 else img_size[0], + "center_crop": img_size[0], + "to_tensor": None, + "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], + } + + train_augmentations = deepcopy(augmentations) + + if img_size[0] != 384: + train_augmentations["randomresized_crop"] = img_size[0] + train_augmentations["hflip"] = True + train_augmentations["color_jitter"] = [0.1, 0.1, 0.1] + del train_augmentations["resize"] + del train_augmentations["center_crop"] + return DataConfig( dataset=dataset, data_dir=SI("${oc.env:DATASET_ROOT_DIR}/breeds"), img_size=(img_size[0], img_size[1], 3), num_classes=13, augmentations={ - "train": { - "randomresized_crop": img_size, - "hflip": True, - "color_jitter": [0.1, 0.1, 0.1], - "to_tensor": None, - "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], - }, - "val": { - "resize": 256 if img_size[0] == 224 else img_size, - "center_crop": img_size, - "to_tensor": None, - "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], - }, - "test": { - "resize": 256 if img_size[0] == 224 else img_size, - "center_crop": img_size, - "to_tensor": None, - "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], - }, + "train": train_augmentations, + "val": augmentations, + "test": augmentations, }, kwargs={"info_dir_path": "loaders/breeds_hierarchies"}, ) -def breeds_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: +def breeds_query_config(img_size: int | tuple[int, int] = 224) -> QueryStudiesConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + return QueryStudiesConfig( - iid_study="breeds", + iid_study="breeds" + ("_384" if img_size[0] == 384 else ""), noise_study=[], in_class_study=[breeds_data_config("breeds_ood_test", img_size)], new_class_study=[], ) -__experiments: dict[str, Config] = {} +def tinyimagenet_data_config(img_size: int | tuple[int, int] = 64) -> DataConfig: + if isinstance(img_size, int): + img_size = (img_size, img_size) + augmentations = { + "to_tensor": None, + "normalize": [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]], + } -def svhn_modelvit_bbvit(lr: float, run: int, do: int, **kwargs) -> Config: - return Config( - exp=ExperimentConfig( - group_name="vit", - name=f"svhn_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", - ), - pkgversion="0.0.1+f85760e", - data=svhn_data_config("svhn", 384), - trainer=TrainerConfig( - num_epochs=None, - num_steps=40000, - batch_size=128, - lr_scheduler=LRSchedulerConfig( - init_args={ - "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", - "init_args": { - "warmup_epochs": 500, - "warmup_start_lr": 0, - "eta_min": 0, - "max_epochs": 40000, - }, - }, - class_path="fd_shifts.configs.LRSchedulerConfig", - ), - optimizer=OptimizerConfig( - init_args={ - "class_path": "torch.optim.SGD", - "init_args": { - "lr": 0.01, - "dampening": 0.0, - "momentum": 0.9, - "nesterov": False, - "maximize": False, - "weight_decay": 0.0, - }, - }, - class_path="fd_shifts.configs.OptimizerConfig", - ), - lr_scheduler_interval="epoch", - ), - model=ModelConfig( - name="vit_model", - network=NetworkConfig( - name="vit", - ), - fc_dim=512, - avg_pool=True, - dropout_rate=0, - ), - eval=EvalConfig( - val_tuning=True, - query_studies=svhn_query_config("svhn", 384), + if img_size[0] != 64: + augmentations["resize"] = img_size + + return DataConfig( + dataset="tinyimagenet" + ("" if img_size[0] == 384 else "_resize"), + data_dir=SI( + "${oc.env:DATASET_ROOT_DIR}/" + + "tinyimagenet" + + ("" if img_size[0] == 384 else "_resize") ), + img_size=(img_size[0], img_size[1], 3), + num_classes=200, + augmentations={ + "train": augmentations, + "val": augmentations, + "test": augmentations, + }, + kwargs={}, ) -def svhn_modeldg_bbvit(lr: float, run: int, do: int, rew: int | float) -> Config: - config = svhn_modelvit_bbvit(lr=lr, run=run, do=do) - config.trainer.num_steps = 60000 +__dataset_configs: dict[str, DataConfig] = { + "svhn": svhn_data_config("svhn"), + "svhn_384": svhn_data_config("svhn", 384), + "cifar10": cifar10_data_config(), + "cifar10_384": cifar10_data_config(img_size=384), + "cifar100": cifar100_data_config(), + "cifar100_384": cifar100_data_config(img_size=384), + "corrupt_cifar10": cifar10_data_config(dataset="corrupt_cifar10"), + "corrupt_cifar10_384": cifar10_data_config(dataset="corrupt_cifar10", img_size=384), + "corrupt_cifar100": cifar100_data_config(dataset="corrupt_cifar100"), + "corrupt_cifar100_384": cifar100_data_config( + dataset="corrupt_cifar100", img_size=384 + ), + "wilds_animals_ood_test": wilds_animals_data_config("wilds_animals_ood_test"), + "wilds_animals_ood_test_384": wilds_animals_data_config( + "wilds_animals_ood_test", 384 + ), + "wilds_camelyon_ood_test": wilds_camelyon_data_config("wilds_camelyon_ood_test"), + "wilds_camelyon_ood_test_384": wilds_camelyon_data_config( + "wilds_camelyon_ood_test", 384 + ), + "breeds_ood_test": breeds_data_config("breeds_ood_test"), + "breeds_ood_test_384": breeds_data_config("breeds_ood_test", 384), + "tinyimagenet_384": tinyimagenet_data_config(384), + "tinyimagenet_resize": tinyimagenet_data_config(32), +} + + +def get_dataset_config(name: str) -> DataConfig: + return __dataset_configs[name] + + +__experiments: dict[str, Config] = {} + + +def cnn(group_name: str, name: str): + config = Config(exp=ExperimentConfig(group_name=group_name, name=name)) + config.trainer.batch_size = 128 config.trainer.lr_scheduler = LRSchedulerConfig( - { - "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", - "init_args": { - "warmup_epochs": 500, - "max_epochs": 60000, - "warmup_start_lr": 0.0, - "eta_min": 0.0, - "last_epoch": -1, - }, - } + init_args={ + "class_path": "torch.optim.lr_scheduler.CosineAnnealingLR", + "init_args": {}, + }, + class_path="fd_shifts.configs.LRSchedulerConfig", ) config.trainer.optimizer = OptimizerConfig( - { + init_args={ "class_path": "torch.optim.SGD", "init_args": { - "lr": lr, "dampening": 0.0, "momentum": 0.9, "nesterov": False, "maximize": False, "weight_decay": 0.0, }, - } - ) - config.trainer.dg_pretrain_epochs = None - config.trainer.dg_pretrain_steps = 20000 - config.trainer.lr_scheduler_interval = "step" - config.exp.name = f"svhn_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}" - config.model = ModelConfig( - name="devries_model", - network=NetworkConfig( - name="vit", - save_dg_backbone_path=Path("${exp.dir}/dg_backbone.ckpt"), - ), - fc_dim=768, - avg_pool=True, - dropout_rate=1, - dg_reward=rew, + }, + class_path="fd_shifts.configs.OptimizerConfig", ) + config.model.confidnet_fc_dim = 400 + return config + + +def cnn_animals(name: str): + config = cnn("animals_paper_sweep", name=name) + config.data = wilds_animals_data_config() + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.001 + config.model.fc_dim = 2048 + config.model.avg_pool = True + config.eval.query_studies = wilds_animals_query_config() + return config + + +def cnn_animals_modelconfidnet(run: int, do: int, **kwargs): + config = cnn_animals(name=f"confidnet_bbresnet50_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 20 + config.trainer.num_epochs_backbone = 12 + config.trainer.learning_rate_confidnet = 0.0001 + config.trainer.learning_rate_confidnet_finetune = 1e-06 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 12 + config.trainer.callbacks["training_stages"] = {} + config.trainer.callbacks["training_stages"]["milestones"] = [12, 17] + config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True + config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.model.name = "confidnet_model" + config.model.dropout_rate = do + config.model.network.name = "confidnet_and_enc" + config.model.network.backbone = "resnet50" + config.eval.ext_confid_name = "tcp" + return config + + +def cnn_animals_modeldevries(run: int, do: int, **kwargs): + config = cnn_animals(name=f"devries_bbresnet50_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 12 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 12 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.model.name = "devries_model" + config.model.dg_reward = -1 + config.model.dropout_rate = do + config.model.network.name = "devries_and_enc" + config.model.network.backbone = "resnet50" + config.eval.ext_confid_name = "devries" + return config + + +def cnn_animals_modeldg(run: int, do: int, rew: float): + config = cnn_animals(name=f"dg_bbresnet50_do{do}_run{run + 1}_rew{rew}") + config.trainer.num_epochs = 18 + config.trainer.dg_pretrain_epochs = 6 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 18 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.model.name = "devries_model" + config.model.dropout_rate = do + config.model.dg_reward = rew + config.model.network.name = "resnet50" config.eval.ext_confid_name = "dg" - config.eval.confidence_measures.test.append("ext") + return config + +def cnn_camelyon(name: str): + config = cnn("camelyon_paper_sweep", name=name) + config.data = wilds_camelyon_data_config() + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.01 + config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.01 + config.model.fc_dim = 2048 + config.model.avg_pool = True + config.eval.query_studies = wilds_camelyon_query_config() return config -def cifar10_modelvit_bbvit(lr: float, run: int, do: Literal[0, 1], **kwargs) -> Config: - return Config( - exp=ExperimentConfig( - group_name="vit", - name=f"cifar10_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", - ), - data=cifar10_data_config(384), - trainer=TrainerConfig( - num_epochs=None, - num_steps=40000, - batch_size=128, - lr_scheduler=LRSchedulerConfig( - init_args={ - "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", - "init_args": { - "warmup_epochs": 500, - "warmup_start_lr": 0, - "eta_min": 0, - "max_epochs": 40000, - }, - }, - class_path="fd_shifts.configs.LRSchedulerConfig", - ), - optimizer=OptimizerConfig( - init_args={ - "class_path": "torch.optim.SGD", - "init_args": { - "lr": lr, - "dampening": 0.0, - "momentum": 0.9, - "nesterov": False, - "maximize": False, - "weight_decay": 0.0, - }, - }, - class_path="fd_shifts.configs.OptimizerConfig", - ), - ), - model=ModelConfig( - name="vit_model", - network=NetworkConfig( - name="vit", - ), - fc_dim=512, - avg_pool=True, - dropout_rate=do, - ), - eval=EvalConfig( - query_studies=cifar10_query_config(384), - ), - ) +def cnn_camelyon_modelconfidnet(run: int, do: int, **kwargs): + config = cnn_camelyon(f"confidnet_bbresnet50_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 9 + config.trainer.num_epochs_backbone = 5 + config.trainer.learning_rate_confidnet = 0.0001 + config.trainer.learning_rate_confidnet_finetune = 1e-06 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 5 + config.trainer.callbacks["training_stages"] = {} + config.trainer.callbacks["training_stages"]["milestones"] = [5, 8] + config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True + config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.model.name = "confidnet_model" + config.model.dropout_rate = do + config.model.network.name = "confidnet_and_enc" + config.model.network.backbone = "resnet50" + config.eval.ext_confid_name = "tcp" + return config -def cifar10_modeldg_bbvit( - lr: float, run: int, do: Literal[0, 1], rew: int | float -) -> Config: - config = cifar10_modelvit_bbvit(lr=lr, run=run, do=do) - config.trainer.num_steps = 60000 +def cnn_camelyon_modeldevries(run: int, do: int, **kwargs): + config = cnn_camelyon(f"devries_bbresnet50_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 5 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 5 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.model.name = "devries_model" + config.model.dropout_rate = do + config.model.dg_reward = -1 + config.model.network.name = "devries_and_enc" + config.model.network.backbone = "resnet50" + config.eval.ext_confid_name = "devries" + return config + + +def cnn_camelyon_modeldg(run: int, do: int, rew: float): + config = cnn_camelyon(f"dg_bbresnet50_do{do}_run{run + 1}_rew{rew}") + config.trainer.num_epochs = 8 + config.trainer.dg_pretrain_epochs = 3 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 8 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.model.name = "devries_model" + config.model.dg_reward = rew + config.model.dropout_rate = do + config.model.network.name = "resnet50" + config.eval.ext_confid_name = "dg" + return config + + +def cnn_svhn(name: str): + config = cnn("svhn_paper_sweep", name=name) + config.data = svhn_data_config("svhn", img_size=32) + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.01 + config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.0005 + config.model.fc_dim = 512 + config.model.avg_pool = True + config.eval.query_studies = svhn_query_config("svhn", img_size=32) + return config + + +def cnn_svhn_modelconfidnet(run: int, do: int, **kwargs): + config = cnn_svhn(f"confidnet_bbsvhn_small_conv_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 320 + config.trainer.num_epochs_backbone = 100 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 100 + config.trainer.learning_rate_confidnet = 0.0001 + config.trainer.learning_rate_confidnet_finetune = 1e-06 + config.trainer.callbacks["training_stages"] = {} + config.trainer.callbacks["training_stages"]["milestones"] = [100, 300] + config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True + config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.model.name = "confidnet_model" + config.model.dropout_rate = do + config.model.network.name = "confidnet_and_enc" + config.model.network.backbone = "svhn_small_conv" + config.eval.ext_confid_name = "tcp" + return config + + +def cnn_svhn_modeldevries(run: int, do: int, **kwargs): + config = cnn_svhn(f"devries_bbsvhn_small_conv_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 100 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 100 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.model.name = "devries_model" + config.model.dropout_rate = do + config.model.dg_reward = -1 + config.model.network.name = "devries_and_enc" + config.model.network.backbone = "svhn_small_conv" + config.eval.ext_confid_name = "devries" + return config + + +def cnn_svhn_modeldg(run: int, do: int, rew: float): + config = cnn_svhn(f"dg_bbsvhn_small_conv_do{do}_run{run + 1}_rew{rew}") + config.trainer.num_epochs = 150 + config.trainer.dg_pretrain_epochs = 50 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 150 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.model.name = "devries_model" + config.model.dg_reward = rew + config.model.dropout_rate = do + config.model.network.name = "svhn_small_conv" + config.eval.ext_confid_name = "dg" + return config + + +def cnn_cifar10(name: str): + config = cnn("cifar10_paper_sweep", name=name) + config.data = cifar10_data_config(img_size=32) + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.1 + config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.0005 + config.model.fc_dim = 512 + config.eval.query_studies = cifar10_query_config(img_size=32) + return config + + +def cnn_cifar10_modelconfidnet(run: int, do: int, **kwargs): + config = cnn_cifar10(f"confidnet_bbvgg13_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 470 + config.trainer.num_epochs_backbone = 250 + config.trainer.learning_rate_confidnet = 0.0001 + config.trainer.learning_rate_confidnet_finetune = 1e-06 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 + config.trainer.callbacks["training_stages"] = {} + config.trainer.callbacks["training_stages"]["milestones"] = [250, 450] + config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True + config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.model.name = "confidnet_model" + config.model.dropout_rate = do + config.model.avg_pool = do == 0 + config.model.network.name = "confidnet_and_enc" + config.model.network.backbone = "vgg13" + config.eval.ext_confid_name = "tcp" + return config + + +def cnn_cifar10_modeldevries(run: int, do: int, **kwargs): + config = cnn_cifar10(f"devries_bbvgg13_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 250 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.model.name = "devries_model" + config.model.dropout_rate = do + config.model.avg_pool = do == 0 + config.model.dg_reward = -1 + config.model.network.name = "devries_and_enc" + config.model.network.backbone = "vgg13" + config.eval.ext_confid_name = "devries" + return config + + +def cnn_cifar10_modeldg(run: int, do: int, rew: float): + config = cnn_cifar10(f"dg_bbvgg13_do{do}_run{run + 1}_rew{rew}") + config.trainer.num_epochs = 300 + config.trainer.dg_pretrain_epochs = 100 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.model.name = "devries_model" + config.model.dg_reward = rew + config.model.dropout_rate = do + config.model.avg_pool = do == 0 + config.model.network.name = "vgg13" + config.eval.ext_confid_name = "dg" + return config + + +def cnn_cifar100(name: str): + config = cnn("cifar100_paper_sweep", name=name) + config.data = cifar100_data_config(img_size=32) + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.1 + config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.0005 + config.model.fc_dim = 512 + config.eval.query_studies = cifar100_query_config(img_size=32) + return config + + +def cnn_cifar100_modelconfidnet(run: int, do: int, **kwargs): + config = cnn_cifar100(f"confidnet_bbvgg13_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 470 + config.trainer.num_epochs_backbone = 250 + config.trainer.learning_rate_confidnet = 0.0001 + config.trainer.learning_rate_confidnet_finetune = 1e-06 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 + config.trainer.callbacks["training_stages"] = {} + config.trainer.callbacks["training_stages"]["milestones"] = [250, 450] + config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True + config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.model.name = "confidnet_model" + config.model.avg_pool = do == 0 + config.model.dropout_rate = do + config.model.network.name = "confidnet_and_enc" + config.model.network.backbone = "vgg13" + config.eval.ext_confid_name = "tcp" + return config + + +def cnn_cifar100_modeldevries(run: int, do: int, **kwargs): + config = cnn_cifar100(f"devries_bbvgg13_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 250 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.model.name = "devries_model" + config.model.dropout_rate = do + config.model.dg_reward = -1 + config.model.avg_pool = do == 0 + config.model.network.name = "devries_and_enc" + config.model.network.backbone = "vgg13" + config.eval.ext_confid_name = "devries" + return config + + +def cnn_cifar100_modeldg(run: int, do: int, rew: float): + config = cnn_cifar100(f"dg_bbvgg13_do{do}_run{run + 1}_rew{rew}") + config.trainer.num_epochs = 300 + config.trainer.dg_pretrain_epochs = 100 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.model.name = "devries_model" + config.model.dg_reward = rew + config.model.dropout_rate = do + config.model.avg_pool = do == 0 + config.model.network.name = "vgg13" + config.eval.ext_confid_name = "dg" + return config + + +def cnn_breeds(name: str): + config = cnn("breeds_paper_sweep", name=name) + config.data = breeds_data_config() + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.1 + config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.0001 + config.model.fc_dim = 2048 + config.model.avg_pool = True + config.eval.query_studies = breeds_query_config() + return config + + +def cnn_breeds_modelconfidnet(run: int, do: int, **kwargs): + config = cnn_breeds(f"confidnet_bbresnet50_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 520 + config.trainer.num_epochs_backbone = 300 + config.trainer.learning_rate_confidnet = 0.0001 + config.trainer.learning_rate_confidnet_finetune = 1e-06 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 + config.trainer.callbacks["training_stages"] = {} + config.trainer.callbacks["training_stages"]["milestones"] = [300, 500] + config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True + config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.model.name = "confidnet_model" + config.model.dropout_rate = do + config.model.network.name = "confidnet_and_enc" + config.model.network.backbone = "resnet50" + config.eval.ext_confid_name = "tcp" + return config + + +def cnn_breeds_modeldevries(run: int, do: int, **kwargs): + config = cnn_breeds(f"devries_bbresnet50_do{do}_run{run + 1}_rew2.2") + config.trainer.num_epochs = 300 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.model.name = "devries_model" + config.model.dropout_rate = do + config.model.dg_reward = -1 + config.model.network.name = "devries_and_enc" + config.model.network.backbone = "resnet50" + config.eval.ext_confid_name = "devries" + return config + + +def cnn_breeds_modeldg(run: int, do: int, rew: float): + config = cnn_breeds(f"dg_bbresnet50_do{do}_run{run + 1}_rew{rew}") + config.trainer.num_epochs = 350 + config.trainer.dg_pretrain_epochs = 50 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 350 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.model.name = "devries_model" + config.model.dg_reward = rew + config.model.dropout_rate = do + config.model.network.name = "resnet50" + config.eval.ext_confid_name = "dg" + return config + + +def vit(name: str): + config = Config(exp=ExperimentConfig(group_name="vit", name=name)) + config.trainer.num_epochs = None + config.trainer.num_steps = 40000 + config.trainer.lr_scheduler_interval = "epoch" config.trainer.lr_scheduler = LRSchedulerConfig( - { + init_args={ "class_path": "pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR", "init_args": { "warmup_epochs": 500, - "max_epochs": 60000, - "warmup_start_lr": 0.0, - "eta_min": 0.0, - "last_epoch": -1, + "warmup_start_lr": 0, + "eta_min": 0, + "max_epochs": 40000, }, - } + }, + class_path="fd_shifts.configs.LRSchedulerConfig", ) config.trainer.optimizer = OptimizerConfig( - { + init_args={ "class_path": "torch.optim.SGD", "init_args": { - "lr": lr, "dampening": 0.0, "momentum": 0.9, "nesterov": False, "maximize": False, "weight_decay": 0.0, }, - } + }, + class_path="fd_shifts.configs.OptimizerConfig", ) + config.trainer.batch_size = 128 + config.model.name = "vit_model" + config.model.network.name = "vit" + config.model.fc_dim = 512 + config.model.avg_pool = True + config.eval.ext_confid_name = "maha" + return config + + +def vit_modeldg(name: str): + config = vit(name) + config.model.name = "devries_model" + config.trainer.lr_scheduler_interval = "step" + config.model.fc_dim = 768 config.trainer.dg_pretrain_epochs = None + config.eval.ext_confid_name = "dg" + return config + + +def vit_wilds_animals_modeldg(run: int, lr: float, do: int, rew: float): + config = vit_modeldg( + name=f"wilds_animals_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", + ) + config.data = wilds_animals_data_config("wilds_animals", 384) + config.trainer.num_steps = 60000 + config.trainer.batch_size = 512 config.trainer.dg_pretrain_steps = 20000 - config.trainer.lr_scheduler_interval = "step" - config.exp.name = f"cifar10_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}" - config.model = ModelConfig( - name="devries_model", - network=NetworkConfig( - name="vit", - save_dg_backbone_path=Path("${exp.dir}/dg_backbone.ckpt"), - ), - fc_dim=768, - avg_pool=True, - dropout_rate=1, - dg_reward=rew, + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.model.dg_reward = rew + config.eval.query_studies = wilds_animals_query_config(384) + return config + + +def vit_wilds_camelyon_modeldg(run: int, lr: float, do: int, rew: float): + config = vit_modeldg( + name=f"wilds_camelyon_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", ) - config.eval.ext_confid_name = "dg" - config.eval.confidence_measures.test.append("ext") + config.data = wilds_camelyon_data_config("wilds_camelyon", 384) + config.trainer.num_steps = 60000 + config.trainer.dg_pretrain_steps = 20000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.model.dg_reward = rew + config.eval.query_studies = wilds_camelyon_query_config(384) + return config + +def vit_svhn_modeldg(run: int, lr: float, do: int, rew: float): + config = vit_modeldg( + name=f"svhn_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", + ) + config.data = svhn_data_config("svhn", 384) + config.trainer.num_steps = 60000 + config.trainer.dg_pretrain_steps = 20000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.model.dg_reward = rew + config.eval.query_studies = svhn_query_config("svhn", 384) + return config + + +def vit_cifar10_modeldg(run: int, lr: float, do: int, rew: float): + config = vit_modeldg( + name=f"cifar10_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", + ) + config.data = cifar10_data_config(img_size=384) + config.trainer.num_steps = 60000 + config.trainer.dg_pretrain_steps = 20000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.model.dg_reward = rew + config.model.avg_pool = do == 0 + config.eval.query_studies = cifar10_query_config(384) + return config + + +def vit_cifar100_modeldg(run: int, lr: float, do: int, rew: float): + config = vit_modeldg( + name=f"cifar100_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", + ) + config.data = cifar100_data_config(img_size=384) + config.trainer.num_steps = 15000 + config.trainer.batch_size = 512 + config.trainer.dg_pretrain_steps = 5000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 15000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.model.dg_reward = rew + config.eval.query_studies = cifar100_query_config(384) + return config + + +def vit_breeds_modeldg(run: int, lr: float, do: int, rew: float): + config = vit_modeldg( + name=f"breeds_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", + ) + config.data = breeds_data_config("breeds", 384) + config.trainer.num_steps = 60000 + config.trainer.dg_pretrain_steps = 20000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.model.dg_reward = rew + config.eval.query_studies = breeds_query_config(384) + return config + + +def vit_wilds_animals_modelvit(run: int, lr: float, do: int, **kwargs): + config = vit( + name=f"wilds_animals_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", + ) + config.data = wilds_animals_data_config("wilds_animals", 384) + config.trainer.num_steps = 40000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.eval.query_studies = wilds_animals_query_config(384) + return config + + +def vit_wilds_camelyon_modelvit(run: int, lr: float, do: int, **kwargs): + config = vit( + name=f"wilds_camelyon_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", + ) + config.data = wilds_camelyon_data_config("wilds_camelyon", 384) + config.trainer.num_steps = 40000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.eval.query_studies = wilds_camelyon_query_config(384) + return config + + +def vit_svhn_modelvit(run: int, lr: float, do: int, **kwargs): + config = vit( + name=f"svhn_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", + ) + config.data = svhn_data_config("svhn", 384) + config.trainer.num_steps = 40000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.eval.query_studies = svhn_query_config("svhn", 384) + return config + + +def vit_cifar10_modelvit(run: int, lr: float, do: int, **kwargs): + config = vit( + name=f"cifar10_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", + ) + config.data = cifar10_data_config(img_size=384) + config.trainer.num_steps = 40000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.model.avg_pool = do == 0 + config.eval.query_studies = cifar10_query_config(384) + return config + + +def vit_cifar100_modelvit(run: int, lr: float, do: int, **kwargs): + config = vit( + name=f"cifar100_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", + ) + config.data = cifar100_data_config(img_size=384) + config.trainer.num_steps = 10000 + config.trainer.batch_size = 512 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 10000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.eval.query_studies = cifar100_query_config(384) + return config + + +def vit_breeds_modelvit(run: int, lr: float, do: int, **kwargs): + config = vit( + name=f"breeds_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", + ) + config.data = breeds_data_config("breeds", 384) + config.trainer.num_steps = 40000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.model.dropout_rate = do + config.eval.query_studies = breeds_query_config(384) return config def register(config_fn: Callable[..., Config], n_runs: int = 5, **kwargs): for run in range(n_runs): config = config_fn(**kwargs, run=run) - __experiments[config.exp.name] = config - - -register(svhn_modelvit_bbvit, lr=0.03, do=1, rew=2.2) -register(svhn_modelvit_bbvit, lr=0.01, do=0, rew=2.2) -register(svhn_modelvit_bbvit, lr=0.01, do=1, rew=2.2) -register(svhn_modeldg_bbvit, lr=0.01, do=1, rew=2.2) -register(svhn_modeldg_bbvit, lr=0.01, do=1, rew=3) -register(svhn_modeldg_bbvit, lr=0.01, do=1, rew=6) -register(svhn_modeldg_bbvit, lr=0.01, do=1, rew=10) -register(svhn_modeldg_bbvit, lr=0.03, do=1, rew=2.2) -register(svhn_modeldg_bbvit, lr=0.03, do=1, rew=3) -register(svhn_modeldg_bbvit, lr=0.03, do=1, rew=6) -register(svhn_modeldg_bbvit, lr=0.03, do=1, rew=10) - -register(cifar10_modelvit_bbvit, lr=3e-4, do=0, rew=2.2) -register(cifar10_modelvit_bbvit, lr=0.01, do=1, rew=2.2) -register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=2.2) -register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=2.2) -register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=3) -register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=3) -register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=6) -register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=6) -register(cifar10_modeldg_bbvit, lr=3e-4, do=0, rew=10) -register(cifar10_modeldg_bbvit, lr=0.01, do=1, rew=10) + __experiments[f"{config.exp.group_name}/{config.exp.name}"] = config + + +register(vit_svhn_modelvit, lr=0.03, do=1, rew=0) +register(vit_svhn_modelvit, lr=0.01, do=0, rew=0) +register(vit_svhn_modelvit, lr=0.01, do=1, rew=0) +register(vit_svhn_modeldg, lr=0.01, do=1, rew=2.2) +register(vit_svhn_modeldg, lr=0.01, do=1, rew=3) +register(vit_svhn_modeldg, lr=0.01, do=1, rew=6) +register(vit_svhn_modeldg, lr=0.01, do=1, rew=10) +register(vit_svhn_modeldg, lr=0.01, do=0, rew=2.2) +register(vit_svhn_modeldg, lr=0.01, do=0, rew=3) +register(vit_svhn_modeldg, lr=0.01, do=0, rew=6) +register(vit_svhn_modeldg, lr=0.01, do=0, rew=10) +register(vit_svhn_modeldg, lr=0.03, do=1, rew=2.2) +register(vit_svhn_modeldg, lr=0.03, do=1, rew=3) +register(vit_svhn_modeldg, lr=0.03, do=1, rew=6) +register(vit_svhn_modeldg, lr=0.03, do=1, rew=10) + +register(vit_cifar10_modelvit, lr=3e-4, do=0, rew=0) +register(vit_cifar10_modelvit, lr=0.01, do=1, rew=0) +register(vit_cifar10_modeldg, lr=3e-4, do=0, rew=2.2) +register(vit_cifar10_modeldg, lr=0.01, do=1, rew=2.2) +register(vit_cifar10_modeldg, lr=3e-4, do=0, rew=3) +register(vit_cifar10_modeldg, lr=0.01, do=1, rew=3) +register(vit_cifar10_modeldg, lr=3e-4, do=0, rew=6) +register(vit_cifar10_modeldg, lr=0.01, do=1, rew=6) +register(vit_cifar10_modeldg, lr=3e-4, do=0, rew=10) +register(vit_cifar10_modeldg, lr=0.01, do=1, rew=10) + +register(vit_cifar100_modelvit, lr=1e-2, do=0, rew=0) +register(vit_cifar100_modelvit, lr=1e-2, do=1, rew=0) +register(vit_cifar100_modeldg, lr=1e-2, do=0, rew=2.2) +register(vit_cifar100_modeldg, lr=1e-2, do=1, rew=2.2) +register(vit_cifar100_modeldg, lr=1e-2, do=0, rew=3) +register(vit_cifar100_modeldg, lr=1e-2, do=1, rew=3) +register(vit_cifar100_modeldg, lr=1e-2, do=0, rew=6) +register(vit_cifar100_modeldg, lr=1e-2, do=1, rew=6) +register(vit_cifar100_modeldg, lr=1e-2, do=0, rew=10) +register(vit_cifar100_modeldg, lr=1e-2, do=1, rew=10) +register(vit_cifar100_modeldg, lr=1e-2, do=0, rew=12) +register(vit_cifar100_modeldg, lr=1e-2, do=1, rew=12) +register(vit_cifar100_modeldg, lr=1e-2, do=0, rew=15) +register(vit_cifar100_modeldg, lr=1e-2, do=1, rew=15) +register(vit_cifar100_modeldg, lr=1e-2, do=0, rew=20) +register(vit_cifar100_modeldg, lr=1e-2, do=1, rew=20) + +register(vit_wilds_animals_modelvit, lr=1e-3, do=0, rew=0) +register(vit_wilds_animals_modelvit, lr=1e-2, do=0, rew=0) +register(vit_wilds_animals_modelvit, lr=1e-2, do=1, rew=0) +register(vit_wilds_animals_modelvit, lr=3e-3, do=0, rew=0) +register(vit_wilds_animals_modelvit, lr=3e-3, do=1, rew=0) +register(vit_wilds_animals_modeldg, lr=1e-3, do=0, rew=2.2) +register(vit_wilds_animals_modeldg, lr=1e-3, do=0, rew=3) +register(vit_wilds_animals_modeldg, lr=1e-3, do=0, rew=6) +register(vit_wilds_animals_modeldg, lr=1e-3, do=0, rew=10) +register(vit_wilds_animals_modeldg, lr=1e-3, do=0, rew=15) +register(vit_wilds_animals_modeldg, lr=3e-3, do=0, rew=2.2) +register(vit_wilds_animals_modeldg, lr=3e-3, do=0, rew=3) +register(vit_wilds_animals_modeldg, lr=3e-3, do=0, rew=6) +register(vit_wilds_animals_modeldg, lr=3e-3, do=0, rew=10) +register(vit_wilds_animals_modeldg, lr=3e-3, do=0, rew=15) +register(vit_wilds_animals_modeldg, lr=3e-3, do=1, rew=2.2) +register(vit_wilds_animals_modeldg, lr=3e-3, do=1, rew=3) +register(vit_wilds_animals_modeldg, lr=3e-3, do=1, rew=6) +register(vit_wilds_animals_modeldg, lr=3e-3, do=1, rew=10) +register(vit_wilds_animals_modeldg, lr=3e-3, do=1, rew=15) + +register(vit_wilds_camelyon_modelvit, lr=1e-3, do=0, rew=0) +register(vit_wilds_camelyon_modelvit, lr=3e-3, do=1, rew=0) +register(vit_wilds_camelyon_modeldg, lr=1e-3, do=0, rew=2.2) +register(vit_wilds_camelyon_modeldg, lr=1e-3, do=0, rew=3) +register(vit_wilds_camelyon_modeldg, lr=1e-3, do=0, rew=6) +register(vit_wilds_camelyon_modeldg, lr=1e-3, do=0, rew=10) +register(vit_wilds_camelyon_modeldg, lr=3e-3, do=1, rew=2.2) +register(vit_wilds_camelyon_modeldg, lr=3e-3, do=1, rew=3) +register(vit_wilds_camelyon_modeldg, lr=3e-3, do=1, rew=6) +register(vit_wilds_camelyon_modeldg, lr=3e-3, do=1, rew=10) + +register(vit_breeds_modelvit, lr=3e-3, do=0, rew=0, n_runs=2) +register(vit_breeds_modelvit, lr=1e-3, do=0, rew=0, n_runs=2) +register(vit_breeds_modelvit, lr=1e-2, do=1, rew=0, n_runs=2) +register(vit_breeds_modeldg, lr=3e-3, do=0, rew=2.2, n_runs=2) +register(vit_breeds_modeldg, lr=3e-3, do=0, rew=3, n_runs=2) +register(vit_breeds_modeldg, lr=3e-3, do=0, rew=6, n_runs=2) +register(vit_breeds_modeldg, lr=3e-3, do=0, rew=10, n_runs=2) +register(vit_breeds_modeldg, lr=3e-3, do=0, rew=15, n_runs=2) +register(vit_breeds_modeldg, lr=1e-3, do=0, rew=2.2, n_runs=2) +register(vit_breeds_modeldg, lr=1e-3, do=0, rew=3, n_runs=2) +register(vit_breeds_modeldg, lr=1e-3, do=0, rew=6, n_runs=2) +register(vit_breeds_modeldg, lr=1e-3, do=0, rew=10, n_runs=2) +register(vit_breeds_modeldg, lr=1e-3, do=0, rew=15, n_runs=2) +register(vit_breeds_modeldg, lr=1e-2, do=1, rew=2.2, n_runs=2) +register(vit_breeds_modeldg, lr=1e-2, do=1, rew=3, n_runs=2) +register(vit_breeds_modeldg, lr=1e-2, do=1, rew=6, n_runs=2) +register(vit_breeds_modeldg, lr=1e-2, do=1, rew=10, n_runs=2) +register(vit_breeds_modeldg, lr=1e-2, do=1, rew=15, n_runs=2) + +register(cnn_svhn_modeldevries, do=0) +register(cnn_svhn_modeldevries, do=1) +register(cnn_svhn_modelconfidnet, do=0) +register(cnn_svhn_modelconfidnet, do=1) +register(cnn_svhn_modeldg, do=0, rew=2.2) +register(cnn_svhn_modeldg, do=1, rew=2.2) +register(cnn_svhn_modeldg, do=0, rew=3) +register(cnn_svhn_modeldg, do=1, rew=3) +register(cnn_svhn_modeldg, do=0, rew=6) +register(cnn_svhn_modeldg, do=1, rew=6) +register(cnn_svhn_modeldg, do=0, rew=10) +register(cnn_svhn_modeldg, do=1, rew=10) + +register(cnn_cifar10_modeldevries, do=0) +register(cnn_cifar10_modeldevries, do=1) +register(cnn_cifar10_modelconfidnet, do=0) +register(cnn_cifar10_modelconfidnet, do=1) +register(cnn_cifar10_modeldg, do=0, rew=2.2) +register(cnn_cifar10_modeldg, do=1, rew=2.2) +register(cnn_cifar10_modeldg, do=0, rew=3) +register(cnn_cifar10_modeldg, do=1, rew=3) +register(cnn_cifar10_modeldg, do=0, rew=6) +register(cnn_cifar10_modeldg, do=1, rew=6) +register(cnn_cifar10_modeldg, do=0, rew=10) +register(cnn_cifar10_modeldg, do=1, rew=10) + +register(cnn_cifar100_modeldevries, do=0) +register(cnn_cifar100_modeldevries, do=1) +register(cnn_cifar100_modelconfidnet, do=0) +register(cnn_cifar100_modelconfidnet, do=1) +register(cnn_cifar100_modeldg, do=0, rew=2.2) +register(cnn_cifar100_modeldg, do=1, rew=2.2) +register(cnn_cifar100_modeldg, do=0, rew=3) +register(cnn_cifar100_modeldg, do=1, rew=3) +register(cnn_cifar100_modeldg, do=0, rew=6) +register(cnn_cifar100_modeldg, do=1, rew=6) +register(cnn_cifar100_modeldg, do=0, rew=10) +register(cnn_cifar100_modeldg, do=1, rew=10) +register(cnn_cifar100_modeldg, do=0, rew=12) +register(cnn_cifar100_modeldg, do=1, rew=12) +register(cnn_cifar100_modeldg, do=0, rew=15) +register(cnn_cifar100_modeldg, do=1, rew=15) +register(cnn_cifar100_modeldg, do=0, rew=20) +register(cnn_cifar100_modeldg, do=1, rew=20) + +register(cnn_animals_modeldevries, do=0) +register(cnn_animals_modeldevries, do=1) +register(cnn_animals_modelconfidnet, do=0) +register(cnn_animals_modelconfidnet, do=1) +register(cnn_animals_modeldg, do=0, rew=2.2) +register(cnn_animals_modeldg, do=1, rew=2.2) +register(cnn_animals_modeldg, do=0, rew=3) +register(cnn_animals_modeldg, do=1, rew=3) +register(cnn_animals_modeldg, do=0, rew=6) +register(cnn_animals_modeldg, do=1, rew=6) +register(cnn_animals_modeldg, do=0, rew=10) +register(cnn_animals_modeldg, do=1, rew=10) +register(cnn_animals_modeldg, do=0, rew=15) +register(cnn_animals_modeldg, do=1, rew=15) + +register(cnn_camelyon_modeldevries, do=0, n_runs=10) +register(cnn_camelyon_modeldevries, do=1, n_runs=10) +register(cnn_camelyon_modelconfidnet, do=0, n_runs=10) +register(cnn_camelyon_modelconfidnet, do=1, n_runs=10) +register(cnn_camelyon_modeldg, do=0, rew=2.2, n_runs=10) +register(cnn_camelyon_modeldg, do=1, rew=2.2, n_runs=10) +register(cnn_camelyon_modeldg, do=0, rew=3, n_runs=10) +register(cnn_camelyon_modeldg, do=1, rew=3, n_runs=10) +register(cnn_camelyon_modeldg, do=0, rew=6, n_runs=10) +register(cnn_camelyon_modeldg, do=1, rew=6, n_runs=10) +register(cnn_camelyon_modeldg, do=0, rew=10, n_runs=10) +register(cnn_camelyon_modeldg, do=1, rew=10, n_runs=10) + +register(cnn_breeds_modeldevries, do=0, n_runs=2) +register(cnn_breeds_modeldevries, do=1, n_runs=2) +register(cnn_breeds_modelconfidnet, do=0, n_runs=2) +register(cnn_breeds_modelconfidnet, do=1, n_runs=2) +register(cnn_breeds_modeldg, do=0, rew=2.2, n_runs=2) +register(cnn_breeds_modeldg, do=1, rew=2.2, n_runs=2) +register(cnn_breeds_modeldg, do=0, rew=3, n_runs=2) +register(cnn_breeds_modeldg, do=1, rew=3, n_runs=2) +register(cnn_breeds_modeldg, do=0, rew=6, n_runs=2) +register(cnn_breeds_modeldg, do=1, rew=6, n_runs=2) +register(cnn_breeds_modeldg, do=0, rew=10, n_runs=2) +register(cnn_breeds_modeldg, do=1, rew=10, n_runs=2) +register(cnn_breeds_modeldg, do=0, rew=15, n_runs=2) +register(cnn_breeds_modeldg, do=1, rew=15, n_runs=2) def get_experiment_config(name: str) -> Config: diff --git a/fd_shifts/main.py b/fd_shifts/main.py index ddc69a3..2bf866d 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -1,5 +1,7 @@ +import re import types import typing +import warnings from contextlib import contextmanager from contextvars import ContextVar from dataclasses import asdict, is_dataclass @@ -21,7 +23,13 @@ from fd_shifts import analysis, logger from fd_shifts.configs import Config, TestConfig -from fd_shifts.experiments.configs import get_experiment_config, list_experiment_configs +from fd_shifts.experiments.configs import ( + get_dataset_config, + get_experiment_config, + list_experiment_configs, + wilds_animals_query_config, +) +from fd_shifts.experiments.tracker import get_path from fd_shifts.loaders.data_loader import FDShiftsDataLoader from fd_shifts.models import get_model from fd_shifts.models.callbacks import get_callbacks @@ -173,6 +181,40 @@ def apply_config(parser, cfg, dest, value, option_string) -> None: }, }, } + + # query_studies contain DataConfig objects now, not just names + for k, v in cfg_file["config"]["eval"]["query_studies"].items(): + if k == "iid_study": + pass + elif k in ["in_class_study", "noise_study", "new_class_study"]: + cfg_file["config"]["eval"]["query_studies"][k] = [ + asdict(get_dataset_config(v2)) for v2 in v + ] + else: + raise ValueError(f"Unknown query study {k}") + + # for specific experiments, the seed should be fixed, if "random_seed" was written fix it + if isinstance(cfg_file["config"]["exp"]["global_seed"], str): + warnings.warn( + "global_seed is set to random in file, setting it to -1" + ) + cfg_file["config"]["exp"]["global_seed"] = -1 + + # hydra is gone + if cfg_file["config"]["exp"]["work_dir"] == "${hydra:runtime.cwd}": + cfg_file["config"]["exp"]["work_dir"] = Path.cwd() + + # resolve everything else + oc_config = OmegaConf.create(cfg_file["config"]) + dict_config: dict[str, Any] = OmegaConf.to_object(oc_config) # type: ignore + cfg_file["config"] = dict_config + + # don't need to comply with accumulate_grad_batches, that's runtime env dependent + cfg_file["config"]["trainer"]["batch_size"] *= cfg_file["config"][ + "trainer" + ].get("accumulate_grad_batches", 1) + cfg_file["config"]["trainer"]["accumulate_grad_batches"] = 1 + else: raise ValueError(f"Unknown option string {option_string}") From 9fcd20e3e03dac590c4abd08f171413847821092 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 20 Feb 2024 00:05:09 +0100 Subject: [PATCH 085/136] feat(main): add analysis subcommand --- fd_shifts/configs/__init__.py | 1 + fd_shifts/main.py | 20 ++++++++++++++------ 2 files changed, 15 insertions(+), 6 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 814a6a1..475dd74 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -112,6 +112,7 @@ class OutputPathsPerMode(_IterableMixin): encoded_output=Path("${test.dir}/encoded_output.npz"), attributions_output=Path("${test.dir}/attributions.csv"), ) + analysis: Path = SI("${test.dir}") @defer_validation diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 2bf866d..3292927 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -1,4 +1,3 @@ -import re import types import typing import warnings @@ -21,13 +20,13 @@ from pytorch_lightning.loggers.wandb import WandbLogger from rich.pretty import pretty_repr -from fd_shifts import analysis, logger -from fd_shifts.configs import Config, TestConfig +from fd_shifts import analysis as ana +from fd_shifts import logger +from fd_shifts.configs import Config from fd_shifts.experiments.configs import ( get_dataset_config, get_experiment_config, list_experiment_configs, - wilds_animals_query_config, ) from fd_shifts.experiments.tracker import get_path from fd_shifts.loaders.data_loader import FDShiftsDataLoader @@ -453,9 +452,13 @@ def test(config: Config): precision=16, ) trainer.test(model=module, datamodule=datamodule) - analysis.main( + + +@subcommand +def analysis(config: Config): + ana.main( in_path=config.test.dir, - out_path=config.test.dir, + out_path=config.exp.output_paths.analysis, query_studies=config.eval.query_studies, add_val_tuning=config.eval.val_tuning, threshold_plot_confid=None, @@ -463,6 +466,11 @@ def test(config: Config): ) +@subcommand +def debug(config: Config): + pass + + def _list_experiments(): rich.print("Available experiments:") for exp in sorted(list_experiment_configs()): From 157a6107024a2cadad15898ccc379f694e09b81d Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 20 Feb 2024 14:10:01 +0100 Subject: [PATCH 086/136] perf(main): delay imports for faster cli startup --- fd_shifts/analysis/__init__.py | 15 +++++--- fd_shifts/analysis/eval_utils.py | 60 +++++++++++++++++++++----------- fd_shifts/configs/__init__.py | 28 ++++++++------- fd_shifts/main.py | 56 +++++++++++++++++++---------- 4 files changed, 103 insertions(+), 56 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 4f8fed1..631c9d9 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -10,17 +10,14 @@ import numpy as np import numpy.typing as npt import pandas as pd -import torch from loguru import logger -from omegaconf import DictConfig, ListConfig, OmegaConf +from omegaconf import ListConfig from rich import inspect from scipy import special as scpspecial -from sklearn import neighbors from sklearn.calibration import _sigmoid_calibration as calib from fd_shifts import configs -from . import metrics from .confid_scores import ConfidScore, SecondaryConfidScore, is_external_confid from .eval_utils import ( ConfidEvaluator, @@ -361,6 +358,8 @@ def __call__(self, confids: npt.NDArray[Any]) -> npt.NDArray[Any]: class TemperatureScaling: def __init__(self, val_logits: npt.NDArray[Any], val_labels: npt.NDArray[Any]): + import torch + logger.info("Fit temperature to validation logits") self.temperature = torch.ones(1).requires_grad_(True) @@ -380,6 +379,8 @@ def _eval(): self.temperature = self.temperature.item() def __call__(self, logits: npt.NDArray[Any]) -> npt.NDArray[Any]: + import torch + return np.max( torch.softmax(torch.tensor(logits) / self.temperature, dim=1).numpy(), axis=1, @@ -394,6 +395,8 @@ def _react( clip_quantile=99, val_set_index=0, ): + import torch + logger.info("Compute REACT logits") logger.warning( "Currently uses validation set for clip parameter fit, will switch to training set in the future" @@ -425,6 +428,8 @@ def _maha_dist( dataset_idx: npt.NDArray[np.int_], val_set_index=0, ): + import torch + logger.info("Compute Mahalanobis distance") # mask = np.argwhere(dataset_idx == val_set_index)[:, 0] @@ -453,6 +458,8 @@ def _vim( features: npt.NDArray[np.float_], logits: npt.NDArray[np.float_], ): + import torch + logger.info("Compute ViM score") D = 512 w, b = last_layer diff --git a/fd_shifts/analysis/eval_utils.py b/fd_shifts/analysis/eval_utils.py index f706d3d..50a3d7b 100644 --- a/fd_shifts/analysis/eval_utils.py +++ b/fd_shifts/analysis/eval_utils.py @@ -1,19 +1,25 @@ +from __future__ import annotations + import math import os +from typing import TYPE_CHECKING -import matplotlib.pyplot as plt import numpy as np import pandas as pd import scipy import seaborn -import torch from sklearn import metrics as skm from sklearn.calibration import calibration_curve -from torchmetrics import Metric from . import logger from .metrics import StatsCache, get_metric_function +# from torchmetrics import Metric + + +if TYPE_CHECKING: + import torch + def _get_tb_hparams(cf): hparams_collection = {"fold": cf.exp.fold} @@ -29,6 +35,8 @@ def monitor_eval( do_plot=True, ext_confid_name=None, ): + import torch + out_metrics = {} out_plots = {} bins = 20 @@ -367,6 +375,8 @@ def __init__( self.threshold = None def compose_plot(self): + import matplotlib.pyplot as plt + seaborn.set(font_scale=self.fig_scale, style="whitegrid") self.colors_list = seaborn.hls_palette(len(self.confid_keys_list)).as_hex() n_columns = 2 @@ -681,29 +691,31 @@ def RC_curve(residuals, confidence): return curve, aurc, e_aurc -class BrierScore(Metric): - def __init__(self, num_classes, dist_sync_on_step=False): - # call `self.add_state`for every internal state that is needed for the metrics computations - # dist_reduce_fx indicates the function that should be used to reduce - # state from multiple processes - super().__init__(dist_sync_on_step=dist_sync_on_step) +# class BrierScore(Metric): +# def __init__(self, num_classes, dist_sync_on_step=False): +# import torch +# # call `self.add_state`for every internal state that is needed for the metrics computations +# # dist_reduce_fx indicates the function that should be used to reduce +# # state from multiple processes +# super().__init__(dist_sync_on_step=dist_sync_on_step) - self.num_classes = num_classes - self.add_state("brier_score", default=torch.tensor(0.0), dist_reduce_fx="sum") - self.add_state("total", default=torch.tensor(0), dist_reduce_fx="sum") +# self.num_classes = num_classes +# self.add_state("brier_score", default=torch.tensor(0.0), dist_reduce_fx="sum") +# self.add_state("total", default=torch.tensor(0), dist_reduce_fx="sum") - def update(self, preds: torch.Tensor, target: torch.Tensor): - # update metric states +# def update(self, preds: torch.Tensor, target: torch.Tensor): +# import torch +# # update metric states - y_one_hot = torch.nn.functional.one_hot(target, num_classes=self.num_classes) - assert preds.shape == y_one_hot.shape +# y_one_hot = torch.nn.functional.one_hot(target, num_classes=self.num_classes) +# assert preds.shape == y_one_hot.shape - self.brier_score += ((preds - y_one_hot) ** 2).sum(1).mean() - self.total += 1 +# self.brier_score += ((preds - y_one_hot) ** 2).sum(1).mean() +# self.total += 1 - def compute(self): - # compute final result - return self.brier_score.float() / self.total +# def compute(self): +# # compute final result +# return self.brier_score.float() / self.total def clean_logging(log_dir): @@ -716,6 +728,8 @@ def clean_logging(log_dir): def plot_input_imgs(x, y, out_path): + import matplotlib.pyplot as plt + f, axs = plt.subplots(nrows=4, ncols=4, figsize=(10, 10)) for ix in range(len(f.axes)): ax = f.axes[ix] @@ -728,6 +742,8 @@ def plot_input_imgs(x, y, out_path): def qual_plot(fp_dict, fn_dict, out_path): + import matplotlib.pyplot as plt + n_rows = len(fp_dict["images"]) f, axs = plt.subplots(nrows=n_rows, ncols=2, figsize=(6, 13)) title_pad = 0.85 @@ -761,6 +777,8 @@ def qual_plot(fp_dict, fn_dict, out_path): def ThresholdPlot(plot_dict): + import matplotlib.pyplot as plt + scale = 10 n_cols = len(plot_dict) n_rows = 1 diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 475dd74..2cc650c 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -8,28 +8,20 @@ from enum import Enum, auto from pathlib import Path from random import randint -from typing import TYPE_CHECKING, Any, Callable, Iterable, Iterator, Optional, TypeVar +from typing import TYPE_CHECKING, Any, Iterable, Optional, TypeVar -import pl_bolts -import torch from hydra.core.config_store import ConfigStore -from hydra_zen import builds # type: ignore from omegaconf import SI, DictConfig, OmegaConf -from omegaconf.omegaconf import MISSING from pydantic import ConfigDict, validator from pydantic.dataclasses import dataclass from typing_extensions import dataclass_transform -import fd_shifts -from fd_shifts import models -from fd_shifts.analysis import confid_scores, metrics -from fd_shifts.loaders import dataset_collection -from fd_shifts.utils import exp_utils +from fd_shifts import get_version -from ..models import networks from .iterable_mixin import _IterableMixin if TYPE_CHECKING: + import torch from pydantic.dataclasses import Dataclass ConfigT = TypeVar("ConfigT", bound=Dataclass) @@ -310,6 +302,8 @@ def validate_network_name(cls: NetworkConfig, name: str) -> str: Returns: name """ + from ..models import networks + if name is not None and not networks.network_exists(name): raise ValueError(f'Network "{name}" does not exist.') return name @@ -343,6 +337,8 @@ def validate_network_name(cls: ModelConfig, name: str) -> str: Returns: name """ + from fd_shifts import models + if name is not None and not models.model_exists(name): raise ValueError(f'Model "{name}" does not exist.') return name @@ -415,6 +411,8 @@ def validate(cls: ConfidMetricsConfig, name: str) -> str: Returns: name """ + from fd_shifts.analysis import metrics + if not metrics.metric_function_exists(name): raise ValueError(f'Confid metric function "{name}" does not exist.') return name @@ -439,6 +437,8 @@ def validate(cls: ConfidMeasuresConfig, name: str) -> str: Returns: name """ + from fd_shifts.analysis import confid_scores + if not confid_scores.confid_function_exists(name): raise ValueError(f'Confid function "{name}" does not exist.') return name @@ -466,6 +466,8 @@ def validate(cls, name: str) -> str: Returns: name """ + from fd_shifts.loaders import dataset_collection + if not dataset_collection.dataset_exists(name): raise ValueError(f'Dataset "{name}" does not exist.') return name @@ -548,7 +550,7 @@ class Config(_IterableMixin): exp: ExperimentConfig - pkgversion: str = fd_shifts.get_version() + pkgversion: str = get_version() data: DataConfig = field(default_factory=lambda: DataConfig()) @@ -560,6 +562,8 @@ class Config(_IterableMixin): test: TestConfig = field(default_factory=lambda: TestConfig()) def update_experiment(self, name: str): + from fd_shifts.utils import exp_utils + config = deepcopy(self) group_name = config.data.dataset group_dir = config.exp.group_dir.parent / group_name diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 3292927..ae69175 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -1,3 +1,5 @@ +from __future__ import annotations + import types import typing import warnings @@ -5,35 +7,17 @@ from contextvars import ContextVar from dataclasses import asdict, is_dataclass from pathlib import Path -from typing import Any, Callable, Optional +from typing import TYPE_CHECKING, Any, Callable, Optional import jsonargparse -import pytorch_lightning as pl import rich import yaml from jsonargparse import ActionConfigFile, ArgumentParser from jsonargparse._actions import Action from omegaconf import OmegaConf -from pytorch_lightning.callbacks.progress.rich_progress import RichProgressBar -from pytorch_lightning.loggers.csv_logs import CSVLogger -from pytorch_lightning.loggers.tensorboard import TensorBoardLogger -from pytorch_lightning.loggers.wandb import WandbLogger from rich.pretty import pretty_repr -from fd_shifts import analysis as ana -from fd_shifts import logger from fd_shifts.configs import Config -from fd_shifts.experiments.configs import ( - get_dataset_config, - get_experiment_config, - list_experiment_configs, -) -from fd_shifts.experiments.tracker import get_path -from fd_shifts.loaders.data_loader import FDShiftsDataLoader -from fd_shifts.models import get_model -from fd_shifts.models.callbacks import get_callbacks -from fd_shifts.utils import exp_utils -from fd_shifts.version import get_version __subcommands = {} @@ -85,6 +69,8 @@ def __call__(self, parser, cfg, values, option_string=None): @staticmethod def apply_experiment_config(parser: ArgumentParser, cfg, dest, value) -> None: + from fd_shifts.experiments.configs import get_experiment_config + with previous_config_context(cfg): experiment_cfg = get_experiment_config(value) tcfg = parser.parse_object( @@ -135,6 +121,8 @@ def set_default_error(): def apply_config(parser, cfg, dest, value, option_string) -> None: from jsonargparse._link_arguments import skip_apply_links + from fd_shifts.experiments.configs import get_dataset_config + with jsonargparse._actions._ActionSubCommands.not_single_subcommand(), previous_config_context( cfg ), skip_apply_links(): @@ -292,6 +280,8 @@ def omegaconf_resolve(config: Config): def setup_logging(): + from fd_shifts import logger + rich.reconfigure(stderr=True, force_terminal=True) logger.remove() # Remove default 'stderr' handler @@ -309,6 +299,18 @@ def setup_logging(): @subcommand def train(config: Config): + import pytorch_lightning as pl + from pytorch_lightning.callbacks.progress.rich_progress import RichProgressBar + from pytorch_lightning.loggers.csv_logs import CSVLogger + from pytorch_lightning.loggers.tensorboard import TensorBoardLogger + from pytorch_lightning.loggers.wandb import WandbLogger + + from fd_shifts import logger + from fd_shifts.loaders.data_loader import FDShiftsDataLoader + from fd_shifts.models import get_model + from fd_shifts.models.callbacks import get_callbacks + from fd_shifts.utils import exp_utils + progress = RichProgressBar(console_kwargs={"stderr": True, "force_terminal": True}) if config.exp.dir is None: @@ -397,6 +399,16 @@ def train(config: Config): @subcommand def test(config: Config): + import pytorch_lightning as pl + from pytorch_lightning.callbacks.progress.rich_progress import RichProgressBar + from pytorch_lightning.loggers.wandb import WandbLogger + + from fd_shifts import logger + from fd_shifts.loaders.data_loader import FDShiftsDataLoader + from fd_shifts.models import get_model + from fd_shifts.models.callbacks import get_callbacks + from fd_shifts.utils import exp_utils + progress = RichProgressBar(console_kwargs={"stderr": True, "force_terminal": True}) if config.exp.dir is None: @@ -456,6 +468,8 @@ def test(config: Config): @subcommand def analysis(config: Config): + from fd_shifts import analysis as ana + ana.main( in_path=config.test.dir, out_path=config.exp.output_paths.analysis, @@ -472,12 +486,16 @@ def debug(config: Config): def _list_experiments(): + from fd_shifts.experiments.configs import list_experiment_configs + rich.print("Available experiments:") for exp in sorted(list_experiment_configs()): rich.print(exp) def get_parser(): + from fd_shifts import get_version + parser = ArgumentParser(version=get_version()) parser.add_argument("-f", "--overwrite-config-file", action="store_true") subcommands = parser.add_subcommands(dest="command") From 1c5303a89307cbc818f3bcab9432ad66e2d57fc0 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 20 Feb 2024 18:20:07 +0100 Subject: [PATCH 087/136] fix(config): make noise_study a singular entry --- fd_shifts/configs/__init__.py | 18 +++++++++--------- fd_shifts/loaders/data_loader.py | 6 +++++- fd_shifts/main.py | 22 +++++++++++++++++++++- 3 files changed, 35 insertions(+), 11 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 2cc650c..0f4175e 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -72,13 +72,13 @@ def defer_validation(original_class: type[ConfigT]) -> type[ConfigT]: class OutputPathsConfig(_IterableMixin): """Where outputs are stored""" - raw_output: Path | None = None - raw_output_dist: Path | None = None - external_confids: Path | None = None - external_confids_dist: Path | None = None + raw_output: Path + raw_output_dist: Path + external_confids: Path + external_confids_dist: Path + encoded_output: Path + attributions_output: Path input_imgs_plot: Optional[Path] = None - encoded_output: Optional[Path] = None - attributions_output: Optional[Path] = None @defer_validation @@ -92,8 +92,8 @@ class OutputPathsPerMode(_IterableMixin): external_confids=Path("${exp.version_dir}/external_confids.npz"), external_confids_dist=Path("${exp.version_dir}/external_confids_dist.npz"), input_imgs_plot=Path("${exp.dir}/input_imgs.png"), - encoded_output=None, - attributions_output=None, + encoded_output=Path("${test.dir}/encoded_output.npz"), + attributions_output=Path("${test.dir}/attributions.csv"), ) test: OutputPathsConfig = OutputPathsConfig( raw_output=Path("${test.dir}/raw_logits.npz"), @@ -450,7 +450,7 @@ class QueryStudiesConfig(_IterableMixin): """Query Studies Configuration""" iid_study: str | None = None - noise_study: list[DataConfig] = field(default_factory=lambda: []) + noise_study: DataConfig = field(default_factory=lambda: DataConfig()) in_class_study: list[DataConfig] = field(default_factory=lambda: []) new_class_study: list[DataConfig] = field(default_factory=lambda: []) diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index 80aa22a..2e10bcd 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -51,7 +51,10 @@ def __init__(self, cf: configs.Config, no_norm_flag=False): self.external_test_sets = [] for key, values in self.query_studies: if key != "iid_study" and values is not None: - self.external_test_sets.extend(list(values)) + if key == "noise_study" and values.dataset is not None: + self.external_test_sets.append(values) + else: + self.external_test_sets.extend(list(values)) logging.debug( "CHECK flat list of external datasets %s", self.external_test_sets ) @@ -267,6 +270,7 @@ def setup(self, stage=None): target_transform=self.target_transforms, transform=self.augmentations["external_{}".format(ext_set)], kwargs=self.dataset_kwargs, + config=self.external_test_configs[ext_set], ) if ( self.devries_repro_ood_split diff --git a/fd_shifts/main.py b/fd_shifts/main.py index ae69175..35c880c 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -173,7 +173,16 @@ def apply_config(parser, cfg, dest, value, option_string) -> None: for k, v in cfg_file["config"]["eval"]["query_studies"].items(): if k == "iid_study": pass - elif k in ["in_class_study", "noise_study", "new_class_study"]: + elif k == "noise_study": + if len(v) == 0: + cfg_file["config"]["eval"]["query_studies"][k] = None + elif len(v) == 1: + cfg_file["config"]["eval"]["query_studies"][k] = asdict( + get_dataset_config(v[0]) + ) + else: + raise ValueError(f"Too many noise studies {v}") + elif k in ["in_class_study", "new_class_study"]: cfg_file["config"]["eval"]["query_studies"][k] = [ asdict(get_dataset_config(v2)) for v2 in v ] @@ -238,6 +247,17 @@ def __dict_to_dataclass(cfg, cls): return cls( **{k: __dict_to_dataclass(v, fieldtypes[k]) for k, v in cfg.items()} ) + if ( + isinstance(cls, types.UnionType) + and len(cls.__args__) == 2 + and cls.__args__[1] == type(None) + and is_dataclass(cls.__args__[0]) + and isinstance(cfg, dict) + ): + fieldtypes = typing.get_type_hints(cls.__args__[0]) + return cls.__args__[0]( + **{k: __dict_to_dataclass(v, fieldtypes[k]) for k, v in cfg.items()} + ) if typing.get_origin(cls) == list: return [__dict_to_dataclass(v, typing.get_args(cls)[0]) for v in cfg] if cls == Path or ( From b9760e9e004fbe9b3a7c1f25c4a234a7a09acc6b Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 4 Jun 2024 17:13:43 +0200 Subject: [PATCH 088/136] feat: save train encodings on test --- fd_shifts/configs/__init__.py | 4 ++ fd_shifts/loaders/data_loader.py | 8 ++++ fd_shifts/models/callbacks/confid_monitor.py | 41 +++++++++++++++++--- fd_shifts/models/confidnet_model.py | 4 +- fd_shifts/models/devries_model.py | 2 +- fd_shifts/models/vit_model.py | 2 +- 6 files changed, 51 insertions(+), 10 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 0f4175e..390d719 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -77,6 +77,7 @@ class OutputPathsConfig(_IterableMixin): external_confids: Path external_confids_dist: Path encoded_output: Path + encoded_train: Path attributions_output: Path input_imgs_plot: Optional[Path] = None @@ -93,6 +94,7 @@ class OutputPathsPerMode(_IterableMixin): external_confids_dist=Path("${exp.version_dir}/external_confids_dist.npz"), input_imgs_plot=Path("${exp.dir}/input_imgs.png"), encoded_output=Path("${test.dir}/encoded_output.npz"), + encoded_train=Path("${test.dir}/train_features.npz"), attributions_output=Path("${test.dir}/attributions.csv"), ) test: OutputPathsConfig = OutputPathsConfig( @@ -102,6 +104,7 @@ class OutputPathsPerMode(_IterableMixin): external_confids_dist=Path("${test.dir}/external_confids_dist.npz"), input_imgs_plot=None, encoded_output=Path("${test.dir}/encoded_output.npz"), + encoded_train=Path("${test.dir}/train_features.npz"), attributions_output=Path("${test.dir}/attributions.csv"), ) analysis: Path = SI("${test.dir}") @@ -524,6 +527,7 @@ class TestConfig(_IterableMixin): external_confids_output_path: str = "external_confids.npz" output_precision: int = 16 selection_mode: Optional[str] = "max" + compute_train_encodings: bool = False @defer_validation diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index 2e10bcd..d9f3cab 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -24,6 +24,7 @@ class FDShiftsDataLoader(pl.LightningDataModule): def __init__(self, cf: configs.Config, no_norm_flag=False): super().__init__() + self.cf = cf self.crossval_ids_path = cf.exp.crossval_ids_path self.crossval_n_folds = cf.exp.crossval_n_folds self.fold = cf.exp.fold @@ -247,6 +248,13 @@ def setup(self, stage=None): self.test_datasets = [] + if self.cf.test.compute_train_encodings: + self.test_datasets.append(self.train_dataset) + logging.debug( + "Adding training data. (preliminary) len: %s", + len(self.test_datasets[-1]), + ) + if self.add_val_tuning: self.test_datasets.append(self.val_dataset) logging.debug( diff --git a/fd_shifts/models/callbacks/confid_monitor.py b/fd_shifts/models/callbacks/confid_monitor.py index 8acde26..90d42a0 100644 --- a/fd_shifts/models/callbacks/confid_monitor.py +++ b/fd_shifts/models/callbacks/confid_monitor.py @@ -7,7 +7,7 @@ from rich import print from tqdm import tqdm -from fd_shifts import configs +from fd_shifts import configs, logger from fd_shifts.analysis import eval_utils DTYPES = { @@ -70,6 +70,8 @@ def __init__(self, cf: configs.Config): self.output_paths = cf.exp.output_paths self.version_dir = cf.exp.version_dir self.val_every_n_epoch = cf.trainer.val_every_n_epoch + self.running_test_train_encoded = [] + self.running_test_train_labels = [] self.running_test_encoded = [] self.running_test_softmax = [] self.running_test_softmax_dist = [] @@ -476,9 +478,20 @@ def on_train_end(self, trainer, pl_module): def on_test_batch_end( self, trainer, pl_module, outputs, batch, batch_idx, dataloader_idx ): - if not hasattr(pl_module, "test_results"): + if not isinstance(outputs, dict): + return + + if self.cfg.test.compute_train_encodings and dataloader_idx == 0: + if outputs["encoded"] is not None: + self.running_test_train_encoded.extend( + outputs["encoded"].to(dtype=torch.float16).cpu() + ) + self.running_test_train_labels.extend(outputs["labels"].cpu()) return - outputs = pl_module.test_results + + if self.cfg.test.compute_train_encodings: + dataloader_idx -= 1 + if outputs["encoded"] is not None: self.running_test_encoded.extend( outputs["encoded"].to(dtype=torch.float16).cpu() @@ -501,6 +514,7 @@ def on_test_batch_end( ) def on_test_end(self, trainer, pl_module): + logger.info("Saving test outputs to disk") if not hasattr(pl_module, "test_results"): return @@ -529,6 +543,22 @@ def on_test_end(self, trainer, pl_module): np.savez_compressed( self.output_paths.test.encoded_output, encoded_output.cpu().data.numpy() ) + if len(self.running_test_train_encoded) > 0: + stacked_train_encoded = torch.stack(self.running_test_train_encoded, dim=0) + stacked_train_labels = torch.stack( + self.running_test_train_labels, dim=0 + ).unsqueeze(1) + encoded_train_output = torch.cat( + [ + stacked_train_encoded, + stacked_train_labels, + ], + dim=1, + ) + np.savez_compressed( + self.output_paths.test.encoded_train, + encoded_train_output.cpu().data.numpy(), + ) # try: # trainer.datamodule.test_datasets[0].csv.to_csv( # self.output_paths.test.attributions_output @@ -538,14 +568,13 @@ def on_test_end(self, trainer, pl_module): test_ds.csv.to_csv( f"{self.output_paths.test.attributions_output[:-4]}{ds_idx}.csv" ) - except: pass np.savez_compressed( self.output_paths.test.raw_output, raw_output.cpu().data.numpy() ) - tqdm.write( - "saved raw test outputs to {}".format(self.output_paths.test.raw_output) + logger.info( + "Saved raw test outputs to {}".format(self.output_paths.test.raw_output) ) if len(self.running_test_softmax_dist) > 0: diff --git a/fd_shifts/models/confidnet_model.py b/fd_shifts/models/confidnet_model.py index d1910b0..87dad61 100644 --- a/fd_shifts/models/confidnet_model.py +++ b/fd_shifts/models/confidnet_model.py @@ -256,7 +256,7 @@ def test_step( batch: tuple[torch.Tensor, torch.Tensor], batch_idx: int, dataloader_id: int | None = None, - ) -> None: + ) -> dict[str, torch.Tensor | None]: x, y = batch z = self.backbone.forward_features(x) @@ -272,7 +272,7 @@ def test_step( x=x, n_samples=self.test_mcd_samples ) - self.test_results = { + return { "logits": logits, "logits_dist": logits_dist, "labels": y, diff --git a/fd_shifts/models/devries_model.py b/fd_shifts/models/devries_model.py index f887e7e..7c8c73c 100644 --- a/fd_shifts/models/devries_model.py +++ b/fd_shifts/models/devries_model.py @@ -302,7 +302,7 @@ def test_step(self, batch, batch_idx, *args): x=x, n_samples=self.test_mcd_samples ) - self.test_results = { + return { "logits": logits, "labels": y, "confid": confidence, diff --git a/fd_shifts/models/vit_model.py b/fd_shifts/models/vit_model.py index a01678f..631888b 100644 --- a/fd_shifts/models/vit_model.py +++ b/fd_shifts/models/vit_model.py @@ -213,7 +213,7 @@ def test_step(self, batch, batch_idx, *args): x=x, n_samples=self.test_mcd_samples ) - self.test_results = { + return { "logits": probs, "labels": y, "confid": maha, From 36611b5c0fadbad94695e9589311194a5466da83 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 20 Feb 2024 19:05:05 +0100 Subject: [PATCH 089/136] feat: subsample corruption dataset --- fd_shifts/configs/__init__.py | 1 + fd_shifts/loaders/dataset_collection.py | 55 +++++++++++++++++++++++++ 2 files changed, 56 insertions(+) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 390d719..0d7f3c1 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -544,6 +544,7 @@ class DataConfig(_IterableMixin): reproduce_confidnet_splits: bool = False augmentations: dict[str, dict[str, Any]] | None = None target_transforms: Optional[Any] = None + subsample_corruptions: int = 10 kwargs: Optional[dict[Any, Any]] = None diff --git a/fd_shifts/loaders/dataset_collection.py b/fd_shifts/loaders/dataset_collection.py index 1114545..c2808c6 100644 --- a/fd_shifts/loaders/dataset_collection.py +++ b/fd_shifts/loaders/dataset_collection.py @@ -29,6 +29,7 @@ from fd_shifts import logger from fd_shifts.analysis import eval_utils +from fd_shifts.configs import Config, DataConfig from fd_shifts.data import SVHN from fd_shifts.loaders import breeds_hierarchies @@ -802,6 +803,7 @@ def __init__( download: bool, transform: Optional[Callable] = None, target_transform: Optional[Callable] = None, + subsample: int = 1, kwargs: Optional[Callable] = None, ) -> None: super(CorruptCIFAR, self).__init__( @@ -840,8 +842,43 @@ def __init__( self.targets.extend(labels) self.data = np.vstack(self.data) + self.targets = np.array(self.targets) + + if subsample > 1: + self.data, self.targets = self.subsample(self.data, self.targets, subsample) self.classes = eval_utils.cifar100_classes + @staticmethod + def subsample(data, targets, subsample): + n_classes = len(np.unique(targets)) + n_cor_kinds = 15 + n_cor_levels = 5 + n_samples_per_cor = len(targets) // n_cor_kinds // n_cor_levels + n_samples_per_class_per_cor = n_samples_per_cor // n_classes + + single_targets = targets[:n_samples_per_cor] + + sort_idx = np.argsort(single_targets, kind="stable") + single_idx = np.sort( + np.concatenate( + [ + i * n_samples_per_class_per_cor + + np.arange(n_samples_per_class_per_cor // subsample) + for i in range(n_classes) + ] + ) + ) + idx = np.concatenate( + [ + cor_kind_idx * n_samples_per_cor * n_cor_levels + + cor_level_idx * n_samples_per_cor + + single_idx + for cor_kind_idx in range(n_cor_kinds) + for cor_level_idx in range(n_cor_levels) + ] + ) + return data[idx, :], targets[idx] + def __getitem__(self, index: int) -> Tuple[Any, Any]: """ Args: @@ -963,6 +1000,15 @@ def __init__(self, root, train, download, transform): ) logger.debug("CHECK ROOT !!! {}", root) + if isinstance(root, str): + root = Path(root) + categories = { + r[1]: r[2] + for r in pd.read_csv(root / "iwildcam_v2.0" / "categories.csv")[ + ["y", "name"] + ].to_records() + } + self.classes = [categories[i] for i in range(self.n_classes)] def get_subset(self, split, frac=1.0, transform=None): """ @@ -1245,6 +1291,7 @@ def get_dataset( transform: Callable, target_transform: Callable | None, kwargs: dict[str, Any], + config: DataConfig | None = None, ) -> Any: """Return a new instance of a dataset @@ -1266,6 +1313,14 @@ def get_dataset( "download": download, "transform": transform, } + if name.startswith("corrupt_cifar"): + pass_kwargs = { + "root": root, + "train": train, + "download": download, + "transform": transform, + "subsample": config.subsample_corruptions if config else 1, + } if name.startswith("svhn"): pass_kwargs = { "root": root, From 6404c3a5f27848684386af24a21683a2ade23734 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 20 Feb 2024 19:10:08 +0100 Subject: [PATCH 090/136] feat: write config file only if not exists or overwrite --- fd_shifts/main.py | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 35c880c..84c0456 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -559,13 +559,14 @@ def main(): rich.print(config) # TODO: Check if configs are the same - config.test.cf_path.parent.mkdir(parents=True, exist_ok=True) - subparsers[args.command].save( - args[args.command], - config.test.cf_path, - skip_check=True, - overwrite=args.overwrite_config_file, - ) + if not config.test.cf_path.is_file() or args.overwrite_config_file: + config.test.cf_path.parent.mkdir(parents=True, exist_ok=True) + subparsers[args.command].save( + args[args.command], + config.test.cf_path, + skip_check=True, + overwrite=args.overwrite_config_file, + ) __subcommands[args.command](config=config) From 7a57882503d458089b06112adff2466c363a7112 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 10:49:13 +0100 Subject: [PATCH 091/136] fix: some fixes for noise study handling --- fd_shifts/analysis/__init__.py | 20 ++++--- fd_shifts/analysis/studies.py | 38 +++++++++++++- fd_shifts/loaders/data_loader.py | 16 +++--- fd_shifts/main.py | 90 ++++++++++++++++++++++---------- 4 files changed, 119 insertions(+), 45 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 631c9d9..bd70921 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -192,7 +192,12 @@ def dataset_name_to_idx(self, dataset_name: str) -> int: if isinstance(datasets[0], configs.DataConfig): datasets = map(lambda d: d.dataset, datasets) flat_test_set_list.extend(list(datasets)) - else: + elif ( + isinstance(datasets, configs.DataConfig) + and datasets.dataset is not None + ): + flat_test_set_list.append(datasets.dataset) + elif isinstance(datasets, str): flat_test_set_list.append(datasets) logger.error(f"{flat_test_set_list=}") @@ -398,12 +403,7 @@ def _react( import torch logger.info("Compute REACT logits") - logger.warning( - "Currently uses validation set for clip parameter fit, will switch to training set in the future" - ) - # mask = np.argwhere(dataset_idx == val_set_index)[:, 0] - # val_features = features[mask] clip = torch.tensor(np.quantile(train_features[:, :-1], clip_quantile / 100)) w, b = last_layer @@ -426,13 +426,11 @@ def _maha_dist( labels: npt.NDArray[np.int_], predicted: npt.NDArray[np.int_], dataset_idx: npt.NDArray[np.int_], - val_set_index=0, ): import torch logger.info("Compute Mahalanobis distance") - # mask = np.argwhere(dataset_idx == val_set_index)[:, 0] val_features = train_features[:, :-1] val_labels = train_features[:, -1] @@ -621,6 +619,12 @@ def __init__( self.query_studies.__dict__[study_name] = list( map(lambda d: d.dataset, datasets) ) + if isinstance(datasets, configs.DataConfig): + if datasets.dataset is not None: + self.query_studies.__dict__[study_name] = [datasets.dataset] + else: + self.query_studies.__dict__[study_name] = [] + self.analysis_out_dir = analysis_out_dir self.calibration_bins = 20 self.val_risk_scores = {} diff --git a/fd_shifts/analysis/studies.py b/fd_shifts/analysis/studies.py index e3940d0..3a7f8c8 100644 --- a/fd_shifts/analysis/studies.py +++ b/fd_shifts/analysis/studies.py @@ -1,7 +1,7 @@ from __future__ import annotations from copy import deepcopy -from typing import TYPE_CHECKING, Any, Callable, Iterator, Tuple +from typing import TYPE_CHECKING, Any, Callable, Iterator, Tuple, overload import numpy as np import numpy.typing as npt @@ -385,7 +385,21 @@ def __filter_intensity_3d(data, mask, noise_level): :, noise_level ].reshape(-1, data.shape[-2], data.shape[-1]) - def __filter_intensity_2d(data, mask, noise_level): + @overload + def __filter_intensity_2d( + data: npt.NDArray[Any], mask: npt.NDArray[Any], noise_level: int + ) -> npt.NDArray[Any]: + ... + + @overload + def __filter_intensity_2d( + data: None, mask: npt.NDArray[Any], noise_level: int + ) -> None: + ... + + def __filter_intensity_2d( + data: npt.NDArray[Any] | None, mask: npt.NDArray[Any], noise_level: int + ) -> npt.NDArray[Any] | None: if data is None: return None @@ -398,6 +412,18 @@ def __filter_intensity_2d(data, mask, noise_level): -1, data.shape[-1] ) + @overload + def __filter_intensity_1d( + data: npt.NDArray[Any], mask: npt.NDArray[Any], noise_level: int + ) -> npt.NDArray[Any]: + ... + + @overload + def __filter_intensity_1d( + data: None, mask: npt.NDArray[Any], noise_level: int + ) -> None: + ... + def __filter_intensity_1d(data, mask, noise_level): if data is None: return None @@ -429,6 +455,14 @@ def __filter_intensity_1d(data, mask, noise_level): data.mcd_logits_dist, select_ix, noise_level ), config=data.config, + _correct=__filter_intensity_1d(data._correct, select_ix, noise_level), + _mcd_correct=__filter_intensity_1d(data._mcd_correct, select_ix, noise_level), + _mcd_labels=__filter_intensity_1d(data._mcd_labels, select_ix, noise_level), + _react_logits=__filter_intensity_2d(data._react_logits, select_ix, noise_level), + _maha_dist=__filter_intensity_1d(data._maha_dist, select_ix, noise_level), + _vim_score=__filter_intensity_1d(data._vim_score, select_ix, noise_level), + _dknn_dist=__filter_intensity_1d(data._dknn_dist, select_ix, noise_level), + _train_features=data._train_features, ) diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index d9f3cab..41f0844 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -51,13 +51,15 @@ def __init__(self, cf: configs.Config, no_norm_flag=False): if self.query_studies is not None: self.external_test_sets = [] for key, values in self.query_studies: - if key != "iid_study" and values is not None: - if key == "noise_study" and values.dataset is not None: - self.external_test_sets.append(values) - else: - self.external_test_sets.extend(list(values)) - logging.debug( - "CHECK flat list of external datasets %s", self.external_test_sets + if ( + isinstance(values, configs.DataConfig) + and values.dataset is not None + ): + self.external_test_sets.append(values) + elif isinstance(values, list): + self.external_test_sets.extend(list(values)) + logger.debug( + f"CHECK flat list of external datasets {self.external_test_sets}" ) if len(self.external_test_sets) > 0: diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 84c0456..01abe7f 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -17,7 +17,7 @@ from omegaconf import OmegaConf from rich.pretty import pretty_repr -from fd_shifts.configs import Config +from fd_shifts.configs import Config, DataConfig, OutputPathsPerMode __subcommands = {} @@ -175,7 +175,9 @@ def apply_config(parser, cfg, dest, value, option_string) -> None: pass elif k == "noise_study": if len(v) == 0: - cfg_file["config"]["eval"]["query_studies"][k] = None + cfg_file["config"]["eval"]["query_studies"][k] = asdict( + DataConfig() + ) elif len(v) == 1: cfg_file["config"]["eval"]["query_studies"][k] = asdict( get_dataset_config(v[0]) @@ -200,6 +202,26 @@ def apply_config(parser, cfg, dest, value, option_string) -> None: if cfg_file["config"]["exp"]["work_dir"] == "${hydra:runtime.cwd}": cfg_file["config"]["exp"]["work_dir"] = Path.cwd() + # some paths could previously be none + if ( + cfg_file["config"]["exp"]["output_paths"]["fit"].get( + "encoded_output", "" + ) + is None + ): + cfg_file["config"]["exp"]["output_paths"]["fit"][ + "encoded_output" + ] = OutputPathsPerMode().fit.encoded_output + if ( + cfg_file["config"]["exp"]["output_paths"]["fit"].get( + "attributions_output", "" + ) + is None + ): + cfg_file["config"]["exp"]["output_paths"]["fit"][ + "attributions_output" + ] = OutputPathsPerMode().fit.attributions_output + # resolve everything else oc_config = OmegaConf.create(cfg_file["config"]) dict_config: dict[str, Any] = OmegaConf.to_object(oc_config) # type: ignore @@ -241,34 +263,46 @@ def __path_to_str(cfg): def _dict_to_dataclass(cfg) -> Config: - def __dict_to_dataclass(cfg, cls): - if is_dataclass(cls): - fieldtypes = typing.get_type_hints(cls) - return cls( - **{k: __dict_to_dataclass(v, fieldtypes[k]) for k, v in cfg.items()} - ) - if ( - isinstance(cls, types.UnionType) - and len(cls.__args__) == 2 - and cls.__args__[1] == type(None) - and is_dataclass(cls.__args__[0]) - and isinstance(cfg, dict) - ): - fieldtypes = typing.get_type_hints(cls.__args__[0]) - return cls.__args__[0]( - **{k: __dict_to_dataclass(v, fieldtypes[k]) for k, v in cfg.items()} - ) - if typing.get_origin(cls) == list: - return [__dict_to_dataclass(v, typing.get_args(cls)[0]) for v in cfg] - if cls == Path or ( - isinstance(cls, types.UnionType) - and Path in cls.__args__ - and cfg is not None - ): - return Path(cfg) + def __dict_to_dataclass(cfg, cls, key): + try: + if is_dataclass(cls): + fieldtypes = typing.get_type_hints(cls) + return cls( + **{ + k: __dict_to_dataclass(v, fieldtypes[k], k) + for k, v in cfg.items() + } + ) + if ( + isinstance(cls, types.UnionType) + and len(cls.__args__) == 2 + and cls.__args__[1] == type(None) + and is_dataclass(cls.__args__[0]) + and isinstance(cfg, dict) + ): + fieldtypes = typing.get_type_hints(cls.__args__[0]) + return cls.__args__[0]( + **{ + k: __dict_to_dataclass(v, fieldtypes[k], k) + for k, v in cfg.items() + } + ) + if typing.get_origin(cls) == list: + return [ + __dict_to_dataclass(v, typing.get_args(cls)[0], key) for v in cfg + ] + if cls == Path or ( + isinstance(cls, types.UnionType) + and Path in cls.__args__ + and cfg is not None + ): + return Path(cfg) + except: + print(key) + raise return cfg - return __dict_to_dataclass(cfg, Config) # type: ignore + return __dict_to_dataclass(cfg, Config, "") # type: ignore def omegaconf_resolve(config: Config): From 184083e3b5b783ce93bff07dcf2d64550e251bd8 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 10:50:19 +0100 Subject: [PATCH 092/136] feat: add super_cifar configs --- fd_shifts/experiments/configs.py | 88 +++++++++++++++++++++++++------- 1 file changed, 69 insertions(+), 19 deletions(-) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index ec2d89c..f82514d 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -59,8 +59,6 @@ def svhn_query_config( return QueryStudiesConfig( iid_study="svhn" + ("_384" if img_size[0] == 384 else ""), - noise_study=[], - in_class_study=[], new_class_study=[ cifar10_data_config(img_size=img_size), cifar100_data_config(img_size=img_size), @@ -120,10 +118,7 @@ def cifar10_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: return QueryStudiesConfig( iid_study="cifar10" + ("_384" if img_size[0] == 384 else ""), - noise_study=[ - cifar10_data_config("corrupt_cifar10", img_size), - ], - in_class_study=[], + noise_study=cifar10_data_config("corrupt_cifar10", img_size), new_class_study=[ cifar100_data_config(img_size=img_size), svhn_data_config("svhn", img_size), @@ -133,7 +128,7 @@ def cifar10_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: def cifar100_data_config( - dataset: Literal["cifar100", "corrupt_cifar100"] = "cifar100", + dataset: Literal["cifar100", "corrupt_cifar100", "super_cifar100"] = "cifar100", img_size: int | tuple[int, int] = 32, ) -> DataConfig: if isinstance(img_size, int): @@ -158,11 +153,14 @@ def cifar100_data_config( return DataConfig( dataset=dataset, - data_dir=SI("${oc.env:DATASET_ROOT_DIR}/" + dataset), + data_dir=SI( + "${oc.env:DATASET_ROOT_DIR}/" + + ("cifar100" if dataset in ["cifar100", "super_cifar100"] else dataset) + ), pin_memory=True, img_size=(img_size[0], img_size[1], 3), num_workers=12, - num_classes=100, + num_classes=19 if dataset == "super_cifar100" else 100, reproduce_confidnet_splits=True, augmentations={ "train": train_augmentations, @@ -174,21 +172,26 @@ def cifar100_data_config( ) -def cifar100_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: +def cifar100_query_config( + img_size: int | tuple[int, int], + dataset: Literal["cifar100", "super_cifar100"] = "cifar100", +) -> QueryStudiesConfig: if isinstance(img_size, int): img_size = (img_size, img_size) return QueryStudiesConfig( - iid_study="cifar100" + ("_384" if img_size[0] == 384 else ""), - noise_study=[ - cifar100_data_config("corrupt_cifar100", img_size), - ], + iid_study=dataset + ("_384" if img_size[0] == 384 else ""), + noise_study=cifar100_data_config("corrupt_cifar100", img_size) + if dataset == "cifar100" + else DataConfig(), in_class_study=[], new_class_study=[ cifar10_data_config(img_size=img_size), svhn_data_config("svhn", img_size), tinyimagenet_data_config(img_size), - ], + ] + if dataset == "cifar100" + else [], ) @@ -234,7 +237,6 @@ def wilds_animals_query_config( return QueryStudiesConfig( iid_study="wilds_animals" + ("_384" if img_size[0] == 384 else ""), - noise_study=[], in_class_study=[wilds_animals_data_config("wilds_animals_ood_test", img_size)], new_class_study=[], ) @@ -284,7 +286,6 @@ def wilds_camelyon_query_config( return QueryStudiesConfig( iid_study="wilds_camelyon" + ("_384" if img_size[0] == 384 else ""), - noise_study=[], in_class_study=[ wilds_camelyon_data_config("wilds_camelyon_ood_test", img_size) ], @@ -335,9 +336,7 @@ def breeds_query_config(img_size: int | tuple[int, int] = 224) -> QueryStudiesCo return QueryStudiesConfig( iid_study="breeds" + ("_384" if img_size[0] == 384 else ""), - noise_study=[], in_class_study=[breeds_data_config("breeds_ood_test", img_size)], - new_class_study=[], ) @@ -378,6 +377,8 @@ def tinyimagenet_data_config(img_size: int | tuple[int, int] = 64) -> DataConfig "cifar10_384": cifar10_data_config(img_size=384), "cifar100": cifar100_data_config(), "cifar100_384": cifar100_data_config(img_size=384), + "super_cifar100": cifar100_data_config(dataset="super_cifar100"), + "super_cifar100_384": cifar100_data_config(img_size=384, dataset="super_cifar100"), "corrupt_cifar10": cifar10_data_config(dataset="corrupt_cifar10"), "corrupt_cifar10_384": cifar10_data_config(dataset="corrupt_cifar10", img_size=384), "corrupt_cifar100": cifar100_data_config(dataset="corrupt_cifar100"), @@ -726,6 +727,36 @@ def cnn_cifar100_modeldg(run: int, do: int, rew: float): return config +def cnn_super_cifar100_modelconfidnet(run: int, do: int, **kwargs): + config = cnn_cifar100_modelconfidnet(run, do, **kwargs) + config.exp.group_name = "supercifar_paper_sweep" + config.data = cifar100_data_config(dataset="super_cifar100", img_size=32) + config.eval.query_studies = cifar100_query_config( + dataset="super_cifar100", img_size=32 + ) + return config + + +def cnn_super_cifar100_modeldevries(run: int, do: int, **kwargs): + config = cnn_cifar100_modeldevries(run, do, **kwargs) + config.exp.group_name = "supercifar_paper_sweep" + config.data = cifar100_data_config(dataset="super_cifar100", img_size=32) + config.eval.query_studies = cifar100_query_config( + dataset="super_cifar100", img_size=32 + ) + return config + + +def cnn_super_cifar100_modeldg(run: int, do: int, rew: float): + config = cnn_cifar100_modeldg(run, do, rew) + config.exp.group_name = "supercifar_paper_sweep" + config.data = cifar100_data_config(dataset="super_cifar100", img_size=32) + config.eval.query_studies = cifar100_query_config( + dataset="super_cifar100", img_size=32 + ) + return config + + def cnn_breeds(name: str): config = cnn("breeds_paper_sweep", name=name) config.data = breeds_data_config() @@ -1152,6 +1183,25 @@ def register(config_fn: Callable[..., Config], n_runs: int = 5, **kwargs): register(cnn_cifar100_modeldg, do=0, rew=20) register(cnn_cifar100_modeldg, do=1, rew=20) +register(cnn_super_cifar100_modeldevries, do=0) +register(cnn_super_cifar100_modeldevries, do=1) +register(cnn_super_cifar100_modelconfidnet, do=0) +register(cnn_super_cifar100_modelconfidnet, do=1) +register(cnn_super_cifar100_modeldg, do=0, rew=2.2) +register(cnn_super_cifar100_modeldg, do=1, rew=2.2) +register(cnn_super_cifar100_modeldg, do=0, rew=3) +register(cnn_super_cifar100_modeldg, do=1, rew=3) +register(cnn_super_cifar100_modeldg, do=0, rew=6) +register(cnn_super_cifar100_modeldg, do=1, rew=6) +register(cnn_super_cifar100_modeldg, do=0, rew=10) +register(cnn_super_cifar100_modeldg, do=1, rew=10) +register(cnn_super_cifar100_modeldg, do=0, rew=12) +register(cnn_super_cifar100_modeldg, do=1, rew=12) +register(cnn_super_cifar100_modeldg, do=0, rew=15) +register(cnn_super_cifar100_modeldg, do=1, rew=15) +register(cnn_super_cifar100_modeldg, do=0, rew=20) +register(cnn_super_cifar100_modeldg, do=1, rew=20) + register(cnn_animals_modeldevries, do=0) register(cnn_animals_modeldevries, do=1) register(cnn_animals_modelconfidnet, do=0) From 2d33c956bb2553425a2f6efab84eeddbea9abda3 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 10:51:51 +0100 Subject: [PATCH 093/136] fix: write out last_layer, fix vim --- fd_shifts/analysis/__init__.py | 10 ++++++-- fd_shifts/models/callbacks/confid_monitor.py | 7 ++++-- fd_shifts/models/confidnet_model.py | 22 ++++++++++++++++- fd_shifts/models/devries_model.py | 26 ++++++++++++++++++-- 4 files changed, 58 insertions(+), 7 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index bd70921..84c68b2 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -459,7 +459,13 @@ def _vim( import torch logger.info("Compute ViM score") - D = 512 + if features.shape[-1] >= 2048: + D = 1000 + elif features.shape[-1] >= 768: + D = 512 + else: + D = features.shape[-1] // 2 + w, b = last_layer w = torch.tensor(w, dtype=torch.float) b = torch.tensor(b, dtype=torch.float) @@ -596,7 +602,7 @@ def __init__( ): self.method_dict["query_confids"].append("maha") self.method_dict["query_confids"].append("dknn") - # self.method_dict["query_confids"].append("vim") + self.method_dict["query_confids"].append("vim") self.method_dict["query_confids"].append("react_det_mcp") self.method_dict["query_confids"].append("react_det_mls") self.method_dict["query_confids"].append("react_temp_mls") diff --git a/fd_shifts/models/callbacks/confid_monitor.py b/fd_shifts/models/callbacks/confid_monitor.py index 90d42a0..dcc86f5 100644 --- a/fd_shifts/models/callbacks/confid_monitor.py +++ b/fd_shifts/models/callbacks/confid_monitor.py @@ -515,8 +515,6 @@ def on_test_batch_end( def on_test_end(self, trainer, pl_module): logger.info("Saving test outputs to disk") - if not hasattr(pl_module, "test_results"): - return stacked_softmax = torch.stack(self.running_test_softmax, dim=0) stacked_labels = torch.stack(self.running_test_labels, dim=0).unsqueeze(1) @@ -559,6 +557,11 @@ def on_test_end(self, trainer, pl_module): self.output_paths.test.encoded_train, encoded_train_output.cpu().data.numpy(), ) + w, b = pl_module.last_layer() + w = w.cpu().numpy() + b = b.cpu().numpy() + np.savez_compressed(self.cfg.test.dir / "last_layer.npz", w=w, b=b) + # try: # trainer.datamodule.test_datasets[0].csv.to_csv( # self.output_paths.test.attributions_output diff --git a/fd_shifts/models/confidnet_model.py b/fd_shifts/models/confidnet_model.py index 87dad61..620155e 100644 --- a/fd_shifts/models/confidnet_model.py +++ b/fd_shifts/models/confidnet_model.py @@ -267,7 +267,9 @@ def test_step( logits_dist = None pred_confid_dist = None - if any("mcd" in cfd for cfd in self.query_confids.test): + if any("mcd" in cfd for cfd in self.query_confids.test) and ( + not (self.conf.test.compute_train_encodings and dataloader_id == 0) + ): logits_dist, pred_confid_dist = self.mcd_eval_forward( x=x, n_samples=self.test_mcd_samples ) @@ -330,3 +332,21 @@ def load_only_state_dict(self, path: str | Path) -> None: logger.info("loading checkpoint from epoch {}".format(ckpt["epoch"])) self.load_state_dict(ckpt["state_dict"], strict=False) + + def last_layer(self): + state = self.state_dict() + model_prefix = "backbone" + if f"{model_prefix}._classifier.module.weight" in state: + w = state[f"{model_prefix}._classifier.module.weight"] + b = state[f"{model_prefix}._classifier.module.bias"] + elif f"{model_prefix}._classifier.fc.weight" in state: + w = state[f"{model_prefix}._classifier.fc.weight"] + b = state[f"{model_prefix}._classifier.fc.bias"] + elif f"{model_prefix}._classifier.fc2.weight" in state: + w = state[f"{model_prefix}._classifier.fc2.weight"] + b = state[f"{model_prefix}._classifier.fc2.bias"] + else: + print(list(state.keys())) + raise RuntimeError("No classifier weights found") + + return w, b diff --git a/fd_shifts/models/devries_model.py b/fd_shifts/models/devries_model.py index 7c8c73c..075e3d6 100644 --- a/fd_shifts/models/devries_model.py +++ b/fd_shifts/models/devries_model.py @@ -47,6 +47,8 @@ def __init__(self, cf: configs.Config): self.save_hyperparameters(to_dict(cf)) + self.cf = cf + self.optimizer_cfgs = cf.trainer.optimizer self.lr_scheduler_cfgs = cf.trainer.lr_scheduler self.lr_scheduler_interval = cf.trainer.lr_scheduler_interval @@ -280,7 +282,7 @@ def validation_step(self, batch, batch_idx): def validation_step_end(self, batch_parts): return batch_parts - def test_step(self, batch, batch_idx, *args): + def test_step(self, batch, batch_idx, dataloader_idx, *args): x, y = batch z = self.model.forward_features(x) if self.ext_confid_name == "devries": @@ -297,7 +299,9 @@ def test_step(self, batch, batch_idx, *args): logits_dist = None confid_dist = None - if any("mcd" in cfd for cfd in self.query_confids.test): + if any("mcd" in cfd for cfd in self.query_confids.test) and ( + not (self.cf.test.compute_train_encodings and dataloader_idx == 0) + ): logits_dist, confid_dist = self.mcd_eval_forward( x=x, n_samples=self.test_mcd_samples ) @@ -366,3 +370,21 @@ def load_only_state_dict(self, path: str | Path) -> None: logger.info("loading checkpoint from epoch {}".format(ckpt["epoch"])) self.load_state_dict(ckpt["state_dict"], strict=True) + + def last_layer(self): + state = self.state_dict() + model_prefix = "model" + if f"{model_prefix}._classifier.module.weight" in state: + w = state[f"{model_prefix}._classifier.module.weight"] + b = state[f"{model_prefix}._classifier.module.bias"] + elif f"{model_prefix}._classifier.fc.weight" in state: + w = state[f"{model_prefix}._classifier.fc.weight"] + b = state[f"{model_prefix}._classifier.fc.bias"] + elif f"{model_prefix}._classifier.fc2.weight" in state: + w = state[f"{model_prefix}._classifier.fc2.weight"] + b = state[f"{model_prefix}._classifier.fc2.bias"] + else: + print(list(state.keys())) + raise RuntimeError("No classifier weights found") + + return w, b From 60a5e2711fcbc0d8a3f4cbca61de9a8f7de8f69c Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 10:52:50 +0100 Subject: [PATCH 094/136] feat: analysis load data from store path --- fd_shifts/analysis/__init__.py | 88 +++++++++++++++++++++++----------- 1 file changed, 60 insertions(+), 28 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 84c68b2..d28a8b0 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -4,7 +4,7 @@ from dataclasses import dataclass, field from numbers import Number from pathlib import Path -from typing import Any +from typing import Any, Literal, overload import faiss import numpy as np @@ -246,6 +246,39 @@ def __load_npz_if_exists(path: Path) -> npt.NDArray[np.float64] | None: with np.load(path) as npz: return npz.f.arr_0 + @overload + @staticmethod + def __load_from_store( + config: configs.Config, file: str + ) -> npt.NDArray[np.float64] | None: + ... + + @overload + @staticmethod + def __load_from_store( + config: configs.Config, file: str, unpack: Literal[False] + ) -> dict[str, npt.NDArray[np.float64]] | None: + ... + + @staticmethod + def __load_from_store( + config: configs.Config, file: str, unpack: bool = True + ) -> npt.NDArray[np.float64] | dict[str, npt.NDArray[np.float64]] | None: + store_paths = map(Path, os.getenv("FD_SHIFTS_STORE_PATH", "").split(":")) + + test_dir = config.test.dir.relative_to(os.getenv("EXPERIMENT_ROOT_DIR", "")) + + for store_path in store_paths: + if (store_path / test_dir / file).is_file(): + logger.debug(f"Loading {store_path / test_dir / file}") + with np.load(store_path / test_dir / file) as npz: + if unpack: + return npz.f.arr_0.astype(np.float64) + else: + return dict(npz.items()) + + return None + @staticmethod def from_experiment( test_dir: Path, @@ -255,10 +288,9 @@ def from_experiment( if not isinstance(test_dir, Path): test_dir = Path(test_dir) - if (test_dir / "raw_logits.npz").is_file(): - with np.load(test_dir / "raw_logits.npz") as npz: - raw_output = npz.f.arr_0.astype(np.float64) - + if ( + raw_output := ExperimentData.__load_from_store(config, "raw_logits.npz") + ) is not None: logits = raw_output[:, :-2] softmax = scpspecial.softmax(logits, axis=1) @@ -266,8 +298,8 @@ def from_experiment( "mcd" in confid for confid in config.eval.confidence_measures.test ) and ( ( - mcd_logits_dist := ExperimentData.__load_npz_if_exists( - test_dir / "raw_logits_dist.npz" + mcd_logits_dist := ExperimentData.__load_from_store( + config, "raw_logits_dist.npz" ) ) is not None @@ -277,15 +309,14 @@ def from_experiment( mcd_logits_dist = None mcd_softmax_dist = None - elif (test_dir / "raw_output.npz").is_file(): - with np.load(test_dir / "raw_output.npz") as npz: - raw_output = npz.f.arr_0 - + elif ( + raw_output := ExperimentData.__load_from_store(config, "raw_output.npz") + ) is not None: logits = None mcd_logits_dist = None softmax = raw_output[:, :-2] - mcd_softmax_dist = ExperimentData.__load_npz_if_exists( - test_dir / "raw_output_dist.npz" + mcd_softmax_dist = ExperimentData.__load_from_store( + config, "raw_output_dist.npz" ) else: raise FileNotFoundError(f"Could not find model output in {test_dir}") @@ -304,29 +335,30 @@ def from_experiment( mcd_logits_dist[:, holdout_classes, :] = -np.inf mcd_softmax_dist = scpspecial.softmax(mcd_logits_dist, axis=1) - external_confids = ExperimentData.__load_npz_if_exists( - test_dir / "external_confids.npz" + external_confids = ExperimentData.__load_from_store( + config, "external_confids.npz" ) if any("mcd" in confid for confid in config.eval.confidence_measures.test): - mcd_external_confids_dist = ExperimentData.__load_npz_if_exists( - test_dir / "external_confids_dist.npz" + mcd_external_confids_dist = ExperimentData.__load_from_store( + config, "external_confids_dist.npz" ) else: mcd_external_confids_dist = None if ( - features := ExperimentData.__load_npz_if_exists( - test_dir / "encoded_output.npz" - ) + features := ExperimentData.__load_from_store(config, "encoded_output.npz") ) is not None: features = features[:, :-1] - last_layer: tuple[npt.NDArray[np.float_], npt.NDArray[np.float_]] | None = None - if (test_dir / "last_layer.npz").is_file(): - last_layer = tuple(np.load(test_dir / "last_layer.npz").values()) # type: ignore - train_features = None - if (test_dir / "train_features.npz").is_file(): - with np.load(test_dir / "train_features.npz") as npz: - train_features = npz.f.arr_0 + + if ( + last_layer := ExperimentData.__load_from_store( + config, "last_layer.npz", unpack=False + ) + ) is not None: + last_layer = tuple(last_layer.values()) + + train_features = ExperimentData.__load_from_store(config, "train_features.npz") + return ExperimentData( softmax_output=softmax, logits=logits, @@ -339,7 +371,7 @@ def from_experiment( config=config, _features=features, _train_features=train_features, - _last_layer=last_layer, + _last_layer=last_layer, # type: ignore ) From 7b3ca0d01fb85125ec14a4f1fe791293dc806428 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 16:23:02 +0100 Subject: [PATCH 095/136] fix: subsample mcd results that are already done --- fd_shifts/analysis/__init__.py | 52 +++++++++++++++++++++++++ fd_shifts/loaders/dataset_collection.py | 7 +++- 2 files changed, 58 insertions(+), 1 deletion(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index d28a8b0..caf7fa5 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -17,6 +17,7 @@ from sklearn.calibration import _sigmoid_calibration as calib from fd_shifts import configs +from fd_shifts.loaders.dataset_collection import CorruptCIFAR from .confid_scores import ConfidScore, SecondaryConfidScore, is_external_confid from .eval_utils import ( @@ -304,6 +305,30 @@ def from_experiment( ) is not None ): + if mcd_logits_dist.shape[0] > logits.shape[0]: + dset = CorruptCIFAR( + config.eval.query_studies.noise_study.data_dir, + train=False, + download=False, + ) + idx = ( + CorruptCIFAR.subsample_idx( + dset.data, + dset.targets, + config.eval.query_studies.noise_study.subsample_corruptions, + ) + + raw_output[raw_output[:, -1] < 2].shape[0] + ) + idx = np.concatenate( + [ + np.argwhere(raw_output[:, -1] < 2).flatten(), + idx, + np.argwhere(raw_output[:, -1] > 2).flatten() + + mcd_logits_dist.shape[0] + - raw_output.shape[0], + ] + ) + mcd_logits_dist = mcd_logits_dist[idx] mcd_softmax_dist = scpspecial.softmax(mcd_logits_dist, axis=1) else: mcd_logits_dist = None @@ -342,6 +367,33 @@ def from_experiment( mcd_external_confids_dist = ExperimentData.__load_from_store( config, "external_confids_dist.npz" ) + if ( + mcd_external_confids_dist is not None + and mcd_external_confids_dist.shape[0] > logits.shape[0] + ): + dset = CorruptCIFAR( + config.eval.query_studies.noise_study.data_dir, + train=False, + download=False, + ) + idx = ( + CorruptCIFAR.subsample_idx( + dset.data, + dset.targets, + config.eval.query_studies.noise_study.subsample_corruptions, + ) + + raw_output[raw_output[:, -1] < 2].shape[0] + ) + idx = np.concatenate( + [ + np.argwhere(raw_output[:, -1] < 2).flatten(), + idx, + np.argwhere(raw_output[:, -1] > 2).flatten() + + mcd_logits_dist.shape[0] + - raw_output.shape[0], + ] + ) + mcd_external_confids_dist = mcd_external_confids_dist[idx] else: mcd_external_confids_dist = None diff --git a/fd_shifts/loaders/dataset_collection.py b/fd_shifts/loaders/dataset_collection.py index c2808c6..54de4d6 100644 --- a/fd_shifts/loaders/dataset_collection.py +++ b/fd_shifts/loaders/dataset_collection.py @@ -849,7 +849,7 @@ def __init__( self.classes = eval_utils.cifar100_classes @staticmethod - def subsample(data, targets, subsample): + def subsample_idx(data, targets, subsample): n_classes = len(np.unique(targets)) n_cor_kinds = 15 n_cor_levels = 5 @@ -877,6 +877,11 @@ def subsample(data, targets, subsample): for cor_level_idx in range(n_cor_levels) ] ) + return idx + + @staticmethod + def subsample(data, targets, subsample): + idx = CorruptCIFAR.subsample_idx(data, targets, subsample) return data[idx, :], targets[idx] def __getitem__(self, index: int) -> Tuple[Any, Any]: From f6d2a26eb1b8959751daf82e38fd202c13b740d1 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 16:23:31 +0100 Subject: [PATCH 096/136] fix(analysis): handle dg class in new confids --- fd_shifts/analysis/__init__.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index caf7fa5..ebf80fd 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -483,6 +483,7 @@ def _react( dataset_idx: npt.NDArray[np.integer], clip_quantile=99, val_set_index=0, + is_dg=False, ): import torch @@ -501,6 +502,8 @@ def _react( ) + b ) + if is_dg: + logits = logits[:, :-1] return logits.numpy() @@ -539,6 +542,7 @@ def _vim( train_features: npt.NDArray[np.float_] | None, features: npt.NDArray[np.float_], logits: npt.NDArray[np.float_], + is_dg=False, ): import torch @@ -556,7 +560,7 @@ def _vim( logger.debug("ViM: Compute NS") u = -torch.pinverse(w) @ b - train_f = torch.tensor(train_features[:1000, :-1], dtype=torch.float) + train_f = torch.tensor(train_features[:, :-1], dtype=torch.float) cov = torch.cov((train_f - u).T) eig_vals, eigen_vectors = torch.linalg.eig(cov) eig_vals = eig_vals.real @@ -566,6 +570,9 @@ def _vim( logger.debug("ViM: Compute alpha") logit_train = torch.matmul(train_f, w.T) + b + if is_dg: + logit_train = logit_train[:, :-1] + vlogit_train = torch.linalg.norm(torch.matmul(train_f - u, NS), dim=-1) alpha = logit_train.max(dim=-1)[0].mean() / vlogit_train.mean() From 1af74821bfb979b75fea2eccc3697e130f4351ea Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 4 Jun 2024 17:19:12 +0200 Subject: [PATCH 097/136] feat(main): add shell tab completion --- fd_shifts/main.py | 13 ++++++++++--- pyproject.toml | 2 ++ 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 01abe7f..ad6811e 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -11,6 +11,7 @@ import jsonargparse import rich +import shtab import yaml from jsonargparse import ActionConfigFile, ArgumentParser from jsonargparse._actions import Action @@ -542,15 +543,15 @@ def debug(config: Config): def _list_experiments(): from fd_shifts.experiments.configs import list_experiment_configs - rich.print("Available experiments:") for exp in sorted(list_experiment_configs()): - rich.print(exp) + print(exp) def get_parser(): from fd_shifts import get_version parser = ArgumentParser(version=get_version()) + shtab.add_argument_to(parser, ["-s", "--print-completion"]) parser.add_argument("-f", "--overwrite-config-file", action="store_true") subcommands = parser.add_subcommands(dest="command") subparsers: dict[str, ArgumentParser] = {} @@ -562,7 +563,7 @@ def get_parser(): subparser = ArgumentParser() subparser.add_argument( "--config-file", "--legacy-config-file", action=ActionLegacyConfigFile - ) + ).complete = shtab.FILE # type: ignore subparser.add_argument("--experiment", action=ActionExperiment) subparser.add_function_arguments(func, sub_configs=True) subparsers[name] = subparser @@ -578,6 +579,8 @@ def config_from_parser(parser, args): def main(): + from fd_shifts import logger + setup_logging() parser, subparsers = get_parser() @@ -601,6 +604,10 @@ def main(): skip_check=True, overwrite=args.overwrite_config_file, ) + else: + logger.warning( + "Config file already exists, use --overwrite-config-file to force" + ) __subcommands[args.command](config=config) diff --git a/pyproject.toml b/pyproject.toml index ed61e77..5e530d7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -34,6 +34,7 @@ dependencies = [ "scikit-learn>=0.24.2", "scipy>=1.6.1", "seaborn>=0.11.1", + "shtab", "tensorboard>=2.4.1", "timm==0.5.4", "toml>=0.10.2", @@ -69,6 +70,7 @@ launcher = [ [project.scripts] fd_shifts = "fd_shifts.cli:main" +fd-shifts = "fd_shifts.main:main" _fd_shifts_exec = "fd_shifts.exec:main" [tool.setuptools_scm] From e1695f8907c0130efe1565a003efd993115a765f Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 4 Jun 2024 17:21:20 +0200 Subject: [PATCH 098/136] feat: add back reporting --- fd_shifts/experiments/tracker.py | 53 +++++++ fd_shifts/main.py | 10 ++ fd_shifts/reporting/__init__.py | 264 +++++++++++-------------------- fd_shifts/reporting/tables.py | 62 ++++---- 4 files changed, 191 insertions(+), 198 deletions(-) create mode 100644 fd_shifts/experiments/tracker.py diff --git a/fd_shifts/experiments/tracker.py b/fd_shifts/experiments/tracker.py new file mode 100644 index 0000000..8b203e9 --- /dev/null +++ b/fd_shifts/experiments/tracker.py @@ -0,0 +1,53 @@ +import os +from pathlib import Path + +from fd_shifts.configs import Config, DataConfig + + +def get_path(config: Config) -> Path | None: + paths = os.getenv("FD_SHIFTS_STORE_PATH", "").split(":") + for path in paths: + path = Path(path) + exp_path = path / config.exp.group_name / config.exp.name + if (exp_path / "hydra" / "config.yaml").exists(): + return exp_path + + +def list_analysis_output_files(config: Config) -> list: + files = [] + for study_name, testset in config.eval.query_studies: + if study_name == "iid_study": + files.append("analysis_metrics_iid_study.csv") + continue + if study_name == "noise_study": + if isinstance(testset, DataConfig) and testset.dataset is not None: + files.extend( + f"analysis_metrics_noise_study_{i}.csv" for i in range(1, 6) + ) + continue + + if isinstance(testset, list): + if len(testset) > 0: + if isinstance(testset[0], DataConfig): + testset = map( + lambda d: d.dataset + ("_384" if d.img_size[0] == 384 else ""), + testset, + ) + + testset = [f"analysis_metrics_{study_name}_{d}.csv" for d in testset] + if study_name == "new_class_study": + testset = [ + d.replace(".csv", f"_{mode}.csv") + for d in testset + for mode in ["original_mode", "proposed_mode"] + ] + files.extend(list(testset)) + elif isinstance(testset, DataConfig) and testset.dataset is not None: + files.append(testset.dataset) + elif isinstance(testset, str): + files.append(testset) + + if config.eval.val_tuning: + files.append("analysis_metrics_val_tuning.csv") + + return files diff --git a/fd_shifts/main.py b/fd_shifts/main.py index ad6811e..3faea50 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -18,6 +18,7 @@ from omegaconf import OmegaConf from rich.pretty import pretty_repr +from fd_shifts import reporting from fd_shifts.configs import Config, DataConfig, OutputPathsPerMode __subcommands = {} @@ -559,6 +560,11 @@ def get_parser(): subparser = ArgumentParser() subcommands.add_subcommand("list-experiments", subparser) + subparser = ArgumentParser() + subparser.add_function_arguments(reporting.main) + subparsers["report"] = subparser + subcommands.add_subcommand("report", subparser) + for name, func in __subcommands.items(): subparser = ArgumentParser() subparser.add_argument( @@ -591,6 +597,10 @@ def main(): _list_experiments() return + if args.command == "report": + reporting.main(**args.report) + return + config = config_from_parser(parser, args) rich.print(config) diff --git a/fd_shifts/reporting/__init__.py b/fd_shifts/reporting/__init__.py index 4f8c30e..3fbfceb 100644 --- a/fd_shifts/reporting/__init__.py +++ b/fd_shifts/reporting/__init__.py @@ -1,10 +1,16 @@ +import concurrent.futures +import functools import os from pathlib import Path from typing import cast import pandas as pd +from fd_shifts import logger +from fd_shifts.configs import Config from fd_shifts.experiments import Experiment, get_all_experiments +from fd_shifts.experiments.configs import get_experiment_config, list_experiment_configs +from fd_shifts.experiments.tracker import list_analysis_output_files DATASETS = ( "svhn", @@ -17,162 +23,75 @@ ) -def _filter_experiment_by_dataset(experiments: list[Experiment], dataset: str): - match dataset: - case "super_cifar100": - _experiments = list( - filter( - lambda exp: exp.dataset in ("super_cifar100", "supercifar"), - experiments, - ) - ) - case "animals": - _experiments = list( - filter( - lambda exp: exp.dataset in ("animals", "wilds_animals"), experiments - ) - ) - case "animals_openset": - _experiments = list( - filter( - lambda exp: exp.dataset - in ("animals_openset", "wilds_animals_openset"), - experiments, - ) - ) - case "camelyon": - _experiments = list( - filter( - lambda exp: exp.dataset in ("camelyon", "wilds_camelyon"), - experiments, - ) - ) - case _: - _experiments = list(filter(lambda exp: exp.dataset == dataset, experiments)) +def __find_in_store(config: Config, file: str) -> Path | None: + store_paths = map(Path, os.getenv("FD_SHIFTS_STORE_PATH", "").split(":")) + test_dir = config.test.dir.relative_to(os.getenv("EXPERIMENT_ROOT_DIR", "")) + for store_path in store_paths: + if (store_path / test_dir / file).is_file(): + logger.info(f"Loading {store_path / test_dir / file}") + return store_path / test_dir / file - return _experiments +def __load_file(config: Config, name: str, file: str): + if f := __find_in_store(config, file): + return pd.read_csv(f) + else: + logger.error(f"Could not find {name}: {file} in store") + return None -def gather_data(data_dir: Path): - """Collect all csv files from experiments into one location - Args: - data_dir (Path): where to collect to - """ - experiment_dirs = [ - Path(os.environ["EXPERIMENT_ROOT_DIR"]), - ] +def __load_experiment(name: str) -> pd.DataFrame | None: + from fd_shifts.main import omegaconf_resolve - if add_dirs := os.getenv("EXPERIMENT_ADD_DIRS"): - ( - experiment_dirs.extend( - map( - lambda path: Path(path), - add_dirs.split(os.pathsep), - ) - ), - ) + config = get_experiment_config(name) + config = omegaconf_resolve(config) - experiments = get_all_experiments( - with_ms_runs=False, with_precision_study=False, with_vit_special_runs=False + # data = list(executor.map(functools.partial(__load_file, config, name), list_analysis_output_files(config))) + data = list( + map( + functools.partial(__load_file, config, name), + list_analysis_output_files(config), + ) ) - - for dataset in DATASETS + ("animals_openset", "svhn_openset"): - print(dataset) - _experiments = _filter_experiment_by_dataset(experiments, dataset) - - _paths = [] - _vit_paths = [] - - for experiment_dir in experiment_dirs: - for experiment in _experiments: - if experiment.model == "vit": - _vit_paths.extend( - (experiment_dir / experiment.to_path() / "test_results").glob( - "*.csv" - ) - ) - else: - _paths.extend( - (experiment_dir / experiment.to_path() / "test_results").glob( - "*.csv" - ) - ) - - if len(_paths) > 0: - dframe: pd.DataFrame = pd.concat( - [cast(pd.DataFrame, pd.read_csv(p)) for p in _paths] - ) - dframe.to_csv(data_dir / f"{dataset}.csv") - - if len(_vit_paths) > 0: - dframe: pd.DataFrame = pd.concat( - [cast(pd.DataFrame, pd.read_csv(p)) for p in _vit_paths] - ) - dframe.to_csv(data_dir / f"{dataset}vit.csv") - - -def load_file(path: Path, experiment_override: str | None = None) -> pd.DataFrame: - """Load experiment result csv into dataframe and set experiment accordingly - - Args: - path (Path): path to csv file - experiment_override (str | None): use this experiment instead of inferring it from the file - - Returns: - Dataframe created from csv including some cleanup - - Raises: - FileNotFoundError: if the file at path does not exist - RuntimeError: if loading does not result in a dataframe - """ - result = pd.read_csv(path) - - if not isinstance(result, pd.DataFrame): - raise FileNotFoundError - - result = ( - result.assign( - experiment=experiment_override - if experiment_override is not None - else path.stem + if len(data) == 0 or any(map(lambda d: d is None, data)): + return + data = pd.concat(data) # type: ignore + data = ( + data.assign( + experiment=config.data.dataset + ("vit" if "vit" in name else ""), + run=int(name.split("run")[1].split("_")[0]), + dropout=config.model.dropout_rate, + rew=config.model.dg_reward if config.model.dg_reward is not None else 0, + lr=config.trainer.optimizer.init_args["init_args"]["lr"], ) .dropna(subset=["name", "model"]) .drop_duplicates(subset=["name", "study", "model", "network", "confid"]) ) + return data - if not isinstance(result, pd.DataFrame): - raise RuntimeError - - return result - - -def load_data(data_dir: Path) -> tuple[pd.DataFrame, list[str]]: - """ - Args: - data_dir (Path): the directory where all experiment results are - - Returns: - dataframe with all experiments and list of experiments that were loaded - """ - data = pd.concat( - [ - load_file(path) - for path in filter( - lambda path: str(path.stem).startswith(DATASETS), - data_dir.glob("*.csv"), +def load_all(): + dataframes = [] + # TODO: make this async + with concurrent.futures.ProcessPoolExecutor(max_workers=12) as executor: + dataframes = list( + filter( + lambda d: d is not None, + executor.map( + __load_experiment, + list_experiment_configs(), + ), ) - ] - ) + ) + data = pd.concat(dataframes) # type: ignore data = data.loc[~data["study"].str.contains("tinyimagenet_original")] data = data.loc[~data["study"].str.contains("tinyimagenet_proposed")] - data = data.query( - 'not (experiment in ["cifar10", "cifar100", "super_cifar100"]' - 'and not name.str.contains("vgg13"))' - ) + # data = data.query( + # 'not (experiment in ["cifar10", "cifar100", "super_cifar100"]' + # 'and not name.str.contains("vgg13"))' + # ) data = data.query( 'not ((experiment.str.contains("super_cifar100")' @@ -208,14 +127,7 @@ def load_data(data_dir: Path) -> tuple[pd.DataFrame, list[str]]: data = data.assign(ece=data.ece.mask(data.ece < 0)) - exp_names = list( - filter( - lambda exp: not exp.startswith("super_cifar100"), - data.experiment.unique(), - ) - ) - - return data, exp_names + return data def _extract_hparam( @@ -234,6 +146,7 @@ def assign_hparams_from_names(data: pd.DataFrame) -> pd.DataFrame: Returns: experiment data with additional columns """ + logger.info("Assigning hyperparameters from experiment names") data = data.assign( backbone=lambda data: _extract_hparam( data.name, r"bb([a-z0-9]+)(_small_conv)?" @@ -245,20 +158,19 @@ def assign_hparams_from_names(data: pd.DataFrame) -> pd.DataFrame: .mask(data["backbone"] == "vit", "vit_") + data.model.where( data.backbone == "vit", data.name.str.split("_", expand=True)[0] + ).mask( + data.backbone == "vit", + data.name.str.split("model", expand=True)[1].str.split("_", expand=True)[0], ), - run=lambda data: _extract_hparam(data.name, r"run([0-9]+)"), - dropout=lambda data: _extract_hparam(data.name, r"do([01])"), - rew=lambda data: _extract_hparam(data.name, r"rew([0-9.]+)"), - lr=lambda data: _extract_hparam(data.name, r"lr([0-9.]+)", "0.1"), # Encode every detail into confid name _confid=data.confid, confid=lambda data: data.model + "_" + data.confid + "_" - + data.dropout + + data.dropout.astype(str) + "_" - + data.rew, + + data.rew.astype(str), ) return data @@ -276,6 +188,7 @@ def filter_best_lr(data: pd.DataFrame, metric: str = "aurc") -> pd.DataFrame: Returns: filtered data """ + logger.info("Filtering best learning rates") def _filter_row(row, selection_df, optimization_columns, fixed_columns): if "openset" in row["study"]: @@ -347,6 +260,8 @@ def filter_best_hparams(data: pd.DataFrame, metric: str = "aurc") -> pd.DataFram filtered data """ + logger.info("Filtering best hyperparameters") + def _filter_row(row, selection_df, optimization_columns, fixed_columns): if "openset" in row["study"]: return True @@ -355,10 +270,19 @@ def _filter_row(row, selection_df, optimization_columns, fixed_columns): & (row._confid == selection_df._confid) & (row.model == selection_df.model) ] + if len(temp) > 1: + print(f"{len(temp)=}") + raise ValueError("More than one row") + + if len(temp) == 0: + return False + + temp = temp.iloc[0] result = row[optimization_columns] == temp[optimization_columns] - if result.all(axis=1).any().item(): - return True + # if result.all(axis=1).any().item(): + # return True + return result.all() return False @@ -489,7 +413,7 @@ def str_format_metrics(data: pd.DataFrame) -> pd.DataFrame: return data -def main(base_path: str | Path): +def main(out_path: str | Path): """Main entrypoint for CLI report generation Args: @@ -508,12 +432,10 @@ def main(base_path: str | Path): pd.set_option("display.width", None) pd.set_option("display.max_colwidth", None) - data_dir: Path = Path(base_path).expanduser().resolve() + data_dir: Path = Path(out_path).expanduser().resolve() data_dir.mkdir(exist_ok=True, parents=True) - gather_data(data_dir) - - data, exp_names = load_data(data_dir) + data = load_all() data = assign_hparams_from_names(data) @@ -524,19 +446,19 @@ def main(base_path: str | Path): data = rename_confids(data) data = rename_studies(data) - plot_rank_style(data, "cifar10", "aurc", data_dir) - vit_v_cnn_box(data, data_dir) + # plot_rank_style(data, "cifar10", "aurc", data_dir) + # vit_v_cnn_box(data, data_dir) - data = tables.aggregate_over_runs(data) + data, std = tables.aggregate_over_runs(data) data = str_format_metrics(data) paper_results(data, "aurc", False, data_dir) - paper_results(data, "aurc", False, data_dir, True) - paper_results(data, "ece", False, data_dir) - paper_results(data, "failauc", True, data_dir) - paper_results(data, "accuracy", True, data_dir) - paper_results(data, "fail-NLL", False, data_dir) - - rank_comparison_metric(data, data_dir) - rank_comparison_mode(data, data_dir) - rank_comparison_mode(data, data_dir, False) + # paper_results(data, "aurc", False, data_dir, rank_cols=True) + # paper_results(data, "ece", False, data_dir) + # paper_results(data, "failauc", True, data_dir) + # paper_results(data, "accuracy", True, data_dir) + # paper_results(data, "fail-NLL", False, data_dir) + + # rank_comparison_metric(data, data_dir) + # rank_comparison_mode(data, data_dir) + # rank_comparison_mode(data, data_dir, False) diff --git a/fd_shifts/reporting/tables.py b/fd_shifts/reporting/tables.py index 2977157..9812147 100644 --- a/fd_shifts/reporting/tables.py +++ b/fd_shifts/reporting/tables.py @@ -8,6 +8,8 @@ import numpy as np import pandas as pd +from fd_shifts import logger + LATEX_TABLE_TEMPLATE = r""" \documentclass{article} % For LaTeX2e \usepackage[table]{xcolor} @@ -89,6 +91,7 @@ def aggregate_over_runs(data: pd.DataFrame) -> pd.DataFrame: Returns: aggregated experiment data """ + logger.info("Aggregating over runs") fixed_columns = ["study", "confid"] metrics_columns = ["accuracy", "aurc", "ece", "failauc", "fail-NLL"] @@ -167,6 +170,9 @@ def _study_name_to_multilabel(study_name): if study_name in ["confid", "classifier"]: return (study_name, "", "") + if study_name.startswith("wilds_"): + study_name = study_name.replace("wilds_", "") + return ( study_name.split("_")[0], study_name.split("_")[1] @@ -230,7 +236,7 @@ def _reorder_studies( ordered_columns = [ ("animals", "iid", ""), ("animals", "sub", ""), - ("animals", "s-ncs", ""), + # ("animals", "s-ncs", ""), ("animals", "rank", ""), ("breeds", "iid", ""), ("breeds", "sub", ""), @@ -252,7 +258,7 @@ def _reorder_studies( ("cifar10", "ns-ncs", "ti"), ("cifar10", "rank", ""), ("svhn", "iid", ""), - ("svhn", "s-ncs", ""), + # ("svhn", "s-ncs", ""), ("svhn", "ns-ncs", "c10"), ("svhn", "ns-ncs", "c100"), ("svhn", "ns-ncs", "ti"), @@ -411,16 +417,17 @@ def paper_results( out_dir (Path): where to save the output to rank_cols: (bool): whether to report ranks instead of absolute values """ + logger.info(f"Creating results table for {metric}") + _formatter = ( lambda x: f"{x:>3.2f}"[:4] if "." in f"{x:>3.2f}"[:3] else f"{x:>3.2f}"[:3] ) + results_table = build_results_table(data, metric) cmap = "Oranges_r" if invert else "Oranges" if rank_cols: results_table = _add_rank_columns(results_table) - print(f"{metric}") - print(results_table) _formatter = lambda x: f"{int(x):>3d}" cmap = "Oranges" @@ -436,63 +443,65 @@ def paper_results( lambda val: round(val, 2) if val < 10 else round(val, 1) ) - gmap_vit = _compute_gmap( + gmap_cnn = _compute_gmap( results_table.loc[ results_table.index[ - results_table.index.get_level_values(1).str.contains("ViT") + ~results_table.index.get_level_values(1).str.contains("ViT") ], results_table.columns, ], invert, ) - gmap_cnn = _compute_gmap( - results_table.loc[ + + ltex = results_table.style.background_gradient( + cmap, + axis=None, + subset=( results_table.index[ ~results_table.index.get_level_values(1).str.contains("ViT") ], results_table.columns, - ], - invert, + ), + gmap=gmap_cnn, ) - ltex = ( - results_table.style.background_gradient( - cmap, - axis=None, - subset=( + if results_table.index.get_level_values(1).str.contains("ViT").any(): + gmap_vit = _compute_gmap( + results_table.loc[ results_table.index[ results_table.index.get_level_values(1).str.contains("ViT") ], results_table.columns, - ), - gmap=gmap_vit, + ], + invert, ) - .background_gradient( + ltex = ltex.background_gradient( cmap, axis=None, subset=( results_table.index[ - ~results_table.index.get_level_values(1).str.contains("ViT") + results_table.index.get_level_values(1).str.contains("ViT") ], results_table.columns, ), - gmap=gmap_cnn, - ) - .highlight_null(props="background-color: white;color: black") - .format( - _formatter, - na_rep="*", + gmap=gmap_vit, ) + + ltex = ltex.highlight_null(props="background-color: white;color: black").format( + _formatter, + na_rep="*", ) ltex.data.columns = ltex.data.columns.set_names( ["\\multicolumn{1}{c}{}", "study", "ncs-data set"] ) + print(ltex.data) ltex = ltex.to_latex( convert_css=True, hrules=True, multicol_align="c?", - column_format="ll?rrr?xx?xx?rrrrrr?rrrrr?rrrrr", + # column_format="ll?rrr?xx?xx?rrrrrr?rrrrr?rrrrr", + column_format="ll?rr?xx?xx?rrrrrr?rrrrr?rrrr", ) # Remove toprule @@ -782,7 +791,6 @@ def rank_comparison_mode(data: pd.DataFrame, out_dir: Path, rank: bool = True): ltex.data.columns = ltex.data.columns.set_names( ["\\multicolumn{1}{c}{}", "study", "ncs-data set", "ood protocol"] ) - print(len(results_table.columns)) ltex = ltex.to_latex( convert_css=True, hrules=True, From 77c6c8ab524da50ddb0c3d8f96c4d945980deebd Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 16:25:50 +0100 Subject: [PATCH 099/136] feat(configs): add supercifar configs --- fd_shifts/experiments/configs.py | 39 ++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index f82514d..411f415 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -942,6 +942,16 @@ def vit_cifar100_modeldg(run: int, lr: float, do: int, rew: float): return config +def vit_super_cifar100_modeldg(run: int, lr: float, do: int, rew: float): + config = vit_cifar100_modeldg(run, lr, do, rew) + config.exp.name = "super_" + config.exp.name + config.data = cifar100_data_config(dataset="super_cifar100", img_size=384) + config.eval.query_studies = cifar100_query_config( + dataset="super_cifar100", img_size=384 + ) + return config + + def vit_breeds_modeldg(run: int, lr: float, do: int, rew: float): config = vit_modeldg( name=f"breeds_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", @@ -1024,6 +1034,18 @@ def vit_cifar100_modelvit(run: int, lr: float, do: int, **kwargs): return config +def vit_super_cifar100_modelvit(run: int, lr: float, do: int, **kwargs): + config = vit_cifar100_modelvit(run, lr, do, **kwargs) + config.exp.name = "super_" + config.exp.name + config.data = cifar100_data_config(dataset="super_cifar100", img_size=384) + config.eval.query_studies = cifar100_query_config( + dataset="super_cifar100", img_size=384 + ) + config.trainer.num_steps = 40000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 + return config + + def vit_breeds_modelvit(run: int, lr: float, do: int, **kwargs): config = vit( name=f"breeds_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", @@ -1087,6 +1109,23 @@ def register(config_fn: Callable[..., Config], n_runs: int = 5, **kwargs): register(vit_cifar100_modeldg, lr=1e-2, do=0, rew=20) register(vit_cifar100_modeldg, lr=1e-2, do=1, rew=20) +register(vit_super_cifar100_modelvit, lr=3e-3, do=0, rew=0) +register(vit_super_cifar100_modelvit, lr=1e-3, do=1, rew=0) +register(vit_super_cifar100_modeldg, lr=3e-3, do=0, rew=2.2) +register(vit_super_cifar100_modeldg, lr=1e-3, do=1, rew=2.2) +register(vit_super_cifar100_modeldg, lr=3e-3, do=0, rew=3) +register(vit_super_cifar100_modeldg, lr=1e-3, do=1, rew=3) +register(vit_super_cifar100_modeldg, lr=3e-3, do=0, rew=6) +register(vit_super_cifar100_modeldg, lr=1e-3, do=1, rew=6) +register(vit_super_cifar100_modeldg, lr=3e-3, do=0, rew=10) +register(vit_super_cifar100_modeldg, lr=1e-3, do=1, rew=10) +register(vit_super_cifar100_modeldg, lr=3e-3, do=0, rew=12) +register(vit_super_cifar100_modeldg, lr=1e-3, do=1, rew=12) +register(vit_super_cifar100_modeldg, lr=3e-3, do=0, rew=15) +register(vit_super_cifar100_modeldg, lr=1e-3, do=1, rew=15) +register(vit_super_cifar100_modeldg, lr=3e-3, do=0, rew=20) +register(vit_super_cifar100_modeldg, lr=1e-3, do=1, rew=20) + register(vit_wilds_animals_modelvit, lr=1e-3, do=0, rew=0) register(vit_wilds_animals_modelvit, lr=1e-2, do=0, rew=0) register(vit_wilds_animals_modelvit, lr=1e-2, do=1, rew=0) From f8b4fb3206d174ca41d0355c35af54fecf86c104 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 21 Feb 2024 16:34:52 +0100 Subject: [PATCH 100/136] fix: tinyimagenet name --- fd_shifts/analysis/__init__.py | 3 ++- fd_shifts/experiments/configs.py | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index ebf80fd..86b60d8 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -17,7 +17,6 @@ from sklearn.calibration import _sigmoid_calibration as calib from fd_shifts import configs -from fd_shifts.loaders.dataset_collection import CorruptCIFAR from .confid_scores import ConfidScore, SecondaryConfidScore, is_external_confid from .eval_utils import ( @@ -286,6 +285,8 @@ def from_experiment( config: configs.Config, holdout_classes: list | None = None, ) -> ExperimentData: + from fd_shifts.loaders.dataset_collection import CorruptCIFAR + if not isinstance(test_dir, Path): test_dir = Path(test_dir) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index 411f415..c828408 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -353,7 +353,7 @@ def tinyimagenet_data_config(img_size: int | tuple[int, int] = 64) -> DataConfig augmentations["resize"] = img_size return DataConfig( - dataset="tinyimagenet" + ("" if img_size[0] == 384 else "_resize"), + dataset="tinyimagenet" + ("_384" if img_size[0] == 384 else "_resize"), data_dir=SI( "${oc.env:DATASET_ROOT_DIR}/" + "tinyimagenet" From 719f82eaef3f80950271d5f45ee745262ddd53d8 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Mon, 4 Mar 2024 14:30:11 +0100 Subject: [PATCH 101/136] fix: subsample old mcd results before converting to 64bit --- fd_shifts/analysis/__init__.py | 53 +++++++++++++++++++++++++--------- 1 file changed, 40 insertions(+), 13 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 86b60d8..2c44579 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -256,13 +256,20 @@ def __load_from_store( @overload @staticmethod def __load_from_store( - config: configs.Config, file: str, unpack: Literal[False] + config: configs.Config, file: str, dtype: type, unpack: Literal[False] ) -> dict[str, npt.NDArray[np.float64]] | None: ... + @overload @staticmethod def __load_from_store( - config: configs.Config, file: str, unpack: bool = True + config: configs.Config, file: str, dtype: type + ) -> npt.NDArray[np.float64] | None: + ... + + @staticmethod + def __load_from_store( + config: configs.Config, file: str, dtype: type = np.float64, unpack: bool = True ) -> npt.NDArray[np.float64] | dict[str, npt.NDArray[np.float64]] | None: store_paths = map(Path, os.getenv("FD_SHIFTS_STORE_PATH", "").split(":")) @@ -273,7 +280,7 @@ def __load_from_store( logger.debug(f"Loading {store_path / test_dir / file}") with np.load(store_path / test_dir / file) as npz: if unpack: - return npz.f.arr_0.astype(np.float64) + return npz.f.arr_0.astype(dtype) else: return dict(npz.items()) @@ -301,7 +308,7 @@ def from_experiment( ) and ( ( mcd_logits_dist := ExperimentData.__load_from_store( - config, "raw_logits_dist.npz" + config, "raw_logits_dist.npz", dtype=np.float16 ) ) is not None @@ -330,6 +337,7 @@ def from_experiment( ] ) mcd_logits_dist = mcd_logits_dist[idx] + mcd_logits_dist = mcd_logits_dist.astype(np.float64) mcd_softmax_dist = scpspecial.softmax(mcd_logits_dist, axis=1) else: mcd_logits_dist = None @@ -364,14 +372,16 @@ def from_experiment( external_confids = ExperimentData.__load_from_store( config, "external_confids.npz" ) - if any("mcd" in confid for confid in config.eval.confidence_measures.test): - mcd_external_confids_dist = ExperimentData.__load_from_store( - config, "external_confids_dist.npz" + if ( + any("mcd" in confid for confid in config.eval.confidence_measures.test) + and ( + mcd_external_confids_dist := ExperimentData.__load_from_store( + config, "external_confids_dist.npz", dtype=np.float16 + ) ) - if ( - mcd_external_confids_dist is not None - and mcd_external_confids_dist.shape[0] > logits.shape[0] - ): + is not None + ): + if mcd_external_confids_dist.shape[0] > logits.shape[0]: dset = CorruptCIFAR( config.eval.query_studies.noise_study.data_dir, train=False, @@ -395,6 +405,7 @@ def from_experiment( ] ) mcd_external_confids_dist = mcd_external_confids_dist[idx] + mcd_external_confids_dist = mcd_external_confids_dist.astype(np.float64) else: mcd_external_confids_dist = None @@ -715,11 +726,27 @@ def __init__( if isinstance(datasets, (list, ListConfig)) and len(datasets) > 0: if isinstance(datasets[0], configs.DataConfig): self.query_studies.__dict__[study_name] = list( - map(lambda d: d.dataset, datasets) + map( + lambda d: d.dataset + + ( + "_384" + if d.img_size[0] == 384 and "384" not in d.dataset + else "" + ), + datasets, + ) ) if isinstance(datasets, configs.DataConfig): if datasets.dataset is not None: - self.query_studies.__dict__[study_name] = [datasets.dataset] + self.query_studies.__dict__[study_name] = [ + datasets.dataset + + ( + "_384" + if datasets.img_size[0] == 384 + and "384" not in datasets.dataset + else "" + ) + ] else: self.query_studies.__dict__[study_name] = [] From 23df3ce0ad14baa5fd0ed3fb5384c068cdea93e9 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Fri, 5 Apr 2024 13:56:56 +0200 Subject: [PATCH 102/136] deps: update lightning and torch --- fd_shifts/configs/__init__.py | 263 +++--------------- fd_shifts/experiments/configs.py | 12 + fd_shifts/loaders/data_loader.py | 4 +- fd_shifts/main.py | 32 ++- fd_shifts/models/callbacks/__init__.py | 15 +- fd_shifts/models/callbacks/confid_monitor.py | 11 +- fd_shifts/models/callbacks/training_stages.py | 237 ---------------- fd_shifts/models/confidnet_model.py | 234 +++++++++++++++- fd_shifts/models/devries_model.py | 8 +- fd_shifts/models/vit_model.py | 146 ++-------- pyproject.toml | 23 +- 11 files changed, 327 insertions(+), 658 deletions(-) delete mode 100644 fd_shifts/models/callbacks/training_stages.py diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 0d7f3c1..b932e0d 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -2,19 +2,14 @@ import importlib import os -from collections.abc import Mapping from copy import deepcopy -from dataclasses import field +from dataclasses import dataclass, field from enum import Enum, auto from pathlib import Path from random import randint from typing import TYPE_CHECKING, Any, Iterable, Optional, TypeVar -from hydra.core.config_store import ConfigStore from omegaconf import SI, DictConfig, OmegaConf -from pydantic import ConfigDict, validator -from pydantic.dataclasses import dataclass -from typing_extensions import dataclass_transform from fd_shifts import get_version @@ -54,21 +49,7 @@ class ValSplit(StrEnum): zhang = auto() -@dataclass_transform() -def defer_validation(original_class: type[ConfigT]) -> type[ConfigT]: - """Disable validation for a pydantic dataclass - - original_class (type[T]): original pydantic dataclass - - Returns: - original_class but with validation disabled - """ - original_class.__pydantic_run_validation__ = False - return original_class - - -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) +@dataclass class OutputPathsConfig(_IterableMixin): """Where outputs are stored""" @@ -82,36 +63,38 @@ class OutputPathsConfig(_IterableMixin): input_imgs_plot: Optional[Path] = None -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) +@dataclass class OutputPathsPerMode(_IterableMixin): """Container for per-mode output paths""" - fit: OutputPathsConfig = OutputPathsConfig( - raw_output=Path("${exp.version_dir}/raw_output.npz"), - raw_output_dist=Path("${exp.version_dir}/raw_output_dist.npz"), - external_confids=Path("${exp.version_dir}/external_confids.npz"), - external_confids_dist=Path("${exp.version_dir}/external_confids_dist.npz"), - input_imgs_plot=Path("${exp.dir}/input_imgs.png"), - encoded_output=Path("${test.dir}/encoded_output.npz"), - encoded_train=Path("${test.dir}/train_features.npz"), - attributions_output=Path("${test.dir}/attributions.csv"), + fit: OutputPathsConfig = field( + default_factory=lambda: OutputPathsConfig( + raw_output=Path("${exp.version_dir}/raw_output.npz"), + raw_output_dist=Path("${exp.version_dir}/raw_output_dist.npz"), + external_confids=Path("${exp.version_dir}/external_confids.npz"), + external_confids_dist=Path("${exp.version_dir}/external_confids_dist.npz"), + input_imgs_plot=Path("${exp.dir}/input_imgs.png"), + encoded_output=Path("${test.dir}/encoded_output.npz"), + encoded_train=Path("${test.dir}/train_features.npz"), + attributions_output=Path("${test.dir}/attributions.csv"), + ) ) - test: OutputPathsConfig = OutputPathsConfig( - raw_output=Path("${test.dir}/raw_logits.npz"), - raw_output_dist=Path("${test.dir}/raw_logits_dist.npz"), - external_confids=Path("${test.dir}/external_confids.npz"), - external_confids_dist=Path("${test.dir}/external_confids_dist.npz"), - input_imgs_plot=None, - encoded_output=Path("${test.dir}/encoded_output.npz"), - encoded_train=Path("${test.dir}/train_features.npz"), - attributions_output=Path("${test.dir}/attributions.csv"), + test: OutputPathsConfig = field( + default_factory=lambda: OutputPathsConfig( + raw_output=Path("${test.dir}/raw_logits.npz"), + raw_output_dist=Path("${test.dir}/raw_logits_dist.npz"), + external_confids=Path("${test.dir}/external_confids.npz"), + external_confids_dist=Path("${test.dir}/external_confids_dist.npz"), + input_imgs_plot=None, + encoded_output=Path("${test.dir}/encoded_output.npz"), + encoded_train=Path("${test.dir}/train_features.npz"), + attributions_output=Path("${test.dir}/attributions.csv"), + ) ) analysis: Path = SI("${test.dir}") -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) +@dataclass class ExperimentConfig(_IterableMixin): """Main experiment config""" @@ -133,7 +116,9 @@ class ExperimentConfig(_IterableMixin): crossval_ids_path: Path = Path("${exp.dir}/crossval_ids.pickle") log_path: Path = Path("log.txt") global_seed: int = randint(0, 1_000_000) - output_paths: OutputPathsPerMode = OutputPathsPerMode() + output_paths: OutputPathsPerMode = field( + default_factory=lambda: OutputPathsPerMode() + ) # @defer_validation @@ -223,8 +208,7 @@ def __call__(self, params: Iterable) -> torch.optim.Optimizer: return cls(params, **self.init_args["init_args"]) -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True, arbitrary_types_allowed=True)) +@dataclass class TrainerConfig(_IterableMixin): """Main configuration for PyTorch Lightning Trainer""" @@ -262,29 +246,8 @@ class TrainerConfig(_IterableMixin): learning_rate_confidnet: Optional[float] = None learning_rate_confidnet_finetune: Optional[float] = None - # pylint: disable=no-self-argument - @validator("num_steps") - def validate_steps( - cls: TrainerConfig, num_steps: Optional[int], values: dict[str, Any] - ) -> Optional[int]: - """Validate either num_epochs or num_steps is set - - cls (TrainerConfig): TrainerConfig - num_steps (Optional[int]): num_steps value - values (dict[str, Any]): other values - - Returns: - num_steps - """ - if (num_steps is None and values["num_epochs"] is None) or ( - num_steps == 0 and values["num_epochs"] == 0 - ): - raise ValueError("Must specify either num_steps or num_epochs") - return num_steps - -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) +@dataclass class NetworkConfig(_IterableMixin): """Model Network configuration""" @@ -294,26 +257,8 @@ class NetworkConfig(_IterableMixin): load_dg_backbone_path: Optional[Path] = None save_dg_backbone_path: Optional[Path] = None - # pylint: disable=no-self-argument - @validator("name", "backbone") - def validate_network_name(cls: NetworkConfig, name: str) -> str: - """Check if network and backbone exist - - cls (NetworkConfig): this config - name (str): name of the network - Returns: - name - """ - from ..models import networks - - if name is not None and not networks.network_exists(name): - raise ValueError(f'Network "{name}" does not exist.') - return name - - -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) +@dataclass class ModelConfig(_IterableMixin): """Model Configuration""" @@ -329,26 +274,8 @@ class ModelConfig(_IterableMixin): balanced_sampeling: bool = False budget: float = 0.3 - # pylint: disable=no-self-argument - @validator("name") - def validate_network_name(cls: ModelConfig, name: str) -> str: - """Check if the model exists - - cls (ModelConfig): - name (str): - Returns: - name - """ - from fd_shifts import models - - if name is not None and not models.model_exists(name): - raise ValueError(f'Model "{name}" does not exist.') - return name - - -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) +@dataclass class PerfMetricsConfig(_IterableMixin): """Performance Metrics Configuration""" @@ -365,8 +292,7 @@ class PerfMetricsConfig(_IterableMixin): test: list[str] = field(default_factory=lambda: ["nll", "accuracy", "brier_score"]) -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) +@dataclass class ConfidMetricsConfig(_IterableMixin): """Confidence Metrics Configuration""" @@ -403,26 +329,8 @@ class ConfidMetricsConfig(_IterableMixin): ] ) - # pylint: disable=no-self-argument - @validator("train", "val", "test", each_item=True) - def validate(cls: ConfidMetricsConfig, name: str) -> str: - """Check all metric functions exist - - cls (ConfidMetricsConfig) - name (str) - - Returns: - name - """ - from fd_shifts.analysis import metrics - - if not metrics.metric_function_exists(name): - raise ValueError(f'Confid metric function "{name}" does not exist.') - return name - -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) +@dataclass class ConfidMeasuresConfig(_IterableMixin): """Confidence Measures Configuration""" @@ -430,25 +338,8 @@ class ConfidMeasuresConfig(_IterableMixin): val: list[str] = field(default_factory=lambda: ["det_mcp"]) test: list[str] = field(default_factory=lambda: ["det_mcp", "det_pe"]) - # pylint: disable=no-self-argument - @validator("train", "val", "test", each_item=True) - def validate(cls: ConfidMeasuresConfig, name: str) -> str: - """Check all confid functions exist - cls (type[ConfidMeasuresConfig]): - name (str): - - Returns: - name - """ - from fd_shifts.analysis import confid_scores - - if not confid_scores.confid_function_exists(name): - raise ValueError(f'Confid function "{name}" does not exist.') - return name - -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) +@dataclass class QueryStudiesConfig(_IterableMixin): """Query Studies Configuration""" @@ -457,27 +348,8 @@ class QueryStudiesConfig(_IterableMixin): in_class_study: list[DataConfig] = field(default_factory=lambda: []) new_class_study: list[DataConfig] = field(default_factory=lambda: []) - # pylint: disable=no-self-argument - @validator( - "iid_study", "in_class_study", "noise_study", "new_class_study", each_item=True - ) - def validate(cls, name: str) -> str: - """Check all datasets exist - cls (): - name (str): - - Returns: - name - """ - from fd_shifts.loaders import dataset_collection - - if not dataset_collection.dataset_exists(name): - raise ValueError(f'Dataset "{name}" does not exist.') - return name - -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) +@dataclass class EvalConfig(_IterableMixin): """Evaluation Configuration container""" @@ -509,8 +381,7 @@ class EvalConfig(_IterableMixin): ext_confid_name: Optional[str] = None -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) +@dataclass class TestConfig(_IterableMixin): """Inference time configuration""" @@ -530,8 +401,7 @@ class TestConfig(_IterableMixin): compute_train_encodings: bool = False -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) +@dataclass class DataConfig(_IterableMixin): """Dataset Configuration""" @@ -548,8 +418,7 @@ class DataConfig(_IterableMixin): kwargs: Optional[dict[Any, Any]] = None -@defer_validation -@dataclass(config=ConfigDict(validate_assignment=True)) +@dataclass class Config(_IterableMixin): """Main Configuration Class""" @@ -663,55 +532,3 @@ def with_defaults( config.__pydantic_validate_values__() return config - - # pylint: disable=no-self-argument - @validator("pkgversion") - def validate_version(cls, version: str) -> str: - """Check if the running version is the same as the version of the configuration - cls (): - version (str): - - Returns: - version - """ - return version - - -def _update(d, u): - for k, v in u.items(): - if isinstance(v, Mapping): - d[k] = _update(d.get(k, {}), v) - else: - d[k] = v - return d - - -def init() -> None: - """Initialize the hydra config store with config classes""" - store = ConfigStore.instance() - store.store(name="config_schema", node=Config) - store.store(group="data", name="data_schema", node=DataConfig) - - store.store( - group="trainer/lr_scheduler", - name="LinearWarmupCosineAnnealingLR", - node=LinearWarmupCosineAnnealingLR, - ) - - store.store( - group="trainer/lr_scheduler", - name="CosineAnnealingLR", - node=CosineAnnealingLR, - ) - - store.store( - group="trainer/optimizer", - name="SGD", - node=SGD, - ) - - store.store( - group="trainer/optimizer", - name="Adam", - node=Adam, - ) diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index c828408..fb4eb6f 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -453,6 +453,8 @@ def cnn_animals_modelconfidnet(run: int, do: int, **kwargs): config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 12 config.trainer.callbacks["training_stages"] = {} config.trainer.callbacks["training_stages"]["milestones"] = [12, 17] + config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None + config.trainer.callbacks["training_stages"]["pretrained_confidnet_path"] = None config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False config.model.name = "confidnet_model" @@ -511,6 +513,8 @@ def cnn_camelyon_modelconfidnet(run: int, do: int, **kwargs): config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 5 config.trainer.callbacks["training_stages"] = {} config.trainer.callbacks["training_stages"]["milestones"] = [5, 8] + config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None + config.trainer.callbacks["training_stages"]["pretrained_confidnet_path"] = None config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False config.model.name = "confidnet_model" @@ -569,6 +573,8 @@ def cnn_svhn_modelconfidnet(run: int, do: int, **kwargs): config.trainer.learning_rate_confidnet_finetune = 1e-06 config.trainer.callbacks["training_stages"] = {} config.trainer.callbacks["training_stages"]["milestones"] = [100, 300] + config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None + config.trainer.callbacks["training_stages"]["pretrained_confidnet_path"] = None config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False config.model.name = "confidnet_model" @@ -626,6 +632,8 @@ def cnn_cifar10_modelconfidnet(run: int, do: int, **kwargs): config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 config.trainer.callbacks["training_stages"] = {} config.trainer.callbacks["training_stages"]["milestones"] = [250, 450] + config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None + config.trainer.callbacks["training_stages"]["pretrained_confidnet_path"] = None config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False config.model.name = "confidnet_model" @@ -686,6 +694,8 @@ def cnn_cifar100_modelconfidnet(run: int, do: int, **kwargs): config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 config.trainer.callbacks["training_stages"] = {} config.trainer.callbacks["training_stages"]["milestones"] = [250, 450] + config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None + config.trainer.callbacks["training_stages"]["pretrained_confidnet_path"] = None config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False config.model.name = "confidnet_model" @@ -777,6 +787,8 @@ def cnn_breeds_modelconfidnet(run: int, do: int, **kwargs): config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 config.trainer.callbacks["training_stages"] = {} config.trainer.callbacks["training_stages"]["milestones"] = [300, 500] + config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None + config.trainer.callbacks["training_stages"]["pretrained_confidnet_path"] = None config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False config.model.name = "confidnet_model" diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index 41f0844..f767a10 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -5,8 +5,8 @@ from dataclasses import asdict from pathlib import Path +import lightning as L import numpy as np -import pytorch_lightning as pl import torch from omegaconf import OmegaConf from sklearn.model_selection import KFold @@ -19,7 +19,7 @@ from fd_shifts.utils.aug_utils import get_transform, target_transforms_collection -class FDShiftsDataLoader(pl.LightningDataModule): +class FDShiftsDataLoader(L.LightningDataModule): """Data module class for combination of multiple datasets for testing with shifts""" def __init__(self, cf: configs.Config, no_norm_flag=False): diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 3faea50..a22be82 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -355,11 +355,11 @@ def setup_logging(): @subcommand def train(config: Config): - import pytorch_lightning as pl - from pytorch_lightning.callbacks.progress.rich_progress import RichProgressBar - from pytorch_lightning.loggers.csv_logs import CSVLogger - from pytorch_lightning.loggers.tensorboard import TensorBoardLogger - from pytorch_lightning.loggers.wandb import WandbLogger + import lightning as L + from lightning.pytorch.callbacks.progress.rich_progress import RichProgressBar + from lightning.pytorch.loggers.csv_logs import CSVLogger + from lightning.pytorch.loggers.tensorboard import TensorBoardLogger + from lightning.pytorch.loggers.wandb import WandbLogger from fd_shifts import logger from fd_shifts.loaders.data_loader import FDShiftsDataLoader @@ -426,23 +426,25 @@ def train(config: Config): name=config.exp.name, ) - trainer = pl.Trainer( + trainer = L.Trainer( accelerator="auto", devices="auto", logger=[tb_logger, csv_logger, wandb_logger], log_every_n_steps=log_every_n_steps, max_epochs=num_epochs, - max_steps=max_steps, # type: ignore + max_steps=-1 if max_steps is None else max_steps, callbacks=[progress] + get_callbacks(config), benchmark=config.trainer.benchmark, - precision=16, + precision="16-mixed", check_val_every_n_epoch=val_every_n_epoch, num_sanity_val_steps=5, limit_train_batches=limit_batches, limit_val_batches=0 if config.trainer.do_val is False else limit_batches, limit_test_batches=limit_batches, - gradient_clip_val=1, - accumulate_grad_batches=accumulate_grad_batches, + gradient_clip_val=None if config.model.name == "confidnet_model" else 1, + accumulate_grad_batches=1 + if config.model.name == "confidnet_model" + else accumulate_grad_batches, ) logger.info( @@ -455,9 +457,9 @@ def train(config: Config): @subcommand def test(config: Config): - import pytorch_lightning as pl - from pytorch_lightning.callbacks.progress.rich_progress import RichProgressBar - from pytorch_lightning.loggers.wandb import WandbLogger + import lightning as L + from lightning.pytorch.callbacks.progress.rich_progress import RichProgressBar + from lightning.pytorch.loggers.wandb import WandbLogger from fd_shifts import logger from fd_shifts.loaders.data_loader import FDShiftsDataLoader @@ -510,14 +512,14 @@ def test(config: Config): name=config.exp.name, ) - trainer = pl.Trainer( + trainer = L.Trainer( accelerator="auto", devices="auto", logger=wandb_logger, log_every_n_steps=log_every_n_steps, callbacks=[progress] + get_callbacks(config), limit_test_batches=limit_batches, - precision=16, + precision="bf16-mixed", ) trainer.test(model=module, datamodule=datamodule) diff --git a/fd_shifts/models/callbacks/__init__.py b/fd_shifts/models/callbacks/__init__.py index 8ab95d1..990900a 100644 --- a/fd_shifts/models/callbacks/__init__.py +++ b/fd_shifts/models/callbacks/__init__.py @@ -1,13 +1,12 @@ -from pytorch_lightning import Callback -from pytorch_lightning.callbacks import ( - GPUStatsMonitor, +from lightning import Callback +from lightning.pytorch.callbacks import ( LearningRateMonitor, ModelCheckpoint, RichProgressBar, ) from fd_shifts import configs, logger -from fd_shifts.models.callbacks import confid_monitor, training_stages +from fd_shifts.models.callbacks import confid_monitor def get_callbacks(cfg: configs.Config) -> list[Callback]: @@ -50,14 +49,6 @@ def get_callbacks(cfg: configs.Config) -> list[Callback]: if k == "confid_monitor": out_cb_list.append(confid_monitor.ConfidMonitor(cfg)) - if k == "training_stages": - out_cb_list.append( - training_stages.TrainingStages( - milestones=v["milestones"], - disable_dropout_at_finetuning=v["disable_dropout_at_finetuning"], - ) - ) - if k == "learning_rate_monitor": out_cb_list.append(LearningRateMonitor(logging_interval="epoch")) diff --git a/fd_shifts/models/callbacks/confid_monitor.py b/fd_shifts/models/callbacks/confid_monitor.py index dcc86f5..c46edb7 100644 --- a/fd_shifts/models/callbacks/confid_monitor.py +++ b/fd_shifts/models/callbacks/confid_monitor.py @@ -1,9 +1,6 @@ import numpy as np import torch -from pytorch_lightning.callbacks import Callback -from pytorch_lightning.trainer.connectors.logger_connector.logger_connector import ( - LoggerConnector, -) +from lightning import Callback from rich import print from tqdm import tqdm @@ -108,9 +105,7 @@ def on_train_start(self, trainer, pl_module): ) pl_module.loggers[0].log_hyperparams(self.tensorboard_hparams, hp_metrics) - def on_train_batch_end( - self, trainer, pl_module, outputs, batch, batch_idx, dataloader_idx - ): + def on_train_batch_end(self, trainer, pl_module, outputs, batch, batch_idx): loss = outputs["loss"].cpu() softmax = outputs["softmax"].cpu() y = outputs["labels"].cpu() @@ -224,7 +219,7 @@ def on_train_epoch_end(self, trainer, pl_module): self.running_train_correct_sum_sanity = 0 def on_validation_batch_end( - self, trainer, pl_module, outputs, batch, batch_idx, dataloader_idx + self, trainer, pl_module, outputs, batch, batch_idx, dataloader_idx=0 ): tmp_correct = None loss = outputs["loss"] diff --git a/fd_shifts/models/callbacks/training_stages.py b/fd_shifts/models/callbacks/training_stages.py deleted file mode 100644 index fe5eb83..0000000 --- a/fd_shifts/models/callbacks/training_stages.py +++ /dev/null @@ -1,237 +0,0 @@ -from collections import OrderedDict -from copy import deepcopy -from typing import Any - -import torch -from pytorch_lightning.callbacks import Callback -from pytorch_lightning.core import optimizer as pl_optimizer - -from fd_shifts import logger - - -def _init_optimizers_and_lr_schedulers(optim_conf: Any): - """Calls `LightningModule.configure_optimizers` and parses and validates the output.""" - - ( - optimizers, - lr_schedulers, - optimizer_frequencies, - monitor, - ) = pl_optimizer._configure_optimizers(optim_conf) - lr_scheduler_configs = pl_optimizer._configure_schedulers_automatic_opt( - lr_schedulers, monitor - ) - pl_optimizer._set_scheduler_opt_idx(optimizers, lr_scheduler_configs) - return optimizers, lr_scheduler_configs, optimizer_frequencies - - -class TrainingStages(Callback): - """Training stages for ConfidNet training - - Attributes: - milestones: - disable_dropout_at_finetuning: - """ - - def __init__(self, milestones, disable_dropout_at_finetuning): - self.milestones = milestones - self.disable_dropout_at_finetuning = disable_dropout_at_finetuning - - def on_train_start(self, trainer, pl_module): - if pl_module.pretrained_backbone_path is not None: - self.milestones[1] = self.milestones[1] - self.milestones[0] - self.milestones[0] = 0 - - def on_train_epoch_start(self, trainer, pl_module): - if ( - pl_module.current_epoch == self.milestones[0] - ): # this is the end before the queried epoch - logger.info("Starting Training ConfidNet") - pl_module.training_stage = 1 - if ( - pl_module.pretrained_backbone_path is None - ): # trained from scratch, reload best epoch - best_ckpt_path = trainer.checkpoint_callbacks[ - 0 - ].last_model_path # No backbone model selection!! - logger.info("Check last backbone path {}", best_ckpt_path) - else: - best_ckpt_path = pl_module.pretrained_backbone_path - - loaded_ckpt = torch.load(best_ckpt_path) - loaded_state_dict = loaded_ckpt["state_dict"] - - backbone_encoder_state_dict = OrderedDict( - (k.replace("backbone.encoder.", ""), v) - for k, v in loaded_state_dict.items() - if "backbone.encoder." in k - ) - if len(backbone_encoder_state_dict) == 0: - backbone_encoder_state_dict = loaded_state_dict - backbone_classifier_state_dict = OrderedDict( - (k.replace("backbone.classifier.", ""), v) - for k, v in loaded_state_dict.items() - if "backbone.classifier." in k - ) - - pl_module.backbone.encoder.load_state_dict( - backbone_encoder_state_dict, strict=True - ) - pl_module.backbone.classifier.load_state_dict( - backbone_classifier_state_dict, strict=True - ) - pl_module.network.encoder.load_state_dict( - backbone_encoder_state_dict, strict=True - ) - pl_module.network.classifier.load_state_dict( - backbone_classifier_state_dict, strict=True - ) - - logger.info( - "loaded checkpoint {} from epoch {} into backbone and network.".format( - best_ckpt_path, loaded_ckpt["epoch"] - ) - ) - - pl_module.network.encoder = deepcopy(pl_module.backbone.encoder) - pl_module.network.classifier = deepcopy(pl_module.backbone.classifier) - - logger.info("freezing backbone and enabling confidnet") - self.freeze_layers(pl_module.backbone.encoder) - self.freeze_layers(pl_module.backbone.classifier) - self.freeze_layers(pl_module.network.encoder) - self.freeze_layers(pl_module.network.classifier) - - optim_conf: torch.optim.Optimizer | dict[str, Any] = torch.optim.Adam( - pl_module.network.confid_net.parameters(), - lr=pl_module.learning_rate_confidnet, - ) - - if pl_module.confidnet_lr_scheduler: - logger.info("initializing new scheduler for confidnet...") - optim_conf = { - "optimizer": optim_conf, - "lr_scheduler": { - "scheduler": torch.optim.lr_scheduler.CosineAnnealingLR( - optimizer=optim_conf, - T_max=self.milestones[1] - self.milestones[0], - verbose=True, - ), - "interval": "epoch", - "frequency": 1, - "name": "confidnet_adam", - }, - } - - ( - trainer.strategy.optimizers, - trainer.strategy.lr_scheduler_configs, - trainer.strategy.optimizer_frequencies, - ) = _init_optimizers_and_lr_schedulers(optim_conf) - - lr_monitor = [x for x in trainer.callbacks if "lr_monitor" in x.__str__()] - if len(lr_monitor) > 0: - lr_monitor[0].__init__() - lr_monitor[0].on_train_start(trainer) - - if pl_module.current_epoch >= self.milestones[0]: - self.disable_bn(pl_module.backbone.encoder) - self.disable_bn(pl_module.network.encoder) - for param_group in trainer.optimizers[0].param_groups: - logger.info("CHECK ConfidNet RATE {}", param_group["lr"]) - - if pl_module.current_epoch == self.milestones[1]: - logger.info( - "Starting Training Fine Tuning ConfidNet" - ) # new optimizer or add param groups? both adam according to paper! - pl_module.training_stage = 2 - if pl_module.pretrained_confidnet_path is not None: - best_ckpt_path = pl_module.pretrained_confidnet_path - elif ( - hasattr(pl_module, "test_selection_criterion") - and "latest" not in pl_module.test_selection_criterion - ): - best_ckpt_path = trainer.checkpoint_callbacks[1].best_model_path - logger.info( - "Test selection criterion {}", pl_module.test_selection_criterion - ) - logger.info("Check BEST confidnet path {}", best_ckpt_path) - else: - best_ckpt_path = None - logger.info("going with latest confidnet") - if best_ckpt_path is not None: - loaded_ckpt = torch.load(best_ckpt_path) - loaded_state_dict = loaded_ckpt["state_dict"] - loaded_state_dict = OrderedDict( - (k.replace("network.confid_net.", ""), v) - for k, v in loaded_state_dict.items() - if "network.confid_net" in k - ) - pl_module.network.confid_net.load_state_dict( - loaded_state_dict, strict=True - ) - logger.info( - "loaded checkpoint {} from epoch {} into new encoder".format( - best_ckpt_path, loaded_ckpt["epoch"] - ) - ) - - self.unfreeze_layers(pl_module.network.encoder) - new_optimizer = torch.optim.Adam( - pl_module.network.parameters(), - lr=pl_module.learning_rate_confidnet_finetune, - ) - trainer.optimizers = [new_optimizer] - trainer.optimizer_frequencies = [] - - if self.disable_dropout_at_finetuning: - if pl_module.current_epoch >= self.milestones[1]: - self.disable_dropout(pl_module.backbone.encoder) - self.disable_dropout(pl_module.network.encoder) - - def freeze_layers(self, model, freeze_string=None, keep_string=None): - for param in model.named_parameters(): - if freeze_string is None and keep_string is None: - param[1].requires_grad = False - if freeze_string is not None and freeze_string in param[0]: - param[1].requires_grad = False - if keep_string is not None and keep_string not in param[0]: - param[1].requires_grad = False - - def unfreeze_layers(self, model, unfreeze_string=None): - for param in model.named_parameters(): - if unfreeze_string is None or unfreeze_string in param[0]: - param[1].requires_grad = True - - def disable_bn(self, model): - # Freeze also BN running average parameters - for layer in model.named_modules(): - if ( - "bn" in layer[0] - or "cbr_unit.1" in layer[0] - or isinstance(layer[1], torch.nn.BatchNorm2d) - ): - layer[1].momentum = 0 - layer[1].eval() - - def disable_dropout(self, model): - for layer in model.named_modules(): - if "dropout" in layer[0] or isinstance(layer[1], torch.nn.Dropout): - layer[1].eval() - - def check_weight_consistency(self, pl_module): - for ix, x in enumerate(pl_module.backbone.named_parameters()): - if ix == 0: - logger.debug("BACKBONE {} {}", x[0], x[1].mean().item()) - - for ix, x in enumerate(pl_module.network.encoder.named_parameters()): - if ix == 0: - logger.debug("CONFID ENCODER {} {}", x[0], x[1].mean().item()) - - for ix, x in enumerate(pl_module.network.confid_net.named_parameters()): - if ix == 0: - logger.debug("CONFIDNET {} {}", x[0], x[1].mean().item()) - - for ix, x in enumerate(pl_module.network.classifier.named_parameters()): - if ix == 0: - logger.debug("CONFID CLassifier {} {}", x[0], x[1].mean().item()) diff --git a/fd_shifts/models/confidnet_model.py b/fd_shifts/models/confidnet_model.py index 620155e..183ffb6 100644 --- a/fd_shifts/models/confidnet_model.py +++ b/fd_shifts/models/confidnet_model.py @@ -1,11 +1,11 @@ from __future__ import annotations import re +from collections import OrderedDict from pathlib import Path from typing import TYPE_CHECKING, Any -import hydra -import pytorch_lightning as pl +import lightning as L import torch from torch import nn from torch.nn import functional as F @@ -20,7 +20,7 @@ from fd_shifts import configs -class Module(pl.LightningModule): +class Module(L.LightningModule): """ Attributes: @@ -51,6 +51,7 @@ class Module(pl.LightningModule): def __init__(self, cf: configs.Config): super().__init__() + self.automatic_optimization = False self.save_hyperparameters(to_dict(cf)) self.conf = cf @@ -94,6 +95,11 @@ def __init__(self, cf: configs.Config): self.test_results: dict[str, torch.Tensor | None] = {} + self.milestones = cf.trainer.callbacks["training_stages"]["milestones"] + self.disable_dropout_at_finetuning = cf.trainer.callbacks["training_stages"][ + "disable_dropout_at_finetuning" + ] + # pylint: disable=arguments-differ def forward(self, x: torch.Tensor) -> torch.Tensor: """ @@ -145,6 +151,117 @@ def on_train_start(self) -> None: tqdm.write(str(ix)) tqdm.write(str(x[1])) + if self.pretrained_backbone_path is not None: + self.milestones[1] = self.milestones[1] - self.milestones[0] + self.milestones[0] = 0 + + def on_train_epoch_start(self): + if ( + self.current_epoch == self.milestones[0] + ): # this is the end before the queried epoch + logger.info("Starting Training ConfidNet") + self.training_stage = 1 + if ( + self.pretrained_backbone_path is None + ): # trained from scratch, reload best epoch + best_ckpt_path = self.trainer.checkpoint_callbacks[ + 0 + ].last_model_path # No backbone model selection!! + logger.info("Check last backbone path {}", best_ckpt_path) + else: + best_ckpt_path = self.pretrained_backbone_path + + loaded_ckpt = torch.load(best_ckpt_path) + loaded_state_dict = loaded_ckpt["state_dict"] + + backbone_encoder_state_dict = OrderedDict( + (k.replace("backbone.encoder.", ""), v) + for k, v in loaded_state_dict.items() + if "backbone.encoder." in k + ) + if len(backbone_encoder_state_dict) == 0: + backbone_encoder_state_dict = loaded_state_dict + backbone_classifier_state_dict = OrderedDict( + (k.replace("backbone.classifier.", ""), v) + for k, v in loaded_state_dict.items() + if "backbone.classifier." in k + ) + + self.backbone.encoder.load_state_dict( + backbone_encoder_state_dict, strict=True + ) + self.backbone.classifier.load_state_dict( + backbone_classifier_state_dict, strict=True + ) + self.network.encoder.load_state_dict( + backbone_encoder_state_dict, strict=True + ) + self.network.classifier.load_state_dict( + backbone_classifier_state_dict, strict=True + ) + + logger.info( + "loaded checkpoint {} from epoch {} into backbone and network.".format( + best_ckpt_path, loaded_ckpt["epoch"] + ) + ) + + self.network.encoder = deepcopy(self.backbone.encoder) + self.network.classifier = deepcopy(self.backbone.classifier) + + logger.info("freezing backbone and enabling confidnet") + self.freeze_layers(self.backbone.encoder) + self.freeze_layers(self.backbone.classifier) + self.freeze_layers(self.network.encoder) + self.freeze_layers(self.network.classifier) + + if self.current_epoch >= self.milestones[0]: + self.disable_bn(self.backbone.encoder) + self.disable_bn(self.network.encoder) + for param_group in trainer.optimizers[0].param_groups: + logger.info("CHECK ConfidNet RATE {}", param_group["lr"]) + + if self.current_epoch == self.milestones[1]: + logger.info( + "Starting Training Fine Tuning ConfidNet" + ) # new optimizer or add param groups? both adam according to paper! + self.training_stage = 2 + if self.pretrained_confidnet_path is not None: + best_ckpt_path = self.pretrained_confidnet_path + elif ( + hasattr(self, "test_selection_criterion") + and "latest" not in self.test_selection_criterion + ): + best_ckpt_path = trainer.checkpoint_callbacks[1].best_model_path + logger.info( + "Test selection criterion {}", self.test_selection_criterion + ) + logger.info("Check BEST confidnet path {}", best_ckpt_path) + else: + best_ckpt_path = None + logger.info("going with latest confidnet") + if best_ckpt_path is not None: + loaded_ckpt = torch.load(best_ckpt_path) + loaded_state_dict = loaded_ckpt["state_dict"] + loaded_state_dict = OrderedDict( + (k.replace("network.confid_net.", ""), v) + for k, v in loaded_state_dict.items() + if "network.confid_net" in k + ) + self.network.confid_net.load_state_dict(loaded_state_dict, strict=True) + logger.info( + "loaded checkpoint {} from epoch {} into new encoder".format( + best_ckpt_path, loaded_ckpt["epoch"] + ) + ) + + self.unfreeze_layers(self.network.encoder) + + if self.disable_dropout_at_finetuning: + if self.current_epoch >= self.milestones[1]: + self.disable_dropout(self.backbone.encoder) + self.disable_dropout(self.network.encoder) + def training_step( self, batch: tuple[torch.Tensor, torch.Tensor], batch_idx: int ) -> dict[str, torch.Tensor | None]: @@ -159,20 +276,41 @@ def training_step( Raises: ValueError: if somehow the training stage goes beyond 2 """ + optimizer = self.optimizers()[self.training_stage] + if self.training_stage == 0: + lr_sched = self.lr_schedulers()[0] + x, y = batch logits = self.backbone(x) - loss = self.loss_ce(logits, y) + loss = self.loss_ce(logits, y) / self.conf.trainer.accumulate_grad_batches + self.manual_backward(loss) + if batch_idx % self.conf.trainer.accumulate_grad_batches == 0: + self.clip_gradients(optimizer, 1) + optimizer.step() + optimizer.zero_grad() + lr_sched.step() softmax = F.softmax(logits, dim=1) return {"loss": loss, "softmax": softmax, "labels": y, "confid": None} if self.training_stage == 1: + lr_sched = self.lr_schedulers()[1] + x, y = batch outputs = self.network(x) softmax = F.softmax(outputs[0], dim=1) pred_confid = torch.sigmoid(outputs[1]) tcp = softmax.gather(1, y.unsqueeze(1)) - loss = F.mse_loss(pred_confid, tcp) + loss = ( + F.mse_loss(pred_confid, tcp) / self.conf.trainer.accumulate_grad_batches + ) + self.manual_backward(loss) + if batch_idx % self.conf.trainer.accumulate_grad_batches == 0: + self.clip_gradients(optimizer, 1) + optimizer.step() + optimizer.zero_grad() + if self.trainer.is_last_batch: + lr_sched.step() return { "loss": loss, "softmax": softmax, @@ -186,7 +324,14 @@ def training_step( _, pred_confid = self.network(x) pred_confid = torch.sigmoid(pred_confid) tcp = softmax.gather(1, y.unsqueeze(1)) - loss = F.mse_loss(pred_confid, tcp) + loss = ( + F.mse_loss(pred_confid, tcp) / self.conf.trainer.accumulate_grad_batches + ) + self.manual_backward(loss) + if batch_idx % self.conf.trainer.accumulate_grad_batches == 0: + self.clip_gradients(optimizer, 1) + optimizer.step() + optimizer.zero_grad() return { "loss": loss, "softmax": softmax, @@ -288,16 +433,34 @@ def configure_optimizers( ) -> tuple[ list[torch.optim.Optimizer], list[torch.optim.lr_scheduler._LRScheduler] ]: + # one optimizer per training stage optimizers = [ - hydra.utils.instantiate(self.conf.trainer.optimizer, _partial_=True)( - self.backbone.parameters() - ) + # backbone training + self.conf.trainer.optimizer(self.backbone.parameters()), + # confidnet training + torch.optim.Adam( + self.network.confid_net.parameters(), + lr=self.conf.trainer.learning_rate_confidnet, + ), + # backbone fine-tuning + torch.optim.Adam( + self.network.parameters(), + lr=self.conf.trainer.learning_rate_confidnet_finetune, + ), ] schedulers = [ - hydra.utils.instantiate(self.conf.trainer.lr_scheduler)( - optimizer=optimizers[0] - ) + self.conf.trainer.lr_scheduler(optimizers[0]), + { + "scheduler": torch.optim.lr_scheduler.CosineAnnealingLR( + optimizer=optimizers[1], + T_max=self.milestones[1] - self.milestones[0], + verbose=True, + ), + "interval": "epoch", + "frequency": 1, + "name": "confidnet_adam", + }, ] return optimizers, schedulers @@ -350,3 +513,50 @@ def last_layer(self): raise RuntimeError("No classifier weights found") return w, b + + def freeze_layers(self, model, freeze_string=None, keep_string=None): + for param in model.named_parameters(): + if freeze_string is None and keep_string is None: + param[1].requires_grad = False + if freeze_string is not None and freeze_string in param[0]: + param[1].requires_grad = False + if keep_string is not None and keep_string not in param[0]: + param[1].requires_grad = False + + def unfreeze_layers(self, model, unfreeze_string=None): + for param in model.named_parameters(): + if unfreeze_string is None or unfreeze_string in param[0]: + param[1].requires_grad = True + + def disable_bn(self, model): + # Freeze also BN running average parameters + for layer in model.named_modules(): + if ( + "bn" in layer[0] + or "cbr_unit.1" in layer[0] + or isinstance(layer[1], torch.nn.BatchNorm2d) + ): + layer[1].momentum = 0 + layer[1].eval() + + def disable_dropout(self, model): + for layer in model.named_modules(): + if "dropout" in layer[0] or isinstance(layer[1], torch.nn.Dropout): + layer[1].eval() + + def check_weight_consistency(self, pl_module): + for ix, x in enumerate(pl_module.backbone.named_parameters()): + if ix == 0: + logger.debug("BACKBONE {} {}", x[0], x[1].mean().item()) + + for ix, x in enumerate(pl_module.network.encoder.named_parameters()): + if ix == 0: + logger.debug("CONFID ENCODER {} {}", x[0], x[1].mean().item()) + + for ix, x in enumerate(pl_module.network.confid_net.named_parameters()): + if ix == 0: + logger.debug("CONFIDNET {} {}", x[0], x[1].mean().item()) + + for ix, x in enumerate(pl_module.network.classifier.named_parameters()): + if ix == 0: + logger.debug("CONFID CLassifier {} {}", x[0], x[1].mean().item()) diff --git a/fd_shifts/models/devries_model.py b/fd_shifts/models/devries_model.py index 075e3d6..f21267e 100644 --- a/fd_shifts/models/devries_model.py +++ b/fd_shifts/models/devries_model.py @@ -3,9 +3,7 @@ import re from typing import TYPE_CHECKING -import hydra -import pl_bolts -import pytorch_lightning as pl +import lightning as L import torch from torch import nn from torch.nn import functional as F @@ -19,7 +17,7 @@ from fd_shifts import configs -class net(pl.LightningModule): +class net(L.LightningModule): """ Attributes: @@ -119,7 +117,7 @@ def mcd_eval_forward(self, x, n_samples): return torch.cat(softmax_list, dim=2), torch.cat(conf_list, dim=1) - def on_epoch_end(self): + def on_train_epoch_end(self): if ( self.ext_confid_name == "dg" and ( diff --git a/fd_shifts/models/vit_model.py b/fd_shifts/models/vit_model.py index 631888b..49bb7db 100644 --- a/fd_shifts/models/vit_model.py +++ b/fd_shifts/models/vit_model.py @@ -1,20 +1,11 @@ from __future__ import annotations -import json -from itertools import islice from typing import TYPE_CHECKING -import hydra -import numpy as np -import pl_bolts -import pytorch_lightning as pl +import lightning as L import timm import torch import torch.nn as nn -from pytorch_lightning.utilities.parsing import AttributeDict -from rich import get_console -from rich.progress import track -from tqdm import tqdm from fd_shifts import logger from fd_shifts.utils import to_dict @@ -23,7 +14,7 @@ from fd_shifts import configs -class net(pl.LightningModule): +class net(L.LightningModule): """Vision Transformer module""" def __init__(self, cfg: configs.Config): @@ -44,12 +35,7 @@ def __init__(self, cfg: configs.Config): self.model.head.weight.tensor = torch.zeros_like(self.model.head.weight) self.model.head.bias.tensor = torch.zeros_like(self.model.head.bias) - self.mean = torch.zeros((self.config.data.num_classes, self.model.num_features)) - self.icov = torch.eye(self.model.num_features) - self.ext_confid_name = self.config.eval.ext_confid_name - self.latent = [] - self.labels = [] self.query_confids = cfg.eval.confidence_measures self.test_mcd_samples = 50 @@ -72,13 +58,6 @@ def mcd_eval_forward(self, x, n_samples): for _ in range(n_samples - len(softmax_list)): z = self.model.forward_features(x) probs = self.model.head(z) - maha = None - if any("ext" in cfd for cfd in self.query_confids.test): - zm = z[:, None, :] - self.mean - - maha = -(torch.einsum("inj,jk,ink->in", zm, self.icov, zm)) - maha = maha.max(dim=1)[0].type_as(x).unsqueeze(1) - conf_list.append(maha) softmax_list.append(probs.unsqueeze(2)) @@ -95,115 +74,31 @@ def forward(self, x): def training_step(self, batch, batch_idx): x, y = batch z = self.model.forward_features(x) - probs = self.model.head(z) + probs = self.model.forward_head(z) loss = torch.nn.functional.cross_entropy(probs, y) - self.latent.append(z.cpu()) - self.labels.append(y.cpu()) - return {"loss": loss, "softmax": torch.softmax(probs, dim=1), "labels": y} - def training_step_end(self, batch_parts): - batch_parts["loss"] = batch_parts["loss"].mean() - return batch_parts - - def training_epoch_end(self, outputs): - with torch.no_grad(): - z = torch.cat(self.latent, dim=0) - y = torch.cat(self.labels, dim=0) - - mean = [] - for c in y.unique(): - mean.append(z[y == c].mean(dim=0)) - - mean = torch.stack(mean, dim=0) - self.mean = mean - self.icov = torch.inverse( - torch.tensor(np.cov(z.numpy(), rowvar=False)).type_as( - self.model.head.weight - ) - ).cpu() - - self.latent = [] - self.labels = [] - def validation_step(self, batch, batch_idx, dataloader_idx=0): x, y = batch - if dataloader_idx > 0: - y = y.fill_(0) - y = y.long() - z = self.model.forward_features(x) - zm = z[:, None, :].cpu() - self.mean - - maha = -(torch.einsum("inj,jk,ink->in", zm, self.icov, zm)) - maha = maha.max(dim=1)[0] - - probs = self.model.head(z) + probs = self.model.forward_head(z) loss = torch.nn.functional.cross_entropy(probs, y) return { "loss": loss, "softmax": torch.softmax(probs, dim=1), "labels": y, - "confid": maha.type_as(x), + "confid": None, } def validation_step_end(self, batch_parts): return batch_parts - def on_test_start(self, *args): - if not any("ext" in cfd for cfd in self.query_confids.test): - return - logger.info("Calculating trainset mean and cov") - all_z = [] - all_y = [] - get_console().clear_live() - tracker = track( - self.trainer.datamodule.train_dataloader(), console=get_console() - ) - - if self.config.trainer.fast_dev_run: - tracker = track( - islice( - self.trainer.datamodule.train_dataloader(), - self.config.trainer.fast_dev_run, - ), - console=get_console(), - ) - - for x, y in tracker: - x = x.type_as(self.model.head.weight) - y = y.type_as(self.model.head.weight) - z = self.model.forward_features(x) - all_z.append(z.cpu()) - all_y.append(y.cpu()) - - all_z = torch.cat(all_z, dim=0) - all_y = torch.cat(all_y, dim=0) - - if torch.isnan(all_z).any(): - logger.error("NaN in z's: {}%", torch.isnan(all_z).any(dim=1).mean() * 100) - - mean = [] - for c in all_y.unique(): - mean.append(all_z[all_y == c].mean(dim=0)) - - mean = torch.stack(mean, dim=0) - self.mean = mean.type_as(self.model.head.weight) - self.icov = torch.inverse(torch.cov(all_z.type_as(self.model.head.weight).T)) - def test_step(self, batch, batch_idx, *args): x, y = batch z = self.model.forward_features(x) - - maha = None - if any("ext" in cfd for cfd in self.query_confids.test): - zm = z[:, None, :] - self.mean - - maha = -(torch.einsum("inj,jk,ink->in", zm, self.icov, zm)) - maha = maha.max(dim=1)[0].type_as(x) - # maha final ist abstand zu most likely class + z = self.model.forward_head(z, pre_logits=True) probs = self.model.head(z) logits_dist = None @@ -216,34 +111,25 @@ def test_step(self, batch, batch_idx, *args): return { "logits": probs, "labels": y, - "confid": maha, + "confid": None, "logits_dist": logits_dist, "confid_dist": confid_dist, "encoded": z, } def configure_optimizers(self): - optim = hydra.utils.instantiate( - self.config.trainer.optimizer, - _convert_="all", - _partial_=False, - params=self.model.parameters(), - ) + optim = self.config.trainer.optimizer(self.model.parameters()) - lr_sched = { - "scheduler": hydra.utils.instantiate(self.config.trainer.lr_scheduler)( - optimizer=optim - ), - "interval": "step", - } + lr_sched = [ + { + "scheduler": self.config.trainer.lr_scheduler(optim), + "interval": "step", + } + ] - optimizers = { - "optimizer": optim, - "lr_scheduler": lr_sched, - "frequency": 1, - } + optimizers = [optim] - return optimizers + return optimizers, lr_sched def load_only_state_dict(self, path): ckpt = torch.load(path) diff --git a/pyproject.toml b/pyproject.toml index 5e530d7..55bbce9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -5,10 +5,11 @@ build-backend = "setuptools.build_meta" [project] name = "fd_shifts" dynamic = ["version"] -requires-python = ">=3.10" +requires-python = ">=3.11" dependencies = [ "albumentations>=1.0.3", "deepdiff", + "faiss-cpu", "hydra-colorlog>=1.1.0", "hydra-core>=1.1.1", "hydra-zen", @@ -26,8 +27,8 @@ dependencies = [ "Pillow==9.5.0", "protobuf<=3.20.0", "pydantic>=1.10.0,<2.0.0", - "pytorch-lightning-bolts>=0.3.2", - "pytorch-lightning==1.6.5", + "lightning-bolts==0.7.0", + "lightning==2.2.1", "rich>=10.7.0", "robustness @ https://github.com/MadryLab/robustness/archive/master.tar.gz", "scikit-image>=0.18.2", @@ -36,9 +37,9 @@ dependencies = [ "seaborn>=0.11.1", "shtab", "tensorboard>=2.4.1", - "timm==0.5.4", + "timm>=0.5.4", "toml>=0.10.2", - "torch>=1.11.0,<2.0.0", + "torch>=2.0.0", "torchmetrics>=0.2.0", "torchvision>=0.12.0", "tqdm>=4.62.0", @@ -57,16 +58,10 @@ dev = [ "pylint", "black", "debugpy", - "pre-commit" -] -docs = [ - "jupyterlab", - "notebook", - "ipykernel", -] -launcher = [ - "parallel-ssh", + "pre-commit", ] +docs = ["jupyterlab", "notebook", "ipykernel"] +launcher = ["parallel-ssh"] [project.scripts] fd_shifts = "fd_shifts.cli:main" From 1e83b5cde374ddec5d3e0a51b9ef586061054ab6 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Fri, 5 Apr 2024 14:24:57 +0200 Subject: [PATCH 103/136] fix: newer pytorch needs benchmark=False to function --- fd_shifts/configs/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index b932e0d..783245a 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -219,7 +219,7 @@ class TrainerConfig(_IterableMixin): do_val: bool = True batch_size: int = 128 resume_from_ckpt: bool = False - benchmark: bool = True + benchmark: bool = False fast_dev_run: bool | int = False # lr_scheduler: Callable[ # [torch.optim.Optimizer], torch.optim.lr_scheduler._LRScheduler From 1ee2629f09a36c2f68e04bec886eb416622ca4f8 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Fri, 5 Apr 2024 16:04:03 +0200 Subject: [PATCH 104/136] fix(deps): update pillow because non-deterministic cuda error --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 55bbce9..89a8caa 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -24,7 +24,7 @@ dependencies = [ "omegaconf>=2.1.1", "opencv-python-headless", "pandas>=1.2.3", - "Pillow==9.5.0", + "Pillow>=9.5.0", "protobuf<=3.20.0", "pydantic>=1.10.0,<2.0.0", "lightning-bolts==0.7.0", From f253a7deae334429f7cf5e31a25b0e5de28361c4 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 4 Jun 2024 17:24:01 +0200 Subject: [PATCH 105/136] feat: make subsampling configurable --- fd_shifts/loaders/data_loader.py | 6 ++++-- fd_shifts/loaders/dataset_collection.py | 4 ++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index f767a10..4008e29 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -63,7 +63,7 @@ def __init__(self, cf: configs.Config, no_norm_flag=False): ) if len(self.external_test_sets) > 0: - self.external_test_configs = {} + self.external_test_configs: dict[str, configs.DataConfig] = {} for i, ext_set in enumerate(self.external_test_sets): overwrite_dataset = False if isinstance(ext_set, str): @@ -280,7 +280,9 @@ def setup(self, stage=None): target_transform=self.target_transforms, transform=self.augmentations["external_{}".format(ext_set)], kwargs=self.dataset_kwargs, - config=self.external_test_configs[ext_set], + subsample_corruptions=self.external_test_configs[ + ext_set + ].subsample_corruptions, ) if ( self.devries_repro_ood_split diff --git a/fd_shifts/loaders/dataset_collection.py b/fd_shifts/loaders/dataset_collection.py index 54de4d6..7b16af0 100644 --- a/fd_shifts/loaders/dataset_collection.py +++ b/fd_shifts/loaders/dataset_collection.py @@ -1296,7 +1296,7 @@ def get_dataset( transform: Callable, target_transform: Callable | None, kwargs: dict[str, Any], - config: DataConfig | None = None, + subsample_corruptions: int = 1, ) -> Any: """Return a new instance of a dataset @@ -1324,7 +1324,7 @@ def get_dataset( "train": train, "download": download, "transform": transform, - "subsample": config.subsample_corruptions if config else 1, + "subsample": subsample_corruptions, } if name.startswith("svhn"): pass_kwargs = { From 807bce954d48481606a2591408fd40f989f9b952 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 17 Apr 2024 13:35:35 +0200 Subject: [PATCH 106/136] fix: output dtypes and shape --- fd_shifts/models/callbacks/confid_monitor.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/fd_shifts/models/callbacks/confid_monitor.py b/fd_shifts/models/callbacks/confid_monitor.py index c46edb7..cd7c205 100644 --- a/fd_shifts/models/callbacks/confid_monitor.py +++ b/fd_shifts/models/callbacks/confid_monitor.py @@ -496,13 +496,17 @@ def on_test_batch_end( ) self.running_test_labels.extend(outputs["labels"].cpu()) if "ext" in self.query_confids.test: - self.running_test_external_confids.extend(outputs["confid"].cpu()) + self.running_test_external_confids.extend( + outputs["confid"].to(dtype=self.output_dtype).cpu() + ) if outputs.get("logits_dist") is not None: self.running_test_softmax_dist.extend( outputs["logits_dist"].to(dtype=self.output_dtype).cpu() ) if outputs.get("confid_dist") is not None: - self.running_test_external_confids_dist.extend(outputs["confid_dist"].cpu()) + self.running_test_external_confids_dist.extend( + outputs["confid_dist"].to(dtype=self.output_dtype).cpu() + ) self.running_test_dataset_idx.extend( torch.ones_like(outputs["labels"].cpu()) * dataloader_idx @@ -590,7 +594,7 @@ def on_test_end(self, trainer, pl_module): if len(self.running_test_external_confids) > 0: stacked_external_confids = torch.stack( self.running_test_external_confids, dim=0 - ) + ).squeeze() np.savez_compressed( self.output_paths.test.external_confids, stacked_external_confids.cpu().data.numpy(), From 0a27a61f6e6a63327e3313617a5b2cecc05d889a Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Wed, 17 Apr 2024 13:36:15 +0200 Subject: [PATCH 107/136] chore: clean up main --- fd_shifts/exec.py | 323 ---------------------------------------------- fd_shifts/main.py | 120 +++++++++-------- 2 files changed, 69 insertions(+), 374 deletions(-) delete mode 100644 fd_shifts/exec.py diff --git a/fd_shifts/exec.py b/fd_shifts/exec.py deleted file mode 100644 index aa7f4d4..0000000 --- a/fd_shifts/exec.py +++ /dev/null @@ -1,323 +0,0 @@ -import os -import random -from pathlib import Path -from typing import cast - -import hydra -import pytorch_lightning as pl -import torch -from omegaconf import DictConfig, OmegaConf -from pytorch_lightning.callbacks import RichProgressBar -from pytorch_lightning.loggers import CSVLogger, TensorBoardLogger, WandbLogger -from rich import get_console, reconfigure - -from fd_shifts import analysis, configs, logger -from fd_shifts.loaders.data_loader import FDShiftsDataLoader -from fd_shifts.models import get_model -from fd_shifts.models.callbacks import get_callbacks -from fd_shifts.utils import exp_utils - -configs.init() - - -def train( - cf: configs.Config, - progress: RichProgressBar = RichProgressBar(), - subsequent_testing: bool = False, -) -> None: - """ - perform the training routine for a given fold. saves plots and selected parameters to the experiment dir - specified in the configs. - """ - - logger.info("CHECK CUDNN VERSION", torch.backends.cudnn.version()) # type: ignore - train_deterministic_flag = False - if cf.exp.global_seed is not None: - exp_utils.set_seed(cf.exp.global_seed) - cf.trainer.benchmark = False - logger.info( - "setting seed {}, benchmark to False for deterministic training.".format( - cf.exp.global_seed - ) - ) - - resume_ckpt_path = None - cf.exp.version = exp_utils.get_next_version(cf.exp.dir) - cf.exp.version_dir = cf.exp.version_dir.parent / f"version_{cf.exp.version}" - if cf.trainer.resume_from_ckpt: - cf.exp.version -= 1 - resume_ckpt_path = exp_utils._get_resume_ckpt_path(cf) - logger.info("resuming previous training:", resume_ckpt_path) - - if cf.trainer.resume_from_ckpt_confidnet: - cf.exp.version -= 1 - cf.trainer.callbacks.training_stages.pretrained_confidnet_path = ( # type: ignore - exp_utils._get_resume_ckpt_path(cf) - ) - logger.info("resuming previous training:", resume_ckpt_path) - - if "openset" in cf.data.dataset: - if cf.data.kwargs is None: - cf.data.kwargs = {} - cf.data.kwargs["out_classes"] = cf.data.kwargs.get( - "out_classes", - random.sample(range(cf.data.num_classes), int(0.4 * cf.data.num_classes)), - ) - - max_steps = cf.trainer.num_steps if hasattr(cf.trainer, "num_steps") else None - accumulate_grad_batches = ( - cf.trainer.accumulate_grad_batches - if hasattr(cf.trainer, "accumulate_grad_batches") - else 1 - ) - - limit_batches: float | int = 1.0 - num_epochs = cf.trainer.num_epochs - val_every_n_epoch = cf.trainer.val_every_n_epoch - log_every_n_steps = 50 - - if isinstance(cf.trainer.fast_dev_run, bool): - limit_batches = 1 if cf.trainer.fast_dev_run else 1.0 - num_epochs = 1 if cf.trainer.fast_dev_run else num_epochs - max_steps = 1 if cf.trainer.fast_dev_run else max_steps - val_every_n_epoch = 1 if cf.trainer.fast_dev_run else val_every_n_epoch - elif isinstance(cf.trainer.fast_dev_run, int): - limit_batches = cf.trainer.fast_dev_run * accumulate_grad_batches - max_steps = cf.trainer.fast_dev_run * 2 - cf.trainer.dg_pretrain_epochs = None - cf.trainer.dg_pretrain_steps = (max_steps * 2) // 3 - val_every_n_epoch = 1 - log_every_n_steps = 1 - num_epochs = None - - datamodule = FDShiftsDataLoader(cf) - model = get_model(cf.model.name)(cf) - tb_logger = TensorBoardLogger( - save_dir=str(cf.exp.group_dir), - name=cf.exp.name, - default_hp_metric=False, - ) - csv_logger = CSVLogger( - save_dir=str(cf.exp.group_dir), name=cf.exp.name, version=cf.exp.version - ) - - wandb_logger = WandbLogger( - project="fd_shifts_proto", - name=cf.exp.name, - ) - - trainer = pl.Trainer( - accelerator="auto", - devices="auto", - logger=[tb_logger, csv_logger, wandb_logger], - log_every_n_steps=log_every_n_steps, - max_epochs=num_epochs, - max_steps=max_steps, # type: ignore - callbacks=[progress] + get_callbacks(cf), - resume_from_checkpoint=resume_ckpt_path, - benchmark=cf.trainer.benchmark, - precision=16, - check_val_every_n_epoch=val_every_n_epoch, - num_sanity_val_steps=5, - deterministic=train_deterministic_flag, - limit_train_batches=limit_batches, - limit_val_batches=0 if cf.trainer.do_val is False else limit_batches, - limit_test_batches=limit_batches, - gradient_clip_val=1, - accumulate_grad_batches=accumulate_grad_batches, - ) - - logger.info( - "logging training to: {}, version: {}".format(cf.exp.dir, cf.exp.version) - ) - trainer.fit(model=model, datamodule=datamodule) - - if subsequent_testing: - test(cf, progress) - - -def test(cf: configs.Config, progress: RichProgressBar = RichProgressBar()) -> None: - """Run inference - - Args: - cf (configs.Config): configuration object to run inference on - progress: (RichProgressBar): global progress bar - """ - if "best" in cf.test.selection_criterion and cf.test.only_latest_version is False: - ckpt_path = exp_utils._get_path_to_best_ckpt( - cf.exp.dir, cf.test.selection_criterion, cf.test.selection_mode - ) - else: - logger.info("CHECK cf.exp.dir", cf.exp.dir) - cf.exp.version = exp_utils.get_most_recent_version(cf.exp.dir) - cf.exp.version_dir = cf.exp.version_dir.parent / f"version_{cf.exp.version}" - ckpt_path = exp_utils._get_resume_ckpt_path(cf) - - logger.info( - "testing model from checkpoint: {} from model selection tpye {}".format( - ckpt_path, cf.test.selection_criterion - ) - ) - logger.info("logging testing to: {}".format(cf.test.dir)) - - module = get_model(cf.model.name)(cf) - - # TODO: make common module class with this method - module.load_only_state_dict(ckpt_path) # type: ignore - - datamodule = FDShiftsDataLoader(cf) - - if not os.path.exists(cf.test.dir): - os.makedirs(cf.test.dir) - - limit_batches: float | int = 1.0 - log_every_n_steps = 50 - - if isinstance(cf.trainer.fast_dev_run, bool): - limit_batches = 1 if cf.trainer.fast_dev_run else 1.0 - elif isinstance(cf.trainer.fast_dev_run, int): - limit_batches = cf.trainer.fast_dev_run - log_every_n_steps = 1 - - wandb_logger = WandbLogger( - project="fd_shifts_proto", - name=cf.exp.name, - ) - - trainer = pl.Trainer( - accelerator="auto", - devices="auto", - logger=wandb_logger, - log_every_n_steps=log_every_n_steps, - callbacks=[progress] + get_callbacks(cf), - limit_test_batches=limit_batches, - precision=16, - ) - trainer.test(model=module, datamodule=datamodule) - analysis.main( - in_path=cf.test.dir, - out_path=cf.test.dir, - query_studies=cf.eval.query_studies, - add_val_tuning=cf.eval.val_tuning, - threshold_plot_confid=None, - cf=cf, - ) - - -@hydra.main(config_path="configs", config_name="config", version_base="1.1") -def main(dconf: DictConfig) -> None: - """main entry point for running anything with a Trainer - - Args: - dconf (DictConfig): config passed in by hydra - """ - # multiprocessing.set_start_method("spawn") - - reconfigure(stderr=True, force_terminal=True) - progress = RichProgressBar(console_kwargs={"stderr": True, "force_terminal": True}) - logger.remove() # Remove default 'stderr' handler - - # We need to specify end=''" as log message already ends with \n (thus the lambda function) - # Also forcing 'colorize=True' otherwise Loguru won't recognize that the sink support colors - logger.add( - lambda m: get_console().print(m, end="", markup=False, highlight=False), - colorize=True, - enqueue=True, - level="DEBUG", - backtrace=True, - diagnose=True, - ) - - try: - # NOTE: Needed because hydra does not set this if we load a previous experiment - dconf._metadata.object_type = configs.Config - - def _fix_metadata(cfg: DictConfig) -> None: - if hasattr(cfg, "_target_"): - cfg._metadata.object_type = getattr( - configs, cfg._target_.split(".")[-1] - ) - for _, v in cfg.items(): - match v: - case DictConfig(): # type: ignore - _fix_metadata(v) - case _: - pass - - _fix_metadata(dconf) - conf: configs.Config = cast(configs.Config, OmegaConf.to_object(dconf)) - - conf.__pydantic_validate_values__() # type: ignore - - if conf.exp.mode == configs.Mode.train: - conf.exp.version = exp_utils.get_next_version(conf.exp.dir) - if conf.trainer.resume_from_ckpt: - conf.exp.version -= 1 - - if conf.trainer.resume_from_ckpt_confidnet: - conf.exp.version -= 1 - conf.data.num_workers = exp_utils._get_allowed_n_proc_DA( - conf.data.num_workers - ) - - conf.__pydantic_validate_values__() # type: ignore - logger.info(OmegaConf.to_yaml(conf)) - - train(conf, progress) - - elif conf.exp.mode == configs.Mode.train_test: - conf.exp.version = exp_utils.get_next_version(conf.exp.dir) - if conf.trainer.resume_from_ckpt: - conf.exp.version -= 1 - - if conf.trainer.resume_from_ckpt_confidnet: - conf.exp.version -= 1 - conf.data.num_workers = exp_utils._get_allowed_n_proc_DA( - conf.data.num_workers - ) - - conf.__pydantic_validate_values__() # type: ignore - logger.info(OmegaConf.to_yaml(conf)) - train(conf, progress, subsequent_testing=True) - - elif conf.exp.mode == configs.Mode.test: - if ( - "best" in conf.test.selection_criterion - and conf.test.only_latest_version is False - ): - ckpt_path = exp_utils._get_path_to_best_ckpt( - conf.exp.dir, - conf.test.selection_criterion, - conf.test.selection_mode, - ) - else: - logger.info("CHECK conf.exp.dir", conf.exp.dir) - version = exp_utils.get_most_recent_version(conf.exp.dir) - if version is not None: - conf.exp.version = version - ckpt_path = exp_utils._get_resume_ckpt_path(conf) - conf.__pydantic_validate_values__() # type: ignore - logger.info(OmegaConf.to_yaml(conf)) - test(conf, progress) - - elif conf.exp.mode == configs.Mode.analysis: - conf.__pydantic_validate_values__() # type: ignore - logger.info(OmegaConf.to_yaml(conf)) - analysis.main( - in_path=conf.test.dir, - out_path=conf.test.dir, - query_studies=conf.eval.query_studies, - add_val_tuning=conf.eval.val_tuning, - threshold_plot_confid=None, - cf=conf, - ) - else: - conf.__pydantic_validate_values__() # type: ignore - logger.info("BEGIN CONFIG\n{}\nEND CONFIG", OmegaConf.to_yaml(conf)) - except Exception as e: - logger.exception(e) - raise e - - -if __name__ == "__main__": - main() diff --git a/fd_shifts/main.py b/fd_shifts/main.py index a22be82..d9b5d36 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -7,19 +7,23 @@ from contextvars import ContextVar from dataclasses import asdict, is_dataclass from pathlib import Path -from typing import TYPE_CHECKING, Any, Callable, Optional +from typing import TYPE_CHECKING, Any import jsonargparse import rich import shtab import yaml -from jsonargparse import ActionConfigFile, ArgumentParser +from jsonargparse import ActionConfigFile, ArgumentParser, Namespace from jsonargparse._actions import Action from omegaconf import OmegaConf from rich.pretty import pretty_repr from fd_shifts import reporting from fd_shifts.configs import Config, DataConfig, OutputPathsPerMode +from fd_shifts.experiments.configs import list_experiment_configs + +if TYPE_CHECKING: + from collections.abc import Callable __subcommands = {} @@ -89,7 +93,7 @@ def apply_experiment_config(parser: ArgumentParser, cfg, dest, value) -> None: class ActionLegacyConfigFile(ActionConfigFile): """Action to indicate that an argument is a configuration file or a configuration string.""" - def __init__(self, **kwargs): + def __init__(self, **kwargs) -> None: """Initializer for ActionLegacyConfigFile instance.""" if "default" in kwargs: self.set_default_error() @@ -105,7 +109,7 @@ def __init__(self, **kwargs): kwargs["help"] = "Path to a configuration file." super().__init__(**kwargs) - def __call__(self, parser, cfg, values, option_string=None): + def __call__(self, parser, cfg, values, option_string=None) -> None: """Parses the given configuration and adds all the corresponding keys to the namespace. Raises: @@ -114,26 +118,28 @@ def __call__(self, parser, cfg, values, option_string=None): self.apply_config(parser, cfg, self.dest, values, option_string) @staticmethod - def set_default_error(): + def set_default_error() -> typing.NoReturn: raise ValueError( "ActionLegacyConfigFile does not accept a default, use default_config_files." ) @staticmethod - def apply_config(parser, cfg, dest, value, option_string) -> None: + def apply_config(parser, cfg, dest, value, option_string) -> None: # type: ignore from jsonargparse._link_arguments import skip_apply_links from fd_shifts.experiments.configs import get_dataset_config - with jsonargparse._actions._ActionSubCommands.not_single_subcommand(), previous_config_context( - cfg - ), skip_apply_links(): + with ( + jsonargparse._actions._ActionSubCommands.not_single_subcommand(), + previous_config_context(cfg), + skip_apply_links(), + ): kwargs = { "env": False, "defaults": False, "_skip_check": True, } - cfg_path: Optional[jsonargparse.Path] = jsonargparse.Path( + cfg_path: jsonargparse.Path | None = jsonargparse.Path( value, mode=jsonargparse._optionals.get_config_read_mode() ) @@ -193,7 +199,8 @@ def apply_config(parser, cfg, dest, value, option_string) -> None: else: raise ValueError(f"Unknown query study {k}") - # for specific experiments, the seed should be fixed, if "random_seed" was written fix it + # for specific experiments, the seed should be fixed, if "random_seed" + # was written fix it if isinstance(cfg_file["config"]["exp"]["global_seed"], str): warnings.warn( "global_seed is set to random in file, setting it to -1" @@ -226,10 +233,13 @@ def apply_config(parser, cfg, dest, value, option_string) -> None: # resolve everything else oc_config = OmegaConf.create(cfg_file["config"]) - dict_config: dict[str, Any] = OmegaConf.to_object(oc_config) # type: ignore + dict_config: dict[str, Any] = OmegaConf.to_object( + oc_config + ) # pyright: ignore [reportAssignmentType] cfg_file["config"] = dict_config - # don't need to comply with accumulate_grad_batches, that's runtime env dependent + # don't need to comply with accumulate_grad_batches, that's runtime env + # dependent cfg_file["config"]["trainer"]["batch_size"] *= cfg_file["config"][ "trainer" ].get("accumulate_grad_batches", 1) @@ -247,8 +257,8 @@ def apply_config(parser, cfg, dest, value, option_string) -> None: cfg[dest].append(cfg_path) -def _path_to_str(cfg) -> dict: - def __path_to_str(cfg): +def _path_to_str(cfg: dict | Config) -> dict: + def __path_to_str(cfg): # noqa: ANN202,ANN001 if isinstance(cfg, dict): return {k: __path_to_str(v) for k, v in cfg.items()} if is_dataclass(cfg): @@ -261,11 +271,11 @@ def __path_to_str(cfg): return str(cfg) return cfg - return __path_to_str(cfg) # type: ignore + return __path_to_str(cfg) # pyright: ignore [reportReturnType] -def _dict_to_dataclass(cfg) -> Config: - def __dict_to_dataclass(cfg, cls, key): +def _dict_to_dataclass(cfg: dict) -> Config: + def __dict_to_dataclass(cfg, cls: type, key: str): # noqa: ANN202,ANN001 try: if is_dataclass(cls): fieldtypes = typing.get_type_hints(cls) @@ -304,11 +314,11 @@ def __dict_to_dataclass(cfg, cls, key): raise return cfg - return __dict_to_dataclass(cfg, Config, "") # type: ignore + return __dict_to_dataclass(cfg, Config, "") # pyright: ignore [reportReturnType] -def omegaconf_resolve(config: Config): - """Resolve all variable interpolations in config object with OmegaConf +def omegaconf_resolve(config: Config) -> Config: + """Resolve all variable interpolations in config object with OmegaConf. Args: config: Config object to resolve @@ -318,31 +328,35 @@ def omegaconf_resolve(config: Config): """ dict_config = asdict(config) - # convert all paths to string, omegaconf does not do variable interpolation in anything that's not a string + # convert all paths to string, omegaconf does not do variable interpolation in + # anything that's not a string dict_config = _path_to_str(dict_config) - # omegaconf can't handle callables, may need to extend this list if other callable configs get added + # omegaconf can't handle callables, may need to extend this list if other callable + # configs get added del dict_config["trainer"]["lr_scheduler"] del dict_config["trainer"]["optimizer"] oc_config = OmegaConf.create(dict_config) - dict_config: dict[str, Any] = OmegaConf.to_object(oc_config) # type: ignore + dict_config: dict[str, Any] = OmegaConf.to_object( + oc_config + ) # pyright: ignore [reportAssignmentType] dict_config["trainer"]["lr_scheduler"] = config.trainer.lr_scheduler dict_config["trainer"]["optimizer"] = config.trainer.optimizer - new_config = _dict_to_dataclass(dict_config) - return new_config + return _dict_to_dataclass(dict_config) -def setup_logging(): +def setup_logging() -> None: from fd_shifts import logger rich.reconfigure(stderr=True, force_terminal=True) logger.remove() # Remove default 'stderr' handler - # We need to specify end=''" as log message already ends with \n (thus the lambda function) - # Also forcing 'colorize=True' otherwise Loguru won't recognize that the sink support colors + # We need to specify end=''" as log message already ends with \n (thus the lambda + # function). Also forcing 'colorize=True' otherwise Loguru won't recognize that the + # sink support colors logger.add( lambda m: rich.get_console().print(m, end="", markup=False, highlight=False), colorize=True, @@ -433,7 +447,7 @@ def train(config: Config): log_every_n_steps=log_every_n_steps, max_epochs=num_epochs, max_steps=-1 if max_steps is None else max_steps, - callbacks=[progress] + get_callbacks(config), + callbacks=[progress, *get_callbacks(config)], benchmark=config.trainer.benchmark, precision="16-mixed", check_val_every_n_epoch=val_every_n_epoch, @@ -447,11 +461,7 @@ def train(config: Config): else accumulate_grad_batches, ) - logger.info( - "logging training to: {}, version: {}".format( - config.exp.dir, config.exp.version - ) - ) + logger.info(f"logging training to: {config.exp.dir}, version: {config.exp.version}") trainer.fit(model=model, datamodule=datamodule) @@ -482,16 +492,16 @@ def test(config: Config): ckpt_path = exp_utils._get_resume_ckpt_path(config) logger.info( - "testing model from checkpoint: {} from model selection tpye {}".format( + "testing model from checkpoint: {} from model selection type {}".format( ckpt_path, config.test.selection_criterion ) ) - logger.info("logging testing to: {}".format(config.test.dir)) + logger.info(f"logging testing to: {config.test.dir}") module = get_model(config.model.name)(config) # TODO: make common module class with this method - module.load_only_state_dict(ckpt_path) # type: ignore + module.load_only_state_dict(ckpt_path) # pyright: ignore [reportCallIssue] datamodule = FDShiftsDataLoader(config) @@ -517,15 +527,17 @@ def test(config: Config): devices="auto", logger=wandb_logger, log_every_n_steps=log_every_n_steps, - callbacks=[progress] + get_callbacks(config), + callbacks=[progress, *get_callbacks(config)], limit_test_batches=limit_batches, precision="bf16-mixed", ) trainer.test(model=module, datamodule=datamodule) + analysis(config) @subcommand -def analysis(config: Config): +def analysis(config: Config) -> None: + """Run analysis on the results of the experiment.""" from fd_shifts import analysis as ana ana.main( @@ -539,18 +551,19 @@ def analysis(config: Config): @subcommand -def debug(config: Config): - pass +def debug(config: Config) -> None: # noqa: ARG001 + """Noop function for debugging purposes.""" -def _list_experiments(): +def _list_experiments() -> None: from fd_shifts.experiments.configs import list_experiment_configs for exp in sorted(list_experiment_configs()): - print(exp) + print(exp) # noqa: T201 -def get_parser(): +def get_parser() -> tuple[ArgumentParser, dict[str, ArgumentParser]]: + """Return the parser and subparsers for the command line interface.""" from fd_shifts import get_version parser = ArgumentParser(version=get_version()) @@ -571,8 +584,12 @@ def get_parser(): subparser = ArgumentParser() subparser.add_argument( "--config-file", "--legacy-config-file", action=ActionLegacyConfigFile - ).complete = shtab.FILE # type: ignore - subparser.add_argument("--experiment", action=ActionExperiment) + ).complete = ( # pyright: ignore [reportAttributeAccessIssue,reportOptionalMemberAccess] + shtab.FILE + ) + subparser.add_argument( + "--experiment", action=ActionExperiment, choices=list_experiment_configs() + ) subparser.add_function_arguments(func, sub_configs=True) subparsers[name] = subparser subcommands.add_subcommand(name, subparser) @@ -580,13 +597,14 @@ def get_parser(): return parser, subparsers -def config_from_parser(parser, args): +def config_from_parser(parser: ArgumentParser, args: Namespace) -> Config: + """Parse the command line arguments and return the configuration object.""" config = parser.instantiate_classes(args)[args.command].config - config = omegaconf_resolve(config) - return config + return omegaconf_resolve(config) -def main(): +def main() -> None: + """Main entry point for the command line interface.""" from fd_shifts import logger setup_logging() From 27167a61bf11dee0830dde8c4f8fe14df66aef96 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 4 Jun 2024 17:27:27 +0200 Subject: [PATCH 108/136] refactor: small linter error fixes --- fd_shifts/configs/__init__.py | 10 ++++---- fd_shifts/experiments/configs.py | 41 ++++++++++++++++++++++++-------- 2 files changed, 36 insertions(+), 15 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 783245a..1873143 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -23,7 +23,7 @@ class StrEnum(str, Enum): - """Enum where members are also (and must be) strings""" + """Enum where members are also (and must be) strings.""" # pylint: disable=no-self-argument def _generate_next_value_(name, start, count, last_values): # type: ignore @@ -269,8 +269,8 @@ class ModelConfig(_IterableMixin): dropout_rate: int = 0 monitor_mcd_samples: int = 50 test_mcd_samples: int = 50 - confidnet_fc_dim: Optional[int] = None - dg_reward: Optional[float] = None + confidnet_fc_dim: int | None = None + dg_reward: float | None = None balanced_sampeling: bool = False budget: float = 0.3 @@ -413,9 +413,9 @@ class DataConfig(_IterableMixin): num_classes: int | None = None reproduce_confidnet_splits: bool = False augmentations: dict[str, dict[str, Any]] | None = None - target_transforms: Optional[Any] = None + target_transforms: Any | None = None subsample_corruptions: int = 10 - kwargs: Optional[dict[Any, Any]] = None + kwargs: dict[Any, Any] | None = None @dataclass diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index fb4eb6f..9e35154 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -181,17 +181,21 @@ def cifar100_query_config( return QueryStudiesConfig( iid_study=dataset + ("_384" if img_size[0] == 384 else ""), - noise_study=cifar100_data_config("corrupt_cifar100", img_size) - if dataset == "cifar100" - else DataConfig(), + noise_study=( + cifar100_data_config("corrupt_cifar100", img_size) + if dataset == "cifar100" + else DataConfig() + ), in_class_study=[], - new_class_study=[ - cifar10_data_config(img_size=img_size), - svhn_data_config("svhn", img_size), - tinyimagenet_data_config(img_size), - ] - if dataset == "cifar100" - else [], + new_class_study=( + [ + cifar10_data_config(img_size=img_size), + svhn_data_config("svhn", img_size), + tinyimagenet_data_config(img_size), + ] + if dataset == "cifar100" + else [] + ), ) @@ -385,25 +389,42 @@ def tinyimagenet_data_config(img_size: int | tuple[int, int] = 64) -> DataConfig "corrupt_cifar100_384": cifar100_data_config( dataset="corrupt_cifar100", img_size=384 ), + "wilds_animals": wilds_animals_data_config(), "wilds_animals_ood_test": wilds_animals_data_config("wilds_animals_ood_test"), "wilds_animals_ood_test_384": wilds_animals_data_config( "wilds_animals_ood_test", 384 ), + "wilds_camelyon": wilds_camelyon_data_config(), "wilds_camelyon_ood_test": wilds_camelyon_data_config("wilds_camelyon_ood_test"), "wilds_camelyon_ood_test_384": wilds_camelyon_data_config( "wilds_camelyon_ood_test", 384 ), + "breeds": breeds_data_config(), "breeds_ood_test": breeds_data_config("breeds_ood_test"), "breeds_ood_test_384": breeds_data_config("breeds_ood_test", 384), "tinyimagenet_384": tinyimagenet_data_config(384), "tinyimagenet_resize": tinyimagenet_data_config(32), } +__query_configs: dict[str, QueryStudiesConfig] = { + "svhn": svhn_query_config("svhn", 32), + "cifar10": cifar10_query_config(32), + "cifar100": cifar100_query_config(32), + "super_cifar100": cifar100_query_config(32, "super_cifar100"), + "wilds_animals": wilds_animals_query_config(), + "wilds_camelyon": wilds_camelyon_query_config(), + "breeds": breeds_query_config(), +} + def get_dataset_config(name: str) -> DataConfig: return __dataset_configs[name] +def get_query_config(name: str) -> QueryStudiesConfig: + return __query_configs[name] + + __experiments: dict[str, Config] = {} From c19b55ecc2a33f26bf067bc4cfe13d6b0153d0c7 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Mon, 3 Jun 2024 22:11:44 +0200 Subject: [PATCH 109/136] feat: compile model --- fd_shifts/main.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/fd_shifts/main.py b/fd_shifts/main.py index d9b5d36..f7c1eca 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -12,6 +12,7 @@ import jsonargparse import rich import shtab +import torch import yaml from jsonargparse import ActionConfigFile, ArgumentParser, Namespace from jsonargparse._actions import Action @@ -456,9 +457,9 @@ def train(config: Config): limit_val_batches=0 if config.trainer.do_val is False else limit_batches, limit_test_batches=limit_batches, gradient_clip_val=None if config.model.name == "confidnet_model" else 1, - accumulate_grad_batches=1 - if config.model.name == "confidnet_model" - else accumulate_grad_batches, + accumulate_grad_batches=( + 1 if config.model.name == "confidnet_model" else accumulate_grad_batches + ), ) logger.info(f"logging training to: {config.exp.dir}, version: {config.exp.version}") @@ -502,6 +503,7 @@ def test(config: Config): # TODO: make common module class with this method module.load_only_state_dict(ckpt_path) # pyright: ignore [reportCallIssue] + module = torch.compile(module) datamodule = FDShiftsDataLoader(config) From 31fe779f9aa0866f31b62f5b41a85641d3044b41 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 4 Jun 2024 17:37:38 +0200 Subject: [PATCH 110/136] refactor: fix some linter errors --- .pre-commit-config.yaml | 2 +- fd_shifts/experiments/configs.py | 437 +++++++++++++++++-------------- 2 files changed, 248 insertions(+), 191 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 7863ee4..bf09f79 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -3,7 +3,7 @@ repos: - repo: https://github.com/psf/black - rev: 23.10.1 + rev: 24.4.2 hooks: - id: black name: black code formatting diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index 9e35154..c424289 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -1,6 +1,6 @@ +from collections.abc import Callable from copy import deepcopy -from pathlib import Path -from typing import Callable, Literal +from typing import Literal from omegaconf import SI @@ -15,6 +15,11 @@ QueryStudiesConfig, ) +DEFAULT_VIT_INFERENCE_IMG_SIZE = 384 +DEFAULT_VIT_PRETRAIN_IMG_SIZE = 224 +DEFAULT_SMALL_IMG_SIZE = 32 +DEFAULT_CAMELYON_IMG_SIZE = 96 + def svhn_data_config( dataset: Literal["svhn", "svhn_openset"], img_size: int | tuple[int, int] = 32 @@ -30,7 +35,7 @@ def svhn_data_config( if isinstance(img_size, int): img_size = (img_size, img_size) - if img_size[0] != 32: + if img_size[0] != DEFAULT_SMALL_IMG_SIZE: augmentations["resize"] = img_size[0] return DataConfig( @@ -58,7 +63,8 @@ def svhn_query_config( img_size = (img_size, img_size) return QueryStudiesConfig( - iid_study="svhn" + ("_384" if img_size[0] == 384 else ""), + iid_study="svhn" + + ("_384" if img_size[0] == DEFAULT_VIT_INFERENCE_IMG_SIZE else ""), new_class_study=[ cifar10_data_config(img_size=img_size), cifar100_data_config(img_size=img_size), @@ -69,7 +75,7 @@ def svhn_query_config( def cifar10_data_config( dataset: Literal["cifar10", "corrupt_cifar10"] = "cifar10", - img_size: int | tuple[int, int] = 32, + img_size: int | tuple[int, int] = DEFAULT_SMALL_IMG_SIZE, ) -> DataConfig: if isinstance(img_size, int): img_size = (img_size, img_size) @@ -78,13 +84,13 @@ def cifar10_data_config( "to_tensor": None, "normalize": [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.201]], } - if img_size[0] != 32: + if img_size[0] != DEFAULT_SMALL_IMG_SIZE: augmentations["resize"] = img_size[0] train_augmentations = deepcopy(augmentations) - if img_size[0] != 384: - train_augmentations["random_crop"] = [32, 4] + if img_size[0] != DEFAULT_VIT_INFERENCE_IMG_SIZE: + train_augmentations["random_crop"] = [DEFAULT_SMALL_IMG_SIZE, 4] train_augmentations["hflip"] = True if dataset == "corrupt_cifar10": train_augmentations["rotate"] = 15 @@ -117,7 +123,8 @@ def cifar10_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: img_size = (img_size, img_size) return QueryStudiesConfig( - iid_study="cifar10" + ("_384" if img_size[0] == 384 else ""), + iid_study="cifar10" + + ("_384" if img_size[0] == DEFAULT_VIT_INFERENCE_IMG_SIZE else ""), noise_study=cifar10_data_config("corrupt_cifar10", img_size), new_class_study=[ cifar100_data_config(img_size=img_size), @@ -129,7 +136,7 @@ def cifar10_query_config(img_size: int | tuple[int, int]) -> QueryStudiesConfig: def cifar100_data_config( dataset: Literal["cifar100", "corrupt_cifar100", "super_cifar100"] = "cifar100", - img_size: int | tuple[int, int] = 32, + img_size: int | tuple[int, int] = DEFAULT_SMALL_IMG_SIZE, ) -> DataConfig: if isinstance(img_size, int): img_size = (img_size, img_size) @@ -138,13 +145,13 @@ def cifar100_data_config( "to_tensor": None, "normalize": [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.201]], } - if img_size[0] != 32: + if img_size[0] != DEFAULT_SMALL_IMG_SIZE: augmentations["resize"] = img_size[0] train_augmentations = deepcopy(augmentations) - if img_size[0] != 384: - train_augmentations["random_crop"] = [32, 4] + if img_size[0] != DEFAULT_VIT_INFERENCE_IMG_SIZE: + train_augmentations["random_crop"] = [DEFAULT_SMALL_IMG_SIZE, 4] train_augmentations["hflip"] = True if dataset == "corrupt_cifar100": train_augmentations["rotate"] = 15 @@ -180,7 +187,8 @@ def cifar100_query_config( img_size = (img_size, img_size) return QueryStudiesConfig( - iid_study=dataset + ("_384" if img_size[0] == 384 else ""), + iid_study=dataset + + ("_384" if img_size[0] == DEFAULT_VIT_INFERENCE_IMG_SIZE else ""), noise_study=( cifar100_data_config("corrupt_cifar100", img_size) if dataset == "cifar100" @@ -208,11 +216,13 @@ def wilds_animals_data_config( augmentations = { "to_tensor": None, - "resize": img_size[0] if img_size[0] == 384 else img_size, + "resize": ( + img_size[0] if img_size[0] == DEFAULT_VIT_INFERENCE_IMG_SIZE else img_size + ), "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], } - if img_size[0] == 384: + if img_size[0] == DEFAULT_VIT_INFERENCE_IMG_SIZE: augmentations["center_crop"] = 384 return DataConfig( @@ -240,7 +250,8 @@ def wilds_animals_query_config( img_size = (img_size, img_size) return QueryStudiesConfig( - iid_study="wilds_animals" + ("_384" if img_size[0] == 384 else ""), + iid_study="wilds_animals" + + ("_384" if img_size[0] == DEFAULT_VIT_INFERENCE_IMG_SIZE else ""), in_class_study=[wilds_animals_data_config("wilds_animals_ood_test", img_size)], new_class_study=[], ) @@ -248,7 +259,7 @@ def wilds_animals_query_config( def wilds_camelyon_data_config( dataset: Literal["wilds_camelyon", "wilds_camelyon_ood_test"] = "wilds_camelyon", - img_size: int | tuple[int, int] = 96, + img_size: int | tuple[int, int] = DEFAULT_CAMELYON_IMG_SIZE, ) -> DataConfig: if isinstance(img_size, int): img_size = (img_size, img_size) @@ -257,11 +268,15 @@ def wilds_camelyon_data_config( "to_tensor": None, "normalize": [ [0.485, 0.456, 0.406], - [0.229, 0.384 if img_size[0] == 384 else 0.224, 0.225], + [ + 0.229, + 0.384 if img_size[0] == DEFAULT_VIT_INFERENCE_IMG_SIZE else 0.224, + 0.225, + ], ], } - if img_size[0] != 96: + if img_size[0] != DEFAULT_CAMELYON_IMG_SIZE: augmentations["resize"] = img_size[0] return DataConfig( @@ -289,7 +304,8 @@ def wilds_camelyon_query_config( img_size = (img_size, img_size) return QueryStudiesConfig( - iid_study="wilds_camelyon" + ("_384" if img_size[0] == 384 else ""), + iid_study="wilds_camelyon" + + ("_384" if img_size[0] == DEFAULT_VIT_INFERENCE_IMG_SIZE else ""), in_class_study=[ wilds_camelyon_data_config("wilds_camelyon_ood_test", img_size) ], @@ -299,13 +315,13 @@ def wilds_camelyon_query_config( def breeds_data_config( dataset: Literal["breeds", "breeds_ood_test"] = "breeds", - img_size: int | tuple[int, int] = 224, + img_size: int | tuple[int, int] = DEFAULT_VIT_PRETRAIN_IMG_SIZE, ) -> DataConfig: if isinstance(img_size, int): img_size = (img_size, img_size) augmentations = { - "resize": 256 if img_size[0] == 224 else img_size[0], + "resize": 256 if img_size[0] == DEFAULT_VIT_PRETRAIN_IMG_SIZE else img_size[0], "center_crop": img_size[0], "to_tensor": None, "normalize": [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]], @@ -313,7 +329,7 @@ def breeds_data_config( train_augmentations = deepcopy(augmentations) - if img_size[0] != 384: + if img_size[0] != DEFAULT_VIT_INFERENCE_IMG_SIZE: train_augmentations["randomresized_crop"] = img_size[0] train_augmentations["hflip"] = True train_augmentations["color_jitter"] = [0.1, 0.1, 0.1] @@ -334,12 +350,15 @@ def breeds_data_config( ) -def breeds_query_config(img_size: int | tuple[int, int] = 224) -> QueryStudiesConfig: +def breeds_query_config( + img_size: int | tuple[int, int] = DEFAULT_VIT_PRETRAIN_IMG_SIZE +) -> QueryStudiesConfig: if isinstance(img_size, int): img_size = (img_size, img_size) return QueryStudiesConfig( - iid_study="breeds" + ("_384" if img_size[0] == 384 else ""), + iid_study="breeds" + + ("_384" if img_size[0] == DEFAULT_VIT_INFERENCE_IMG_SIZE else ""), in_class_study=[breeds_data_config("breeds_ood_test", img_size)], ) @@ -353,15 +372,15 @@ def tinyimagenet_data_config(img_size: int | tuple[int, int] = 64) -> DataConfig "normalize": [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]], } - if img_size[0] != 64: + if img_size[0] != 64: # noqa: PLR2004 augmentations["resize"] = img_size return DataConfig( - dataset="tinyimagenet" + ("_384" if img_size[0] == 384 else "_resize"), + dataset="tinyimagenet" + + ("_384" if img_size[0] == DEFAULT_VIT_INFERENCE_IMG_SIZE else "_resize"), data_dir=SI( - "${oc.env:DATASET_ROOT_DIR}/" - + "tinyimagenet" - + ("" if img_size[0] == 384 else "_resize") + "${oc.env:DATASET_ROOT_DIR}/tinyimagenet" + + ("" if img_size[0] == DEFAULT_VIT_INFERENCE_IMG_SIZE else "_resize") ), img_size=(img_size[0], img_size[1], 3), num_classes=200, @@ -376,15 +395,19 @@ def tinyimagenet_data_config(img_size: int | tuple[int, int] = 64) -> DataConfig __dataset_configs: dict[str, DataConfig] = { "svhn": svhn_data_config("svhn"), - "svhn_384": svhn_data_config("svhn", 384), + "svhn_384": svhn_data_config("svhn", DEFAULT_VIT_INFERENCE_IMG_SIZE), "cifar10": cifar10_data_config(), - "cifar10_384": cifar10_data_config(img_size=384), + "cifar10_384": cifar10_data_config(img_size=DEFAULT_VIT_INFERENCE_IMG_SIZE), "cifar100": cifar100_data_config(), - "cifar100_384": cifar100_data_config(img_size=384), + "cifar100_384": cifar100_data_config(img_size=DEFAULT_VIT_INFERENCE_IMG_SIZE), "super_cifar100": cifar100_data_config(dataset="super_cifar100"), - "super_cifar100_384": cifar100_data_config(img_size=384, dataset="super_cifar100"), + "super_cifar100_384": cifar100_data_config( + img_size=DEFAULT_VIT_INFERENCE_IMG_SIZE, dataset="super_cifar100" + ), "corrupt_cifar10": cifar10_data_config(dataset="corrupt_cifar10"), - "corrupt_cifar10_384": cifar10_data_config(dataset="corrupt_cifar10", img_size=384), + "corrupt_cifar10_384": cifar10_data_config( + dataset="corrupt_cifar10", img_size=DEFAULT_VIT_INFERENCE_IMG_SIZE + ), "corrupt_cifar100": cifar100_data_config(dataset="corrupt_cifar100"), "corrupt_cifar100_384": cifar100_data_config( dataset="corrupt_cifar100", img_size=384 @@ -401,16 +424,18 @@ def tinyimagenet_data_config(img_size: int | tuple[int, int] = 64) -> DataConfig ), "breeds": breeds_data_config(), "breeds_ood_test": breeds_data_config("breeds_ood_test"), - "breeds_ood_test_384": breeds_data_config("breeds_ood_test", 384), - "tinyimagenet_384": tinyimagenet_data_config(384), - "tinyimagenet_resize": tinyimagenet_data_config(32), + "breeds_ood_test_384": breeds_data_config( + "breeds_ood_test", DEFAULT_VIT_INFERENCE_IMG_SIZE + ), + "tinyimagenet_384": tinyimagenet_data_config(DEFAULT_VIT_INFERENCE_IMG_SIZE), + "tinyimagenet_resize": tinyimagenet_data_config(DEFAULT_SMALL_IMG_SIZE), } __query_configs: dict[str, QueryStudiesConfig] = { - "svhn": svhn_query_config("svhn", 32), - "cifar10": cifar10_query_config(32), - "cifar100": cifar100_query_config(32), - "super_cifar100": cifar100_query_config(32, "super_cifar100"), + "svhn": svhn_query_config("svhn", DEFAULT_SMALL_IMG_SIZE), + "cifar10": cifar10_query_config(DEFAULT_SMALL_IMG_SIZE), + "cifar100": cifar100_query_config(DEFAULT_SMALL_IMG_SIZE), + "super_cifar100": cifar100_query_config(DEFAULT_SMALL_IMG_SIZE, "super_cifar100"), "wilds_animals": wilds_animals_query_config(), "wilds_camelyon": wilds_camelyon_query_config(), "breeds": breeds_query_config(), @@ -428,7 +453,7 @@ def get_query_config(name: str) -> QueryStudiesConfig: __experiments: dict[str, Config] = {} -def cnn(group_name: str, name: str): +def cnn(group_name: str, name: str) -> Config: config = Config(exp=ExperimentConfig(group_name=group_name, name=name)) config.trainer.batch_size = 128 config.trainer.lr_scheduler = LRSchedulerConfig( @@ -455,23 +480,23 @@ def cnn(group_name: str, name: str): return config -def cnn_animals(name: str): +def cnn_animals(name: str) -> Config: config = cnn("animals_paper_sweep", name=name) config.data = wilds_animals_data_config() - config.trainer.optimizer.init_args["init_args"]["lr"] = 0.001 + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.001 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.fc_dim = 2048 config.model.avg_pool = True config.eval.query_studies = wilds_animals_query_config() return config -def cnn_animals_modelconfidnet(run: int, do: int, **kwargs): +def cnn_animals_modelconfidnet(run: int, do: int, **kwargs) -> Config: config = cnn_animals(name=f"confidnet_bbresnet50_do{do}_run{run + 1}_rew2.2") config.trainer.num_epochs = 20 config.trainer.num_epochs_backbone = 12 config.trainer.learning_rate_confidnet = 0.0001 config.trainer.learning_rate_confidnet_finetune = 1e-06 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 12 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 12 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.trainer.callbacks["training_stages"] = {} config.trainer.callbacks["training_stages"]["milestones"] = [12, 17] config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None @@ -486,11 +511,11 @@ def cnn_animals_modelconfidnet(run: int, do: int, **kwargs): return config -def cnn_animals_modeldevries(run: int, do: int, **kwargs): +def cnn_animals_modeldevries(run: int, do: int, **kwargs) -> Config: config = cnn_animals(name=f"devries_bbresnet50_do{do}_run{run + 1}_rew2.2") config.trainer.num_epochs = 12 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 12 - config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 12 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.name = "devries_model" config.model.dg_reward = -1 config.model.dropout_rate = do @@ -500,12 +525,12 @@ def cnn_animals_modeldevries(run: int, do: int, **kwargs): return config -def cnn_animals_modeldg(run: int, do: int, rew: float): +def cnn_animals_modeldg(run: int, do: int, rew: float) -> Config: config = cnn_animals(name=f"dg_bbresnet50_do{do}_run{run + 1}_rew{rew}") config.trainer.num_epochs = 18 config.trainer.dg_pretrain_epochs = 6 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 18 - config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 18 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.name = "devries_model" config.model.dropout_rate = do config.model.dg_reward = rew @@ -514,24 +539,24 @@ def cnn_animals_modeldg(run: int, do: int, rew: float): return config -def cnn_camelyon(name: str): +def cnn_camelyon(name: str) -> Config: config = cnn("camelyon_paper_sweep", name=name) config.data = wilds_camelyon_data_config() - config.trainer.optimizer.init_args["init_args"]["lr"] = 0.01 - config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.01 + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.01 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.01 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.fc_dim = 2048 config.model.avg_pool = True config.eval.query_studies = wilds_camelyon_query_config() return config -def cnn_camelyon_modelconfidnet(run: int, do: int, **kwargs): +def cnn_camelyon_modelconfidnet(run: int, do: int, **kwargs) -> Config: config = cnn_camelyon(f"confidnet_bbresnet50_do{do}_run{run + 1}_rew2.2") config.trainer.num_epochs = 9 config.trainer.num_epochs_backbone = 5 config.trainer.learning_rate_confidnet = 0.0001 config.trainer.learning_rate_confidnet_finetune = 1e-06 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 5 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 5 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.trainer.callbacks["training_stages"] = {} config.trainer.callbacks["training_stages"]["milestones"] = [5, 8] config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None @@ -546,11 +571,11 @@ def cnn_camelyon_modelconfidnet(run: int, do: int, **kwargs): return config -def cnn_camelyon_modeldevries(run: int, do: int, **kwargs): +def cnn_camelyon_modeldevries(run: int, do: int, **kwargs) -> Config: config = cnn_camelyon(f"devries_bbresnet50_do{do}_run{run + 1}_rew2.2") config.trainer.num_epochs = 5 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 5 - config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 5 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.name = "devries_model" config.model.dropout_rate = do config.model.dg_reward = -1 @@ -560,12 +585,12 @@ def cnn_camelyon_modeldevries(run: int, do: int, **kwargs): return config -def cnn_camelyon_modeldg(run: int, do: int, rew: float): +def cnn_camelyon_modeldg(run: int, do: int, rew: float) -> Config: config = cnn_camelyon(f"dg_bbresnet50_do{do}_run{run + 1}_rew{rew}") config.trainer.num_epochs = 8 config.trainer.dg_pretrain_epochs = 3 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 8 - config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 8 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.name = "devries_model" config.model.dg_reward = rew config.model.dropout_rate = do @@ -574,22 +599,24 @@ def cnn_camelyon_modeldg(run: int, do: int, rew: float): return config -def cnn_svhn(name: str): +def cnn_svhn(name: str) -> Config: config = cnn("svhn_paper_sweep", name=name) - config.data = svhn_data_config("svhn", img_size=32) - config.trainer.optimizer.init_args["init_args"]["lr"] = 0.01 - config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.0005 + config.data = svhn_data_config("svhn", img_size=DEFAULT_SMALL_IMG_SIZE) + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.01 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.0005 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.fc_dim = 512 config.model.avg_pool = True - config.eval.query_studies = svhn_query_config("svhn", img_size=32) + config.eval.query_studies = svhn_query_config( + "svhn", img_size=DEFAULT_SMALL_IMG_SIZE + ) return config -def cnn_svhn_modelconfidnet(run: int, do: int, **kwargs): +def cnn_svhn_modelconfidnet(run: int, do: int, **kwargs) -> Config: config = cnn_svhn(f"confidnet_bbsvhn_small_conv_do{do}_run{run + 1}_rew2.2") config.trainer.num_epochs = 320 config.trainer.num_epochs_backbone = 100 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 100 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 100 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.trainer.learning_rate_confidnet = 0.0001 config.trainer.learning_rate_confidnet_finetune = 1e-06 config.trainer.callbacks["training_stages"] = {} @@ -606,11 +633,11 @@ def cnn_svhn_modelconfidnet(run: int, do: int, **kwargs): return config -def cnn_svhn_modeldevries(run: int, do: int, **kwargs): +def cnn_svhn_modeldevries(run: int, do: int, **kwargs) -> Config: config = cnn_svhn(f"devries_bbsvhn_small_conv_do{do}_run{run + 1}_rew2.2") config.trainer.num_epochs = 100 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 100 - config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 100 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.name = "devries_model" config.model.dropout_rate = do config.model.dg_reward = -1 @@ -620,12 +647,12 @@ def cnn_svhn_modeldevries(run: int, do: int, **kwargs): return config -def cnn_svhn_modeldg(run: int, do: int, rew: float): +def cnn_svhn_modeldg(run: int, do: int, rew: float) -> Config: config = cnn_svhn(f"dg_bbsvhn_small_conv_do{do}_run{run + 1}_rew{rew}") config.trainer.num_epochs = 150 config.trainer.dg_pretrain_epochs = 50 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 150 - config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 150 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.name = "devries_model" config.model.dg_reward = rew config.model.dropout_rate = do @@ -634,23 +661,23 @@ def cnn_svhn_modeldg(run: int, do: int, rew: float): return config -def cnn_cifar10(name: str): +def cnn_cifar10(name: str) -> Config: config = cnn("cifar10_paper_sweep", name=name) - config.data = cifar10_data_config(img_size=32) - config.trainer.optimizer.init_args["init_args"]["lr"] = 0.1 - config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.0005 + config.data = cifar10_data_config(img_size=DEFAULT_SMALL_IMG_SIZE) + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.1 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.0005 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.fc_dim = 512 - config.eval.query_studies = cifar10_query_config(img_size=32) + config.eval.query_studies = cifar10_query_config(img_size=DEFAULT_SMALL_IMG_SIZE) return config -def cnn_cifar10_modelconfidnet(run: int, do: int, **kwargs): +def cnn_cifar10_modelconfidnet(run: int, do: int, **kwargs) -> Config: config = cnn_cifar10(f"confidnet_bbvgg13_do{do}_run{run + 1}_rew2.2") config.trainer.num_epochs = 470 config.trainer.num_epochs_backbone = 250 config.trainer.learning_rate_confidnet = 0.0001 config.trainer.learning_rate_confidnet_finetune = 1e-06 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.trainer.callbacks["training_stages"] = {} config.trainer.callbacks["training_stages"]["milestones"] = [250, 450] config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None @@ -666,11 +693,11 @@ def cnn_cifar10_modelconfidnet(run: int, do: int, **kwargs): return config -def cnn_cifar10_modeldevries(run: int, do: int, **kwargs): +def cnn_cifar10_modeldevries(run: int, do: int, **kwargs) -> Config: config = cnn_cifar10(f"devries_bbvgg13_do{do}_run{run + 1}_rew2.2") config.trainer.num_epochs = 250 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 - config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.name = "devries_model" config.model.dropout_rate = do config.model.avg_pool = do == 0 @@ -681,12 +708,12 @@ def cnn_cifar10_modeldevries(run: int, do: int, **kwargs): return config -def cnn_cifar10_modeldg(run: int, do: int, rew: float): +def cnn_cifar10_modeldg(run: int, do: int, rew: float) -> Config: config = cnn_cifar10(f"dg_bbvgg13_do{do}_run{run + 1}_rew{rew}") config.trainer.num_epochs = 300 config.trainer.dg_pretrain_epochs = 100 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 - config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.name = "devries_model" config.model.dg_reward = rew config.model.dropout_rate = do @@ -696,23 +723,23 @@ def cnn_cifar10_modeldg(run: int, do: int, rew: float): return config -def cnn_cifar100(name: str): +def cnn_cifar100(name: str) -> Config: config = cnn("cifar100_paper_sweep", name=name) - config.data = cifar100_data_config(img_size=32) - config.trainer.optimizer.init_args["init_args"]["lr"] = 0.1 - config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.0005 + config.data = cifar100_data_config(img_size=DEFAULT_SMALL_IMG_SIZE) + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.1 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.0005 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.fc_dim = 512 - config.eval.query_studies = cifar100_query_config(img_size=32) + config.eval.query_studies = cifar100_query_config(img_size=DEFAULT_SMALL_IMG_SIZE) return config -def cnn_cifar100_modelconfidnet(run: int, do: int, **kwargs): +def cnn_cifar100_modelconfidnet(run: int, do: int, **kwargs) -> Config: config = cnn_cifar100(f"confidnet_bbvgg13_do{do}_run{run + 1}_rew2.2") config.trainer.num_epochs = 470 config.trainer.num_epochs_backbone = 250 config.trainer.learning_rate_confidnet = 0.0001 config.trainer.learning_rate_confidnet_finetune = 1e-06 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.trainer.callbacks["training_stages"] = {} config.trainer.callbacks["training_stages"]["milestones"] = [250, 450] config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None @@ -728,11 +755,11 @@ def cnn_cifar100_modelconfidnet(run: int, do: int, **kwargs): return config -def cnn_cifar100_modeldevries(run: int, do: int, **kwargs): +def cnn_cifar100_modeldevries(run: int, do: int, **kwargs) -> Config: config = cnn_cifar100(f"devries_bbvgg13_do{do}_run{run + 1}_rew2.2") config.trainer.num_epochs = 250 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 - config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 250 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.name = "devries_model" config.model.dropout_rate = do config.model.dg_reward = -1 @@ -743,12 +770,12 @@ def cnn_cifar100_modeldevries(run: int, do: int, **kwargs): return config -def cnn_cifar100_modeldg(run: int, do: int, rew: float): +def cnn_cifar100_modeldg(run: int, do: int, rew: float) -> Config: config = cnn_cifar100(f"dg_bbvgg13_do{do}_run{run + 1}_rew{rew}") config.trainer.num_epochs = 300 config.trainer.dg_pretrain_epochs = 100 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 - config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.name = "devries_model" config.model.dg_reward = rew config.model.dropout_rate = do @@ -758,54 +785,60 @@ def cnn_cifar100_modeldg(run: int, do: int, rew: float): return config -def cnn_super_cifar100_modelconfidnet(run: int, do: int, **kwargs): +def cnn_super_cifar100_modelconfidnet(run: int, do: int, **kwargs) -> Config: config = cnn_cifar100_modelconfidnet(run, do, **kwargs) config.exp.group_name = "supercifar_paper_sweep" - config.data = cifar100_data_config(dataset="super_cifar100", img_size=32) + config.data = cifar100_data_config( + dataset="super_cifar100", img_size=DEFAULT_SMALL_IMG_SIZE + ) config.eval.query_studies = cifar100_query_config( dataset="super_cifar100", img_size=32 ) return config -def cnn_super_cifar100_modeldevries(run: int, do: int, **kwargs): +def cnn_super_cifar100_modeldevries(run: int, do: int, **kwargs) -> Config: config = cnn_cifar100_modeldevries(run, do, **kwargs) config.exp.group_name = "supercifar_paper_sweep" - config.data = cifar100_data_config(dataset="super_cifar100", img_size=32) + config.data = cifar100_data_config( + dataset="super_cifar100", img_size=DEFAULT_SMALL_IMG_SIZE + ) config.eval.query_studies = cifar100_query_config( dataset="super_cifar100", img_size=32 ) return config -def cnn_super_cifar100_modeldg(run: int, do: int, rew: float): +def cnn_super_cifar100_modeldg(run: int, do: int, rew: float) -> Config: config = cnn_cifar100_modeldg(run, do, rew) config.exp.group_name = "supercifar_paper_sweep" - config.data = cifar100_data_config(dataset="super_cifar100", img_size=32) + config.data = cifar100_data_config( + dataset="super_cifar100", img_size=DEFAULT_SMALL_IMG_SIZE + ) config.eval.query_studies = cifar100_query_config( dataset="super_cifar100", img_size=32 ) return config -def cnn_breeds(name: str): +def cnn_breeds(name: str) -> Config: config = cnn("breeds_paper_sweep", name=name) config.data = breeds_data_config() - config.trainer.optimizer.init_args["init_args"]["lr"] = 0.1 - config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.0001 + config.trainer.optimizer.init_args["init_args"]["lr"] = 0.1 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["weight_decay"] = 0.0001 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.fc_dim = 2048 config.model.avg_pool = True config.eval.query_studies = breeds_query_config() return config -def cnn_breeds_modelconfidnet(run: int, do: int, **kwargs): +def cnn_breeds_modelconfidnet(run: int, do: int, **kwargs) -> Config: config = cnn_breeds(f"confidnet_bbresnet50_do{do}_run{run + 1}_rew2.2") config.trainer.num_epochs = 520 config.trainer.num_epochs_backbone = 300 config.trainer.learning_rate_confidnet = 0.0001 config.trainer.learning_rate_confidnet_finetune = 1e-06 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.trainer.callbacks["training_stages"] = {} config.trainer.callbacks["training_stages"]["milestones"] = [300, 500] config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None @@ -820,11 +853,11 @@ def cnn_breeds_modelconfidnet(run: int, do: int, **kwargs): return config -def cnn_breeds_modeldevries(run: int, do: int, **kwargs): +def cnn_breeds_modeldevries(run: int, do: int, **kwargs) -> Config: config = cnn_breeds(f"devries_bbresnet50_do{do}_run{run + 1}_rew2.2") config.trainer.num_epochs = 300 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 - config.trainer.optimizer.init_args["init_args"]["nesterov"] = True + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 300 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = True # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.name = "devries_model" config.model.dropout_rate = do config.model.dg_reward = -1 @@ -834,12 +867,12 @@ def cnn_breeds_modeldevries(run: int, do: int, **kwargs): return config -def cnn_breeds_modeldg(run: int, do: int, rew: float): +def cnn_breeds_modeldg(run: int, do: int, rew: float) -> Config: config = cnn_breeds(f"dg_bbresnet50_do{do}_run{run + 1}_rew{rew}") config.trainer.num_epochs = 350 config.trainer.dg_pretrain_epochs = 50 - config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 350 - config.trainer.optimizer.init_args["init_args"]["nesterov"] = False + config.trainer.lr_scheduler.init_args["init_args"]["T_max"] = 350 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["nesterov"] = False # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.name = "devries_model" config.model.dg_reward = rew config.model.dropout_rate = do @@ -848,7 +881,7 @@ def cnn_breeds_modeldg(run: int, do: int, rew: float): return config -def vit(name: str): +def vit(name: str) -> Config: config = Config(exp=ExperimentConfig(group_name="vit", name=name)) config.trainer.num_epochs = None config.trainer.num_steps = 40000 @@ -887,7 +920,7 @@ def vit(name: str): return config -def vit_modeldg(name: str): +def vit_modeldg(name: str) -> Config: config = vit(name) config.model.name = "devries_model" config.trainer.lr_scheduler_interval = "step" @@ -897,202 +930,226 @@ def vit_modeldg(name: str): return config -def vit_wilds_animals_modeldg(run: int, lr: float, do: int, rew: float): +def vit_wilds_animals_modeldg(run: int, lr: float, do: int, rew: float) -> Config: config = vit_modeldg( name=f"wilds_animals_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", ) - config.data = wilds_animals_data_config("wilds_animals", 384) + config.data = wilds_animals_data_config( + "wilds_animals", DEFAULT_VIT_INFERENCE_IMG_SIZE + ) config.trainer.num_steps = 60000 config.trainer.batch_size = 512 config.trainer.dg_pretrain_steps = 20000 - config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 - config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.dropout_rate = do config.model.dg_reward = rew - config.eval.query_studies = wilds_animals_query_config(384) + config.eval.query_studies = wilds_animals_query_config( + DEFAULT_VIT_INFERENCE_IMG_SIZE + ) return config -def vit_wilds_camelyon_modeldg(run: int, lr: float, do: int, rew: float): +def vit_wilds_camelyon_modeldg(run: int, lr: float, do: int, rew: float) -> Config: config = vit_modeldg( name=f"wilds_camelyon_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", ) - config.data = wilds_camelyon_data_config("wilds_camelyon", 384) + config.data = wilds_camelyon_data_config( + "wilds_camelyon", DEFAULT_VIT_INFERENCE_IMG_SIZE + ) config.trainer.num_steps = 60000 config.trainer.dg_pretrain_steps = 20000 - config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 - config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.dropout_rate = do config.model.dg_reward = rew - config.eval.query_studies = wilds_camelyon_query_config(384) + config.eval.query_studies = wilds_camelyon_query_config( + DEFAULT_VIT_INFERENCE_IMG_SIZE + ) return config -def vit_svhn_modeldg(run: int, lr: float, do: int, rew: float): +def vit_svhn_modeldg(run: int, lr: float, do: int, rew: float) -> Config: config = vit_modeldg( name=f"svhn_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", ) - config.data = svhn_data_config("svhn", 384) + config.data = svhn_data_config("svhn", DEFAULT_VIT_INFERENCE_IMG_SIZE) config.trainer.num_steps = 60000 config.trainer.dg_pretrain_steps = 20000 - config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 - config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.dropout_rate = do config.model.dg_reward = rew - config.eval.query_studies = svhn_query_config("svhn", 384) + config.eval.query_studies = svhn_query_config( + "svhn", DEFAULT_VIT_INFERENCE_IMG_SIZE + ) return config -def vit_cifar10_modeldg(run: int, lr: float, do: int, rew: float): +def vit_cifar10_modeldg(run: int, lr: float, do: int, rew: float) -> Config: config = vit_modeldg( name=f"cifar10_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", ) - config.data = cifar10_data_config(img_size=384) + config.data = cifar10_data_config(img_size=DEFAULT_VIT_INFERENCE_IMG_SIZE) config.trainer.num_steps = 60000 config.trainer.dg_pretrain_steps = 20000 - config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 - config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.dropout_rate = do config.model.dg_reward = rew config.model.avg_pool = do == 0 - config.eval.query_studies = cifar10_query_config(384) + config.eval.query_studies = cifar10_query_config(DEFAULT_VIT_INFERENCE_IMG_SIZE) return config -def vit_cifar100_modeldg(run: int, lr: float, do: int, rew: float): +def vit_cifar100_modeldg(run: int, lr: float, do: int, rew: float) -> Config: config = vit_modeldg( name=f"cifar100_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", ) - config.data = cifar100_data_config(img_size=384) + config.data = cifar100_data_config(img_size=DEFAULT_VIT_INFERENCE_IMG_SIZE) config.trainer.num_steps = 15000 config.trainer.batch_size = 512 config.trainer.dg_pretrain_steps = 5000 - config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 15000 - config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 15000 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.dropout_rate = do config.model.dg_reward = rew - config.eval.query_studies = cifar100_query_config(384) + config.eval.query_studies = cifar100_query_config(DEFAULT_VIT_INFERENCE_IMG_SIZE) return config -def vit_super_cifar100_modeldg(run: int, lr: float, do: int, rew: float): +def vit_super_cifar100_modeldg(run: int, lr: float, do: int, rew: float) -> Config: config = vit_cifar100_modeldg(run, lr, do, rew) config.exp.name = "super_" + config.exp.name - config.data = cifar100_data_config(dataset="super_cifar100", img_size=384) + config.data = cifar100_data_config( + dataset="super_cifar100", img_size=DEFAULT_VIT_INFERENCE_IMG_SIZE + ) config.eval.query_studies = cifar100_query_config( dataset="super_cifar100", img_size=384 ) return config -def vit_breeds_modeldg(run: int, lr: float, do: int, rew: float): +def vit_breeds_modeldg(run: int, lr: float, do: int, rew: float) -> Config: config = vit_modeldg( name=f"breeds_modeldg_bbvit_lr{lr}_bs128_run{run}_do{do}_rew{rew}", ) - config.data = breeds_data_config("breeds", 384) + config.data = breeds_data_config("breeds", DEFAULT_VIT_INFERENCE_IMG_SIZE) config.trainer.num_steps = 60000 config.trainer.dg_pretrain_steps = 20000 - config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 - config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 60000 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.dropout_rate = do config.model.dg_reward = rew - config.eval.query_studies = breeds_query_config(384) + config.eval.query_studies = breeds_query_config(DEFAULT_VIT_INFERENCE_IMG_SIZE) return config -def vit_wilds_animals_modelvit(run: int, lr: float, do: int, **kwargs): +def vit_wilds_animals_modelvit(run: int, lr: float, do: int, **kwargs) -> Config: config = vit( name=f"wilds_animals_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", ) - config.data = wilds_animals_data_config("wilds_animals", 384) + config.data = wilds_animals_data_config( + "wilds_animals", DEFAULT_VIT_INFERENCE_IMG_SIZE + ) config.trainer.num_steps = 40000 - config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 - config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.dropout_rate = do - config.eval.query_studies = wilds_animals_query_config(384) + config.eval.query_studies = wilds_animals_query_config( + DEFAULT_VIT_INFERENCE_IMG_SIZE + ) return config -def vit_wilds_camelyon_modelvit(run: int, lr: float, do: int, **kwargs): +def vit_wilds_camelyon_modelvit(run: int, lr: float, do: int, **kwargs) -> Config: config = vit( name=f"wilds_camelyon_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", ) - config.data = wilds_camelyon_data_config("wilds_camelyon", 384) + config.data = wilds_camelyon_data_config( + "wilds_camelyon", DEFAULT_VIT_INFERENCE_IMG_SIZE + ) config.trainer.num_steps = 40000 - config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 - config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.dropout_rate = do - config.eval.query_studies = wilds_camelyon_query_config(384) + config.eval.query_studies = wilds_camelyon_query_config( + DEFAULT_VIT_INFERENCE_IMG_SIZE + ) return config -def vit_svhn_modelvit(run: int, lr: float, do: int, **kwargs): +def vit_svhn_modelvit(run: int, lr: float, do: int, **kwargs) -> Config: config = vit( name=f"svhn_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", ) - config.data = svhn_data_config("svhn", 384) + config.data = svhn_data_config("svhn", DEFAULT_VIT_INFERENCE_IMG_SIZE) config.trainer.num_steps = 40000 - config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 - config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.dropout_rate = do - config.eval.query_studies = svhn_query_config("svhn", 384) + config.eval.query_studies = svhn_query_config( + "svhn", DEFAULT_VIT_INFERENCE_IMG_SIZE + ) return config -def vit_cifar10_modelvit(run: int, lr: float, do: int, **kwargs): +def vit_cifar10_modelvit(run: int, lr: float, do: int, **kwargs) -> Config: config = vit( name=f"cifar10_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", ) - config.data = cifar10_data_config(img_size=384) + config.data = cifar10_data_config(img_size=DEFAULT_VIT_INFERENCE_IMG_SIZE) config.trainer.num_steps = 40000 - config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 - config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.dropout_rate = do config.model.avg_pool = do == 0 - config.eval.query_studies = cifar10_query_config(384) + config.eval.query_studies = cifar10_query_config(DEFAULT_VIT_INFERENCE_IMG_SIZE) return config -def vit_cifar100_modelvit(run: int, lr: float, do: int, **kwargs): +def vit_cifar100_modelvit(run: int, lr: float, do: int, **kwargs) -> Config: config = vit( name=f"cifar100_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", ) - config.data = cifar100_data_config(img_size=384) + config.data = cifar100_data_config(img_size=DEFAULT_VIT_INFERENCE_IMG_SIZE) config.trainer.num_steps = 10000 config.trainer.batch_size = 512 - config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 10000 - config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 10000 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.dropout_rate = do - config.eval.query_studies = cifar100_query_config(384) + config.eval.query_studies = cifar100_query_config(DEFAULT_VIT_INFERENCE_IMG_SIZE) return config -def vit_super_cifar100_modelvit(run: int, lr: float, do: int, **kwargs): +def vit_super_cifar100_modelvit(run: int, lr: float, do: int, **kwargs) -> Config: config = vit_cifar100_modelvit(run, lr, do, **kwargs) config.exp.name = "super_" + config.exp.name - config.data = cifar100_data_config(dataset="super_cifar100", img_size=384) + config.data = cifar100_data_config( + dataset="super_cifar100", img_size=DEFAULT_VIT_INFERENCE_IMG_SIZE + ) config.eval.query_studies = cifar100_query_config( dataset="super_cifar100", img_size=384 ) config.trainer.num_steps = 40000 - config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 return config -def vit_breeds_modelvit(run: int, lr: float, do: int, **kwargs): +def vit_breeds_modelvit(run: int, lr: float, do: int, **kwargs) -> Config: config = vit( name=f"breeds_modelvit_bbvit_lr{lr}_bs128_run{run}_do{do}_rew0", ) - config.data = breeds_data_config("breeds", 384) + config.data = breeds_data_config("breeds", DEFAULT_VIT_INFERENCE_IMG_SIZE) config.trainer.num_steps = 40000 - config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 - config.trainer.optimizer.init_args["init_args"]["lr"] = lr + config.trainer.lr_scheduler.init_args["init_args"]["max_epochs"] = 40000 # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 + config.trainer.optimizer.init_args["init_args"]["lr"] = lr # fmt: skip # pyright: ignore[reportOptionalMemberAccess] # noqa: E501 config.model.dropout_rate = do - config.eval.query_studies = breeds_query_config(384) + config.eval.query_studies = breeds_query_config(DEFAULT_VIT_INFERENCE_IMG_SIZE) return config -def register(config_fn: Callable[..., Config], n_runs: int = 5, **kwargs): +def register(config_fn: Callable[..., Config], n_runs: int = 5, **kwargs) -> None: for run in range(n_runs): config = config_fn(**kwargs, run=run) __experiments[f"{config.exp.group_name}/{config.exp.name}"] = config @@ -1323,4 +1380,4 @@ def get_experiment_config(name: str) -> Config: def list_experiment_configs() -> list[str]: - return list(sorted(__experiments.keys())) + return sorted(__experiments.keys()) From b38e284a9450da83b4dbb4f6b787976237205739 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Mon, 3 Jun 2024 22:53:15 +0200 Subject: [PATCH 111/136] feat: allow for no val split Use train set as val set in that case --- fd_shifts/configs/__init__.py | 1 + fd_shifts/loaders/data_loader.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 1873143..1545482 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -47,6 +47,7 @@ class ValSplit(StrEnum): repro_confidnet = auto() cv = auto() zhang = auto() + none = auto() @dataclass diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index 4008e29..eea523e 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -304,7 +304,7 @@ def setup(self, stage=None): self.test_datasets.append(tmp_external_set) logging.debug("Len external Test data: %s", len(self.test_datasets[-1])) - if self.val_split is None or self.val_split == "devries": + if self.val_split in ("none", "devries"): val_idx = [] train_idx = [] self.val_sampler = None From c4441154dc39dba4babc12b1913d1d8f01657ccf Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Mon, 3 Jun 2024 22:53:59 +0200 Subject: [PATCH 112/136] fix: don't double 384 in names --- fd_shifts/experiments/tracker.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/fd_shifts/experiments/tracker.py b/fd_shifts/experiments/tracker.py index 8b203e9..c98c13e 100644 --- a/fd_shifts/experiments/tracker.py +++ b/fd_shifts/experiments/tracker.py @@ -30,7 +30,12 @@ def list_analysis_output_files(config: Config) -> list: if len(testset) > 0: if isinstance(testset[0], DataConfig): testset = map( - lambda d: d.dataset + ("_384" if d.img_size[0] == 384 else ""), + lambda d: d.dataset + + ( + "_384" + if d.img_size[0] == 384 and "384" not in d.dataset + else "" + ), testset, ) From 93d8f56d21fad24e409a5986c0b2a29d9070e215 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Tue, 4 Jun 2024 22:15:04 +0200 Subject: [PATCH 113/136] feat: also compile for training --- fd_shifts/configs/__init__.py | 1 + fd_shifts/main.py | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 1545482..3b1c869 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -229,6 +229,7 @@ class TrainerConfig(_IterableMixin): lr_scheduler: LRSchedulerConfig | None = None optimizer: OptimizerConfig | None = None accumulate_grad_batches: int = 1 + use_compile: bool = True resume_from_ckpt_confidnet: bool = False dg_pretrain_epochs: int | None = 100 dg_pretrain_steps: Optional[int] = None diff --git a/fd_shifts/main.py b/fd_shifts/main.py index f7c1eca..92bedee 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -424,6 +424,9 @@ def train(config: Config): datamodule = FDShiftsDataLoader(config) model = get_model(config.model.name)(config) + if config.trainer.use_compile: + logger.info("Compiling model") + model = torch.compile(model) csv_logger = CSVLogger( save_dir=str(config.exp.group_dir), name=config.exp.name, @@ -471,8 +474,8 @@ def test(config: Config): import lightning as L from lightning.pytorch.callbacks.progress.rich_progress import RichProgressBar from lightning.pytorch.loggers.wandb import WandbLogger + from loguru import logger - from fd_shifts import logger from fd_shifts.loaders.data_loader import FDShiftsDataLoader from fd_shifts.models import get_model from fd_shifts.models.callbacks import get_callbacks @@ -503,7 +506,9 @@ def test(config: Config): # TODO: make common module class with this method module.load_only_state_dict(ckpt_path) # pyright: ignore [reportCallIssue] - module = torch.compile(module) + if config.trainer.use_compile: + logger.info("Compiling model") + module = torch.compile(module) datamodule = FDShiftsDataLoader(config) From cf58528c1fe9b277f30588e240a149be9e4fe0fa Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Wed, 5 Jun 2024 09:27:38 +0200 Subject: [PATCH 114/136] Add AUGRC and bootstrap code --- fd_shifts/analysis/__init__.py | 15 +- fd_shifts/analysis/bootstrap.py | 421 ++++++++++ fd_shifts/analysis/confid_scores.py | 6 +- fd_shifts/analysis/eval_utils.py | 84 +- fd_shifts/analysis/metrics.py | 106 ++- fd_shifts/analysis/rc_stats.py | 640 +++++++++++++++ fd_shifts/analysis/rc_stats_utils.py | 227 +++++ fd_shifts/analysis/studies.py | 3 +- fd_shifts/configs/__init__.py | 63 -- fd_shifts/experiments/__init__.py | 332 ++++---- fd_shifts/experiments/configs.py | 28 +- fd_shifts/experiments/tracker.py | 57 ++ fd_shifts/loaders/dataset_collection.py | 13 +- fd_shifts/main.py | 35 +- fd_shifts/models/callbacks/confid_monitor.py | 2 +- fd_shifts/reporting/__init__.py | 272 ++++-- fd_shifts/reporting/__main__.py | 2 +- fd_shifts/reporting/plots.py | 125 +++ fd_shifts/reporting/plots_bootstrap.py | 822 +++++++++++++++++++ fd_shifts/reporting/report_bootstrap.py | 604 ++++++++++++++ fd_shifts/reporting/tables.py | 141 +++- pyproject.toml | 1 + 22 files changed, 3555 insertions(+), 444 deletions(-) create mode 100644 fd_shifts/analysis/bootstrap.py create mode 100644 fd_shifts/analysis/rc_stats.py create mode 100644 fd_shifts/analysis/rc_stats_utils.py mode change 100644 => 100755 fd_shifts/main.py create mode 100644 fd_shifts/reporting/plots_bootstrap.py create mode 100644 fd_shifts/reporting/report_bootstrap.py diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 2c44579..3b1c039 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -2,6 +2,7 @@ import os from dataclasses import dataclass, field +from itertools import product from numbers import Number from pathlib import Path from typing import Any, Literal, overload @@ -17,6 +18,7 @@ from sklearn.calibration import _sigmoid_calibration as calib from fd_shifts import configs +from fd_shifts.analysis.rc_stats import RiskCoverageStats from .confid_scores import ConfidScore, SecondaryConfidScore, is_external_confid from .eval_utils import ( @@ -200,7 +202,7 @@ def dataset_name_to_idx(self, dataset_name: str) -> int: elif isinstance(datasets, str): flat_test_set_list.append(datasets) - logger.error(f"{flat_test_set_list=}") + logger.info(f"{flat_test_set_list=}") dataset_idx = flat_test_set_list.index(dataset_name) @@ -678,6 +680,8 @@ def __init__( ) ) + # self.method_dict["query_confids"].append("temp_logits") + self.secondary_confids = [] if ( @@ -1245,7 +1249,7 @@ def main( cf: configs.Config, query_studies: configs.QueryStudiesConfig, add_val_tuning: bool = True, - threshold_plot_confid: str | None = "tcp_mcd", + threshold_plot_confid: str | None = None, qual_plot_confid=None, ): path_to_test_dir = in_path @@ -1263,6 +1267,13 @@ def main( "e-aurc", "b-aurc", "aurc", + "augrc", + # "augrc-CI95-l", + # "augrc-CI95-h", + # "augrc-CI95", + "e-augrc", + "augrc-ba", + "aurc-ba", "fpr@95tpr", "risk@100cov", "risk@95cov", diff --git a/fd_shifts/analysis/bootstrap.py b/fd_shifts/analysis/bootstrap.py new file mode 100644 index 0000000..8087597 --- /dev/null +++ b/fd_shifts/analysis/bootstrap.py @@ -0,0 +1,421 @@ +from __future__ import annotations + +import os +from copy import deepcopy +from typing import Any + +import numpy as np +import numpy.typing as npt +import pandas as pd +from loguru import logger +from sklearn.utils import resample + +from fd_shifts import configs +from fd_shifts.analysis import Analysis, ExperimentData + +from .studies import get_study_iterator + +RANDOM_SEED = 10 + + +def bootstrap_openset_data_iterator(analysis: AnalysisBS): + raise NotImplementedError() + + +def bootstrap_new_class_data_iterator( + data: ExperimentData, + iid_set_name, + dataset_name, + n_bs: int, + stratified: bool, + bs_size: int, +): + assert data.correct is not None + iid_set_ix = data.dataset_name_to_idx(iid_set_name) + new_class_set_ix = data.dataset_name_to_idx(dataset_name) + + select_ix_out = np.argwhere(data.dataset_idx == new_class_set_ix)[:, 0] + + correct = deepcopy(data.correct) + correct[select_ix_out] = 0 + labels = deepcopy(data.labels) + labels[select_ix_out] = -99 + + # Select the two datasets + select_ix_all = np.argwhere( + (data.dataset_idx == new_class_set_ix) | (data.dataset_idx == iid_set_ix) + )[:, 0] + + # Create bootstrap indices. By default, do stratification w.r.t. dataset. If + # stratified==True, it is done w.r.t. failure label. + n = len(select_ix_all) + bs_indices = np.vstack( + [ + resample( + select_ix_all, + n_samples=n if bs_size is None else bs_size, + stratify=( + correct[select_ix_all] + if stratified + else data.dataset_idx[select_ix_all] + ), + random_state=rs + RANDOM_SEED, + ) + for rs in range(n_bs) + ] + ) + + mcd_correct = deepcopy(data.mcd_correct) + select_ix_all_mcd = None + if mcd_correct is not None: + mcd_correct[select_ix_out] = 0 + select_ix_all_mcd = np.argwhere( + (data.dataset_idx == new_class_set_ix) | (data.dataset_idx == iid_set_ix) + )[:, 0] + + n = len(select_ix_all_mcd) + bs_indices_mcd = np.vstack( + [ + resample( + select_ix_all_mcd, + n_samples=n, + stratify=( + mcd_correct[select_ix_all_mcd] + if stratified + else data.dataset_idx[select_ix_all_mcd] + ), + random_state=rs + RANDOM_SEED, + ) + for rs in range(n_bs) + ] + ) + else: + bs_indices_mcd = n_bs * [None] + + def __filter_if_exists(data: npt.NDArray[Any] | None, mask): + if data is not None: + return data[mask] + return None + + for bs_idx, (bs_selection, bs_selection_mcd) in enumerate( + zip(bs_indices, bs_indices_mcd) + ): + # De-select incorrect inlier predictions + bs_selection = bs_selection[ + (correct[bs_selection] == 1) + | (data.dataset_idx[bs_selection] == new_class_set_ix) + ] + + if bs_selection_mcd is not None: + bs_selection_mcd = bs_selection_mcd[ + (mcd_correct[bs_selection_mcd] == 1) + | (data.dataset_idx[bs_selection_mcd] == new_class_set_ix) + ] + + yield bs_idx, data.__class__( + softmax_output=data.softmax_output[bs_selection], + logits=__filter_if_exists(data.logits, bs_selection), + labels=labels[bs_selection], + dataset_idx=data.dataset_idx[bs_selection], + mcd_softmax_dist=__filter_if_exists( + data.mcd_softmax_dist, bs_selection_mcd + ), + mcd_logits_dist=__filter_if_exists(data.mcd_logits_dist, bs_selection_mcd), + external_confids=__filter_if_exists(data.external_confids, bs_selection), + mcd_external_confids_dist=__filter_if_exists( + data.mcd_external_confids_dist, bs_selection_mcd + ), + config=data.config, + _correct=__filter_if_exists(correct, bs_selection), + _mcd_correct=__filter_if_exists(mcd_correct, bs_selection_mcd), + _mcd_labels=__filter_if_exists(labels, bs_selection_mcd), + _react_logits=__filter_if_exists(data.react_logits, bs_selection), + _maha_dist=__filter_if_exists(data.maha_dist, bs_selection), + _vim_score=__filter_if_exists(data.vim_score, bs_selection), + _dknn_dist=__filter_if_exists(data.dknn_dist, bs_selection), + _train_features=data._train_features, + ) + + +def bootstrap_iterator(data: ExperimentData, n_bs: int, stratified: bool, bs_size: int): + n = len(data.labels) + bs_indices = np.vstack( + [ + resample( + np.arange(n), + n_samples=n if bs_size is None else bs_size, + stratify=data.correct if stratified else None, + random_state=rs + RANDOM_SEED, + ) + for rs in range(n_bs) + ] + ) + + def __filter_if_exists(data: npt.NDArray[Any] | None, mask): + if data is not None: + return data[mask] + return None + + for bs_idx, bs_selection in enumerate(bs_indices): + yield bs_idx, data.__class__( + softmax_output=data.softmax_output[bs_selection], + logits=__filter_if_exists(data.logits, bs_selection), + labels=data.labels[bs_selection], + dataset_idx=data.dataset_idx[bs_selection], + mcd_softmax_dist=__filter_if_exists(data.mcd_softmax_dist, bs_selection), + mcd_logits_dist=__filter_if_exists(data.mcd_logits_dist, bs_selection), + external_confids=__filter_if_exists(data.external_confids, bs_selection), + mcd_external_confids_dist=__filter_if_exists( + data.mcd_external_confids_dist, bs_selection + ), + config=data.config, + _correct=__filter_if_exists(data.correct, bs_selection), + _mcd_correct=__filter_if_exists(data.mcd_correct, bs_selection), + _mcd_labels=__filter_if_exists(data.labels, bs_selection), + _react_logits=__filter_if_exists(data.react_logits, bs_selection), + _maha_dist=__filter_if_exists(data.maha_dist, bs_selection), + _vim_score=__filter_if_exists(data.vim_score, bs_selection), + _dknn_dist=__filter_if_exists(data.dknn_dist, bs_selection), + _train_features=data._train_features, + ) + + +class AnalysisBS(Analysis): + """Analysis wrapper function for bootstrap analysis""" + + def __init__( + self, *args, stratified_bs: bool, n_bs: int, no_iid: bool = False, **kwargs + ): + super().__init__(*args, **kwargs) + self.stratified_bs = stratified_bs + self.n_bs = n_bs + self._create_bs_indices_only = False + self.no_iid = no_iid + self._skip = False + + def register_and_perform_studies(self, bs_size: int = None): + """""" + if self._skip: + logger.info( + f"SKIPPING BS analysis for {self.cfg.exp.dir}, external config already evaluated!" + ) + return + + if self.add_val_tuning: + self.rstar = self.cfg.eval.r_star + self.rdelta = self.cfg.eval.r_delta + for study_name, study_data in get_study_iterator("val_tuning")( + "val_tuning", self + ): + self.study_name = study_name + logger.info(f"Performing bootstrap study {self.study_name}") + + # For val_tuning, only do a single evaluation on the original data (no + # bootstrapping) + self._perform_bootstrap_study(0, study_data) + + csv_path = ( + self.analysis_out_dir / f"analysis_metrics_{self.study_name}.csv" + ) + logger.info(f"Saved csv to {csv_path}") + + if self.holdout_classes is not None: + self.study_name = "openset_proposed_mode" + for bs_idx, data in bootstrap_openset_data_iterator(self): + self._perform_bootstrap_study(bs_idx, data) + + csv_path = self.analysis_out_dir / f"analysis_metrics_{self.study_name}.csv" + logger.info(f"Saved csv to {csv_path}") + return + + for query_study, _ in self.query_studies: + if query_study == "new_class_study": + for new_class in self.query_studies.new_class_study: + self.study_name = f"new_class_study_{new_class}_proposed_mode" + logger.info(f"Performing bootstrap study {self.study_name}") + + for bs_idx, data in bootstrap_new_class_data_iterator( + self.experiment_data, + self.query_studies.iid_study, + new_class, + self.n_bs, + self.stratified_bs, + bs_size, + ): + self._perform_bootstrap_study(bs_idx, data) + + csv_path = ( + self.analysis_out_dir + / f"analysis_metrics_{self.study_name}.csv" + ) + logger.info(f"Saved csv to {csv_path}") + + elif self.no_iid and query_study == "iid_study": + logger.info("Skipping IID study.") + continue + else: + for study_name, study_data in get_study_iterator(query_study)( + query_study, self + ): + self.study_name = study_name + logger.info(f"Performing bootstrap study {self.study_name}") + + for bs_idx, data in bootstrap_iterator( + study_data, self.n_bs, self.stratified_bs, bs_size + ): + self._perform_bootstrap_study(bs_idx, data) + + csv_path = ( + self.analysis_out_dir + / f"analysis_metrics_{self.study_name}.csv" + ) + logger.info(f"Saved csv to {csv_path}") + + def _perform_bootstrap_study(self, bs_idx: int, selected_data: ExperimentData): + self._get_confidence_scores(selected_data) + self._compute_confid_metrics() + self._create_results_csv(selected_data, bs_idx) + + def _create_results_csv(self, study_data: ExperimentData, bs_index: int): + """Creates/Overwrites the csv for bs_index == 0, otherwise appends to the csv.""" + all_metrics = self.query_performance_metrics + self.query_confid_metrics + columns = [ + "name", + "study", + "model", + "network", + "fold", + "confid", + "n_test", + "bootstrap_index", + ] + all_metrics + df = pd.DataFrame(columns=columns) + network = self.cfg.model.network + if network is not None: + backbone = dict(network).get("backbone") + else: + backbone = None + for confid_key in self.method_dict["query_confids"]: + submit_list = [ + self.method_dict["name"], + self.study_name, + self.cfg.model.name, + backbone, + self.cfg.exp.fold, + confid_key, + study_data.mcd_softmax_mean.shape[0] + if "mcd" in confid_key + else study_data.softmax_output.shape[0], + bs_index, + ] + submit_list += [ + self.method_dict[confid_key]["metrics"][x] for x in all_metrics + ] + df.loc[len(df)] = submit_list + + create_new_file = bs_index == 0 + df.to_csv( + os.path.join(self.analysis_out_dir, "analysis_metrics_{}.csv").format( + self.study_name + ), + float_format="%.5f", + decimal=".", + mode="w" if create_new_file else "a", + header=create_new_file, + ) + + +def run_bs_analysis( + config: configs.Config, + regenerate_bs_indices: bool = False, + stratified_bs: bool = False, + n_bs: int = 500, + iid_only: bool = False, + no_iid: bool = False, + exclude_noise_study: bool = False, +): + """Bootstrap analysis + + Args: + config (configs.Config): Complete Configuration + regenerate_bs_indices (bool, optional): If False, using previously generated + bootstrap indices. Defaults to True. + stratified_bs (bool, optional): Whether to stratify by failure label. Defaults to + False. + n_bs (int, optional): Number of bootstrap samples. Defaults to 500. + """ + if regenerate_bs_indices: + raise NotImplementedError("No longer writing out bs indices!") + + if stratified_bs: + raise ValueError("Stratified BS sampling makes no sense!") + + path_to_test_dir = config.test.dir + analysis_out_dir = ( + config.exp.output_paths.analysis + / f"bootstrap{'-stratified' if stratified_bs else ''}" + ) + + analysis_out_dir.mkdir(exist_ok=True, parents=True) + query_studies = config.eval.query_studies + + if iid_only: + query_studies.noise_study.dataset = None + query_studies.in_class_study = [] + query_studies.new_class_study = [] + + if exclude_noise_study: + query_studies.noise_study.dataset = None + + query_performance_metrics = ["accuracy", "b-accuracy", "nll", "brier_score"] + query_confid_metrics = [ + "failauc", + "failap_suc", + "failap_err", + "fail-NLL", + "mce", + "ece", + "e-aurc", + "b-aurc", + "aurc", + "augrc", + # "augrc-CI95-l", + # "augrc-CI95-h", + # "augrc-CI95", + "e-augrc", + "augrc-ba", + "aurc-ba", + "fpr@95tpr", + "risk@100cov", + "risk@95cov", + "risk@90cov", + "risk@85cov", + "risk@80cov", + "risk@75cov", + ] + + query_plots = [] + + logger.info( + "Starting bootstrap analysis with in_path {}, out_path {}, and query studies {}".format( + path_to_test_dir, analysis_out_dir, query_studies + ) + ) + + bs_analysis = AnalysisBS( + path=path_to_test_dir, + query_performance_metrics=query_performance_metrics, + query_confid_metrics=query_confid_metrics, + query_plots=query_plots, + query_studies=query_studies, + analysis_out_dir=analysis_out_dir, + add_val_tuning=config.eval.val_tuning, + threshold_plot_confid=None, + qual_plot_confid=None, + cf=config, + stratified_bs=stratified_bs, + n_bs=n_bs, + no_iid=no_iid, + ) + + bs_analysis.register_and_perform_studies() diff --git a/fd_shifts/analysis/confid_scores.py b/fd_shifts/analysis/confid_scores.py index 9b5145e..f5e9d50 100644 --- a/fd_shifts/analysis/confid_scores.py +++ b/fd_shifts/analysis/confid_scores.py @@ -1,12 +1,13 @@ from __future__ import annotations -import logging from typing import TYPE_CHECKING, Any, Callable, TypeVar, cast import numpy as np import numpy.typing as npt from scipy import special as scpspecial +from fd_shifts import logger + if TYPE_CHECKING: from fd_shifts.analysis import Analysis, ExperimentData @@ -27,7 +28,7 @@ def _assert_softmax_numerically_stable(softmax: ArrayType): errors = (msr == 1) & ((softmax > 0) & (softmax < 1)).any(axis=1) if softmax.dtype != np.float64: - logging.warning("Softmax is not 64bit, not checking for numerical stability") + logger.warning("Softmax is not 64bit, not checking for numerical stability") return # alert if more than 10% are erroneous @@ -279,6 +280,7 @@ def mcd_ext(mcd_softmax_mean: ArrayType, _: ArrayType) -> ArrayType: @register_confid_func("maha_qt") @register_confid_func("temp_mls") @register_confid_func("react_temp_mls") +@register_confid_func("temp_logits") @register_confid_func("ext_qt") @register_confid_func("tcp") @register_confid_func("dg") diff --git a/fd_shifts/analysis/eval_utils.py b/fd_shifts/analysis/eval_utils.py index 50a3d7b..d7270c4 100644 --- a/fd_shifts/analysis/eval_utils.py +++ b/fd_shifts/analysis/eval_utils.py @@ -133,7 +133,6 @@ def __init__(self, confids, correct, labels, query_metrics, query_plots, bins): self.bin_confids = None self.fpr_list = None self.tpr_list = None - self.rc_curve = None self.precision_list = None self.recall_list = None self.labels = labels @@ -167,18 +166,42 @@ def get_metrics_per_confid(self): or "e-aurc" in self.query_metrics or "b-aurc" in self.query_metrics ): - if self.rc_curve is None: - self.get_rc_curve_stats() if "aurc" in self.query_metrics: out_metrics["aurc"] = get_metric_function("aurc")(self.stats_cache) if "b-aurc" in self.query_metrics: out_metrics["b-aurc"] = get_metric_function("b-aurc")(self.stats_cache) if "e-aurc" in self.query_metrics: out_metrics["e-aurc"] = get_metric_function("e-aurc")(self.stats_cache) + if "aurc-ba" in self.query_metrics: + out_metrics["aurc-ba"] = get_metric_function("aurc-ba")( + self.stats_cache + ) + if "augrc" in self.query_metrics: + out_metrics["augrc"] = get_metric_function("augrc")(self.stats_cache) + if "augrc-CI95" in self.query_metrics: + out_metrics["augrc-CI95"] = get_metric_function("augrc-CI95")( + self.stats_cache + ) + if "augrc-CI95-l" in self.query_metrics: + out_metrics["augrc-CI95-l"] = get_metric_function("augrc-CI95-l")( + self.stats_cache + ) + if "augrc-CI95-h" in self.query_metrics: + out_metrics["augrc-CI95-h"] = get_metric_function("augrc-CI95-h")( + self.stats_cache + ) + if "e-augrc" in self.query_metrics: + out_metrics["e-augrc"] = get_metric_function("e-augrc")( + self.stats_cache + ) + if "augrc-ba" in self.query_metrics: + out_metrics["augrc-ba"] = get_metric_function("augrc-ba")( + self.stats_cache + ) if "risk@95cov" in self.query_metrics: - coverages = np.array(self.rc_curve[0]) - risks = np.array(self.rc_curve[1]) + coverages = self.stats_cache.coverages + risks = self.stats_cache.selective_risks out_metrics["risk@100cov"] = ( np.min(risks[np.argwhere(coverages >= 1)]) * 100 ) @@ -228,10 +251,8 @@ def get_plot_stats_per_confid(self): plot_stats_dict["bin_confids"] = self.bin_confids if "rc_curve" in self.query_plots: - if self.rc_curve is None: - self.get_rc_curve_stats() - plot_stats_dict["coverage_list"] = np.array(self.rc_curve[0]) - plot_stats_dict["selective_risk_list"] = np.array(self.rc_curve[1]) + plot_stats_dict["coverage_list"] = self.stats_cache.coverages + plot_stats_dict["selective_risk_list"] = self.stats_cache.selective_risks if "prc_curve" in self.query_plots: if self.precision_list is None: @@ -249,11 +270,6 @@ def get_roc_curve_stats(self): f"ROC Curve Failed: {self.correct.shape=}, {self.confids.shape=}, {np.min(self.correct)=}, {np.max(self.correct)=}, {np.min(self.confids)=}, {np.max(self.confids)=}" ) - def get_rc_curve_stats(self): - self.rc_curve, self.aurc, self.eaurc = RC_curve( - (1 - self.correct), self.confids - ) - def get_err_prc_curve_stats(self): self.precision_list, self.recall_list, _ = skm.precision_recall_curve( self.correct, -self.confids, pos_label=0 @@ -651,46 +667,6 @@ def plot_rc(self): self.ax.set_xlabel("Coverage") -def RC_curve(residuals, confidence): - coverages = [] - risks = [] - n = len(residuals) - idx_sorted = np.argsort(confidence) - cov = n - error_sum = sum(residuals[idx_sorted]) - (coverages.append(cov / n),) - risks.append(error_sum / n) - weights = [] - tmp_weight = 0 - for i in range(0, len(idx_sorted) - 1): - cov = cov - 1 - error_sum = error_sum - residuals[idx_sorted[i]] - selective_risk = error_sum / (n - 1 - i) - tmp_weight += 1 - if i == 0 or confidence[idx_sorted[i]] != confidence[idx_sorted[i - 1]]: - coverages.append(cov / n) - risks.append(selective_risk) - weights.append(tmp_weight / n) - tmp_weight = 0 - - # add a well-defined final point to the RC-curve. - if tmp_weight > 0: - coverages.append(0) - risks.append(risks[-1]) - weights.append(tmp_weight / n) - - # aurc is computed as a weighted average over risk scores analogously to the average precision score. - aurc = sum([a * w for a, w in zip(risks, weights)]) - - # compute e-aurc - err = np.mean(residuals) - kappa_star_aurc = err + (1 - err) * (np.log(1 - err)) - e_aurc = aurc - kappa_star_aurc - - curve = (coverages, risks) - return curve, aurc, e_aurc - - # class BrierScore(Metric): # def __init__(self, num_classes, dist_sync_on_step=False): # import torch diff --git a/fd_shifts/analysis/metrics.py b/fd_shifts/analysis/metrics.py index 481a935..8880fde 100644 --- a/fd_shifts/analysis/metrics.py +++ b/fd_shifts/analysis/metrics.py @@ -13,6 +13,8 @@ from sklearn import utils as sku from typing_extensions import ParamSpec +from fd_shifts.analysis.rc_stats import RiskCoverageStatsMixin + from . import logger AURC_DISPLAY_SCALE = 1000 @@ -40,8 +42,7 @@ def _inner_wrapper(*args: P.args, **kwargs: P.kwargs) -> T: return _inner_wrapper -@dataclass -class StatsCache: +class StatsCache(RiskCoverageStatsMixin): """Cache for stats computed by scikit used by multiple metrics. Attributes: @@ -49,10 +50,22 @@ class StatsCache: correct (array_like): Boolean array (best converted to int) where predictions were correct """ - confids: npt.NDArray[Any] - correct: npt.NDArray[Any] - n_bins: int - labels: npt.NDArray[Any] | None = None + def __init__( + self, + confids, + correct, + n_bins, + labels=None, + prevalence_ratios=None, + legacy=False, + ) -> None: + super().__init__() + self.confids: npt.NDArray[Any] = confids + self.correct: npt.NDArray[Any] = correct + self.n_bins: int = n_bins + self.labels = labels + self.prevalence_ratios = prevalence_ratios + self.legacy = legacy @cached_property def roc_curve_stats(self) -> tuple[npt.NDArray[Any], npt.NDArray[Any]]: @@ -345,11 +358,31 @@ def aurc(stats_cache: StatsCache) -> float: Returns: metric value """ - _, risks, weights = stats_cache.rc_curve_stats - return ( - sum([(risks[i] + risks[i + 1]) * 0.5 * weights[i] for i in range(len(weights))]) - * AURC_DISPLAY_SCALE - ) + if stats_cache.legacy: + _, risks, weights = stats_cache.rc_curve_stats + return ( + sum( + [ + (risks[i] + risks[i + 1]) * 0.5 * weights[i] + for i in range(len(weights)) + ] + ) + * AURC_DISPLAY_SCALE + ) + + return stats_cache.aurc + + +@register_metric_func("aurc-CI95-l") +@may_raise_sklearn_exception +def aurc_ci95_l(stats_cache: StatsCache): + return stats_cache.aurc_ci_bs[0] + + +@register_metric_func("aurc-CI95-h") +@may_raise_sklearn_exception +def aurc_ci95_h(stats_cache: StatsCache): + return stats_cache.aurc_ci_bs[1] @register_metric_func("b-aurc") @@ -362,6 +395,48 @@ def baurc(stats_cache: StatsCache): ) +@register_metric_func("aurc-ba") +@may_raise_sklearn_exception +def aurc_ba(stats_cache: StatsCache): + return stats_cache.aurc_ba + + +@register_metric_func("augrc") +@may_raise_sklearn_exception +def augrc(stats_cache: StatsCache): + return stats_cache.augrc + + +@register_metric_func("augrc-CI95") +@may_raise_sklearn_exception +def augrc_ci95(stats_cache: StatsCache): + return stats_cache.augrc_ci_bs[1] - stats_cache.augrc_ci_bs[0] + + +@register_metric_func("augrc-CI95-l") +@may_raise_sklearn_exception +def augrc_ci95_l(stats_cache: StatsCache): + return stats_cache.augrc_ci_bs[0] + + +@register_metric_func("augrc-CI95-h") +@may_raise_sklearn_exception +def augrc_ci95_h(stats_cache: StatsCache): + return stats_cache.augrc_ci_bs[1] + + +@register_metric_func("e-augrc") +@may_raise_sklearn_exception +def eaugrc(stats_cache: StatsCache): + return stats_cache.eaugrc + + +@register_metric_func("augrc-ba") +@may_raise_sklearn_exception +def augrc_ba(stats_cache: StatsCache): + return stats_cache.augrc_ba + + @register_metric_func("e-aurc") @may_raise_sklearn_exception def eaurc(stats_cache: StatsCache) -> float: @@ -373,9 +448,12 @@ def eaurc(stats_cache: StatsCache) -> float: Returns: metric value """ - err = np.mean(stats_cache.residuals) - kappa_star_aurc = err + (1 - err) * (np.log(1 - err + np.finfo(err.dtype).eps)) - return aurc(stats_cache) - kappa_star_aurc * AURC_DISPLAY_SCALE + if stats_cache.legacy: + err = np.mean(stats_cache.residuals) + kappa_star_aurc = err + (1 - err) * (np.log(1 - err + np.finfo(err.dtype).eps)) + return aurc(stats_cache) - kappa_star_aurc * AURC_DISPLAY_SCALE + + return stats_cache.eaurc @register_metric_func("mce") diff --git a/fd_shifts/analysis/rc_stats.py b/fd_shifts/analysis/rc_stats.py new file mode 100644 index 0000000..4e2148c --- /dev/null +++ b/fd_shifts/analysis/rc_stats.py @@ -0,0 +1,640 @@ +import logging +from copy import copy +from dataclasses import dataclass +from functools import cached_property +from typing import Any, Tuple + +import matplotlib.pyplot as plt +import numpy as np +import numpy.typing as npt +from scipy.spatial import ConvexHull +from sklearn import metrics +from sklearn.utils import resample + +from .rc_stats_utils import ( + generalized_risk_ba_stats, + generalized_risk_stats, + selective_risk_ba_stats, + selective_risk_stats, +) + + +class RiskCoverageStatsMixin: + """Mixin for statistics related to the Risk-Coverage-Curve. Classes that inherit from + RiskCoverageStatsMixin should provide the following members: + + - ``residuals``, array of shape (N,): Residuals (binary or non-binary) + - ``confids``, array of shape (N,): Confidence scores + - ``labels``, array of shape (N,): Class labels (required for class-specific risks) + """ + + AUC_DISPLAY_SCALE: int = 1000 + RAISE_ON_NAN: bool = False + + def __init__(self): + super().__init__() + + @cached_property + def n(self) -> int: + """Number of predictions""" + return len(self.residuals) + + @cached_property + def contains_nan(self) -> bool: + """Whether the residuals or confidence scores contain NaN values""" + return any(np.isnan(self.residuals)) or any(np.isnan(self.confids)) + + @cached_property + def is_binary(self) -> bool: + """Whether the residuals are binary""" + return np.all(np.logical_or(self.residuals == 0, self.residuals == 1)) + + @property + def _idx_sorted_confids(self) -> npt.NDArray[Any]: + """Indices that sort the confidence scores in ascending order""" + return np.argsort(self.confids) + + @property + def _idx_sorted_residuals(self) -> npt.NDArray[Any]: + """Indices that sort the residuals in ascending order""" + return np.argsort(self.residuals) + + @cached_property + def curve_stats_selective_risk(self) -> dict: + """RC curve stats for selective risk. + + Returns: + dict with keys: "coverages", "risks", "thresholds", "working_point_mask" + """ + self._validate() + return self._evaluate_rc_curve_stats(risk="selective-risk") + + @cached_property + def curve_stats_generalized_risk(self) -> dict: + """RC curve stats for generalized risk. + + Returns: + dict with keys: "coverages", "risks", "thresholds", "working_point_mask" + """ + self._validate() + return self._evaluate_rc_curve_stats(risk="generalized-risk") + + @cached_property + def curve_stats_selective_risk_ba(self) -> dict: + """RC curve stats for selective risk with BA. + + Returns: + dict with keys: "coverages", "risks", "thresholds", "working_point_mask" + """ + self._validate() + return self._evaluate_rc_curve_stats(risk="selective-risk-ba") + + @cached_property + def curve_stats_generalized_risk_ba(self) -> dict: + """RC curve stats for generalized risk with BA. + + Returns: + dict with keys: "coverages", "risks", "thresholds", "working_point_mask" + """ + self._validate() + return self._evaluate_rc_curve_stats(risk="generalized-risk-ba") + + @property + def coverages(self) -> npt.NDArray[Any]: + """Coverage values in [0, 1], descending""" + return self.curve_stats_generalized_risk["coverages"] + + @property + def thresholds(self) -> npt.NDArray[Any]: + """Confidence threshold values, ascending""" + return self.curve_stats_generalized_risk["thresholds"] + + @property + def working_point_mask(self) -> list[bool]: + """Boolean array indicating the potential working points""" + return self.curve_stats_generalized_risk["working_point_mask"] + + @property + def selective_risks(self) -> npt.NDArray[Any]: + """Selective risk values in [0, 1], sorted by ascending confidence""" + return self.curve_stats_selective_risk["risks"] + + @property + def generalized_risks(self) -> npt.NDArray[Any]: + """Generalized risk values in [0, 1], sorted by ascending confidence""" + return self.curve_stats_generalized_risk["risks"] + + @property + def selective_risks_ba(self) -> npt.NDArray[Any]: + """Selective BA-Risk values in [0, 1], sorted by ascending confidence""" + return self.curve_stats_selective_risk_ba["risks"] + + @property + def generalized_risks_ba(self) -> npt.NDArray[Any]: + """Generalized BA-Risk values in [0, 1], sorted by ascending confidence""" + return self.curve_stats_generalized_risk_ba["risks"] + + @cached_property + def aurc(self) -> float: + """Area under Risk Coverage Curve""" + return self.evaluate_auc(risk="selective-risk") + + @cached_property + def aurc_achievable(self) -> float: + """Achievable area under Risk Coverage Curve""" + return self.evaluate_auc(risk="selective-risk", achievable=True) + + @cached_property + def eaurc(self) -> float: + """Excess AURC""" + return self.aurc - self.aurc_optimal + + @cached_property + def eaurc_achievable(self) -> float: + """Achievable excess AURC""" + return self.aurc_achievable - self.aurc_optimal + + @cached_property + def augrc(self) -> float: + """Area under Generalized Risk Coverage Curve""" + return self.evaluate_auc(risk="generalized-risk") + + @cached_property + def eaugrc(self) -> float: + """Excess AUGRC""" + return self.augrc - self.augrc_optimal + + @cached_property + def aurc_ba(self) -> float: + """AURC with Selective Balanced Accuracy""" + return self.evaluate_auc(risk="selective-risk-ba") + + @cached_property + def augrc_ba(self) -> float: + """AUGRC with residuals corresponding to the Balanced Accuracy-residuals""" + return self.evaluate_auc(risk="generalized-risk-ba") + + @cached_property + def aurc_ci_bs(self) -> Tuple[float, float]: + """Bootstrapped CI (95% percentiles) of the AURC""" + return self.evaluate_ci(risk="selective-risk") + + @cached_property + def augrc_ci_bs(self) -> Tuple[float, float]: + """Bootstrapped CI (95% percentiles) of the AUGRC""" + return self.evaluate_ci(risk="generalized-risk") + + @cached_property + def aurc_ba_ci_bs(self) -> Tuple[float, float]: + """Bootstrapped CI (95% percentiles) of the AURC-BA""" + return self.evaluate_ci(risk="selective-risk-ba") + + @cached_property + def augrc_ba_ci_bs(self) -> Tuple[float, float]: + """Bootstrapped CI (95% percentiles) of the AUGRC-BA""" + return self.evaluate_ci(risk="generalized-risk-ba") + + @cached_property + def dominant_point_mask(self) -> list[bool]: + """Boolean array masking the dominant RC-points""" + if self.is_binary and not self.contains_nan: + if sum(self.residuals) in (0, self.n): + # If the predictions are all correct or all wrong, the RC-Curve is a + # horizontal line, and thus there is one dominant point at cov=1. + indices = np.array([-1]) + num_rc_points = len(self.coverages) + else: + # Compute the convex hull in ROC-space, as the dominant points are the + # same in RC-space. Inspired by + # https://github.com/foxtrotmike/rocch/blob/master/rocch.py + fpr, tpr, _ = metrics.roc_curve( + 1 - self.residuals, self.confids, drop_intermediate=False + ) + num_rc_points = len(fpr) - 1 + + if num_rc_points == 1: + # If there is only one point, the convex hull is trivial + return np.array([True]) + else: + # Add the (2, -1) point to make the convex hull construction easier. + fpr = np.concatenate((fpr, [2.0])) + tpr = np.concatenate((tpr, [-1.0])) + hull = ConvexHull( + np.concatenate((fpr.reshape(-1, 1), tpr.reshape(-1, 1)), axis=1) + ) + indices = hull.vertices - 1 + indices = indices[(indices != -1) & (indices != num_rc_points)] + + mask = np.zeros(num_rc_points, dtype=bool) + mask[indices] = True + # Reverse the order (corresponding to descending coverage) + return mask[::-1] + + # NOTE: For non-binary residuals, finding the subset of RC-points that minimizes + # the AURC is not straightforward. + # Don't mask any points in this case (for now). + return np.ones(len(self.coverages), dtype=bool) + + @cached_property + def aurc_optimal(self) -> float: + """AURC for the same prediction values but optimal confidence scores. Used as + reference for e-AURC calculation. + + For binary residuals, the analytical formula (based on accuracy) is used. + Otherwise, the optimal AURC is calculated based on ideally sorted and stratified + scores. + + Note that if there are confidence plateaus, the computed optimal AURC may be + higher, yielding a negative e-AURC. + """ + if self.contains_nan: + return np.nan + + if self.is_binary: + # Directly calculate optimal AURC from accuracy + err = np.mean(self.residuals) + return self.AUC_DISPLAY_SCALE * ( + err + (1 - err) * (np.log(1 - err + np.finfo(err.dtype).eps)) + ) + + # Evaluate the AURC for optimal confidence scores + rc_point_stats_optimal = self._evaluate_rc_curve_stats( + risk="selective-risk", + confids=np.linspace(1, 0, len(self.confids)), + residuals=self.residuals[self._idx_sorted_residuals], + labels=( + self.labels[self._idx_sorted_residuals] + if self.labels is not None + else None + ), + ) + return self.evaluate_auc( + coverages=rc_point_stats_optimal["coverages"], + risks=rc_point_stats_optimal["risks"], + ) + + @cached_property + def augrc_optimal(self) -> float: + """AUGRC for the same prediction values but optimal confidence scores. Used as + reference for e-AUGRC calculation. + """ + if self.contains_nan: + return np.nan + + if self.is_binary: + return 0.5 * np.mean(self.residuals) ** 2 * self.AUC_DISPLAY_SCALE + + rc_point_stats_optimal = self._evaluate_rc_curve_stats( + risk="generalized-risk", + confids=np.linspace(1, 0, len(self.confids)), + residuals=self.residuals[self._idx_sorted_residuals], + labels=( + self.labels[self._idx_sorted_residuals] + if self.labels is not None + else None + ), + ) + return self.evaluate_auc( + coverages=rc_point_stats_optimal["coverages"], + risks=rc_point_stats_optimal["risks"], + ) + + def _validate(self) -> None: + """""" + assert hasattr(self, "residuals"), "Missing class member 'residuals'" + assert hasattr(self, "confids"), "Missing class member 'confids'" + + if self.contains_nan: + msg = ( + f"There are {sum(np.isnan(self.confids))} NaN confidence values and " + f"{sum(np.isnan(self.residuals))} NaN residuals." + ) + if self.RAISE_ON_NAN: + raise ValueError(msg) + else: + logging.warning(msg) + + def _evaluate_rc_curve_stats( + self, + *, + risk: str, + confids: npt.NDArray[Any] = None, + residuals: npt.NDArray[Any] = None, + labels: npt.NDArray[Any] = None, + ) -> dict: + """Computes the RC-points and the corresponding thresholds and working point mask. + + Returns: + dict with keys: "coverages", "risks", "thresholds", "working_point_mask" + """ + logging.debug("Evaluating the RC points ...") + + idx_sorted_confids = ( + np.argsort(confids) if confids is not None else self._idx_sorted_confids + ) + confids = confids if confids is not None else self.confids + residuals = residuals if residuals is not None else self.residuals + labels = labels if labels is not None else self.labels + + if risk == "selective-risk": + return selective_risk_stats( + confids=confids, + residuals=residuals, + idx_sorted_confids=idx_sorted_confids, + ) + elif risk == "generalized-risk": + return generalized_risk_stats( + confids=confids, + residuals=residuals, + idx_sorted_confids=idx_sorted_confids, + ) + elif risk == "selective-risk-ba": + return selective_risk_ba_stats( + confids=confids, + residuals=residuals, + labels=labels, + idx_sorted_confids=idx_sorted_confids, + ) + elif risk == "generalized-risk-ba": + return generalized_risk_ba_stats( + confids=confids, + residuals=residuals, + labels=labels, + idx_sorted_confids=idx_sorted_confids, + ) + else: + raise ValueError(f"Unknown risk type '{risk}'") + + def get_curve_stats(self, *, risk: str): + """""" + if risk == "selective-risk": + return self.curve_stats_selective_risk + elif risk == "generalized-risk": + return self.curve_stats_generalized_risk + elif risk == "selective-risk-ba": + return self.curve_stats_selective_risk_ba + elif risk == "generalized-risk-ba": + return self.curve_stats_generalized_risk_ba + else: + raise ValueError(f"Unknown risk type '{risk}'") + + def evaluate_auc( + self, + *, + risk: str = None, + coverages: npt.NDArray[Any] = None, + risks: npt.NDArray[Any] = None, + cov_min=0, + cov_max=1, + achievable=False, + interpolation: str = "linear", + ) -> float: + """Compute an AUC value. By default, it is computed over the whole coverage range + [0, 1]. + + Args: + risk (str): Risk type (e.g. "selective-risk" for AURC, "generalized-risk" for + AUGRC) + coverages (npt.NDArray[Any], optional): coverage values + risks (npt.NDArray[Any], optional): risk values + cov_min (int, optional): Lower coverage limit. Defaults to 0. + cov_max (int, optional): Upper coverage limit. Defaults to 1. + achievable (bool, optional): Whether to compute the achievable AURC. + Defaults to False. + interpolation (str): Defaults to trapezoidal interpolation of the RC curve. + + Returns: + float: Area under Risk Coverage Curve + """ + if self.contains_nan: + return np.nan + + if cov_max <= cov_min or cov_max <= 0 or cov_min >= 1: + return 0.0 + + if achievable: + if interpolation == "linear" and "generalized" not in risk: + logging.warning( + "Achievable AURC values should be estimated with 'non-linear' " + f"interpolation. Currvently using: '{interpolation}' interpolation" + ) + risks = risks[self.dominant_point_mask] + coverages = coverages[self.dominant_point_mask] + + assert (coverages is None) == (risks is None) + if coverages is None: + curve_stats = self.get_curve_stats(risk=risk) + coverages = curve_stats["coverages"] + risks = curve_stats["risks"] + + if interpolation == "linear" or "generalized" in risk: + # Linear interpolation + if cov_max != 1 or cov_min != 0: + raise NotImplementedError() + return -np.trapz(risks, coverages) * self.AUC_DISPLAY_SCALE + + # Non-linear interpolation for selective-risk-based AUC + # Prepare the AURC evaluation for a certain coverage range + n = self.n + cov_below = 0 + error_sum_below = 0 + lower_lim = 0 + cov_above = None + error_sum_above = None + upper_lim = None + + if cov_min > 0: + idx_range = np.argwhere(coverages >= cov_min)[:, 0] + if idx_range[-1] < len(coverages) - 1: + cov_below = coverages[idx_range[-1] + 1] + error_sum_below = risks[idx_range[-1] + 1] * cov_below + lower_lim = (cov_min - cov_below) / (coverages[idx_range[-1]] - cov_below) + cov_below *= n + error_sum_below *= n + coverages = coverages[idx_range] + risks = risks[idx_range] + + if cov_max < 1: + idx_range = np.argwhere(coverages <= cov_max)[:, 0] + if len(idx_range) > 0: + cov_above = coverages[idx_range[0] - 1] + error_sum_above = risks[idx_range[0] - 1] * cov_above + upper_lim = (cov_max - coverages[idx_range[0]]) / ( + cov_above - coverages[idx_range[0]] + ) + cov_above *= n + error_sum_above *= n + else: + cov_above = coverages[-1] * n + error_sum_above = risks[-1] * cov_above + upper_lim = cov_max / coverages[-1] + + coverages = coverages[idx_range] + risks = risks[idx_range] + + # Integrate segments between RC-points + cov = coverages * n + error_sum = risks * cov + + # If cov is empty, integrate withing a single segment + if len(cov) == 0: + if cov_below == 0: + aurc = error_sum_above * (upper_lim - lower_lim) + return aurc / n + else: + cov_diff = cov_above - cov_below + aurc = (error_sum_above - error_sum_below) * (upper_lim - lower_lim) + ( + error_sum_below * cov_above - error_sum_above * cov_below + ) * np.log( + (cov_above + cov_diff * upper_lim) + / (cov_below + cov_diff * lower_lim) + ) / cov_diff + return aurc / n + + aurc = 0 + # Add contributions of complete segments + if len(cov) > 1: + cov_diff = -np.diff(cov) + error_sum_prev = error_sum[:-1] + error_sum_next = error_sum[1:] + cov_prev = cov[:-1] + cov_next = cov[1:] + + aurc += sum( + error_sum_prev + - error_sum_next + + (error_sum_next * cov_prev - error_sum_prev * cov_next) + * np.log(cov_prev / cov_next) + / cov_diff + ) + + # Additional contributions at lower coverage + if cov_below == 0: + aurc += error_sum[-1] * (1 - lower_lim) + else: + cov_diff = cov[-1] - cov_below + aurc += (error_sum[-1] - error_sum_below) * (1 - lower_lim) + ( + error_sum_below * cov[-1] - error_sum[-1] * cov_below + ) * np.log(cov[-1] / (cov_below + cov_diff * lower_lim)) / cov_diff + + # Additional contributions at higher coverage + if cov_max < 1: + cov_diff = cov_above - cov[0] + aurc += (error_sum_above - error_sum[0]) * upper_lim + ( + error_sum[0] * cov_above - error_sum_above * cov[0] + ) * np.log((cov[0] + cov_diff * upper_lim) / cov[0]) / cov_diff + + return aurc / n * self.AUC_DISPLAY_SCALE + + def evaluate_ci( + self, + *, + risk: str, + confids: npt.NDArray[Any] = None, + residuals: npt.NDArray[Any] = None, + labels: npt.NDArray[Any] = None, + n_bs: int = 10000, + stratified: bool = True, + ): + """Compute confidence intervals based on bootstrapping.""" + confids = confids if confids is not None else self.confids + residuals = residuals if residuals is not None else self.residuals + labels = labels if labels is not None else self.labels + N = len(confids) + aurc_bs = np.empty(n_bs) + for i in range(n_bs): + if not stratified or not self.is_binary: + indices_bs = np.random.choice(np.arange(N), size=N, replace=True) + else: + indices_bs = resample(np.arange(N), n_samples=N, stratify=residuals) + confids_bs = confids[indices_bs] + residuals_bs = residuals[indices_bs] + labels_bs = labels[indices_bs] if labels is not None else None + + curve_stats = self._evaluate_rc_curve_stats( + risk=risk, + confids=confids_bs, + residuals=residuals_bs, + labels=labels_bs, + ) + aurc_bs[i] = self.evaluate_auc( + coverages=curve_stats["coverages"], risks=curve_stats["risks"] + ) + + # Compute the empirical 95% quantiles + return np.percentile(aurc_bs, [2.5, 97.5]) + + def get_working_point( + self, + *, + risk: str, + target_risk=None, + target_cov=None, + ) -> tuple[float, float, float]: + """Select a working point from the RC-points given a desired risk or coverage. + + Args: + risk str: Risk type (e.g. "selective-risk" for AURC, "generalized-risk" for + AUGRC) + target_risk (float, optional): Desired (maximum) risk value in range [0, 1] + target_cov (float, optional): Desired (maximum) coverage value in range [0, 1] + + Returns: + working point (tuple): coverage, risk, threshold + """ + if target_risk is None and target_cov is None: + raise ValueError("Must provide either target_risk or target_cov value") + if target_risk is not None and target_cov is not None: + raise ValueError( + "The target_risk and target_cov arguments are mutually exclusive" + ) + + curve_stats = self.get_curve_stats(risk=risk) + working_point_mask = curve_stats["working_point_mask"] + coverages = curve_stats["coverages"][working_point_mask] + risks = curve_stats["risks"][working_point_mask] + thresholds = np.r_[curve_stats["thresholds"], -np.infty][working_point_mask] + + if self.contains_nan: + return np.nan, np.nan, np.nan + + if target_risk is not None: + mask = np.argwhere(risks <= target_risk)[:, 0] + idx = np.argmax(coverages[mask]) + elif target_cov is not None: + mask = np.argwhere(coverages >= target_cov)[:, 0] + idx = np.argmin(risks[mask]) + + cov_value = coverages[mask][idx] + risk_value = risks[mask][idx] + threshold = thresholds[mask][idx] + + return cov_value, risk_value, threshold + + +class RiskCoverageStats(RiskCoverageStatsMixin): + """Standalone RiskCoverageStats class""" + + def __init__( + self, + confids: npt.NDArray[Any], + residuals: npt.NDArray[Any], + labels: npt.NDArray[Any] = None, + ): + """Returns a RiskCoverageStats instance which allows for calculating metrics + related to the Risk-Coverage-Curve. + + Applicable to binary failure labels as well as continuous residuals. + + Args: + confids (npt.NDArray[Any]): Confidence values + residuals (npt.NDArray[Any]): 'Residual scores' in [0, 1]. E.g., an integer + array indicating wrong predictions. The selective risks are calculated + as the sum of residuals after selection divided by the coverage. + labels (npt.NDArray[Any], optional): Class labels (required for BA-based + metrics and prevalence shifts) + """ + super().__init__() + self.confids = confids + self.residuals = residuals + self.labels = labels diff --git a/fd_shifts/analysis/rc_stats_utils.py b/fd_shifts/analysis/rc_stats_utils.py new file mode 100644 index 0000000..9f99c49 --- /dev/null +++ b/fd_shifts/analysis/rc_stats_utils.py @@ -0,0 +1,227 @@ +from typing import Any + +import numpy as np +import numpy.typing as npt + + +def selective_risk_stats( + *, + confids: npt.NDArray[Any], + residuals: npt.NDArray[Any], + idx_sorted_confids: npt.NDArray[Any] = None, +) -> dict: + """Computes the RC-point stats for the Selective Risk. + + Returns: + dict with keys: "coverages", "risks", "thresholds", "working_point_mask" + """ + n = len(residuals) + idx_sorted = ( + np.argsort(confids) if idx_sorted_confids is None else idx_sorted_confids + ) # ascending scores + residuals = residuals[idx_sorted] + confidence = confids[idx_sorted] + + cov = n + selective_risk_norm = n + error_sum = sum(residuals) + + coverages = [1.0] # descending coverage + risks = [error_sum / cov] + thresholds = [confidence[0]] + working_point_mask = [True] + current_min_risk = risks[0] + + for i in range(n - 1): + cov -= 1 + selective_risk_norm -= 1 + error_sum -= residuals[i] + + if confidence[i] != confidence[i + 1]: + selective_risk = error_sum / selective_risk_norm + if selective_risk < current_min_risk: + working_point_mask.append(True) + current_min_risk = selective_risk + else: + working_point_mask.append(False) + + thresholds.append(confidence[i + 1]) + coverages.append(cov / n) + risks.append(selective_risk) + + coverages.append(0) + risks.append(risks[-1]) + working_point_mask.append(False) + + return { + "coverages": np.array(coverages), + "risks": np.array(risks), + "thresholds": np.array(thresholds), + "working_point_mask": working_point_mask, + } + + +def generalized_risk_stats( + *, + confids: npt.NDArray[Any], + residuals: npt.NDArray[Any], + idx_sorted_confids: npt.NDArray[Any] = None, +) -> dict: + """Computes the RC-point stats for the Generalized Risk. + + Returns: + dict with keys: "coverages", "risks", "thresholds", "working_point_mask" + """ + n = len(residuals) + idx_sorted = ( + np.argsort(confids) if idx_sorted_confids is None else idx_sorted_confids + ) # ascending scores + residuals = residuals[idx_sorted] + confidence = confids[idx_sorted] + + cov = n + error_sum = sum(residuals) + + coverages = [1.0] + risks = [error_sum / n] + thresholds = [confidence[0]] + working_point_mask = [True] + current_min_risk = risks[0] + + for i in range(n - 1): + cov -= 1 + error_sum -= residuals[i] + risk = error_sum / n + if confidence[i] != confidence[i + 1]: + if risk < current_min_risk: + working_point_mask.append(True) + current_min_risk = risk + else: + working_point_mask.append(False) + + thresholds.append(confidence[i + 1]) + coverages.append(cov / n) + risks.append(risk) + + coverages.append(0) + working_point_mask.append(risks[-1] > 0) + risks.append(0) + + return { + "coverages": np.array(coverages), + "risks": np.array(risks), + "thresholds": np.array(thresholds), + "working_point_mask": working_point_mask, + } + + +def selective_risk_ba_stats( + *, + confids: npt.NDArray[Any], + residuals: npt.NDArray[Any], + labels: npt.NDArray[Any] = None, + idx_sorted_confids: npt.NDArray[Any] = None, + drop_empty_classes: bool = False, +): + """Computes the RC-point stats for the Selective Risk based on Balanced Accuracy. + + Returns: + dict with keys: "coverages", "risks", "thresholds", "working_point_mask" + """ + assert labels is not None + unique_labels, class_coverages = np.unique(labels, return_counts=True) + # Set up look-up dict to access `class_coverages` based on labels + label_to_idx = {l: idx for idx, l in enumerate(unique_labels)} + + n = len(confids) + cov = n + coverages = [1.0] + + idx_sorted = ( + np.argsort(confids) if idx_sorted_confids is None else idx_sorted_confids + ) # ascending scores + residuals = residuals[idx_sorted] + confids = confids[idx_sorted] + labels = labels[idx_sorted] + + error_sum = np.array([sum(residuals[labels == c]) for c in unique_labels]) + risks = [np.mean(error_sum / class_coverages)] + thresholds = [confids[0]] + working_point_mask = [True] + current_min_risk = risks[0] + + for i in range(n - 1): + c = label_to_idx[labels[i]] + cov -= 1 + class_coverages[c] -= 1 + error_sum[c] -= residuals[i] + + # NOTE: If True, classes that are completely deferred no longer contribute to the + # score. But this would mean that CSFs are highly rewarded if they keep TPs + # from all classes up to high confidences. + if drop_empty_classes and class_coverages[c] == 0: + if not error_sum.dtype == "float": + error_sum = np.array(error_sum, dtype=float) + error_sum[c] = np.nan + + if confids[i] != confids[i + 1]: + selective_recalls = np.divide( + error_sum, + class_coverages, + out=np.zeros_like(error_sum, dtype=float), + where=class_coverages != 0, + ) + selective_risk = np.mean(selective_recalls) + if selective_risk < current_min_risk: + working_point_mask.append(True) + current_min_risk = selective_risk + else: + working_point_mask.append(False) + + thresholds.append(confids[i + 1]) + coverages.append(cov / n) + risks.append(selective_risk) + + coverages.append(0) + risks.append(risks[-1]) + working_point_mask.append(False) + + return { + "coverages": np.array(coverages), + "risks": np.array(risks), + "thresholds": np.array(thresholds), + "working_point_mask": working_point_mask, + } + + +def generalized_risk_ba_stats( + *, + confids: npt.NDArray[Any], + residuals: npt.NDArray[Any], + labels: npt.NDArray[Any] = None, + idx_sorted_confids: npt.NDArray[Any] = None, +): + """Computes the RC-point stats for the Generalized Risk based on Balanced Accuracy. + + Returns: + dict with keys: "coverages", "risks", "thresholds", "working_point_mask" + """ + assert labels is not None + unique_labels, class_coverages = np.unique(labels, return_counts=True) + # Set up look-up dict to access `class_coverages` based on labels + label_to_idx = {l: idx for idx, l in enumerate(unique_labels)} + num_classes = len(unique_labels) + n = len(confids) + # Adjust residuals according to class prevalences: residuals for classes with + # prevalence = 1/K stay the same. + weights = np.array( + [n / (num_classes * class_coverages[label_to_idx[l]]) for l in labels] + ) + assert np.isclose(np.sum(weights), n) + residuals = residuals * weights + + return generalized_risk_stats( + confids=confids, + residuals=residuals, + idx_sorted_confids=idx_sorted_confids, + ) diff --git a/fd_shifts/analysis/studies.py b/fd_shifts/analysis/studies.py index 3a7f8c8..632a7a0 100644 --- a/fd_shifts/analysis/studies.py +++ b/fd_shifts/analysis/studies.py @@ -483,8 +483,7 @@ def iterate_noise_study_data( for noise_set in getattr(analysis.query_studies, study_name): for intensity_level in range(5): logger.info( - "Starting noise study with intensitiy level %s", - intensity_level + 1, + f"Starting noise study with intensitiy level {intensity_level + 1}" ) study_data = filter_func( diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 54dc04b..b67e82c 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -136,69 +136,6 @@ class ExperimentConfig(_IterableMixin): output_paths: OutputPathsPerMode = OutputPathsPerMode() -# @defer_validation -# @dataclass(config=ConfigDict(validate_assignment=True)) -# class LRSchedulerConfig: -# """Base class for LR scheduler configuration""" - -# _target_: str = MISSING -# _partial_: Optional[bool] = None - - -# CosineAnnealingLR = builds( -# torch.optim.lr_scheduler.CosineAnnealingLR, -# builds_bases=(LRSchedulerConfig,), -# zen_partial=True, -# populate_full_signature=True, -# T_max="${trainer.num_steps}", -# ) - -# LinearWarmupCosineAnnealingLR = builds( -# pl_bolts.optimizers.lr_scheduler.LinearWarmupCosineAnnealingLR, -# builds_bases=(LRSchedulerConfig,), -# zen_partial=True, -# populate_full_signature=True, -# max_epochs="${trainer.num_steps}", -# warmup_epochs=500, -# ) - - -# @defer_validation -# @dataclass(config=ConfigDict(validate_assignment=True)) -# class OptimizerConfig: -# """Base class for optimizer configuration""" - -# _target_: str = MISSING -# _partial_: Optional[bool] = True - - -# @defer_validation -# @dataclass(config=ConfigDict(validate_assignment=True)) -# class SGD(OptimizerConfig): -# """Configuration for SGD optimizer""" - -# _target_: str = "torch.optim.sgd.SGD" -# lr: float = 0.003 # pylint: disable=invalid-name -# dampening: float = 0.0 -# momentum: float = 0.9 -# nesterov: bool = False -# maximize: bool = False -# weight_decay: float = 0.0 - - -# @defer_validation -# @dataclass(config=ConfigDict(validate_assignment=True)) -# class Adam(OptimizerConfig): -# """Configuration for ADAM optimizer""" - -# _target_: str = "torch.optim.adam.Adam" -# lr: float = 0.003 # pylint: disable=invalid-name -# betas: tuple[float, float] = (0.9, 0.999) -# eps: float = 1e-08 -# maximize: bool = False -# weight_decay: float = 0.0 - - @dataclass class LRSchedulerConfig: init_args: dict diff --git a/fd_shifts/experiments/__init__.py b/fd_shifts/experiments/__init__.py index 5d81b53..1a4d35d 100644 --- a/fd_shifts/experiments/__init__.py +++ b/fd_shifts/experiments/__init__.py @@ -1,6 +1,6 @@ -from collections.abc import Iterable, Iterator +from collections.abc import Iterable from dataclasses import dataclass -from itertools import chain, product +from itertools import product from pathlib import Path from rich import print as pprint @@ -254,18 +254,20 @@ def from_iterables( rewards: Iterable[float], learning_rates: Iterable[float | None], ): - return map( - lambda args: Experiment(*args), - product( - (group_dir,), - datasets, - models, - backbones, - dropouts, - runs, - rewards, - learning_rates, - ), + return list( + map( + lambda args: Experiment(*args), + product( + (group_dir,), + datasets, + models, + backbones, + dropouts, + runs, + rewards, + learning_rates, + ), + ) ) @@ -420,13 +422,12 @@ def get_all_experiments( with_hyperparameter_sweep=False, with_vit_special_runs=True, with_ms_runs=True, - with_precision_study=True, -) -> Iterator[Experiment]: + with_precision_study=False, +) -> list[Experiment]: _experiments = [] # ViT Best lr runs - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("svhn",), @@ -436,11 +437,10 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("svhn",), @@ -450,11 +450,10 @@ def get_all_experiments( dropouts=(0, 1), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("svhn", "svhn_openset"), @@ -464,11 +463,10 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(2.2, 3, 6, 10), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("svhn", "svhn_openset"), @@ -478,11 +476,10 @@ def get_all_experiments( dropouts=(0, 1), runs=range(5), rewards=(2.2, 3, 6, 10), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("svhn_openset",), @@ -492,11 +489,10 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("svhn_openset",), @@ -506,11 +502,10 @@ def get_all_experiments( dropouts=(0, 1), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("cifar10",), @@ -520,11 +515,10 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("cifar10",), @@ -534,11 +528,10 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("cifar10",), @@ -548,11 +541,10 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(2.2, 3, 6, 10), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("cifar10",), @@ -562,11 +554,10 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(2.2, 3, 6, 10), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("cifar100",), @@ -576,11 +567,10 @@ def get_all_experiments( dropouts=(1, 0), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("super_cifar100",), @@ -590,11 +580,10 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("super_cifar100",), @@ -604,11 +593,10 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("cifar100",), @@ -618,11 +606,10 @@ def get_all_experiments( dropouts=(1, 0), runs=range(5), rewards=(2.2, 3, 6, 10, 12, 15, 20), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("super_cifar100",), @@ -632,11 +619,10 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(2.2, 3, 6, 10, 12, 15, 20), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("super_cifar100",), @@ -646,11 +632,10 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(2.2, 3, 6, 10, 12, 15, 20), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("wilds_animals",), @@ -660,11 +645,10 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("wilds_animals",), @@ -674,11 +658,10 @@ def get_all_experiments( dropouts=(0, 1), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("wilds_animals_openset",), @@ -688,11 +671,10 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("wilds_animals_openset",), @@ -702,11 +684,10 @@ def get_all_experiments( dropouts=(0, 1), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=( @@ -719,11 +700,10 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(2.2, 3, 6, 10, 15), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=( @@ -736,11 +716,10 @@ def get_all_experiments( dropouts=(0, 1), runs=range(5), rewards=(2.2, 3, 6, 10, 15), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("wilds_camelyon",), @@ -750,11 +729,10 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("wilds_camelyon",), @@ -764,11 +742,10 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("wilds_camelyon",), @@ -778,11 +755,10 @@ def get_all_experiments( dropouts=(0,), runs=range(5), rewards=(2.2, 3, 6, 10), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("wilds_camelyon",), @@ -792,11 +768,10 @@ def get_all_experiments( dropouts=(1,), runs=range(5), rewards=(2.2, 3, 6, 10), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("breeds",), @@ -806,11 +781,10 @@ def get_all_experiments( dropouts=(0,), runs=range(2), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("breeds",), @@ -820,11 +794,10 @@ def get_all_experiments( dropouts=(1,), runs=range(2), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("breeds",), @@ -834,11 +807,10 @@ def get_all_experiments( dropouts=(0,), runs=range(2), rewards=(2.2, 3, 6, 10, 15), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit"), datasets=("breeds",), @@ -848,13 +820,12 @@ def get_all_experiments( dropouts=(1,), runs=range(2), rewards=(2.2, 3, 6, 10, 15), - ), + ) ) # ViT Best lr runs # Non-vit - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("svhn",), @@ -864,11 +835,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("svhn",), @@ -878,11 +848,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2, 3, 6, 10), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("svhn_openset",), @@ -892,11 +861,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("svhn_openset",), @@ -906,11 +874,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2, 3, 6, 10), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("cifar10",), @@ -920,11 +887,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("cifar10",), @@ -934,11 +900,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2, 3, 6, 10), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("cifar100",), @@ -948,11 +913,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("cifar100",), @@ -962,11 +926,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2, 3, 6, 10, 12, 15, 20), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("supercifar",), @@ -976,11 +939,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("supercifar",), @@ -990,11 +952,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2, 3, 6, 10, 12, 15, 20), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("animals",), @@ -1004,11 +965,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("animals",), @@ -1018,11 +978,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2, 3, 6, 10, 15), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("animals_openset",), @@ -1032,11 +991,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("animals_openset",), @@ -1046,11 +1004,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2, 3, 6, 10, 15), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("camelyon",), @@ -1060,11 +1017,10 @@ def get_all_experiments( runs=range(10), rewards=(2.2,), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("camelyon",), @@ -1074,11 +1030,10 @@ def get_all_experiments( runs=range(10), rewards=(2.2, 3, 6, 10), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("breeds",), @@ -1088,11 +1043,10 @@ def get_all_experiments( runs=range(2), rewards=(2.2,), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts"), datasets=("breeds",), @@ -1102,12 +1056,12 @@ def get_all_experiments( runs=range(2), rewards=(2.2, 3, 6, 10, 15), learning_rates=(None,), - ), + ) ) if with_precision_study: - _experiments = chain( - _experiments, + # precision study + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/svhn_precision_study16"), datasets=("svhn",), @@ -1117,11 +1071,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/svhn_precision_study32"), datasets=("svhn",), @@ -1131,11 +1084,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/svhn_precision_study64"), datasets=("svhn",), @@ -1145,11 +1097,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/camelyon_precision_study16"), datasets=("camelyon",), @@ -1159,11 +1110,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/camelyon_precision_study32"), datasets=("camelyon",), @@ -1173,11 +1123,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/camelyon_precision_study64"), datasets=("camelyon",), @@ -1187,11 +1136,10 @@ def get_all_experiments( runs=range(5), rewards=(2.2,), learning_rates=(None,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit_precision_study16"), datasets=("svhn",), @@ -1201,11 +1149,10 @@ def get_all_experiments( dropouts=(0, 1), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit_precision_study32"), datasets=("svhn",), @@ -1215,11 +1162,10 @@ def get_all_experiments( dropouts=(0, 1), runs=range(5), rewards=(0,), - ), + ) ) - _experiments = chain( - _experiments, + _experiments.extend( Experiment.from_iterables( group_dir=Path("fd-shifts/vit_precision_study64"), datasets=("svhn",), @@ -1229,16 +1175,18 @@ def get_all_experiments( dropouts=(0, 1), runs=range(5), rewards=(0,), - ), + ) ) if not with_vit_special_runs: - _experiments = filter( - lambda exp: not (exp.backbone == "vit" and exp.model != "vit"), - _experiments, + _experiments = list( + filter( + lambda exp: not (exp.backbone == "vit" and exp.model != "vit"), + _experiments, + ) ) - if with_ms_runs: - _experiments = chain(_experiments, get_ms_experiments()) + # if with_ms_runs: + # _experiments.extend(get_ms_experiments()) return _experiments diff --git a/fd_shifts/experiments/configs.py b/fd_shifts/experiments/configs.py index ed88372..2f02bc7 100644 --- a/fd_shifts/experiments/configs.py +++ b/fd_shifts/experiments/configs.py @@ -326,7 +326,7 @@ def breeds_data_config( "val": augmentations, "test": augmentations, }, - kwargs={"info_dir_path": "loaders/breeds_hierarchies"}, + kwargs=None, ) @@ -455,6 +455,8 @@ def cnn_animals_modelconfidnet(run: int, do: int, **kwargs): config.trainer.callbacks["training_stages"]["milestones"] = [12, 17] config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None + config.trainer.callbacks["training_stages"]["pretrained_confidnet_path"] = None config.model.name = "confidnet_model" config.model.dropout_rate = do config.model.network.name = "confidnet_and_enc" @@ -513,6 +515,8 @@ def cnn_camelyon_modelconfidnet(run: int, do: int, **kwargs): config.trainer.callbacks["training_stages"]["milestones"] = [5, 8] config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None + config.trainer.callbacks["training_stages"]["pretrained_confidnet_path"] = None config.model.name = "confidnet_model" config.model.dropout_rate = do config.model.network.name = "confidnet_and_enc" @@ -571,6 +575,8 @@ def cnn_svhn_modelconfidnet(run: int, do: int, **kwargs): config.trainer.callbacks["training_stages"]["milestones"] = [100, 300] config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None + config.trainer.callbacks["training_stages"]["pretrained_confidnet_path"] = None config.model.name = "confidnet_model" config.model.dropout_rate = do config.model.network.name = "confidnet_and_enc" @@ -628,6 +634,8 @@ def cnn_cifar10_modelconfidnet(run: int, do: int, **kwargs): config.trainer.callbacks["training_stages"]["milestones"] = [250, 450] config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None + config.trainer.callbacks["training_stages"]["pretrained_confidnet_path"] = None config.model.name = "confidnet_model" config.model.dropout_rate = do config.model.avg_pool = do == 0 @@ -688,6 +696,8 @@ def cnn_cifar100_modelconfidnet(run: int, do: int, **kwargs): config.trainer.callbacks["training_stages"]["milestones"] = [250, 450] config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None + config.trainer.callbacks["training_stages"]["pretrained_confidnet_path"] = None config.model.name = "confidnet_model" config.model.avg_pool = do == 0 config.model.dropout_rate = do @@ -779,6 +789,8 @@ def cnn_breeds_modelconfidnet(run: int, do: int, **kwargs): config.trainer.callbacks["training_stages"]["milestones"] = [300, 500] config.trainer.callbacks["training_stages"]["disable_dropout_at_finetuning"] = True config.trainer.callbacks["training_stages"]["confidnet_lr_scheduler"] = False + config.trainer.callbacks["training_stages"]["pretrained_backbone_path"] = None + config.trainer.callbacks["training_stages"]["pretrained_confidnet_path"] = None config.model.name = "confidnet_model" config.model.dropout_rate = do config.model.network.name = "confidnet_and_enc" @@ -1086,6 +1098,20 @@ def register(config_fn: Callable[..., Config], n_runs: int = 5, **kwargs): config = config_fn(**kwargs, run=run) __experiments[f"{config.exp.group_name}/{config.exp.name}"] = config + # Add external CSF to the set of computed scores + if config.eval.ext_confid_name is not None: + # if config.model.name != "vit_model": + config.eval.confidence_measures.test += ["ext"] + + # Add MCD-based CSFs to the set of computed scores + if config.model.dropout_rate: + config.eval.confidence_measures.test += [ + "mcd_mcp", + "mcd_pe", + "mcd_ee", + "mcd_mi", # , "mcd_sv", "mcd_waic" + ] + register(vit_svhn_modelvit, lr=0.03, do=1, rew=0) register(vit_svhn_modelvit, lr=0.01, do=0, rew=0) diff --git a/fd_shifts/experiments/tracker.py b/fd_shifts/experiments/tracker.py index 8b203e9..894c87f 100644 --- a/fd_shifts/experiments/tracker.py +++ b/fd_shifts/experiments/tracker.py @@ -51,3 +51,60 @@ def list_analysis_output_files(config: Config) -> list: files.append("analysis_metrics_val_tuning.csv") return files + + +def list_bootstrap_analysis_output_files( + config: Config, + stratified_bs: bool, + filter_study_name: list = None, + original_new_class_mode: bool = False, +) -> list: + subdir = f"bootstrap{'-stratified' if stratified_bs else ''}/" + files = [] + for study_name, testset in config.eval.query_studies: + # Keep only studies that are in filter_study_name + if filter_study_name is not None and study_name not in filter_study_name: + continue + + if study_name == "iid_study": + files.append(subdir + "analysis_metrics_iid_study.csv") + continue + if study_name == "noise_study": + if isinstance(testset, DataConfig) and testset.dataset is not None: + files.extend( + subdir + f"analysis_metrics_noise_study_{i}.csv" + for i in range(1, 6) + ) + continue + + if isinstance(testset, list): + if len(testset) > 0: + if isinstance(testset[0], DataConfig): + testset = map( + lambda d: d.dataset + ("_384" if d.img_size[0] == 384 else ""), + testset, + ) + + testset = [ + subdir + f"analysis_metrics_{study_name}_{d}.csv" for d in testset + ] + if study_name == "new_class_study": + testset = [ + d.replace( + ".csv", + "_original_mode.csv" + if original_new_class_mode + else "_proposed_mode.csv", + ) + for d in testset + ] + files.extend(list(testset)) + elif isinstance(testset, DataConfig) and testset.dataset is not None: + files.append(subdir + testset.dataset) + elif isinstance(testset, str): + files.append(subdir + testset) + + if config.eval.val_tuning: + files.append(subdir + "analysis_metrics_val_tuning.csv") + + return files diff --git a/fd_shifts/loaders/dataset_collection.py b/fd_shifts/loaders/dataset_collection.py index 48667f6..0d9163a 100644 --- a/fd_shifts/loaders/dataset_collection.py +++ b/fd_shifts/loaders/dataset_collection.py @@ -13,11 +13,7 @@ import torchvision from medmnist.info import DEFAULT_ROOT, HOMEPAGE, INFO from PIL import Image, ImageFile -from robustness.tools.breeds_helpers import ( - ClassHierarchy, - make_entity13, - print_dataset_info, -) +from robustness.tools.breeds_helpers import make_entity13 from robustness.tools.folder import ImageFolder from robustness.tools.helpers import get_label_mapping from torch.utils.data import Dataset @@ -1041,7 +1037,8 @@ def get_subset(self, split, frac=1.0, transform=None): class myWILDSSubset(WILDSSubset): def __init__(self, dataset, indices, transform): super().__init__(dataset, indices, transform) - self.classes = dataset.classes + if hasattr(dataset, "classes"): + self.classes = dataset.classes def __getitem__(self, idx): x, y, metadata = self.dataset[self.indices[idx]] @@ -1678,4 +1675,6 @@ def get_dataset( return _dataset_factory[name](**pass_kwargs) else: - return _dataset_factory[name](**pass_kwargs) + return _dataset_factory[name]( + **{**pass_kwargs, **(kwargs if kwargs is not None else {})} + ) diff --git a/fd_shifts/main.py b/fd_shifts/main.py old mode 100644 new mode 100755 index 3faea50..0e70239 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -20,6 +20,7 @@ from fd_shifts import reporting from fd_shifts.configs import Config, DataConfig, OutputPathsPerMode +from fd_shifts.reporting.report_bootstrap import report_bootstrap_results __subcommands = {} @@ -422,8 +423,10 @@ def train(config: Config): ) wandb_logger = WandbLogger( - project="fd_shifts_proto", name=config.exp.name, + project="fd_shifts", + group=config.exp.group_name, + tags=["dev"], ) trainer = pl.Trainer( @@ -536,6 +539,13 @@ def analysis(config: Config): ) +@subcommand +def analysis_bootstrap(config: Config, **kwargs): + from fd_shifts.analysis.bootstrap import run_bs_analysis + + run_bs_analysis(config=config, **kwargs) + + @subcommand def debug(config: Config): pass @@ -565,6 +575,11 @@ def get_parser(): subparsers["report"] = subparser subcommands.add_subcommand("report", subparser) + subparser = ArgumentParser() + subparser.add_function_arguments(report_bootstrap_results) + subparsers["report_bootstrap"] = subparser + subcommands.add_subcommand("report_bootstrap", subparser) + for name, func in __subcommands.items(): subparser = ArgumentParser() subparser.add_argument( @@ -601,9 +616,13 @@ def main(): reporting.main(**args.report) return + if args.command == "report_bootstrap": + report_bootstrap_results(**args.report_bootstrap) + return + config = config_from_parser(parser, args) - rich.print(config) + # rich.print(config) # TODO: Check if configs are the same if not config.test.cf_path.is_file() or args.overwrite_config_file: @@ -619,6 +638,18 @@ def main(): "Config file already exists, use --overwrite-config-file to force" ) + if args.command == "analysis_bootstrap": + __subcommands[args.command]( + config=config, + regenerate_bs_indices=args[args.command].regenerate_bs_indices, + stratified_bs=args[args.command].stratified_bs, + n_bs=args[args.command].n_bs, + iid_only=args[args.command].iid_only, + no_iid=args[args.command].no_iid, + exclude_noise_study=args[args.command].exclude_noise_study, + ) + return + __subcommands[args.command](config=config) diff --git a/fd_shifts/models/callbacks/confid_monitor.py b/fd_shifts/models/callbacks/confid_monitor.py index dcc86f5..a3cf461 100644 --- a/fd_shifts/models/callbacks/confid_monitor.py +++ b/fd_shifts/models/callbacks/confid_monitor.py @@ -500,7 +500,7 @@ def on_test_batch_end( outputs["logits"].to(dtype=self.output_dtype).cpu() ) self.running_test_labels.extend(outputs["labels"].cpu()) - if "ext" in self.query_confids.test: + if "ext" in self.query_confids.test and outputs.get("confid") is not None: self.running_test_external_confids.extend(outputs["confid"].cpu()) if outputs.get("logits_dist") is not None: self.running_test_softmax_dist.extend( diff --git a/fd_shifts/reporting/__init__.py b/fd_shifts/reporting/__init__.py index 2ce1d1c..42834d3 100644 --- a/fd_shifts/reporting/__init__.py +++ b/fd_shifts/reporting/__init__.py @@ -2,59 +2,76 @@ import functools import os from pathlib import Path -from typing import cast import pandas as pd +from pandarallel import pandarallel from fd_shifts import logger from fd_shifts.configs import Config -from fd_shifts.experiments import Experiment, get_all_experiments from fd_shifts.experiments.configs import get_experiment_config, list_experiment_configs -from fd_shifts.experiments.tracker import list_analysis_output_files +from fd_shifts.experiments.tracker import ( + list_analysis_output_files, + list_bootstrap_analysis_output_files, +) + +pandarallel.initialize() DATASETS = ( "svhn", "cifar10", "cifar100", "super_cifar100", - "camelyon", - "animals", + "wilds_camelyon", + "wilds_animals", "breeds", ) -def __find_in_store(config: Config, file: str) -> Path | None: +def _find_in_store(config: Config, file: str) -> Path | None: store_paths = map(Path, os.getenv("FD_SHIFTS_STORE_PATH", "").split(":")) test_dir = config.test.dir.relative_to(os.getenv("EXPERIMENT_ROOT_DIR", "")) for store_path in store_paths: if (store_path / test_dir / file).is_file(): - logger.info(f"Loading {store_path / test_dir / file}") + # logger.info(f"Loading {store_path / test_dir / file}") return store_path / test_dir / file -def __load_file(config: Config, name: str, file: str): - if f := __find_in_store(config, file): +def _load_file(config: Config, name: str, file: str): + if f := _find_in_store(config, file): return pd.read_csv(f) else: logger.error(f"Could not find {name}: {file} in store") return None -def __load_experiment(name: str) -> pd.DataFrame | None: +def _load_experiment( + name: str, bootstrap_analysis: bool = False, stratified_bs: bool = False +) -> pd.DataFrame | None: from fd_shifts.main import omegaconf_resolve config = get_experiment_config(name) config = omegaconf_resolve(config) - # data = list(executor.map(functools.partial(__load_file, config, name), list_analysis_output_files(config))) - data = list( - map( - functools.partial(__load_file, config, name), - list_analysis_output_files(config), + # data = list(executor.map(functools.partial(_load_file, config, name), list_analysis_output_files(config))) + if bootstrap_analysis: + data = list( + map( + functools.partial(_load_file, config, name), + list_bootstrap_analysis_output_files(config, stratified_bs), + ) ) - ) - if len(data) == 0 or any(map(lambda d: d is None, data)): + else: + data = list( + map( + functools.partial(_load_file, config, name), + list_analysis_output_files(config), + ) + ) + + data = [d for d in data if d is not None] + if len(data) == 0: return + data = pd.concat(data) # type: ignore data = ( data.assign( @@ -65,12 +82,23 @@ def __load_experiment(name: str) -> pd.DataFrame | None: lr=config.trainer.optimizer.init_args["init_args"]["lr"], ) .dropna(subset=["name", "model"]) - .drop_duplicates(subset=["name", "study", "model", "network", "confid"]) + .drop_duplicates( + subset=( + ["name", "study", "model", "network", "confid"] + if not bootstrap_analysis + else ["name", "study", "model", "network", "confid", "bootstrap_index"] + ) + ) ) + return data -def load_all(): +def load_all( + bootstrap_analysis: bool = False, + stratified_bs: bool = False, + include_vit: bool = False, +): dataframes = [] # TODO: make this async with concurrent.futures.ProcessPoolExecutor(max_workers=12) as executor: @@ -78,8 +106,21 @@ def load_all(): filter( lambda d: d is not None, executor.map( - __load_experiment, - filter(lambda exp: "clip" not in exp, list_experiment_configs()), + functools.partial( + _load_experiment, + bootstrap_analysis=bootstrap_analysis, + stratified_bs=stratified_bs, + ), + filter( + ( + (lambda exp: ("clip" not in exp)) + if include_vit + else lambda exp: ( + ("clip" not in exp) and (not exp.startswith("vit")) + ) + ), + list_experiment_configs(), + ), ), ) ) @@ -147,6 +188,7 @@ def assign_hparams_from_names(data: pd.DataFrame) -> pd.DataFrame: experiment data with additional columns """ logger.info("Assigning hyperparameters from experiment names") + data = data.assign( backbone=lambda data: _extract_hparam( data.name, r"bb([a-z0-9]+)(_small_conv)?" @@ -157,10 +199,11 @@ def assign_hparams_from_names(data: pd.DataFrame) -> pd.DataFrame: .mask(data["backbone"] != "vit", "") .mask(data["backbone"] == "vit", "vit_") + data.model.where( - data.backbone == "vit", data.name.str.split("_", expand=True)[0] - ).mask( data.backbone == "vit", - data.name.str.split("model", expand=True)[1].str.split("_", expand=True)[0], + data.name.str.split("_", expand=True)[0] + # ).mask( + # data.backbone == "vit", + # data.name.str.split("model", expand=True)[1].str.split("_", expand=True)[0], ), # Encode every detail into confid name _confid=data.confid, @@ -188,7 +231,7 @@ def filter_best_lr(data: pd.DataFrame, metric: str = "aurc") -> pd.DataFrame: Returns: filtered data """ - logger.info("Filtering best learning rates") + logger.info(f"Filtering best learning rates, optimizing {metric}") def _filter_row(row, selection_df, optimization_columns, fixed_columns): if "openset" in row["study"]: @@ -244,10 +287,12 @@ def _filter_row(row, selection_df, optimization_columns, fixed_columns): ) ] - return data + return data, selection_df -def filter_best_hparams(data: pd.DataFrame, metric: str = "aurc") -> pd.DataFrame: +def filter_best_hparams( + data: pd.DataFrame, metric: str = "aurc", bootstrap_analysis: bool = False +) -> pd.DataFrame: """ for every study (which encodes dataset) and confidence (which encodes other stuff) select all runs with the best avg combo of reward and dropout @@ -259,8 +304,7 @@ def filter_best_hparams(data: pd.DataFrame, metric: str = "aurc") -> pd.DataFram Returns: filtered data """ - - logger.info("Filtering best hyperparameters") + logger.info(f"Filtering best hyperparameters, optimizing {metric}") def _filter_row(row, selection_df, optimization_columns, fixed_columns): if "openset" in row["study"]: @@ -293,7 +337,10 @@ def _filter_row(row, selection_df, optimization_columns, fixed_columns): "model", ] optimization_columns = ["rew", "dropout"] - aggregation_columns = ["run", metric] + if bootstrap_analysis: + aggregation_columns = ["run", "bootstrap_index", metric] + else: + aggregation_columns = ["run", metric] # Only look at validation data and the relevant columns selection_df = data[data.study.str.contains("val_tuning")][ @@ -311,7 +358,7 @@ def _filter_row(row, selection_df, optimization_columns, fixed_columns): ] data = data[ - data.apply( + data.parallel_apply( lambda row: _filter_row( row, selection_df, optimization_columns, fixed_columns ), @@ -319,7 +366,7 @@ def _filter_row(row, selection_df, optimization_columns, fixed_columns): ) ] - return data + return data, selection_df def _confid_string_to_name(confid: pd.Series) -> pd.Series: @@ -397,35 +444,50 @@ def str_format_metrics(data: pd.DataFrame) -> pd.DataFrame: Returns: experiment data with formatted metrics """ - data = data.rename(columns={"fail-NLL": "failNLL"}) - - data = data.assign( - accuracy=(data.accuracy * 100).map("{:>2.2f}".format), - aurc=data.aurc.map("{:>3.2f}".format).map( - lambda x: x[:4] if "." in x[:3] else x[:3] + _columns = data.columns + dash_to_no_dash = { + c: c.replace("-", "") for c in _columns if isinstance(c, str) and "-" in c + } + # Remove dashes from column names + data = data.rename(columns=dash_to_no_dash) + + # Formatting instructions for each metric + format_mapping = { + "accuracy": lambda x: "{:>2.2f}".format(x * 100), + "aurc": lambda x: ( + "{:>3.2f}".format(x)[:4] + if "." in "{:>3.2f}".format(x)[:3] + else "{:>3.2f}".format(x)[:3] ), - failauc=(data.failauc * 100).map("{:>3.2f}".format), - ece=data.ece.map("{:>2.2f}".format), - failNLL=data.failNLL.map("{:>2.2f}".format), - ) - data = data.rename(columns={"failNLL": "fail-NLL"}) + "failauc": lambda x: "{:>3.2f}".format(x * 100), + "ece": lambda x: "{:>2.2f}".format(x), + "failNLL": lambda x: "{:>2.2f}".format(x), + } + format_mapping["eaurc"] = format_mapping["aurc"] + format_mapping["augrc"] = format_mapping["aurc"] + format_mapping["eaugrc"] = format_mapping["aurc"] + format_mapping["aurcba"] = format_mapping["aurc"] + format_mapping["augrcba"] = format_mapping["aurc"] + + # Apply formatting if metric is present in the data + for col, formatting_func in format_mapping.items(): + if col in data.columns: + data[col] = data[col].map(formatting_func) + + # Apply inverse mapping, add dashes again + data = data.rename(columns={v: k for k, v in dash_to_no_dash.items()}) return data -def main(out_path: str | Path): - """Main entrypoint for CLI report generation - - Args: - base_path (str | Path): path where experiment data lies - """ +def main( + out_path: str | Path = "./output", + metric_hparam_search: str = "augrc", +): + """Main entrypoint for CLI report generation""" from fd_shifts.reporting import tables from fd_shifts.reporting.plots import plot_rank_style, vit_v_cnn_box - from fd_shifts.reporting.tables import ( - paper_results, - rank_comparison_metric, - rank_comparison_mode, - ) + from fd_shifts.reporting.tables import paper_results, rank_comparison_metric pd.set_option("display.max_rows", None) pd.set_option("display.max_columns", None) @@ -433,32 +495,104 @@ def main(out_path: str | Path): pd.set_option("display.max_colwidth", None) data_dir: Path = Path(out_path).expanduser().resolve() + data_dir = data_dir / f"optimized-{metric_hparam_search}" data_dir.mkdir(exist_ok=True, parents=True) data = load_all() - data = assign_hparams_from_names(data) - data = filter_best_lr(data) - data = filter_best_hparams(data) + # -- Select best hyperparameters --------------------------------------------------- + data, selection_df = filter_best_lr(data, metric=metric_hparam_search) + selection_df.to_csv(data_dir / "filter_best_lr.csv", decimal=".") + logger.info(f"Saved best lr to '{str(data_dir / 'filter_best_lr.csv')}'") + data, selection_df = filter_best_hparams(data, metric=metric_hparam_search) + selection_df.to_csv(data_dir / "filter_best_hparams.csv", decimal=".") + logger.info(f"Saved best hparams to '{str(data_dir / 'filter_best_hparams.csv')}'") data = _filter_unused(data) + + # Filter MCD data + # data = data[~data.confid.str.contains("mcd")] + data = rename_confids(data) data = rename_studies(data) - # plot_rank_style(data, "cifar10", "aurc", data_dir) - # vit_v_cnn_box(data, data_dir) + CONFIDS_TO_REPORT = [ + "MSR", + "MLS", + "PE", + "MCD-MSR", + "MCD-PE", + "MCD-EE", + "DG-MCD-MSR", + "ConfidNet", + "DG-Res", + "Devries et al.", + "TEMP-MLS", + "DG-PE", + "DG-TEMP-MLS", + ] + data = data[data.confid.isin(CONFIDS_TO_REPORT)] + # data = data[data.confid.isin(CONFIDS_TO_REPORT + ["VIT-"+c for c in CONFIDS_TO_REPORT])] + + # -- Aggregate across runs --------------------------------------------------------- + data, std = tables.aggregate_over_runs( + data, + metric_columns=[ + "accuracy", + "aurc", + "ece", + "failauc", + "fail-NLL", + "e-aurc", + "augrc", + "e-augrc", + "aurc-ba", + "augrc-ba", + ], + ) - data, std = tables.aggregate_over_runs(data) + # -- Apply metric formatting ------------------------------------------------------- data = str_format_metrics(data) - paper_results(data, "aurc", False, data_dir) - # paper_results(data, "aurc", False, data_dir, rank_cols=True) - # paper_results(data, "ece", False, data_dir) - # paper_results(data, "failauc", True, data_dir) - # paper_results(data, "accuracy", True, data_dir) - # paper_results(data, "fail-NLL", False, data_dir) + # # -- Relative error (evaluated across runs) -------------------------------------- + metric_list = ["aurc", "e-aurc", "augrc", "e-augrc", "aurc-ba", "augrc-ba"] + data_dir_std = data_dir / "rel_std" + data_dir_std.mkdir(exist_ok=True, parents=True) + for m in metric_list: + std[m] = std[m].astype(float) / data[m].astype(float) + std = str_format_metrics(std) + + for m in metric_list: + # lower is better for all these metrics + paper_results(std, m, False, data_dir_std) + + # # -- Metric tables ----------------------------------------------------------------- + for m in metric_list: + # lower is better for all these metrics + paper_results(data, m, False, data_dir) + paper_results(data, m, False, data_dir, rank_cols=True) + + paper_results(data, "ece", False, data_dir) + paper_results(data, "failauc", True, data_dir) + paper_results(data, "accuracy", True, data_dir) + paper_results(data, "fail-NLL", False, data_dir) + + # -- Ranking comparisons ----------------------------------------------------------- + rank_comparison_metric( + data, + data_dir, + metric1="aurc", + metric2="augrc", + metric1_higherbetter=False, + metric2_higherbetter=False, + ) - # rank_comparison_metric(data, data_dir) - # rank_comparison_mode(data, data_dir) - # rank_comparison_mode(data, data_dir, False) + rank_comparison_metric( + data, + data_dir, + metric1="aurc-ba", + metric2="augrc-ba", + metric1_higherbetter=False, + metric2_higherbetter=False, + ) diff --git a/fd_shifts/reporting/__main__.py b/fd_shifts/reporting/__main__.py index ba3076a..efe050d 100644 --- a/fd_shifts/reporting/__main__.py +++ b/fd_shifts/reporting/__main__.py @@ -1,3 +1,3 @@ from fd_shifts import reporting -reporting.main("./results") +reporting.main("./output") diff --git a/fd_shifts/reporting/plots.py b/fd_shifts/reporting/plots.py index 8db805e..58fb7ea 100644 --- a/fd_shifts/reporting/plots.py +++ b/fd_shifts/reporting/plots.py @@ -448,3 +448,128 @@ def _fix_studies(n): plt.tight_layout() plt.savefig(out_dir / f"vit_v_cnn.png") + + +def acc_auroc_plot(data: pd.DataFrame, metric, out_dir): + """""" + data = data[~data.study.str.contains("proposed_mode")] + + for _, group in data.groupby("study"): + plt.scatter( + np.array(group["accuracy"], dtype=float), + np.array(group["failauc"], dtype=float), + c=np.array(group[metric], dtype=float), + vmin=0, + vmax=300 if metric == "aurc" else 150, + s=2, + cmap="turbo", + ) + + plt.colorbar() + plt.savefig(out_dir / f"pareto_plot_{metric}.pdf") + plt.close() + + +def ranking_change_arrows( + data1: pd.DataFrame, + data2: pd.DataFrame, + metric1, + metric2, + out_dir, +): + """""" + from fd_shifts.reporting.tables import ( + _add_rank_columns, + _dataset_to_display_name, + build_results_table, + ) + + _DATASETS = ["animals", "breeds", "camelyon", "cifar10", "cifar100", "svhn"] + + results_table1 = build_results_table(data1, metric1) + results_table1 = _add_rank_columns(results_table1) + results_table1 = results_table1.iloc[ + :, results_table1.columns.get_level_values(0).isin(_DATASETS) + ] + results_table1 = results_table1.rename(columns=_dataset_to_display_name, level=0) + + results_table2 = build_results_table(data2, metric2) + results_table2 = _add_rank_columns(results_table2) + results_table2 = results_table2.iloc[ + :, results_table2.columns.get_level_values(0).isin(_DATASETS) + ] + results_table2 = results_table2.rename(columns=_dataset_to_display_name, level=0) + + confid_to_label = { + c: f"C{i+1}" + for i, c in enumerate(results_table1.index.get_level_values(0).values) + } + n_confid = len(confid_to_label) + + for c, l in confid_to_label.items(): + print(f"{l}: {c}") + print(results_table1.columns) + print("Left: aurc, Right: augrc") + + for exp in results_table1.columns: + if metric1 == "augrc" and metric2 == "aurc": + ranking2 = results_table1[exp].sort_values() + ranking1 = results_table2[exp].sort_values() + else: + ranking1 = results_table1[exp].sort_values() + ranking2 = results_table2[exp].sort_values() + + arrow_offset = 0.01 + column_distance = 0.1 + + def to_label_string(c): + if c.size == 0: + return "" + return ", ".join( + [confid_to_label[csf_cnn[0]] for csf_cnn in c.index.to_list()] + ) + + # Loop 1 for the labels (loop over rank values) + for r in np.arange(n_confid) + 1: + plt.text( + x=0, + y=n_confid - r, + s=to_label_string(ranking1[ranking1 == r]), + horizontalalignment="right", + verticalalignment="center", + ) + plt.text( + x=column_distance, + y=n_confid - r, + s=to_label_string(ranking2[ranking2 == r]), + horizontalalignment="left", + verticalalignment="center", + ) + + # Loop 2 for the arrows (loop over confids) + for confid in confid_to_label: + y1 = ranking1.loc[(confid, "CNN")] + y2 = ranking2.loc[(confid, "CNN")] + + if y1 != y2: + plt.arrow( + x=arrow_offset, + y=n_confid - y1, + dx=column_distance - 2 * arrow_offset, + dy=y1 - y2, + length_includes_head=True, + width=0.00015, + head_width=0.01, + head_length=0.05, + overhang=0.1, + color="tab:red", + ) + + plt.xlim(-0.5, 0.6) + plt.ylim(-0.2, n_confid - 0.4) + plt.axis("off") + plt.savefig( + out_dir / f"ranking_change_{metric1}_{metric2}_arrows_{'_'.join(exp)}.pdf", + bbox_inches="tight", + ) + plt.close() diff --git a/fd_shifts/reporting/plots_bootstrap.py b/fd_shifts/reporting/plots_bootstrap.py new file mode 100644 index 0000000..a9517af --- /dev/null +++ b/fd_shifts/reporting/plots_bootstrap.py @@ -0,0 +1,822 @@ +from itertools import product +from pathlib import Path + +import matplotlib.pyplot as plt +import matplotlib.ticker as ticker +import numpy as np +import pandas as pd +from matplotlib.patches import Rectangle +from scipy.stats import kendalltau, wilcoxon + +plt.rcParams.update( + { + "font.size": 11.0, + "font.family": "serif", + "font.serif": "Palatino", + "axes.titlesize": "medium", + "figure.titlesize": "medium", + "text.usetex": True, + } +) + + +def _make_color_dict(confids): + colors = [ + "tab:blue", + "green", + "tab:purple", + "orange", + "red", + "black", + "pink", + "olive", + "grey", + "brown", + "tab:cyan", + "blue", + "limegreen", + "darkmagenta", + "salmon", + ] + + color_dict = { + conf: colors[ix % len(colors)] + for ix, conf in enumerate(sorted(list(np.unique(confids)))) + } + return color_dict + + +def bs_box_scatter_plot( + data: pd.DataFrame, + metric: str, + out_dir: Path, + filename: str, +) -> None: + """""" + grouped_data = data.groupby("confid")[metric] + + # Create box plots for each confidence level + plt.boxplot( + [grouped_data.get_group(confid) for confid in grouped_data.groups.keys()], + positions=np.arange(len(grouped_data)), + patch_artist=True, + ) + + # Overlay scatter plot with jittered points + for loc, (_, group) in enumerate(grouped_data): + jitter = np.random.normal(loc=0, scale=0.05, size=len(group)) + plt.scatter([loc] * len(group) + jitter, group, alpha=0.5, color="k", s=2) + + plt.xticks( + ticks=np.arange(len(grouped_data)), + labels=grouped_data.groups.keys(), + rotation=60, + horizontalalignment="right", + verticalalignment="top", + ) + plt.ylabel(metric) + plt.title(filename) + plt.savefig(out_dir / filename, bbox_inches="tight") + plt.close() + + +def bs_podium_plot( + data: pd.DataFrame, + metric: str, + histograms: pd.DataFrame, + out_dir: Path, + filename: str, +) -> None: + """""" + n_confid = histograms.shape[0] + rank_values = np.arange(1, n_confid + 1) + # Assuming the histogram rows to be sorted by overall rank + confid_to_rank_idx = {histograms.index[i]: i for i in range(n_confid)} + + # Create a color map for confid + cmap = plt.cm.turbo + color_list_confids = [cmap(r) for r in np.linspace(0, 1, n_confid)] + colors_dict = _make_color_dict(histograms.index) + + _, (ax_scatter, ax_hist) = plt.subplots( + nrows=2, + ncols=1, + height_ratios=(6, 1), + gridspec_kw=dict(hspace=0), + subplot_kw=dict(xlim=(0.8, n_confid + 1.2)), + ) + + plt.sca(ax_scatter) + # Create scatter plot + for confid, group in data.groupby("confid"): + r = confid_to_rank_idx[confid] + plt.scatter( + group["rank"] + (r + 0.5) / n_confid, + group[metric], + label=confid, + color=colors_dict[confid], + s=3.5, + # increase zorder such that the scatter plot is in front of the lines + zorder=3, + ) + + # Create line plot connecting points with the same bootstrap_index + for _, group in data.sort_values(by="rank").groupby( + "bootstrap_index" if "run" not in data.columns else ["bootstrap_index", "run"] + ): + if len(group) != n_confid: + raise ValueError( + f"Missing results for the following group (expected {n_confid} " + f"confids):\n\n{group}" + ) + for i in range(n_confid - 1): + plt.plot( + [ + group["rank"].values[i] + + (confid_to_rank_idx[group.confid.values[i]] + 0.5) / n_confid, + group["rank"].values[i + 1] + + (confid_to_rank_idx[group.confid.values[i + 1]] + 0.5) / n_confid, + ], + group[metric][i : i + 2], + color=colors_dict[group.confid.values[i]], + lw=0.08, + # random zorder such that no color is completely hidden + zorder=np.random.rand() + 1.5, + ) + + plt.vlines( + np.arange(1, n_confid + 2), + ymin=data[metric].min(), + ymax=data[metric].max(), + linestyles="dashed", + colors="k", + linewidths=0.5, + ) + + plt.legend(loc="upper left", bbox_to_anchor=(1.0, 1.0), markerscale=3) + plt.ylabel(metric) + plt.xticks(np.arange(1, n_confid + 2), labels=(n_confid + 1) * [""]) + plt.tick_params(axis="x", direction="in") + + # Histogram plots on lower axis + plt.sca(ax_hist) + for rank in histograms.columns: + plt.bar( + x=rank + np.linspace(0, 1, n_confid, endpoint=False), + height=histograms[rank], + width=1 / n_confid, + align="edge", + color=[colors_dict[confid] for confid in histograms.index], + ) + plt.yticks(ticks=[]) + # Using hidden minor ticks to get centered labels on the x-axis + plt.gca().xaxis.set_major_locator(ticker.FixedLocator(np.arange(1, n_confid + 2))) + plt.gca().xaxis.set_minor_locator( + ticker.FixedLocator(np.arange(1, n_confid + 1) + 0.5) + ) + plt.gca().xaxis.set_major_formatter(ticker.NullFormatter()) + plt.gca().xaxis.set_minor_formatter(ticker.FixedFormatter(list(rank_values) + [""])) + plt.gca().tick_params(axis="x", which="minor", bottom=False) + plt.xlabel("Rank") + plt.title(filename) + plt.savefig(out_dir / filename, bbox_inches="tight") + plt.close() + + +def bs_blob_plot( + histograms: pd.DataFrame, + medians, + out_dir: Path, + filename: str, +) -> None: + """""" + max_blob_size = 300 + + # Plot blobs + n_samples = histograms.sum(axis=1)[0] + n_confid = histograms.shape[0] + rank_values = np.arange(1, n_confid + 1) + + # Reindex columns handling the case of shared last ranks + histograms = histograms.reindex(columns=rank_values, fill_value=0) + + colors_dict = _make_color_dict(histograms.index) + + for idx, confid in enumerate(histograms.index): + plt.scatter( + n_confid * [idx], + rank_values, + s=histograms.loc[confid] / n_samples * max_blob_size, + c=colors_dict[confid], + ) + + plt.plot(rank_values - 1, rank_values, color="gray", ls="dashed", lw=0.5, zorder=0) + plt.scatter( + rank_values - 1, + medians, + marker="x", + color="k", + s=0.8 * max_blob_size, + linewidths=0.5, + ) + + plt.xticks( + ticks=rank_values - 1, + labels=list(histograms.index), + rotation=60, + horizontalalignment="right", + verticalalignment="top", + ) + plt.yticks(ticks=rank_values) + plt.gca().set_axisbelow(True) + plt.gca().xaxis.grid(color="gray", lw=1.5, alpha=0.15) + plt.gca().yaxis.grid(color="gray", lw=1.5, alpha=0.15) + plt.ylabel("Rank") + plt.title(filename) + plt.tight_layout() + plt.savefig(out_dir / filename) + plt.close() + + +def bs_significance_map( + data: pd.DataFrame, + metric: str, + histograms: pd.DataFrame, + out_dir: Path, + filename: str, +) -> None: + """""" + # significance level + alpha = 0.05 + n_confid = histograms.shape[0] + rank_values = np.arange(1, n_confid + 1) + confid_indices = np.arange(n_confid) + + # Reindex columns handling the case of shared last ranks + histograms = histograms.reindex(columns=rank_values, fill_value=0) + + # Compute significance map + significance = np.zeros((n_confid, n_confid)) + confid_names = histograms.index.values + + for i, j in product(range(n_confid), range(n_confid)): + if i == j: + significance[i, j] = np.nan + continue + + # Catch the case where all values are the same and set significance to 0 + if np.allclose( + data.groupby("confid") + .get_group(confid_names[i]) + .sort_values( + by=["bootstrap_index"] + if "run" not in data.columns + else ["bootstrap_index", "run"] + )[metric], + data.groupby("confid") + .get_group(confid_names[j]) + .sort_values( + by=["bootstrap_index"] + if "run" not in data.columns + else ["bootstrap_index", "run"] + )[metric], + ): + significance[i, j] = 0 + else: + # Get the two confid-groups and sort the values by bootstrap index and run to + # ensure that they are aligned. + significance[i, j] = int( + wilcoxon( + data.groupby("confid") + .get_group(confid_names[i]) + .sort_values( + by=["bootstrap_index"] + if "run" not in data.columns + else ["bootstrap_index", "run"] + )[metric], + data.groupby("confid") + .get_group(confid_names[j]) + .sort_values( + by=["bootstrap_index"] + if "run" not in data.columns + else ["bootstrap_index", "run"] + )[metric], + correction=False, + alternative="less", + ).pvalue + < alpha + ) + + colors = ["steelblue", "yellow"] + alphas = [0.85, 0.5] + + fig = plt.figure(figsize=(10, 10)) + ax = fig.gca() + + for i, c in enumerate(significance): + for j, s in enumerate(c): + if i == j: + continue + ax.add_patch( + Rectangle( + (i - 0.5, j - 0.5), + width=1, + height=1, + color=colors[int(s)], + alpha=alphas[int(s)], + lw=0, + fill=True, + zorder=-2, + ) + ) + + plt.plot( + [-0.6, n_confid - 0.4], [-0.6, n_confid - 0.4], color="k", lw=0.5, zorder=10 + ) + plt.grid(color="whitesmoke") + + plt.xticks( + ticks=confid_indices + 0.4, + labels=list(histograms.index), + rotation=60, + horizontalalignment="right", + verticalalignment="top", + fontsize=23, + minor=True, + ) + plt.yticks( + ticks=confid_indices + 0.25, + labels=list(histograms.index), + rotation=30, + horizontalalignment="right", + verticalalignment="top", + fontsize=23, + minor=True, + ) + + plt.gca().tick_params(axis="x", which="minor", bottom=False) + plt.xticks(ticks=confid_indices, labels=n_confid * []) + plt.gca().tick_params(axis="y", which="minor", left=False) + plt.yticks(ticks=confid_indices, labels=n_confid * []) + + plt.xlim(-0.6, n_confid - 0.4) + plt.ylim(-0.6, n_confid - 0.4) + plt.title(filename) + plt.tight_layout() + plt.savefig(out_dir / filename) + plt.close() + + +def bs_significance_map_colored( + data: pd.DataFrame, + metric: str, + histograms: pd.DataFrame, + out_dir: Path, + filename: str, + no_labels: bool = False, + flip_horizontally: bool = False, +) -> None: + """""" + # significance level + alpha = 0.05 + n_confid = histograms.shape[0] + rank_values = np.arange(1, n_confid + 1) + confid_indices = np.arange(n_confid) + + # Reindex columns handling the case of shared last ranks + histograms = histograms.reindex(columns=rank_values, fill_value=0) + colors_dict = _make_color_dict(histograms.index) + + # Compute significance map + significance = np.zeros((n_confid, n_confid)) + confid_names = histograms.index.values + + for i, j in product(range(n_confid), range(n_confid)): + if i == j: + significance[i, j] = np.nan + continue + + # Catch the case where all values are the same and set significance to 0 + if np.allclose( + data.groupby("confid") + .get_group(confid_names[i]) + .sort_values( + by=["bootstrap_index"] + if "run" not in data.columns + else ["bootstrap_index", "run"] + )[metric], + data.groupby("confid") + .get_group(confid_names[j]) + .sort_values( + by=["bootstrap_index"] + if "run" not in data.columns + else ["bootstrap_index", "run"] + )[metric], + ): + significance[i, j] = 0 + else: + # Get the two confid-groups and sort the values by bootstrap index and run to + # ensure that they are aligned. + significance[i, j] = int( + wilcoxon( + data.groupby("confid") + .get_group(confid_names[i]) + .sort_values( + by=["bootstrap_index"] + if "run" not in data.columns + else ["bootstrap_index", "run"] + )[metric], + data.groupby("confid") + .get_group(confid_names[j]) + .sort_values( + by=["bootstrap_index"] + if "run" not in data.columns + else ["bootstrap_index", "run"] + )[metric], + correction=False, + alternative="less", + ).pvalue + < alpha + ) + + if no_labels: + # Create legend separately + plt.figure(figsize=(10, 10)) + ax = plt.gca() + for i, (confid, color) in enumerate(colors_dict.items()): + ax.add_patch( + Rectangle( + (0, 2 * i), + width=1, + height=1, + color=colors_dict[confid], + alpha=0.5, + lw=0, + fill=True, + zorder=-2, + ) + ) + plt.yticks( + ticks=2 * confid_indices, + labels=list(colors_dict.keys()), + fontsize=23, + ) + plt.xlim(-0.6, 2 * n_confid - 0.4) + plt.ylim(-0.6, 2 * n_confid - 0.4) + plt.savefig(out_dir / "significance_maps_color_legend.pdf", bbox_inches="tight") + plt.close() + + fig = plt.figure(figsize=(10, 10)) + ax = fig.gca() + + if no_labels: + # with open(out_dir / "significance_maps_color_legend.txt", "w") as file: + # for k, v in colors_dict.items(): + # file.write(f"{k}\t{v}\n") + + if flip_horizontally: + for i, (c, confid) in enumerate(zip(significance, confid_names)): + for j, s in enumerate(c): + if i == j: + continue + + if s: + ax.add_patch( + Rectangle( + # (i - 0.5, j - 0.5), + (j - 0.5, n_confid - 1 - i - 0.5), + width=1, + height=1, + color=colors_dict[confid], + alpha=0.5, + lw=0, + fill=True, + zorder=-2, + ) + ) + else: + ax.scatter( + # [i], + # [j], + [j], + [n_confid - 1 - i], + marker="X", + s=300, + c=colors_dict[confid], + alpha=0.5, + ) + # plt.plot([-0.6, n_confid-0.4], [-0.6, n_confid-0.4], color="k", lw=0.5, zorder=10) + plt.plot( + [-0.6, n_confid - 0.4], + [n_confid - 0.4, -0.6], + color="k", + lw=0.5, + zorder=10, + ) + plt.grid(color="whitesmoke") + + plt.gca().tick_params(axis="x", which="minor", bottom=False) + plt.xticks(ticks=confid_indices, labels=n_confid * []) + plt.gca().tick_params(axis="y", which="minor", left=False) + plt.yticks(ticks=confid_indices, labels=n_confid * []) + plt.gca().tick_params(axis="y", which="major", left=False, right=True) + + else: + for i, (c, confid) in enumerate(zip(significance, confid_names)): + for j, s in enumerate(c): + if i == j: + continue + + if s: + ax.add_patch( + Rectangle( + # (i - 0.5, j - 0.5), + (n_confid - 1 - j - 0.5, n_confid - 1 - i - 0.5), + width=1, + height=1, + color=colors_dict[confid], + alpha=0.5, + lw=0, + fill=True, + zorder=-2, + ) + ) + else: + ax.scatter( + # [i], + # [j], + [n_confid - 1 - j], + [n_confid - 1 - i], + marker="X", + s=300, + c=colors_dict[confid], + alpha=0.5, + ) + + plt.plot( + [-0.6, n_confid - 0.4], + [-0.6, n_confid - 0.4], + color="k", + lw=0.5, + zorder=10, + ) + plt.grid(color="whitesmoke") + + plt.gca().tick_params(axis="x", which="minor", bottom=False) + plt.xticks(ticks=confid_indices, labels=n_confid * []) + plt.gca().tick_params(axis="y", which="minor", left=False) + plt.yticks(ticks=confid_indices, labels=n_confid * []) + + else: + for i, (c, confid) in enumerate(zip(significance, confid_names)): + for j, s in enumerate(c): + if i == j: + continue + + if s: + ax.add_patch( + Rectangle( + (i - 0.5, j - 0.5), + width=1, + height=1, + color=colors_dict[confid], + alpha=0.5, + lw=0, + fill=True, + zorder=-2, + ) + ) + else: + ax.scatter( + [i], + [j], + marker="X", + s=300, + c=colors_dict[confid], + alpha=0.5, + ) + + plt.plot( + [-0.6, n_confid - 0.4], [-0.6, n_confid - 0.4], color="k", lw=0.5, zorder=10 + ) + plt.grid(color="whitesmoke") + + plt.xticks( + ticks=confid_indices + 0.4, + labels=list(histograms.index), + rotation=60, + horizontalalignment="right", + verticalalignment="top", + fontsize=23, + minor=True, + ) + plt.yticks( + ticks=confid_indices + 0.25, + labels=list(histograms.index), + rotation=30, + horizontalalignment="right", + verticalalignment="top", + fontsize=23, + minor=True, + ) + + plt.gca().tick_params(axis="x", which="minor", bottom=False) + plt.xticks(ticks=confid_indices, labels=n_confid * []) + plt.gca().tick_params(axis="y", which="minor", left=False) + plt.yticks(ticks=confid_indices, labels=n_confid * []) + + plt.xlim(-0.6, n_confid - 0.4) + plt.ylim(-0.6, n_confid - 0.4) + # plt.title(filename) + plt.tight_layout() + plt.savefig(out_dir / filename) + plt.close() + + +def bs_kendall_tau_violin( + data: pd.DataFrame, + metric: str, + histograms: pd.DataFrame, + out_dir: Path, + filename: str, +) -> None: + """""" + n_confid = histograms.shape[0] + rank_values = np.arange(1, n_confid + 1) + + # Reindex columns handling the case of shared last ranks + histograms = histograms.reindex(columns=rank_values, fill_value=0) + confid_to_rank_idx = {histograms.index[i]: i for i in range(n_confid)} + + taus = [] + taus_aurc_augrc = [] + + data["rank_2"] = data.groupby( + ["bootstrap_index", "run"] if "run" in data.columns else ["bootstrap_index"] + )["aurc" if metric == "augrc" else "augrc"].rank(method="min") + + for (_, group), (_, group_2) in zip( + data.sort_values(by="rank").groupby( + "bootstrap_index" + if "run" not in data.columns + else ["bootstrap_index", "run"] + ), + data.sort_values(by="rank_2").groupby( + "bootstrap_index" + if "run" not in data.columns + else ["bootstrap_index", "run"] + ), + ): + if len(group) != n_confid: + raise ValueError( + f"Missing results for the following group (expected {n_confid} " + f"confids):\n\n{group}" + ) + + taus.append( + kendalltau( + x=np.arange(n_confid), + y=[confid_to_rank_idx[c] for c in group["confid"]], + ).statistic + ) + + taus_aurc_augrc.append( + kendalltau( + x=[confid_to_rank_idx[c] for c in group["confid"]], + y=[confid_to_rank_idx[c] for c in group_2["confid"]], + ).statistic + ) + + plt.violinplot( + dataset=taus, + positions=[1], + showextrema=False, + showmedians=False, + ) + plt.boxplot( + x=taus, + positions=[1], + ) + + plt.violinplot( + dataset=taus_aurc_augrc, + positions=[2], + showextrema=False, + showmedians=False, + ) + plt.boxplot( + x=taus_aurc_augrc, + positions=[2], + ) + + plt.grid(color="gray", lw=1.5, alpha=0.15) + plt.xticks(ticks=[1, 2], labels=[f"{metric.upper()} stability", "AUGRC vs. AURC"]) + plt.ylabel("Kendall's tau") + plt.title(filename) + plt.tight_layout() + plt.savefig(out_dir / filename) + plt.close() + + +def bs_kendall_tau_comparing_metrics( + data: dict, + histograms: dict, + out_dir: Path, + filename: str, +) -> None: + """""" + data_aurc = data["aurc"] + data_augrc = data["augrc"] + histograms_aurc = histograms["aurc"] + histograms_augrc = histograms["augrc"] + + n_confid = histograms_augrc.shape[0] + rank_values = np.arange(1, n_confid + 1) + + # Reindex columns handling the case of shared last ranks + histograms_aurc = histograms_aurc.reindex(columns=rank_values, fill_value=0) + histograms_augrc = histograms_augrc.reindex(columns=rank_values, fill_value=0) + + confid_to_rank_idx_aurc = {histograms_aurc.index[i]: i for i in range(n_confid)} + confid_to_rank_idx_augrc = {histograms_augrc.index[i]: i for i in range(n_confid)} + + taus_aurc = [] + taus_augrc = [] + taus_aurc_augrc = [] + + for (l1, group_aurc), (l2, group_augrc) in zip( + data_aurc.sort_values(by="rank").groupby( + ["bootstrap_index", "study"] + if "run" not in data_aurc.columns + else ["bootstrap_index", "run", "study"] + ), + data_augrc.sort_values(by="rank").groupby( + ["bootstrap_index", "study"] + if "run" not in data_augrc.columns + else ["bootstrap_index", "run", "study"] + ), + ): + taus_aurc.append( + kendalltau( + x=np.arange(n_confid), + y=[confid_to_rank_idx_aurc[c] for c in group_aurc["confid"]], + ).statistic + ) + taus_augrc.append( + kendalltau( + x=np.arange(n_confid), + y=[confid_to_rank_idx_augrc[c] for c in group_augrc["confid"]], + ).statistic + ) + taus_aurc_augrc.append( + kendalltau( + x=[confid_to_rank_idx_aurc[c] for c in group_aurc["confid"]], + y=[confid_to_rank_idx_augrc[c] for c in group_augrc["confid"]], + ).statistic + ) + + # AURC + plt.violinplot( + dataset=taus_aurc, + positions=[1], + showextrema=False, + showmedians=False, + ) + plt.boxplot( + x=taus_aurc, + positions=[1], + ) + # AUGRC + plt.violinplot( + dataset=taus_augrc, + positions=[2], + showextrema=False, + showmedians=False, + ) + plt.boxplot( + x=taus_augrc, + positions=[2], + ) + # Comparison + plt.violinplot( + dataset=taus_aurc_augrc, + positions=[3], + showextrema=False, + showmedians=False, + ) + plt.boxplot( + x=taus_aurc_augrc, + positions=[3], + ) + + plt.ylim(0.48, 1.01) + + plt.grid(color="gray", lw=1.5, alpha=0.15) + plt.xticks( + ticks=[1, 2, 3], labels=[f"AURC stability", "AUGRC stability", "AUGRC vs. AURC"] + ) + plt.ylabel("Kendall's tau") + plt.title(filename) + plt.tight_layout() + plt.savefig(out_dir / filename) + plt.close() diff --git a/fd_shifts/reporting/report_bootstrap.py b/fd_shifts/reporting/report_bootstrap.py new file mode 100644 index 0000000..771ce5f --- /dev/null +++ b/fd_shifts/reporting/report_bootstrap.py @@ -0,0 +1,604 @@ +import concurrent.futures +import functools +from itertools import product +from pathlib import Path + +import pandas as pd +from tqdm import tqdm + +from fd_shifts import logger +from fd_shifts.configs import Config +from fd_shifts.experiments.configs import get_experiment_config, list_experiment_configs +from fd_shifts.experiments.tracker import list_bootstrap_analysis_output_files +from fd_shifts.reporting import ( + DATASETS, + _filter_unused, + _load_file, + assign_hparams_from_names, + filter_best_hparams, + filter_best_lr, + rename_confids, + rename_studies, + tables, +) +from fd_shifts.reporting.plots_bootstrap import ( + bs_blob_plot, + bs_box_scatter_plot, + bs_kendall_tau_comparing_metrics, + bs_kendall_tau_violin, + bs_podium_plot, + bs_significance_map, + bs_significance_map_colored, +) + + +def _load_bootstrap_experiment( + name: str, + stratified_bs: bool = False, + filter_study_name: list = None, + filter_dataset: list = None, + original_new_class_mode: bool = False, +) -> pd.DataFrame | None: + from fd_shifts.main import omegaconf_resolve + + config = get_experiment_config(name) + config = omegaconf_resolve(config) + + if filter_dataset is not None and config.data.dataset not in filter_dataset: + return + + data = list( + map( + functools.partial(_load_file, config, name), + list_bootstrap_analysis_output_files( + config, stratified_bs, filter_study_name, original_new_class_mode + ), + ) + ) + + if len(data) == 0 or any(map(lambda d: d is None, data)): + return + + data = pd.concat(data) # type: ignore + data = ( + data.assign( + experiment=config.data.dataset + ("vit" if "vit" in name else ""), + run=int(name.split("run")[1].split("_")[0]), + dropout=config.model.dropout_rate, + rew=config.model.dg_reward if config.model.dg_reward is not None else 0, + lr=config.trainer.optimizer.init_args["init_args"]["lr"], + ) + .dropna(subset=["name", "model"]) + .drop_duplicates( + subset=["name", "study", "model", "network", "confid", "bootstrap_index"] + ) + ) + + return data + + +def load_all( + stratified_bs: bool = False, + filter_study_name: list = None, + filter_dataset: list = None, + original_new_class_mode: bool = False, + include_vit: bool = False, +): + dataframes = [] + # TODO: make this async + with concurrent.futures.ProcessPoolExecutor(max_workers=12) as executor: + dataframes = list( + filter( + lambda d: d is not None, + executor.map( + functools.partial( + _load_bootstrap_experiment, + stratified_bs=stratified_bs, + filter_study_name=filter_study_name, + filter_dataset=filter_dataset, + original_new_class_mode=original_new_class_mode, + ), + filter( + ( + (lambda exp: ("clip" not in exp)) + if include_vit + else lambda exp: ( + ("clip" not in exp) and (not exp.startswith("vit")) + ) + ), + list_experiment_configs(), + ), + ), + ) + ) + + data = pd.concat(dataframes) # type: ignore + data = data.loc[~data["study"].str.contains("tinyimagenet_original")] + data = data.loc[~data["study"].str.contains("tinyimagenet_proposed")] + + # data = data.query( + # 'not (experiment in ["cifar10", "cifar100", "super_cifar100"]' + # 'and not name.str.contains("vgg13"))' + # ) + + data = data.query( + 'not ((experiment.str.contains("super_cifar100")' + ")" + 'and not (study == "iid_study"))' + ) + + data = data.query( + 'not (experiment.str.contains("openset")' 'and study.str.contains("iid_study"))' + ) + + data = data.assign(study=data.experiment + "_" + data.study) + + data = data.assign( + study=data.study.mask( + data.experiment == "super_cifar100", + "cifar100_in_class_study_superclasses", + ), + experiment=data.experiment.mask( + data.experiment == "super_cifar100", "cifar100" + ), + ) + + data = data.assign( + study=data.study.mask( + data.experiment == "super_cifar100vit", + "cifar100vit_in_class_study_superclasses", + ), + experiment=data.experiment.mask( + data.experiment == "super_cifar100vit", "cifar100vit" + ), + ) + + data = data.assign(ece=data.ece.mask(data.ece < 0)) + + return data + + +def create_plots_per_study( + study: str, + dset: str, + metrics: list, + out_dir: Path, + stratified_bs: bool = False, + original_new_class_mode: bool = False, + metric_hparam_search: str = None, +): + logger.info(f"Reporting bootstrap results for dataset '{dset}', study '{study}'") + + data_raw = load_all( + stratified_bs=stratified_bs, + filter_study_name=[study], + filter_dataset=[dset], + original_new_class_mode=original_new_class_mode, + ) + + data_raw = assign_hparams_from_names(data_raw) + + for metric in metrics: + metric_to_optimize = ( + metric if metric_hparam_search is None else metric_hparam_search + ) + data, selection_df = filter_best_lr(data_raw, metric=metric_to_optimize) + selection_df.to_csv( + out_dir / f"filter_best_lr_{dset}_{metric_to_optimize}.csv", decimal="." + ) + data, selection_df = filter_best_hparams( + data, bootstrap_analysis=True, metric=metric_to_optimize + ) + selection_df.to_csv( + out_dir / f"filter_best_hparams_{dset}_{metric_to_optimize}.csv", + decimal=".", + ) + data = _filter_unused(data) + + # Filter MCD data + # data = data[~data.confid.str.contains("mcd")] + + data = rename_confids(data) + data = rename_studies(data) + + data = data[data.confid.isin(CONFIDS_TO_REPORT)] + + logger.info("Removing 'val_tuning' studies and aggregating noise studies") + data = data[~data["study"].str.contains("val_tuning")] + + if study == "noise_study": + data = ( + data.groupby(["study", "confid", "run", "bootstrap_index"]) + .mean() + .reset_index() + ) + + # First, do all plots without aggregation across runs, then aggregate + # for aggregate_runs in (False, True): + for aggregate_runs in (True,): + if aggregate_runs: + data, _ = tables.aggregate_over_runs(data, metric_columns=metrics) + group_columns = ["bootstrap_index"] + blob_dir = out_dir / "blob_run_avg" + podium_dir = out_dir / "podium_run_avg" + box_dir = out_dir / "box_run_avg" + significance_map_dir = out_dir / "significance_map_run_avg" + kendall_violin_dir = out_dir / "kendall_violin_run_avg" + else: + data = data[["confid", "study", "run", "bootstrap_index"] + metrics] + group_columns = ["bootstrap_index", "run"] + blob_dir = out_dir / "blob" + podium_dir = out_dir / "podium" + box_dir = out_dir / "box" + significance_map_dir = out_dir / "significance_map" + kendall_violin_dir = out_dir / "kendall_violin" + + blob_dir.mkdir(exist_ok=True) + podium_dir.mkdir(exist_ok=True) + box_dir.mkdir(exist_ok=True) + significance_map_dir.mkdir(exist_ok=True) + kendall_violin_dir.mkdir(exist_ok=True) + + # Compute method ranking per bootstrap sample (and run if aggregate_runs=False) + data["rank"] = data.groupby(group_columns)[metric].rank(method="min") + + # Compute ranking histogram per method + histograms = ( + data.groupby("confid")["rank"].value_counts().unstack(fill_value=0) + ) + + # Sort methods by mean rank + histograms["mean_rank"] = (histograms.columns * histograms).sum( + axis=1 + ) / histograms.sum(axis=1) + histograms["median_rank"] = ( + data.groupby("confid")["rank"].median().astype(int) + ) + # histograms = histograms.sort_values(by=["median_rank", "mean_rank"]) + histograms = histograms.sort_values(by=["mean_rank", "median_rank"]) + + medians = histograms.median_rank + histograms = histograms.drop(columns="mean_rank") + histograms = histograms.drop(columns="median_rank") + + filename = f"blob_plot_{dset}_{study}_{metric}.pdf" + bs_blob_plot( + histograms=histograms, + medians=medians, + out_dir=blob_dir, + filename=filename, + ) + + filename = f"podium_plot_{dset}_{study}_{metric}.pdf" + bs_podium_plot( + data=data, + metric=metric, + histograms=histograms, + out_dir=podium_dir, + filename=filename, + ) + + filename = f"box_plot_{dset}_{study}_{metric}.pdf" + bs_box_scatter_plot( + data=data, + metric=metric, + out_dir=box_dir, + filename=filename, + ) + + # filename = f"significance_map_{dset}_{study}_{metric}.pdf" + # bs_significance_map( + # data=data, + # metric=metric, + # histograms=histograms, + # out_dir=significance_map_dir, + # filename=filename, + # ) + + filename = f"colored_significance_map_{dset}_{study}_{metric}.pdf" + bs_significance_map_colored( + data=data, + metric=metric, + histograms=histograms, + out_dir=significance_map_dir, + filename=filename, + no_labels=False, + flip_horizontally=False, + ) + + if "aurc" in metrics and "augrc" in metrics: + filename = f"kendall_violin_{dset}_{study}_{metric}.pdf" + bs_kendall_tau_violin( + data=data, + metric=metric, + histograms=histograms, + out_dir=kendall_violin_dir, + filename=filename, + ) + + +def create_kendall_tau_plot(out_dir: Path): + logger.info(f"Performing iid-study kendall tau analysis across datasets...") + + data_raw = load_all(filter_study_name=["iid_study"]) + data_raw = assign_hparams_from_names(data_raw) + + processed_data = {} + processed_histograms = {} + + # First, do all plots without aggregation across runs, then aggregate + for aggregate_runs in (False, True): + for metric in ["aurc", "augrc"]: + data, _ = filter_best_lr(data_raw, metric=metric) + data, _ = filter_best_hparams(data, bootstrap_analysis=True, metric=metric) + data = _filter_unused(data) + data = rename_confids(data) + data = rename_studies(data) + + data = data[data.confid.isin(CONFIDS_TO_REPORT)] + + logger.info("Removing 'val_tuning' studies") + data = data[~data["study"].str.contains("val_tuning")] + + if aggregate_runs: + data, _ = tables.aggregate_over_runs( + data, metric_columns=["aurc", "augrc"] + ) + group_columns = ["bootstrap_index"] + else: + data = data[ + ["confid", "study", "run", "bootstrap_index"] + ["aurc", "augrc"] + ] + group_columns = ["bootstrap_index", "run"] + + # Compute method ranking per bootstrap sample (and run if aggregate_runs=False) + data["rank"] = data.groupby(group_columns)[metric].rank(method="min") + # Compute ranking histogram per method + histograms = ( + data.groupby("confid")["rank"].value_counts().unstack(fill_value=0) + ) + # Sort methods by mean rank + histograms["mean_rank"] = (histograms.columns * histograms).sum( + axis=1 + ) / histograms.sum(axis=1) + histograms["median_rank"] = ( + data.groupby("confid")["rank"].median().astype(int) + ) + # histograms = histograms.sort_values(by=["median_rank", "mean_rank"]) + histograms = histograms.sort_values(by=["mean_rank", "median_rank"]) + + processed_data[metric] = data + processed_histograms[metric] = histograms + + if aggregate_runs: + filename = "kendall_tau_iid_aurc_vs_augrc_run_avg.pdf" + else: + filename = "kendall_tau_iid_aurc_vs_augrc.pdf" + bs_kendall_tau_comparing_metrics( + processed_data, + processed_histograms, + out_dir, + filename, + ) + + +def ranking_change_arrows(out_dir: Path): + """""" + import matplotlib.pyplot as plt + + _DATASETS = ["wilds_animals", "wilds_camelyon", "cifar10", "breeds"] + + data_raw = load_all(filter_dataset=_DATASETS) + data_raw = assign_hparams_from_names(data_raw) + + mean_rank_dict = {} + median_rank_dict = {} + + for metric in ["aurc", "augrc"]: + data, _ = filter_best_lr(data_raw, metric=metric) + data, _ = filter_best_hparams(data, bootstrap_analysis=True, metric=metric) + data = _filter_unused(data) + data = rename_confids(data) + data = rename_studies(data) + data = data[data.confid.isin(CONFIDS_TO_REPORT)] + logger.info("Removing 'val_tuning' studies") + data = data[~data["study"].str.contains("val_tuning")] + + # Aggregate metric values over runs (should we instead rank then aggregate?) + data, _ = tables.aggregate_over_runs(data, metric_columns=["aurc", "augrc"]) + + # Aggregate noise studies + if "cifar10" in _DATASETS or "cifar100" in _DATASETS: + data["study"] = data["study"].replace( + [ + s + for s in list(data["study"].unique()) + if (s.startswith("cifar10") and "noise_study" in s) + ], + "cifar10_noise_study", + ) + data = ( + data.groupby(["study", "confid", "bootstrap_index"]) + .mean() + .reset_index() + ) + + data["rank"] = data.groupby(["bootstrap_index", "study"])[metric].rank( + method="min" + ) + mean_ranks = data.groupby(["study", "confid"])["rank"].mean() + median_ranks = data.groupby(["study", "confid"])["rank"].median() + + studies = list(data["study"].unique()) + + mean_rank_dict[metric] = mean_ranks.reset_index(level=["study"]) + median_rank_dict[metric] = median_ranks.reset_index(level=["study"]) + del data + + del data_raw + + confid_to_label = {c: f"C{i+1}" for i, c in enumerate(sorted(CONFIDS_TO_REPORT))} + n_confid = len(confid_to_label) + + for c, l in confid_to_label.items(): + print(f"{l}: {c}") + + arrow_offset = 0.01 + column_distance = 0.1 + + # DataFrame with columns: study, rank ; index: confid + mean_rank_aurc = mean_rank_dict["aurc"] + mean_rank_augrc = mean_rank_dict["augrc"] + + out_dir = out_dir / "ranking-changes" + out_dir.mkdir(exist_ok=True) + + print(f"{mean_rank_aurc = }") + + for s in studies: + try: + # Rank CSFs by average rank + ranks_aurc = mean_rank_aurc[mean_rank_aurc["study"] == s]["rank"].rank() + ranks_augrc = mean_rank_augrc[mean_rank_augrc["study"] == s]["rank"].rank() + # -> Series objects with confid index and rank values + + for confid in confid_to_label: + y1 = ranks_aurc[confid] + y2 = ranks_augrc[confid] + + if y1 != y2: + plt.arrow( + x=arrow_offset, + y=n_confid - y1, + dx=column_distance - 2 * arrow_offset, + dy=y1 - y2, + length_includes_head=True, + width=0.00015, + head_width=0.01, + head_length=0.05, + overhang=0.1, + color="tab:red", + ) + plt.text( + x=0, + y=n_confid - y1, + s=confid_to_label[confid], + horizontalalignment="right", + verticalalignment="center", + ) + plt.text( + x=column_distance, + y=n_confid - y2, + s=confid_to_label[confid], + horizontalalignment="left", + verticalalignment="center", + ) + + plt.xlim(-0.5, 0.6) + plt.ylim(-0.2, n_confid - 0.4) + plt.axis("off") + plt.savefig( + out_dir / f"bootstrap_ranking_change_arrows_{s}.pdf", + bbox_inches="tight", + ) + plt.close() + + except Exception as err: + logger.info(f"ERROR for study {s}: '{str(err)}'") + continue + + +CONFIDS_TO_REPORT = [ + "MSR", + "MLS", + "PE", + "MCD-MSR", + "MCD-PE", + "MCD-EE", + "DG-MCD-MSR", + "ConfidNet", + "DG-Res", + "Devries et al.", + "TEMP-MLS", + "DG-PE", + "DG-TEMP-MLS", +] + + +def report_bootstrap_results( + out_path: str | Path = "./output/bootstrap", + stratified_bs: bool = False, + metric_hparam_search: str = None, +): + """""" + if stratified_bs: + out_path = "./output/bootstrap-stratified" + + if metric_hparam_search is not None: + out_path = str(out_path) + f"-optimized-{metric_hparam_search}" + + data_dir: Path = Path(out_path).expanduser().resolve() + data_dir.mkdir(exist_ok=True, parents=True) + + datasets = [d for d in DATASETS if d != "super_cifar100"] + studies = ["iid_study"] + metrics = ["aurc", "augrc"] + + logger.info( + f"Reporting bootstrap results for datasets '{datasets}', studies '{studies}'" + ) + + try: + with concurrent.futures.ProcessPoolExecutor(max_workers=12) as executor: + # Submit tasks to the executor + future_to_arg = { + executor.submit( + create_plots_per_study, + study=study, + dset=dset, + metrics=metrics, + out_dir=data_dir, + stratified_bs=stratified_bs, + original_new_class_mode=False, + metric_hparam_search=metric_hparam_search, + ): dict(study=study, dset=dset) + for dset, study in product(datasets, studies) + } + # future_to_arg = {} + + # future_to_arg[ + # executor.submit(ranking_change_arrows, out_dir=data_dir) + # ] = "" + + # if "aurc" in metrics and "augrc" in metrics: + # future_to_arg[ + # executor.submit(create_kendall_tau_plot, out_dir=data_dir) + # ] = dict(study="iid_study", dset=datasets) + + try: + for future in tqdm( + concurrent.futures.as_completed(future_to_arg), + total=len(future_to_arg), + ): + arg = future_to_arg[future] + # Get the result from the future (this will raise an exception if the + # function call raised an exception) + future.result() + except Exception as exc: + # Handle the exception + print(f"Function call with argument {arg} raised an exception: {exc}") + # Raise an error or take appropriate action + raise RuntimeError("One or more executor failed") from exc + finally: + # Ensure executor and associated processes are properly terminated + executor.shutdown() + + except KeyboardInterrupt: + logger.info("Keyboard interrupt received. Shutting down gracefully...") + executor.shutdown(wait=False, cancel_futures=True) + logger.info( + "Executor shut down. Kill running futures using\n" + "'ps -ef | grep 'main.py report_bootstrap' | grep -v grep | awk '{print $2}' | " + "xargs -r kill -9'" + ) + raise diff --git a/fd_shifts/reporting/tables.py b/fd_shifts/reporting/tables.py index 9812147..346a08c 100644 --- a/fd_shifts/reporting/tables.py +++ b/fd_shifts/reporting/tables.py @@ -82,28 +82,64 @@ """ -def aggregate_over_runs(data: pd.DataFrame) -> pd.DataFrame: +def aggregate_over_runs(data: pd.DataFrame, metric_columns: list[str]) -> pd.DataFrame: """Compute means over equivalent runs Args: data (pd.DataFrame): experiment data + metric_columns (list[str]): metrics to keep & aggregate Returns: aggregated experiment data """ logger.info("Aggregating over runs") fixed_columns = ["study", "confid"] - metrics_columns = ["accuracy", "aurc", "ece", "failauc", "fail-NLL"] + if "bootstrap_index" in data.columns: + fixed_columns.append("bootstrap_index") mean = ( - data[fixed_columns + metrics_columns] + data[fixed_columns + metric_columns] .groupby(by=fixed_columns) .mean() .sort_values("confid") .reset_index() ) std = ( - data[fixed_columns + metrics_columns] + data[fixed_columns + metric_columns] + .groupby(by=fixed_columns) + .std() + .sort_values("confid") + .reset_index() + ) + return mean, std + + +def aggregate_over_bootstrap_index( + data: pd.DataFrame, metric_columns: list[str] +) -> pd.DataFrame: + """Compute means over bootstrap_index + + Args: + data (pd.DataFrame): experiment data + metric_columns (list[str]): metrics to keep & aggregate + + Returns: + aggregated experiment data + """ + logger.info("Aggregating over boostrap_index") + fixed_columns = ["study", "confid"] + if "run" in data.columns: + fixed_columns.append("run") + + mean = ( + data[fixed_columns + metric_columns] + .groupby(by=fixed_columns) + .mean() + .sort_values("confid") + .reset_index() + ) + std = ( + data[fixed_columns + metric_columns] .groupby(by=fixed_columns) .std() .sort_values("confid") @@ -515,8 +551,11 @@ def paper_results( ltex[2] = ltex[2][: ltex[2].rfind("?")] + ltex[2][ltex[2].rfind("?") + 1 :] # Insert empty row before ViT part - i = ltex.index(next((x for x in ltex if "ViT" in x))) - ltex.insert(i, "\\midrule \\\\") + try: + i = ltex.index(next((x for x in ltex if "ViT" in x))) + ltex.insert(i, "\\midrule \\\\") + except StopIteration: + logger.info("No ViT experiment found in table") ltex = "\n".join(ltex) @@ -546,26 +585,43 @@ def paper_results( ) -def rank_comparison_metric(data: pd.DataFrame, out_dir: Path): +def rank_comparison_metric( + data: pd.DataFrame, + out_dir: Path, + metric1: str = "aurc", + metric2: str = "failauc", + metric1_higherbetter: bool = False, + metric2_higherbetter: bool = True, + data2: pd.DataFrame = None, +): """Create colored results table in tex format to compare ranking between metrics Args: data (pd.DataFrame): cleaned up experiment data out_dir (Path): where to save the output to + metric1 (str, optional): Metric 1. Defaults to "aurc". + metric2 (str, optional): Metric 2. Defaults to "failauc". + metric1_higherbetter (bool, optional): Defaults to False. + metric2_higherbetter (bool, optional): Defaults to True. """ - aurc_table = build_results_table(data, "aurc") - aurc_table = _add_rank_columns(aurc_table) - aurc_table.columns = pd.MultiIndex.from_tuples( - map(lambda t: t + (r"$\alpha$",), aurc_table.columns) + metric1_table = build_results_table(data, metric1) + metric1_table = _add_rank_columns(metric1_table, ascending=not metric1_higherbetter) + metric1_table.columns = pd.MultiIndex.from_tuples( + map(lambda t: t + (r"$\alpha$",), metric1_table.columns) ) - failauc_table = build_results_table(data, "failauc") - failauc_table = _add_rank_columns(failauc_table, False) - failauc_table.columns = pd.MultiIndex.from_tuples( - map(lambda t: t + (r"$\beta$",), failauc_table.columns) + if data2 is not None: + metric2_table = build_results_table(data2, metric2) + else: + logger.info(f"Using the same data (and hparam selection) for metric {metric2}") + metric2_table = build_results_table(data, metric2) + + metric2_table = _add_rank_columns(metric2_table, ascending=not metric2_higherbetter) + metric2_table.columns = pd.MultiIndex.from_tuples( + map(lambda t: t + (r"$\beta$",), metric2_table.columns) ) - results_table = pd.concat((aurc_table, failauc_table), axis=1) + results_table = pd.concat((metric1_table, metric2_table), axis=1) results_table = _reorder_studies(results_table, add_level=[r"$\alpha$", r"$\beta$"]) _formatter = lambda x: f"{int(x):>3d}" @@ -581,15 +637,19 @@ def rank_comparison_metric(data: pd.DataFrame, out_dir: Path): lambda val: round(val, 2) if val < 10 else round(val, 1) ) - gmap_vit = _compute_gmap( - results_table.loc[ - results_table.index[ - results_table.index.get_level_values(1).str.contains("ViT") + if results_table.index.get_level_values(1).str.contains("ViT").any(): + gmap_vit = _compute_gmap( + results_table.loc[ + results_table.index[ + results_table.index.get_level_values(1).str.contains("ViT") + ], + results_table.columns, ], - results_table.columns, - ], - True, - ) + True, + ) + else: + gmap_vit = [] + gmap_cnn = _compute_gmap( results_table.loc[ results_table.index[ @@ -662,31 +722,41 @@ def rank_comparison_metric(data: pd.DataFrame, out_dir: Path): ltex[3] = ltex[3][: ltex[3].rfind("?")] + ltex[3][ltex[3].rfind("?") + 1 :] # Insert empty row before ViT part - i = ltex.index(next((x for x in ltex if "ViT" in x))) - ltex.insert(i, "\\midrule \\\\") + try: + i = ltex.index(next((x for x in ltex if "ViT" in x))) + ltex.insert(i, "\\midrule \\\\") + except StopIteration: + logger.info("No ViT experiment found in table") ltex = "\n".join(ltex) - with open(out_dir / f"rank_metric_comparison.tex", "w") as f: + if data2 is None: + filename = f"rank_metric_comparison_{metric1}_to_{metric2}" + else: + filename = f"rank_metric_comparison_{metric1}_to_{metric2}_optimized_both" + + print(f"{filename = }") + + with open(out_dir / f"{filename}.tex", "w") as f: f.write(ltex) with tempfile.TemporaryDirectory() as tmpdir: tmpdir = Path(tmpdir) shutil.copy2( - out_dir / f"rank_metric_comparison.tex", - tmpdir / f"rank_metric_comparison.tex", + out_dir / f"{filename}.tex", + tmpdir / f"{filename}.tex", ) with open(tmpdir / "render.tex", "w") as f: f.write( LATEX_TABLE_TEMPLATE_LANDSCAPE.replace( - "{input_file}", f"rank_metric_comparison.tex" - ).replace("{metric}", "") + "{input_file}", f"{filename}.tex" + ).replace("{metric}", f"{metric1}/{metric2}") ) subprocess.run(f"lualatex render.tex", shell=True, check=True, cwd=tmpdir) shutil.copy2( tmpdir / "render.pdf", - out_dir / f"rank_metric_comparison.pdf", + out_dir / f"{filename}.pdf", ) @@ -817,8 +887,11 @@ def rank_comparison_mode(data: pd.DataFrame, out_dir: Path, rank: bool = True): ltex[3] = ltex[3][: ltex[3].rfind("?")] + ltex[3][ltex[3].rfind("?") + 1 :] # Insert empty row before ViT part - i = ltex.index(next((x for x in ltex if "ViT" in x))) - ltex.insert(i, "\\midrule \\\\") + try: + i = ltex.index(next((x for x in ltex if "ViT" in x))) + ltex.insert(i, "\\midrule \\\\") + except StopIteration: + logger.info("No ViT experiment found in table") ltex = "\n".join(ltex) diff --git a/pyproject.toml b/pyproject.toml index c3ee165..56cd45f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -24,6 +24,7 @@ dependencies = [ "omegaconf>=2.1.1", "open_clip_torch", "opencv-python-headless", + "pandarallel>=1.6.5", "pandas>=1.2.3", "Pillow==9.5.0", "protobuf<=3.20.0", From 9a5b37725388d2d80bec2883e6a8f51e6cb05f16 Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Wed, 5 Jun 2024 15:49:20 +0200 Subject: [PATCH 115/136] fix merge resolve --- fd_shifts/reporting/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fd_shifts/reporting/__init__.py b/fd_shifts/reporting/__init__.py index e90c4d2..6e9b423 100644 --- a/fd_shifts/reporting/__init__.py +++ b/fd_shifts/reporting/__init__.py @@ -37,7 +37,7 @@ def __find_in_store(config: Config, file: str) -> Path | None: def _load_file(config: Config, name: str, file: str): - if f := _find_in_store(config, file): + if f := __find_in_store(config, file): return pd.read_csv(f) else: logger.error(f"Could not find {name}: {file} in store") From afa1fdf0e5f5ee5f29cca0502e4750dd943d6a3b Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Mon, 10 Jun 2024 11:58:43 +0200 Subject: [PATCH 116/136] Add tests --- fd_shifts/analysis/rc_stats.py | 45 ++-- fd_shifts/loaders/data_loader.py | 4 + fd_shifts/tests/pytest.ini | 3 +- fd_shifts/tests/test_analysis.py | 369 ++++++++++++++++++++++----- fd_shifts/tests/utils.py | 423 +++++++++++++++++++++++++++++++ 5 files changed, 760 insertions(+), 84 deletions(-) diff --git a/fd_shifts/analysis/rc_stats.py b/fd_shifts/analysis/rc_stats.py index 4e2148c..1238436 100644 --- a/fd_shifts/analysis/rc_stats.py +++ b/fd_shifts/analysis/rc_stats.py @@ -142,7 +142,9 @@ def aurc(self) -> float: @cached_property def aurc_achievable(self) -> float: """Achievable area under Risk Coverage Curve""" - return self.evaluate_auc(risk="selective-risk", achievable=True) + return self.evaluate_auc( + risk="selective-risk", achievable=True, interpolation="non-linear" + ) @cached_property def eaurc(self) -> float: @@ -198,11 +200,12 @@ def augrc_ba_ci_bs(self) -> Tuple[float, float]: def dominant_point_mask(self) -> list[bool]: """Boolean array masking the dominant RC-points""" if self.is_binary and not self.contains_nan: + num_rc_points = len(self.coverages) + if sum(self.residuals) in (0, self.n): # If the predictions are all correct or all wrong, the RC-Curve is a # horizontal line, and thus there is one dominant point at cov=1. indices = np.array([-1]) - num_rc_points = len(self.coverages) else: # Compute the convex hull in ROC-space, as the dominant points are the # same in RC-space. Inspired by @@ -210,11 +213,9 @@ def dominant_point_mask(self) -> list[bool]: fpr, tpr, _ = metrics.roc_curve( 1 - self.residuals, self.confids, drop_intermediate=False ) - num_rc_points = len(fpr) - 1 - - if num_rc_points == 1: + if num_rc_points == 2: # If there is only one point, the convex hull is trivial - return np.array([True]) + return np.array([True, False]) else: # Add the (2, -1) point to make the convex hull construction easier. fpr = np.concatenate((fpr, [2.0])) @@ -222,8 +223,8 @@ def dominant_point_mask(self) -> list[bool]: hull = ConvexHull( np.concatenate((fpr.reshape(-1, 1), tpr.reshape(-1, 1)), axis=1) ) - indices = hull.vertices - 1 - indices = indices[(indices != -1) & (indices != num_rc_points)] + indices = hull.vertices + indices = indices[(indices != 0) & (indices != num_rc_points)] mask = np.zeros(num_rc_points, dtype=bool) mask[indices] = True @@ -232,8 +233,10 @@ def dominant_point_mask(self) -> list[bool]: # NOTE: For non-binary residuals, finding the subset of RC-points that minimizes # the AURC is not straightforward. - # Don't mask any points in this case (for now). - return np.ones(len(self.coverages), dtype=bool) + # Don't mask any points in this case (only cov=0). + mask = np.ones(len(self.coverages), dtype=bool) + mask[-1] = 0 + return mask @cached_property def aurc_optimal(self) -> float: @@ -412,27 +415,33 @@ def evaluate_auc( if cov_max <= cov_min or cov_max <= 0 or cov_min >= 1: return 0.0 + assert (coverages is None) == (risks is None) + if coverages is None: + curve_stats = self.get_curve_stats(risk=risk) + coverages = curve_stats["coverages"] + risks = curve_stats["risks"] + if achievable: if interpolation == "linear" and "generalized" not in risk: logging.warning( "Achievable AURC values should be estimated with 'non-linear' " f"interpolation. Currvently using: '{interpolation}' interpolation" ) + risks = risks[self.dominant_point_mask] coverages = coverages[self.dominant_point_mask] - assert (coverages is None) == (risks is None) - if coverages is None: - curve_stats = self.get_curve_stats(risk=risk) - coverages = curve_stats["coverages"] - risks = curve_stats["risks"] - if interpolation == "linear" or "generalized" in risk: # Linear interpolation if cov_max != 1 or cov_min != 0: raise NotImplementedError() return -np.trapz(risks, coverages) * self.AUC_DISPLAY_SCALE + # Removing the cov=0 point, this curve segment is handled separately + if coverages[-1] == 0: + coverages = coverages[:-1] + risks = risks[:-1] + # Non-linear interpolation for selective-risk-based AUC # Prepare the AURC evaluation for a certain coverage range n = self.n @@ -440,8 +449,8 @@ def evaluate_auc( error_sum_below = 0 lower_lim = 0 cov_above = None - error_sum_above = None - upper_lim = None + error_sum_above = 1 + upper_lim = 1 if cov_min > 0: idx_range = np.argwhere(coverages >= cov_min)[:, 0] diff --git a/fd_shifts/loaders/data_loader.py b/fd_shifts/loaders/data_loader.py index eea523e..58bb9e1 100644 --- a/fd_shifts/loaders/data_loader.py +++ b/fd_shifts/loaders/data_loader.py @@ -177,6 +177,9 @@ def setup(self, stage=None): kwargs=self.dataset_kwargs, ) + logger.info(f"{self.train_dataset = }") + logger.info(f"{self.iid_test_set = }") + if self.test_iid_split == "tenPercent": length_test = len(self.iid_test_set) split = int(length_test * 0.1) @@ -309,6 +312,7 @@ def setup(self, stage=None): train_idx = [] self.val_sampler = None self.train_sampler = None + if self.balanced_sampeling: # do class balanced sampeling val_idx = [] diff --git a/fd_shifts/tests/pytest.ini b/fd_shifts/tests/pytest.ini index ca71cf0..fde10d1 100644 --- a/fd_shifts/tests/pytest.ini +++ b/fd_shifts/tests/pytest.ini @@ -1,3 +1,4 @@ [pytest] markers = - baurc: selects all tests for this metric \ No newline at end of file + baurc: selects all tests for this metric + legacy: selects all tests for the legacy version of AURC and derived metrics diff --git a/fd_shifts/tests/test_analysis.py b/fd_shifts/tests/test_analysis.py index 06f81e2..4c10f5c 100644 --- a/fd_shifts/tests/test_analysis.py +++ b/fd_shifts/tests/test_analysis.py @@ -3,8 +3,16 @@ import numpy as np import numpy.typing as npt import pytest +from sklearn.metrics import roc_auc_score from fd_shifts.analysis import metrics +from fd_shifts.analysis.rc_stats import RiskCoverageStatsMixin +from fd_shifts.tests.utils import ( + RC_STATS_CLASS_AWARE_TEST_CASES, + RC_STATS_TEST_CASES, + SC_scale1000_test, + SC_test, +) ArrayType = npt.NDArray[np.floating] ExpectedType = float | ArrayType | type[BaseException] @@ -32,74 +40,58 @@ stats_caches = { "all_correct": { - "all_confid": metrics.StatsCache(all_confid, all_correct, N_BINS), - "some_confid": metrics.StatsCache(some_confid, all_correct, N_BINS), - "some_confid_inv": metrics.StatsCache(some_confid_inv, all_correct, N_BINS), - "med_confid": metrics.StatsCache(med_confid, all_correct, N_BINS), - "none_confid": metrics.StatsCache(none_confid, all_correct, N_BINS), - "unnormalized_confid": metrics.StatsCache( - unnormalized_confid, all_correct, N_BINS - ), - "all_nan_confid": metrics.StatsCache(all_nan, all_correct, N_BINS), - "some_nan_confid": metrics.StatsCache(some_nan_confid, all_correct, N_BINS), + "all_confid": SC_scale1000_test(all_confid, all_correct), + "some_confid": SC_scale1000_test(some_confid, all_correct), + "some_confid_inv": SC_scale1000_test(some_confid_inv, all_correct), + "med_confid": SC_scale1000_test(med_confid, all_correct), + "none_confid": SC_scale1000_test(none_confid, all_correct), + "unnormalized_confid": SC_scale1000_test(unnormalized_confid, all_correct), + "all_nan_confid": SC_scale1000_test(all_nan, all_correct), + "some_nan_confid": SC_scale1000_test(some_nan_confid, all_correct), }, "some_correct": { - "all_confid": metrics.StatsCache(all_confid, some_correct, N_BINS), - "some_confid": metrics.StatsCache(some_confid, some_correct, N_BINS), - "some_confid_inv": metrics.StatsCache(some_confid_inv, some_correct, N_BINS), - "med_confid": metrics.StatsCache(med_confid, some_correct, N_BINS), - "none_confid": metrics.StatsCache(none_confid, some_correct, N_BINS), - "unnormalized_confid": metrics.StatsCache( - unnormalized_confid, some_correct, N_BINS - ), - "all_nan_confid": metrics.StatsCache(all_nan, some_correct, N_BINS), - "some_nan_confid": metrics.StatsCache(some_nan_confid, some_correct, N_BINS), + "all_confid": SC_scale1000_test(all_confid, some_correct), + "some_confid": SC_scale1000_test(some_confid, some_correct), + "some_confid_inv": SC_scale1000_test(some_confid_inv, some_correct), + "med_confid": SC_scale1000_test(med_confid, some_correct), + "none_confid": SC_scale1000_test(none_confid, some_correct), + "unnormalized_confid": SC_scale1000_test(unnormalized_confid, some_correct), + "all_nan_confid": SC_scale1000_test(all_nan, some_correct), + "some_nan_confid": SC_scale1000_test(some_nan_confid, some_correct), }, "none_correct": { - "all_confid": metrics.StatsCache(all_confid, none_correct, N_BINS), - "some_confid": metrics.StatsCache(some_confid, none_correct, N_BINS), - "some_confid_inv": metrics.StatsCache(some_confid_inv, none_correct, N_BINS), - "med_confid": metrics.StatsCache(med_confid, none_correct, N_BINS), - "none_confid": metrics.StatsCache(none_confid, none_correct, N_BINS), - "unnormalized_confid": metrics.StatsCache( - unnormalized_confid, none_correct, N_BINS - ), - "all_nan_confid": metrics.StatsCache(all_nan, none_correct, N_BINS), - "some_nan_confid": metrics.StatsCache(some_nan_confid, none_correct, N_BINS), + "all_confid": SC_scale1000_test(all_confid, none_correct), + "some_confid": SC_scale1000_test(some_confid, none_correct), + "some_confid_inv": SC_scale1000_test(some_confid_inv, none_correct), + "med_confid": SC_scale1000_test(med_confid, none_correct), + "none_confid": SC_scale1000_test(none_confid, none_correct), + "unnormalized_confid": SC_scale1000_test(unnormalized_confid, none_correct), + "all_nan_confid": SC_scale1000_test(all_nan, none_correct), + "some_nan_confid": SC_scale1000_test(some_nan_confid, none_correct), }, "all_nan_correct": { - "all_confid": metrics.StatsCache(all_confid, all_nan, N_BINS), - "some_confid": metrics.StatsCache(some_confid, all_nan, N_BINS), - "some_confid_inv": metrics.StatsCache(some_confid_inv, all_nan, N_BINS), - "med_confid": metrics.StatsCache(med_confid, all_nan, N_BINS), - "none_confid": metrics.StatsCache(none_confid, all_nan, N_BINS), - "unnormalized_confid": metrics.StatsCache(unnormalized_confid, all_nan, N_BINS), - "all_nan_confid": metrics.StatsCache(all_nan, all_nan, N_BINS), - "some_nan_confid": metrics.StatsCache(some_nan_confid, all_nan, N_BINS), + "all_confid": SC_scale1000_test(all_confid, all_nan), + "some_confid": SC_scale1000_test(some_confid, all_nan), + "some_confid_inv": SC_scale1000_test(some_confid_inv, all_nan), + "med_confid": SC_scale1000_test(med_confid, all_nan), + "none_confid": SC_scale1000_test(none_confid, all_nan), + "unnormalized_confid": SC_scale1000_test(unnormalized_confid, all_nan), + "all_nan_confid": SC_scale1000_test(all_nan, all_nan), + "some_nan_confid": SC_scale1000_test(some_nan_confid, all_nan), }, "some_nan_correct": { - "all_confid": metrics.StatsCache(all_confid, some_nan_correct, N_BINS), - "some_confid": metrics.StatsCache(some_confid, some_nan_correct, N_BINS), - "some_confid_inv": metrics.StatsCache( - some_confid_inv, some_nan_correct, N_BINS - ), - "med_confid": metrics.StatsCache(med_confid, some_nan_correct, N_BINS), - "none_confid": metrics.StatsCache(none_confid, some_nan_correct, N_BINS), - "unnormalized_confid": metrics.StatsCache( - unnormalized_confid, some_nan_correct, N_BINS - ), - "all_nan_confid": metrics.StatsCache(all_nan, some_nan_correct, N_BINS), - "some_nan_confid": metrics.StatsCache( - some_nan_confid, some_nan_correct, N_BINS - ), + "all_confid": SC_scale1000_test(all_confid, some_nan_correct), + "some_confid": SC_scale1000_test(some_confid, some_nan_correct), + "some_confid_inv": SC_scale1000_test(some_confid_inv, some_nan_correct), + "med_confid": SC_scale1000_test(med_confid, some_nan_correct), + "none_confid": SC_scale1000_test(none_confid, some_nan_correct), + "unnormalized_confid": SC_scale1000_test(unnormalized_confid, some_nan_correct), + "all_nan_confid": SC_scale1000_test(all_nan, some_nan_correct), + "some_nan_confid": SC_scale1000_test(some_nan_confid, some_nan_correct), }, } -def test_stats_cache(): - pass - - @pytest.mark.parametrize( ("stats_cache", "expected"), [ @@ -145,7 +137,7 @@ def test_stats_cache(): (stats_caches["some_nan_correct"]["some_nan_confid"], np.nan), ], ) -def test_failauc(stats_cache: metrics.StatsCache, expected: ExpectedType): +def test_failauc(stats_cache: SC_scale1000_test, expected: ExpectedType): if isinstance(expected, type): with pytest.raises(expected): metrics.failauc(stats_cache) @@ -201,7 +193,7 @@ def test_failauc(stats_cache: metrics.StatsCache, expected: ExpectedType): (stats_caches["some_nan_correct"]["some_nan_confid"], np.nan), ], ) -def test_fpr_at_95_tpr(stats_cache: metrics.StatsCache, expected: ExpectedType): +def test_fpr_at_95_tpr(stats_cache: SC_scale1000_test, expected: ExpectedType): if isinstance(expected, type): with pytest.raises(expected): metrics.fpr_at_95_tpr(stats_cache) @@ -257,7 +249,7 @@ def test_fpr_at_95_tpr(stats_cache: metrics.StatsCache, expected: ExpectedType): (stats_caches["some_nan_correct"]["some_nan_confid"], np.nan), ], ) -def test_failap_suc(stats_cache: metrics.StatsCache, expected: ExpectedType): +def test_failap_suc(stats_cache: SC_scale1000_test, expected: ExpectedType): if isinstance(expected, type): with pytest.raises(expected): metrics.failap_suc(stats_cache) @@ -313,7 +305,7 @@ def test_failap_suc(stats_cache: metrics.StatsCache, expected: ExpectedType): (stats_caches["some_nan_correct"]["some_nan_confid"], np.nan), ], ) -def test_failap_err(stats_cache: metrics.StatsCache, expected: ExpectedType): +def test_failap_err(stats_cache: SC_scale1000_test, expected: ExpectedType): if isinstance(expected, type): with pytest.raises(expected): metrics.failap_err(stats_cache) @@ -324,6 +316,7 @@ def test_failap_err(stats_cache: metrics.StatsCache, expected: ExpectedType): np.testing.assert_almost_equal(score, expected) +@pytest.mark.legacy @pytest.mark.parametrize( ("stats_cache", "expected"), [ @@ -363,7 +356,9 @@ def test_failap_err(stats_cache: metrics.StatsCache, expected: ExpectedType): (stats_caches["some_nan_correct"]["some_nan_confid"], np.nan), ], ) -def test_aurc(stats_cache: metrics.StatsCache, expected: ExpectedType): +def test_aurc(stats_cache: SC_scale1000_test, expected: ExpectedType): + stats_cache.legacy = True + if isinstance(expected, type): with pytest.raises(expected): metrics.aurc(stats_cache) @@ -374,6 +369,7 @@ def test_aurc(stats_cache: metrics.StatsCache, expected: ExpectedType): np.testing.assert_almost_equal(score, expected) +@pytest.mark.legacy @pytest.mark.parametrize( ("stats_cache", "expected"), [ @@ -419,7 +415,9 @@ def test_aurc(stats_cache: metrics.StatsCache, expected: ExpectedType): (stats_caches["some_nan_correct"]["some_nan_confid"], np.nan), ], ) -def test_eaurc(stats_cache: metrics.StatsCache, expected: ExpectedType): +def test_eaurc(stats_cache: SC_scale1000_test, expected: ExpectedType): + stats_cache.legacy = True + if isinstance(expected, type): with pytest.raises(expected): metrics.eaurc(stats_cache) @@ -476,7 +474,7 @@ def test_eaurc(stats_cache: metrics.StatsCache, expected: ExpectedType): ], ) def test_maximum_calibration_error( - stats_cache: metrics.StatsCache, expected: ExpectedType + stats_cache: SC_scale1000_test, expected: ExpectedType ): if isinstance(expected, type): with pytest.raises(expected): @@ -528,7 +526,7 @@ def test_maximum_calibration_error( ], ) def test_expected_calibration_error( - stats_cache: metrics.StatsCache, expected: ExpectedType + stats_cache: SC_scale1000_test, expected: ExpectedType ): """See reference https://github.com/tensorflow/probability/blob/v0.16.0/tensorflow_probability/python/stats/calibration.py#L258-L319 @@ -588,7 +586,7 @@ def test_expected_calibration_error( (stats_caches["some_nan_correct"]["some_nan_confid"], np.nan), ], ) -def test_failnll(stats_cache: metrics.StatsCache, expected: ExpectedType): +def test_failnll(stats_cache: SC_scale1000_test, expected: ExpectedType): if isinstance(expected, type): with pytest.raises(expected): metrics.failnll(stats_cache) @@ -597,3 +595,244 @@ def test_failnll(stats_cache: metrics.StatsCache, expected: ExpectedType): score = metrics.failnll(stats_cache) np.testing.assert_almost_equal(score, expected) + + +def test_caching(): + """Test property caching""" + stats_cache = SC_test(confids=np.ones(3), correct=np.linspace(0, 1, 3)) + np.testing.assert_almost_equal(stats_cache.aurc, 0.5) + np.testing.assert_equal(stats_cache.dominant_point_mask, [True, False]) + # Corrupt underlying data, properties should still be cached + stats_cache.correct = None + np.testing.assert_almost_equal(stats_cache.aurc, 0.5) + np.testing.assert_equal(stats_cache.dominant_point_mask, [True, False]) + + +def test_rcs_validation(): + """Test RiskCoverageStats data validation""" + + class MissingCorrect(RiskCoverageStatsMixin): + def __init__(self, confids): + super().__init__() + self.confids = confids + + class MissingConfids(RiskCoverageStatsMixin): + def __init__(self, residuals): + super().__init__() + self.residuals = residuals + + with pytest.raises(AssertionError, match="Missing class member 'residuals'"): + MissingCorrect(confids=np.ones(3))._validate() + with pytest.raises(AssertionError, match="Missing class member 'confids'"): + MissingConfids(residuals=np.ones(3))._validate() + + stats_cache = SC_test(confids=np.ones(3), correct=np.ones(3) * 2) + with pytest.raises( + ValueError, match="Must provide either target_risk or target_cov value" + ): + stats_cache.get_working_point(risk="selective-risk") + with pytest.raises(ValueError, match="arguments are mutually exclusive"): + stats_cache.get_working_point( + risk="selective-risk", target_risk=0.0, target_cov=0.0 + ) + + +@pytest.mark.parametrize( + ("stats_cache", "expected"), + [(stats_cache, exp) for stats_cache, exp in RC_STATS_TEST_CASES.items()], + # ID for identifying failing test cases + ids=[exp["ID"] for exp in RC_STATS_TEST_CASES.values()], +) +def test_class_agnostic_metric_values(stats_cache: SC_test, expected: dict): + """""" + if stats_cache.contains_nan: + assert np.isnan(stats_cache.aurc) + assert np.isnan(stats_cache.eaurc) + assert np.isnan(stats_cache.aurc_achievable) + assert np.isnan(stats_cache.eaurc_achievable) + assert np.isnan(stats_cache.augrc) + assert np.isnan(stats_cache.aurc_ba) + assert np.isnan(stats_cache.augrc_ba) + assert all( + np.isnan( + stats_cache.get_working_point(risk="selective-risk", target_cov=0.5) + ) + ) + + else: + # Now, compare to explicit result values + np.testing.assert_almost_equal(stats_cache.aurc, expected["aurc"]) + np.testing.assert_almost_equal(stats_cache.eaurc, expected["eaurc"]) + # TODO + np.testing.assert_almost_equal( + stats_cache.aurc_achievable, expected["aurc_achievable"] + ) + np.testing.assert_almost_equal( + stats_cache.eaurc_achievable, expected["eaurc_achievable"] + ) + np.testing.assert_almost_equal( + stats_cache.get_working_point(risk="selective-risk", target_cov=0.5), + expected["selective-risk@50cov"], + ) + np.testing.assert_almost_equal( + stats_cache.get_working_point(risk="selective-risk", target_cov=0.95), + expected["selective-risk@95cov"], + ) + np.testing.assert_almost_equal(stats_cache.augrc, expected["augrc"]) + + # For binary residuals, test that AUGRC matches the theoretical result based on + # failure-AUROC and accuracy + if stats_cache.is_binary: + acc = np.mean(stats_cache.correct) + if acc == 1 or acc == 0: + auroc = 1 + else: + auroc = roc_auc_score(stats_cache.correct, stats_cache.confids) + np.testing.assert_almost_equal( + stats_cache.augrc, (1 - auroc) * acc * (1 - acc) + 0.5 * (1 - acc) ** 2 + ) + + +@pytest.mark.parametrize( + ("stats_cache", "expected"), + [ + (stats_cache, exp) + for stats_cache, exp in RC_STATS_CLASS_AWARE_TEST_CASES.items() + ], + # ID for identifying failing test cases + ids=[exp["ID"] for exp in RC_STATS_CLASS_AWARE_TEST_CASES.values()], +) +def test_class_aware_metric_values(stats_cache: SC_test, expected: dict): + """""" + if stats_cache.contains_nan: + assert np.isnan(stats_cache.aurc_ba) + assert np.isnan(stats_cache.augrc_ba) + assert all( + np.isnan( + stats_cache.get_working_point( + risk="generalized-risk-ba", target_cov=0.5 + ) + ) + ) + + else: + # Now, compare to explicit result values + np.testing.assert_almost_equal(stats_cache.aurc_ba, expected["aurc_ba"]) + np.testing.assert_almost_equal(stats_cache.augrc_ba, expected["augrc_ba"]) + np.testing.assert_almost_equal( + stats_cache.get_working_point(risk="generalized-risk-ba", target_cov=0.95), + expected["generalized-risk-ba@95cov"], + ) + + +def test_achievable_rc(): + """Test toy examples for achievable AURC, e-AURC, and dominant point masks""" + confids = np.array([0.0, 0.0, 0.2, 0.4, 0.6, 0.8]) + correct = np.array([1, 0, 1, 0, 1, 1]) + rcs = SC_test(confids, correct) + assert len(rcs.coverages) == 6 + np.testing.assert_equal(rcs.thresholds, [0.0, 0.2, 0.4, 0.6, 0.8]) + np.testing.assert_equal( + rcs.dominant_point_mask, [True, False, False, True, False, False] + ) + assert rcs.aurc_achievable < rcs.aurc + assert rcs.eaurc_achievable < rcs.eaurc + + confids = np.repeat([0.2, 0.4, 0.6, 0.8], 25) + correct = np.clip(np.linspace(-1, 1, 100), 0, 1) + rcs = SC_test(confids=confids, correct=correct) + np.testing.assert_almost_equal( + rcs.evaluate_auc(risk="selective-risk", interpolation="non-linear") + - rcs.aurc_optimal, + rcs.eaurc_achievable, + ) + + +def test_aurc_coverage_range(): + """Test AURC evaluation over a certain coverage range""" + from itertools import product + + # Most simple case: Equal confidences + rcs = SC_test(confids=np.ones(4), correct=np.array([0, 1, 1, 1])) + np.testing.assert_almost_equal(rcs.aurc, 0.25) + + for lower, upper in product((0.0, 0.3, 0.6, 1.0), (0.4, 0.7, 1.0)): + np.testing.assert_almost_equal( + rcs.evaluate_auc( + risk="selective-risk", + cov_min=lower, + cov_max=upper, + interpolation="non-linear", + ), + rcs.aurc * max((upper - lower), 0.0), + ) + + # Stratified confidences + rcs = SC_test(confids=np.linspace(0, 1, 5), correct=np.array([0, 0, 1, 1, 1])) + for lower in np.linspace(0.0, 0.6, 10): + np.testing.assert_almost_equal( + rcs.evaluate_auc( + risk="selective-risk", + cov_min=lower, + interpolation="non-linear", + ), + rcs.evaluate_auc( + risk="selective-risk", + interpolation="non-linear", + ), + ) + + # assert that segments add up to complete AURC + np.testing.assert_almost_equal( + sum( + [ + rcs.evaluate_auc( + risk="selective-risk", + cov_min=lower, + cov_max=upper, + interpolation="non-linear", + ) + for lower, upper in zip(rcs.coverages[1:], rcs.coverages[:-1]) + ] + + [ + rcs.evaluate_auc( + risk="selective-risk", + cov_max=rcs.coverages[-1], + interpolation="non-linear", + ) + ] + ), + rcs.evaluate_auc( + risk="selective-risk", + interpolation="non-linear", + ), + ) + + # Same test for random and more segments + rcs = SC_test( + confids=np.random.random(size=100), correct=np.random.random(size=100) + ) + np.testing.assert_almost_equal( + sum( + [ + rcs.evaluate_auc( + risk="selective-risk", + cov_min=lower, + cov_max=upper, + interpolation="non-linear", + ) + for lower, upper in zip(rcs.coverages[1:], rcs.coverages[:-1]) + ] + + [ + rcs.evaluate_auc( + risk="selective-risk", + cov_max=rcs.coverages[-1], + interpolation="non-linear", + ) + ] + ), + rcs.evaluate_auc( + risk="selective-risk", + interpolation="non-linear", + ), + ) diff --git a/fd_shifts/tests/utils.py b/fd_shifts/tests/utils.py index ed5da39..4ce138e 100644 --- a/fd_shifts/tests/utils.py +++ b/fd_shifts/tests/utils.py @@ -1,6 +1,10 @@ import os + +import numpy as np import pytest +from fd_shifts.analysis import metrics + @pytest.fixture def mock_env_if_missing(monkeypatch) -> None: @@ -10,3 +14,422 @@ def mock_env_if_missing(monkeypatch) -> None: monkeypatch.setenv( "DATASET_ROOT_DIR", os.getenv("DATASET_ROOT_DIR", default="./data") ) + + +class SC_test(metrics.StatsCache): + """Using AURC_DISPLAY_SCALE=1 and n_bins=20 for testing.""" + + AUC_DISPLAY_SCALE = 1 + + def __init__(self, confids, correct): + super().__init__(confids, correct, n_bins=20, legacy=False) + + +class SC_scale1000_test(metrics.StatsCache): + """Using AURC_DISPLAY_SCALE=1000 and n_bins=20.""" + + AUC_DISPLAY_SCALE = 1000 + + def __init__(self, confids, correct): + super().__init__(confids, correct, n_bins=20, legacy=False) + + +N_SAMPLES = 100 +assert N_SAMPLES % 4 == 0 +nan_index = (np.arange(N_SAMPLES) % 3) > 0 + +# confidence test cases +c_all_equal = np.ones(N_SAMPLES) * np.random.random() +c_alternating_01 = np.arange(N_SAMPLES) % 2 +c_alternating_10 = (np.arange(N_SAMPLES) + 1) % 2 +c_ascending = np.linspace(0.0, 1.0, N_SAMPLES) +c_ascending_unnormalized = np.arange(-(N_SAMPLES // 2), N_SAMPLES // 2) +c_some_nan = np.where(nan_index, c_alternating_01, np.nan) +c_plateaus = np.repeat([0.2, 0.4, 0.6, 0.8], N_SAMPLES // 4) + +# prediction test cases +p_all_one = np.ones(N_SAMPLES) +p_all_zero = np.zeros(N_SAMPLES) +p_alternating_01 = np.arange(N_SAMPLES) % 2 +p_some_nan = np.where(nan_index, p_alternating_01, np.nan) +p_plateau_permutation = np.concatenate( + [ + np.random.permutation( + p_alternating_01[i * N_SAMPLES // 4 : (i + 1) * N_SAMPLES // 4] + ) + for i in range(4) + ] +) +p_ascending = np.linspace(0.0, 1.0, N_SAMPLES) +p_plateaus = np.repeat([0.2, 0.4, 0.6, 0.8], N_SAMPLES // 4) + +# ======================================================================================= +# NOTE: For the following test cases, we use LINEAR interpolation of the Selective Risk +# Coverage curve for the AURC computation and NON-LINEAR interpolation for the +# achievable-AURC computation. +# ======================================================================================= + +# RiskCoverageStats test cases +RC_STATS_TEST_CASES = { + # -- Confidence scores all the same ------------------------------------------------- + SC_test(c_all_equal, p_all_one): { + "ID": "confid-all-equal_p-all-one", + "aurc": 0.0, + "eaurc": 0.0, + "aurc_achievable": 0.0, + "eaurc_achievable": 0.0, + "selective-risk@50cov": (1.0, 0.0, c_all_equal[0]), + "selective-risk@95cov": (1.0, 0.0, c_all_equal[0]), + "augrc": 0, + }, + SC_test(c_all_equal, p_all_zero): { + "ID": "confid-all-equal_p-all-zero", + "aurc": 1.0, + "eaurc": 0.0, + "aurc_achievable": 1.0, + "eaurc_achievable": 0.0, + "selective-risk@50cov": (1.0, 1.0, c_all_equal[0]), + "selective-risk@95cov": (1.0, 1.0, c_all_equal[0]), + "augrc": 0.5, + }, + SC_test(c_all_equal, p_alternating_01): { + "ID": "confid-all-equal_p-01", + "aurc": 0.5, + "eaurc": 0.3465735902799724, + "aurc_achievable": 0.5, + "eaurc_achievable": 0.3465735902799724, + "selective-risk@50cov": (1.0, 0.5, c_all_equal[0]), + "selective-risk@95cov": (1.0, 0.5, c_all_equal[0]), + "augrc": 0.25, + }, + SC_test(c_all_equal, p_some_nan): { + "ID": "confid-all-equal_p-some-nan", + }, + SC_test(c_all_equal, p_ascending): { + "ID": "confid-all-equal_p-asc", + "aurc": 0.5, + "eaurc": 0.2524999999999986, + "aurc_achievable": 0.5, + "eaurc_achievable": 0.2524999999999986, + "selective-risk@50cov": (1.0, 0.5, c_all_equal[0]), + "selective-risk@95cov": (1.0, 0.5, c_all_equal[0]), + "augrc": 0.24999999999999997, + }, + SC_test(c_all_equal, p_plateaus): { + "ID": "confid-all-equal_p-plateau", + "aurc": 0.5, + "eaurc": 0.1817914679883058, + "aurc_achievable": 0.5, + "eaurc_achievable": 0.1817914679883058, + "selective-risk@50cov": (1.0, 0.5, c_all_equal[0]), + "selective-risk@95cov": (1.0, 0.5, c_all_equal[0]), + "augrc": 0.25000000000000017, + }, + # # # -- Confidence scores alternating starting with 0 --------------------------------- + SC_test(c_alternating_01, p_all_one): { + "ID": "confid-01_p-all-one", + "aurc": 0.0, + "eaurc": 0.0, + "aurc_achievable": 0.0, + "eaurc_achievable": 0.0, + "selective-risk@50cov": (1.0, 0.0, 0.0), + "selective-risk@95cov": (1.0, 0.0, 0.0), + "augrc": 0, + }, + SC_test(c_alternating_01, p_all_zero): { + "ID": "confid-01_p-all-zero", + "aurc": 1.0, + "eaurc": 0.0, + "aurc_achievable": 1.0, + "eaurc_achievable": 0.0, + "selective-risk@50cov": (1.0, 1.0, 0.0), + "selective-risk@95cov": (1.0, 1.0, 0.0), + "augrc": 0.5, + }, + SC_test(c_alternating_01, p_alternating_01): { + "ID": "confid-01_p-01", + "aurc": 0.125, + # NOTE Using linear interpolation for computing the AURC can lead to negative + # e-AURC values + "eaurc": -0.02842640972002758, + # NOTE Slightly higher than aurc due to non-linear interpolation for achievable + "aurc_achievable": 0.15342640972002733, + "eaurc_achievable": 0, + "selective-risk@50cov": (0.5, 0.0, 1.0), + "selective-risk@95cov": (1.0, 0.5, 0.0), + "augrc": 0.125, + }, + SC_test(c_alternating_01, p_some_nan): { + "ID": "confid-01_p-some-nan", + }, + SC_test(c_alternating_01, p_ascending): { + "ID": "confid-01_p-asc", + "aurc": 0.49621212121212127, + "eaurc": 0.24871212121211994, + # NOTE Slightly higher than aurc due to non-linear interpolation for achievable + "aurc_achievable": 0.4964992566638387, + "eaurc_achievable": 0.24899925666383738, + "selective-risk@50cov": (0.5, 0.4949495, 1.0), + "selective-risk@95cov": (1.0, 0.5, 0.0), + "augrc": 0.24873737373737373, + }, + SC_test(c_alternating_01, p_plateaus): { + "ID": "confid-01_p-plateau", + "aurc": 0.49699999999999944, + "eaurc": 0.17879146798830492, + "aurc_achievable": 0.4972274112777597, + "eaurc_achievable": 0.1790188792660652, + "selective-risk@50cov": (0.5, 0.496, 1.0), + "selective-risk@95cov": (1.0, 0.5, 0.0), + "augrc": 0.24899999999999978, + }, + # -- Confidence scores alternating starting with 1 --------------------------------- + SC_test(c_alternating_10, p_all_one): { + "ID": "confid-10_p-all-one", + "aurc": 0.0, + "eaurc": 0.0, + "aurc_achievable": 0.0, + "eaurc_achievable": 0.0, + "selective-risk@50cov": (1.0, 0.0, 0.0), + "selective-risk@95cov": (1.0, 0.0, 0.0), + "augrc": 0, + }, + SC_test(c_alternating_10, p_all_zero): { + "ID": "confid-10_p-all-zero", + "aurc": 1.0, + "eaurc": 0.0, + "aurc_achievable": 1.0, + "eaurc_achievable": 0.0, + "selective-risk@50cov": (1.0, 1.0, 0.0), + "selective-risk@95cov": (1.0, 1.0, 0.0), + "augrc": 0.5, + }, + SC_test(c_alternating_10, p_alternating_01): { + "ID": "confid-10_p-01", + "aurc": 0.875, + "eaurc": 0.7215735902799725, + "aurc_achievable": 0.5, + "eaurc_achievable": 0.3465735902799724, + "selective-risk@50cov": (1.0, 0.5, 0.0), + "selective-risk@95cov": (1.0, 0.5, 0.0), + "augrc": 0.375, + }, + SC_test(c_alternating_10, p_some_nan): { + "ID": "confid-10_p-some-nan", + }, + SC_test(c_alternating_10, p_ascending): { + "ID": "confid-10_p-asc", + "aurc": 0.503787878787879, + "eaurc": 0.2562878787878777, + "aurc_achievable": 0.5035007433361615, + "eaurc_achievable": 0.25600074333616013, + "selective-risk@50cov": (1.0, 0.5, 0.0), + "selective-risk@95cov": (1.0, 0.5, 0.0), + "augrc": 0.25126262626262635, + }, + SC_test(c_alternating_10, p_plateaus): { + "ID": "confid-10_p-plateau", + "aurc": 0.5029999999999994, + "eaurc": 0.18479146798830492, + "aurc_achievable": 0.5027725887222393, + "eaurc_achievable": 0.18456405671054477, + "selective-risk@50cov": (1.0, 0.5, 0.0), + "selective-risk@95cov": (1.0, 0.5, 0.0), + "augrc": 0.2509999999999998, + }, + # -- Confidence scores ascending --------------------------------------------------- + SC_test(c_ascending, p_all_one): { + "ID": "confid-asc_p-all-one", + "aurc": 0.0, + "eaurc": 0.0, + "aurc_achievable": 0.0, + "eaurc_achievable": 0.0, + "selective-risk@50cov": (1.0, 0.0, 0.0), + "selective-risk@95cov": (1.0, 0.0, 0.0), + "augrc": 0, + }, + SC_test(c_ascending, p_all_zero): { + "ID": "confid-asc_p-all-zero", + "aurc": 1.0, + "eaurc": 0.0, + "aurc_achievable": 1.0, + "eaurc_achievable": 0.0, + "selective-risk@50cov": (1.0, 1.0, 0.0), + "selective-risk@95cov": (1.0, 1.0, 0.0), + "augrc": 0.5, + }, + SC_test(c_ascending, p_alternating_01): { + "ID": "confid-asc_p-01", + "aurc": 0.48281112575762547, + "eaurc": 0.3293847160375979, + "aurc_achievable": 0.4719992328225763, + "eaurc_achievable": 0.3185728231025487, + "selective-risk@50cov": (0.51, 0.4901961, 0.4949495), + "selective-risk@95cov": (0.95, 0.4947368, 0.0505051), + "augrc": 0.2475, + }, + SC_test(c_ascending, p_some_nan): { + "ID": "confid-asc_p-some-nan", + }, + SC_test(c_ascending, p_ascending): { + "ID": "confid-asc_p-asc", + "aurc": 0.24750000000000133, + "eaurc": 0, + "aurc_achievable": 0.24753863826243439, + "eaurc_achievable": 3.8638262433055015e-05, + "selective-risk@50cov": (0.5, 0.2474747, 0.5050505), + "selective-risk@95cov": (0.95, 0.4747475, 0.0505051), + "augrc": 0.16583333333333353, + }, + SC_test(c_ascending, p_plateaus): { + "ID": "confid-asc_p-plateau", + "aurc": 0.3182085320116945, + "eaurc": 0.0, + "aurc_achievable": 0.31821825302024953, + "eaurc_achievable": 9.721008555008126e-06, + "selective-risk@50cov": (0.5, 0.3, 0.5050505), + "selective-risk@95cov": (0.95, 0.4842105, 0.0505051), + "augrc": 0.18750000000000108, + }, + # -- Confidence scores ascending (unnormalized) ------------------------------------ + SC_test(c_ascending_unnormalized, p_all_one): { + "ID": "confid-asc-u_p-all-one", + "aurc": 0.0, + "eaurc": 0.0, + "aurc_achievable": 0.0, + "eaurc_achievable": 0.0, + "selective-risk@50cov": (1.0, 0.0, -50.0), + "selective-risk@95cov": (1.0, 0.0, -50.0), + "augrc": 0, + }, + SC_test(c_ascending_unnormalized, p_all_zero): { + "ID": "confid-asc-u_p-all-zero", + "aurc": 1.0, + "eaurc": 0.0, + "aurc_achievable": 1.0, + "eaurc_achievable": 0.0, + "selective-risk@50cov": (1.0, 1.0, -50.0), + "selective-risk@95cov": (1.0, 1.0, -50.0), + "augrc": 0.5, + }, + SC_test(c_ascending_unnormalized, p_alternating_01): { + "ID": "confid-asc-u_p-01", + "aurc": 0.48281112575762547, + "eaurc": 0.3293847160375979, + "aurc_achievable": 0.4719992328225763, + "eaurc_achievable": 0.3185728231025487, + "selective-risk@50cov": (0.51, 0.4901961, -1.0), + "selective-risk@95cov": (0.95, 0.4947368, -45.0), + "augrc": 0.2475, + }, + SC_test(c_ascending_unnormalized, p_some_nan): { + "ID": "confid-asc-u_p-some-nan", + }, + SC_test(c_ascending_unnormalized, p_ascending): { + "ID": "confid-asc-u_p-asc", + "aurc": 0.24750000000000133, + "eaurc": 0, + "aurc_achievable": 0.24753863826243439, + "eaurc_achievable": 3.8638262433055015e-05, + "selective-risk@50cov": (0.5, 0.2474747, 0.0), + "selective-risk@95cov": (0.95, 0.4747475, -45.0), + "augrc": 0.16583333333333353, + }, + SC_test(c_ascending_unnormalized, p_plateaus): { + "ID": "confid-asc-u_p-plateau", + "aurc": 0.3182085320116945, + "eaurc": 0.0, + "aurc_achievable": 0.31821825302024953, + "eaurc_achievable": 9.721008555008126e-06, + "selective-risk@50cov": (0.5, 0.3, 0.0), + "selective-risk@95cov": (0.95, 0.4842105, -45.0), + "augrc": 0.18750000000000108, + }, + # -- Confidence scores some NaN ---------------------------------------------------- + SC_test(c_some_nan, p_all_one): { + "ID": "confid-some-nan_p-all-one", + }, + SC_test(c_some_nan, p_all_zero): { + "ID": "confid-some-nan_p-all-zero", + }, + SC_test(c_some_nan, p_alternating_01): { + "ID": "confid-some-nan_p-01", + }, + SC_test(c_some_nan, p_some_nan): { + "ID": "confid-some-nan_p-some-nan", + }, + SC_test(c_some_nan, p_ascending): { + "ID": "confid-some-nan_p-asc", + }, + SC_test(c_some_nan, p_plateaus): { + "ID": "confid-some-nan_p-plateau", + }, + # -- Confidence scores plateaus ---------------------------------------------------- + SC_test(c_plateaus, p_all_one): { + "ID": "confid-plateaus_p-all-one", + "aurc": 0.0, + "eaurc": 0.0, + "aurc_achievable": 0.0, + "eaurc_achievable": 0.0, + "selective-risk@50cov": (1.0, 0.0, 0.2), + "selective-risk@95cov": (1.0, 0.0, 0.2), + "augrc": 0, + }, + SC_test(c_plateaus, p_all_zero): { + "ID": "confid-plateaus_p-all-zero", + "aurc": 1.0, + "eaurc": 0.0, + "aurc_achievable": 1.0, + "eaurc_achievable": 0.0, + "selective-risk@50cov": (1.0, 1.0, 0.2), + "selective-risk@95cov": (1.0, 1.0, 0.2), + "augrc": 0.5, + }, + SC_test(c_plateaus, p_alternating_01): { + "ID": "confid-plateaus_p-01", + "aurc": 0.49083333333333334, + "eaurc": 0.33740692361330576, + "aurc_achievable": 0.4887532971076239, + "eaurc_achievable": 0.3353268873875963, + "selective-risk@50cov": (0.75, 0.4933333, 0.4), + "selective-risk@95cov": (1.0, 0.5, 0.2), + "augrc": 0.2475, + }, + SC_test(c_plateaus, p_plateau_permutation): { + "ID": "confid-plateaus_p-plateau-perm", + "aurc": 0.49083333333333334, + "eaurc": 0.33740692361330576, + "aurc_achievable": 0.4887532971076239, + "eaurc_achievable": 0.3353268873875963, + "selective-risk@50cov": (0.75, 0.4933333, 0.4), + "selective-risk@95cov": (1.0, 0.5, 0.2), + "augrc": 0.2475, + }, + SC_test(c_plateaus, p_some_nan): { + "ID": "confid-plateaus_p-some-nan", + }, + SC_test(c_plateaus, p_ascending): { + "ID": "confid-plateaus_p-asc", + "aurc": 0.2632575757575754, + "eaurc": 0.015757575757574083, + "aurc_achievable": 0.27047759219727724, + "eaurc_achievable": 0.02297759219727591, + "selective-risk@50cov": (0.5, 0.2474747, 0.6), + "selective-risk@95cov": (1.0, 0.5, 0.2), + "augrc": 0.17108585858585845, + }, + SC_test(c_plateaus, p_plateaus): { + "ID": "confid-plateaus_p-plateau", + "aurc": 0.31250000000000255, + "eaurc": -0.005708532011691969, + "aurc_achievable": 0.31821825302024637, + "eaurc_achievable": 9.72100855184399e-06, + "selective-risk@50cov": (0.5, 0.3, 0.6), + "selective-risk@95cov": (1.0, 0.5, 0.2), + "augrc": 0.18750000000000097, + }, +} + + +# Testing metrics that explicitly depend on GT labels +RC_STATS_CLASS_AWARE_TEST_CASES = {} From 56b11fc31aee97a02dbf04455d38aa5a4407b587 Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Mon, 10 Jun 2024 12:10:28 +0200 Subject: [PATCH 117/136] Add BA toy test --- fd_shifts/analysis/metrics.py | 2 -- fd_shifts/tests/test_analysis.py | 4 ---- fd_shifts/tests/utils.py | 20 +++++++++++++++----- 3 files changed, 15 insertions(+), 11 deletions(-) diff --git a/fd_shifts/analysis/metrics.py b/fd_shifts/analysis/metrics.py index 8880fde..0641c21 100644 --- a/fd_shifts/analysis/metrics.py +++ b/fd_shifts/analysis/metrics.py @@ -56,7 +56,6 @@ def __init__( correct, n_bins, labels=None, - prevalence_ratios=None, legacy=False, ) -> None: super().__init__() @@ -64,7 +63,6 @@ def __init__( self.correct: npt.NDArray[Any] = correct self.n_bins: int = n_bins self.labels = labels - self.prevalence_ratios = prevalence_ratios self.legacy = legacy @cached_property diff --git a/fd_shifts/tests/test_analysis.py b/fd_shifts/tests/test_analysis.py index 4c10f5c..8b23989 100644 --- a/fd_shifts/tests/test_analysis.py +++ b/fd_shifts/tests/test_analysis.py @@ -719,10 +719,6 @@ def test_class_aware_metric_values(stats_cache: SC_test, expected: dict): # Now, compare to explicit result values np.testing.assert_almost_equal(stats_cache.aurc_ba, expected["aurc_ba"]) np.testing.assert_almost_equal(stats_cache.augrc_ba, expected["augrc_ba"]) - np.testing.assert_almost_equal( - stats_cache.get_working_point(risk="generalized-risk-ba", target_cov=0.95), - expected["generalized-risk-ba@95cov"], - ) def test_achievable_rc(): diff --git a/fd_shifts/tests/utils.py b/fd_shifts/tests/utils.py index 4ce138e..2143148 100644 --- a/fd_shifts/tests/utils.py +++ b/fd_shifts/tests/utils.py @@ -21,8 +21,8 @@ class SC_test(metrics.StatsCache): AUC_DISPLAY_SCALE = 1 - def __init__(self, confids, correct): - super().__init__(confids, correct, n_bins=20, legacy=False) + def __init__(self, confids, correct, **kwargs): + super().__init__(confids, correct, n_bins=20, legacy=False, **kwargs) class SC_scale1000_test(metrics.StatsCache): @@ -30,8 +30,8 @@ class SC_scale1000_test(metrics.StatsCache): AUC_DISPLAY_SCALE = 1000 - def __init__(self, confids, correct): - super().__init__(confids, correct, n_bins=20, legacy=False) + def __init__(self, confids, correct, **kwargs): + super().__init__(confids, correct, n_bins=20, legacy=False, **kwargs) N_SAMPLES = 100 @@ -432,4 +432,14 @@ def __init__(self, confids, correct): # Testing metrics that explicitly depend on GT labels -RC_STATS_CLASS_AWARE_TEST_CASES = {} +RC_STATS_CLASS_AWARE_TEST_CASES = { + SC_test( + confids=np.array([0, 1, 2, 3]), + correct=np.array([1, 0, 1, 0]), + labels=np.array([0, 0, 1, 1]), + ): { + "ID": "toy-case", + "aurc_ba": 0.5, + "augrc_ba": 0.3125, + } +} From 87923ea6110012158396adc6f3548baadaa4ce3b Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Fri, 14 Jun 2024 16:31:42 +0200 Subject: [PATCH 118/136] Make FD_SHIFTS_STORE_PATH optional --- fd_shifts/analysis/__init__.py | 26 ++++++++++++++++---------- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/fd_shifts/analysis/__init__.py b/fd_shifts/analysis/__init__.py index 2c44579..c5ab5d5 100644 --- a/fd_shifts/analysis/__init__.py +++ b/fd_shifts/analysis/__init__.py @@ -250,28 +250,32 @@ def __load_npz_if_exists(path: Path) -> npt.NDArray[np.float64] | None: @staticmethod def __load_from_store( config: configs.Config, file: str - ) -> npt.NDArray[np.float64] | None: - ... + ) -> npt.NDArray[np.float64] | None: ... @overload @staticmethod def __load_from_store( config: configs.Config, file: str, dtype: type, unpack: Literal[False] - ) -> dict[str, npt.NDArray[np.float64]] | None: - ... + ) -> dict[str, npt.NDArray[np.float64]] | None: ... @overload @staticmethod def __load_from_store( config: configs.Config, file: str, dtype: type - ) -> npt.NDArray[np.float64] | None: - ... + ) -> npt.NDArray[np.float64] | None: ... @staticmethod def __load_from_store( config: configs.Config, file: str, dtype: type = np.float64, unpack: bool = True ) -> npt.NDArray[np.float64] | dict[str, npt.NDArray[np.float64]] | None: - store_paths = map(Path, os.getenv("FD_SHIFTS_STORE_PATH", "").split(":")) + # Look for store paths in 'FD_SHIFTS_STORE_PATH', if not specified default to + # 'EXPERIMENT_ROOT_DIR'. + store_paths = map( + Path, + os.getenv( + "FD_SHIFTS_STORE_PATH", os.getenv("EXPERIMENT_ROOT_DIR", "") + ).split(":"), + ) test_dir = config.test.dir.relative_to(os.getenv("EXPERIMENT_ROOT_DIR", "")) @@ -1161,9 +1165,11 @@ def _create_results_csv(self, study_data: ExperimentData): backbone, self.cfg.exp.fold, confid_key, - study_data.mcd_softmax_mean.shape[0] - if "mcd" in confid_key - else study_data.softmax_output.shape[0], + ( + study_data.mcd_softmax_mean.shape[0] + if "mcd" in confid_key + else study_data.softmax_output.shape[0] + ), ] submit_list += [ self.method_dict[confid_key]["metrics"][x] for x in all_metrics From ad0552124c8fe0110b105de02d1bb3308dfbf3dc Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Fri, 14 Jun 2024 16:35:55 +0200 Subject: [PATCH 119/136] Rework launcher, add fd-shifts-launch cli, and experiment filtering --- fd_shifts/experiments/launcher.py | 187 +++-- fd_shifts/experiments/publications.py | 991 ++++++++++++++++++++++++++ fd_shifts/main.py | 30 +- pyproject.toml | 3 +- 4 files changed, 1108 insertions(+), 103 deletions(-) create mode 100644 fd_shifts/experiments/publications.py diff --git a/fd_shifts/experiments/launcher.py b/fd_shifts/experiments/launcher.py index 8e33587..2f1085c 100644 --- a/fd_shifts/experiments/launcher.py +++ b/fd_shifts/experiments/launcher.py @@ -1,23 +1,22 @@ import argparse import asyncio -import json -import re from datetime import datetime from pathlib import Path -from typing import Any, Iterator +from typing import Any import rich from rich.syntax import Syntax +from tqdm import tqdm -from fd_shifts import experiments, logger -from fd_shifts.experiments.cluster import submit +from fd_shifts import logger +from fd_shifts.experiments.configs import get_experiment_config, list_experiment_configs BASH_LOCAL_COMMAND = r""" bash -c 'set -o pipefail; {command} |& tee -a "./logs/{log_file_name}.log"' """ BASH_BASE_COMMAND = r""" -_fd_shifts_exec {overrides} exp.mode={mode} +fd-shifts {mode} --experiment={experiment} {overrides} """ @@ -42,31 +41,11 @@ async def worker(name, queue: asyncio.Queue[str]): queue.task_done() -def update_overrides( - overrides: dict[str, Any], iid_only: bool = False, mode: str = "train_test" -) -> dict[str, Any]: - if mode in ["train", "train_test"] and overrides.get("trainer.batch_size", -1) > 32: - accum = overrides["trainer.batch_size"] // 32 - overrides["trainer.batch_size"] = 32 - overrides["trainer.accumulate_grad_batches"] = accum - - if mode in ["test"]: - overrides["trainer.batch_size"] = 256 - - if iid_only: - overrides["eval.query_studies.noise_study"] = [] - overrides["eval.query_studies.in_class_study"] = [] - overrides["eval.query_studies.new_class_study"] = [] - - return overrides - - async def run( - _experiments: list[experiments.Experiment], + _experiments: list[str], mode: str, dry_run: bool, - max_batch_size: int = 32, - iid_only: bool = False, + overrides, ): if len(_experiments) == 0: print("Nothing to run") @@ -78,39 +57,28 @@ async def run( queue: asyncio.Queue[str] = asyncio.Queue() for experiment in _experiments: - log_file_name = f"{datetime.now().strftime('%Y-%m-%d_%H-%M-%S')}-{str(experiment.to_path()).replace('/', '_').replace('.','_')}" - - overrides = update_overrides(experiment.overrides(), iid_only, mode) - + log_file_name = f"{datetime.now().strftime('%Y-%m-%d_%H-%M-%S')}-{experiment.replace('/', '_').replace('.','_')}" cmd = BASH_BASE_COMMAND.format( - overrides=" ".join(f"{k}={v}" for k, v in overrides.items()), + experiment=experiment, + overrides=" ".join(overrides), mode=mode, ).strip() - print( - Syntax( - re.sub(r"([^,]) ", "\\1 \\\n\t", cmd), - "bash", - word_wrap=True, - background_color="default", - ) - ) - cmd = BASH_LOCAL_COMMAND.format( command=cmd, log_file_name=log_file_name ).strip() - print(Syntax(cmd, "bash", word_wrap=True, background_color="default")) if not dry_run: + rich.print(Syntax(cmd, "bash", word_wrap=True, background_color="default")) queue.put_nowait(cmd) - break - if queue.empty(): return + progress_bar = tqdm(total=queue.qsize(), desc="Experiments") + tasks = [] for i in range(1): - task = asyncio.create_task(worker(f"worker-{i}", queue)) + task = asyncio.create_task(worker(f"worker-{i}", queue, progress_bar)) tasks.append(task) # Wait until the queue is fully processed. @@ -129,79 +97,109 @@ def filter_experiments( model: str | None, backbone: str | None, exclude_model: str | None, + exclude_backbone: str | None, + exclude_group: str | None, run_nr: int | None, rew: float | None, - name: str | None, -) -> Iterator[experiments.Experiment]: - _experiments = experiments.get_all_experiments() + experiment: str | None, +) -> filter: + _experiments = list_experiment_configs() - _experiments = filter( - lambda e: "precision_study" not in str(e.to_path()), _experiments - ) + if exclude_group is not None: + _experiments = filter( + lambda e: get_experiment_config(e).exp.group_name != exclude_group, + _experiments, + ) if dataset is not None: _experiments = filter( - lambda experiment: experiment.dataset == dataset, + lambda e: get_experiment_config(e).data.dataset == dataset, _experiments, ) if dropout is not None: _experiments = filter( - lambda experiment: experiment.dropout == dropout, + lambda e: get_experiment_config(e).model.dropout_rate == dropout, _experiments, ) if rew is not None: _experiments = filter( - lambda experiment: experiment.reward == rew, + lambda e: get_experiment_config(e).model.dg_reward == rew, _experiments, ) if run_nr is not None: _experiments = filter( - lambda experiment: experiment.run == run_nr, + lambda e: f"_run{run_nr}_" in e, _experiments, ) if model is not None: _experiments = filter( - lambda experiment: experiment.model == model, + lambda e: get_experiment_config(e).model.name == model + "_model", _experiments, ) if backbone is not None: _experiments = filter( - lambda experiment: experiment.backbone == backbone, + lambda e: get_experiment_config(e).model.network.name == backbone, _experiments, ) if exclude_model is not None: _experiments = filter( - lambda experiment: experiment.model != exclude_model, + lambda e: get_experiment_config(e).model.name != exclude_model + "_model", _experiments, ) - if name is not None: + if exclude_backbone is not None: _experiments = filter( - lambda experiment: str(experiment.to_path()) == name, + lambda e: get_experiment_config(e).model.network.name != exclude_backbone, _experiments, ) + if experiment is not None: + _experiments = filter(lambda e: e == experiment, _experiments) + return _experiments +_FILTERS = {} + + +def register_filter(name): + def _inner_wrapper(func): + _FILTERS[name] = func + return func + + return _inner_wrapper + + +@register_filter("iclr2023") +def filter_iclr2023(experiments): + from fd_shifts.experiments.publications import ICLR2023 + + def is_valid(exp): + return exp in ICLR2023 + + return filter(is_valid, experiments) + + def launch( dataset: str | None, dropout: int | None, model: str | None, backbone: str | None, exclude_model: str | None, + exclude_backbone: str | None, + exclude_group: str | None, mode: str, dry_run: bool, run_nr: int | None, rew: float | None, cluster: bool, - name: str | None, - max_batch_size: int, - iid_only: bool, + experiment: str | None, + custom_filter: str | None, + overrides, ): _experiments = filter_experiments( dataset, @@ -209,21 +207,27 @@ def launch( model, backbone, exclude_model, + exclude_backbone, + exclude_group, run_nr, rew, - name, + experiment, ) - print("Launching:") - for exp in map( - lambda exp: str(exp.to_path()), - _experiments, - ): + + if custom_filter is not None: + print(f"Applying custom filter {custom_filter}...") + _experiments = _FILTERS[custom_filter](_experiments) + + _experiments = list(_experiments) + + print(f"Launching {len(_experiments)} experiments:") + for exp in _experiments: rich.print(exp) if cluster: - submit(_experiments, mode, dry_run, iid_only) + raise NotImplementedError() else: - asyncio.run(run(_experiments, mode, dry_run, max_batch_size, iid_only)) + asyncio.run(run(_experiments, mode, dry_run, overrides)) def add_filter_arguments(parser: argparse.ArgumentParser): @@ -233,38 +237,35 @@ def add_filter_arguments(parser: argparse.ArgumentParser): "--model", default=None, type=str, choices=("vit", "dg", "devries", "confidnet") ) parser.add_argument("--backbone", default=None, type=str, choices=("vit",)) + parser.add_argument("--exclude-backbone", default=None, type=str) + parser.add_argument("--exclude-group", default=None, type=str) parser.add_argument( "--exclude-model", default=None, type=str, choices=("vit", "dg", "devries", "confidnet"), ) - parser.add_argument("--run", default=None, type=int) parser.add_argument("--reward", default=None, type=float) - parser.add_argument("--name", default=None, type=str) - + parser.add_argument("--experiment", default=None, type=str) + parser.add_argument("--custom-filter", default=None, type=str, choices=_FILTERS) return parser -def add_arguments(parser: argparse.ArgumentParser): +def add_launch_arguments(parser: argparse.ArgumentParser): add_filter_arguments(parser) parser.add_argument("--dry-run", action="store_true") parser.add_argument( - "--mode", - default="train_test", - choices=("test", "train", "train_test", "analysis"), + "--mode", default="train", choices=("train", "test", "analysis") ) parser.add_argument("--cluster", action="store_true") - parser.add_argument("--iid-only", action="store_true") - - parser.add_argument("--max-batch-size", default=32, type=int) - return parser -def main(args): - # +def main(): + parser = argparse.ArgumentParser() + parser = add_launch_arguments(parser) + args, unknown = parser.parse_known_args() launch( dataset=args.dataset, @@ -272,20 +273,14 @@ def main(args): model=args.model, backbone=args.backbone, exclude_model=args.exclude_model, + exclude_backbone=args.exclude_backbone, + exclude_group=args.exclude_group, mode=args.mode, dry_run=args.dry_run, run_nr=args.run, rew=args.reward, cluster=args.cluster, - name=args.name, - max_batch_size=args.max_batch_size, - iid_only=args.iid_only, + experiment=args.experiment, + custom_filter=args.custom_filter, + overrides=unknown, ) - - -if __name__ == "__main__": - parser = argparse.ArgumentParser() - parser = add_arguments(parser) - args = parser.parse_args() - - main(args) diff --git a/fd_shifts/experiments/publications.py b/fd_shifts/experiments/publications.py new file mode 100644 index 0000000..37bcb27 --- /dev/null +++ b/fd_shifts/experiments/publications.py @@ -0,0 +1,991 @@ +ICLR2023 = [ + "animals_paper_sweep/confidnet_bbresnet50_do0_run1_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do0_run2_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do0_run3_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do0_run4_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do0_run5_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do1_run1_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do1_run2_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do1_run3_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do1_run4_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do1_run5_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do0_run1_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do0_run2_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do0_run3_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do0_run4_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do0_run5_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do1_run1_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do1_run2_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do1_run3_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do1_run4_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do1_run5_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do0_run1_rew10", + "animals_paper_sweep/dg_bbresnet50_do0_run1_rew15", + "animals_paper_sweep/dg_bbresnet50_do0_run1_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do0_run1_rew3", + "animals_paper_sweep/dg_bbresnet50_do0_run1_rew6", + "animals_paper_sweep/dg_bbresnet50_do0_run2_rew10", + "animals_paper_sweep/dg_bbresnet50_do0_run2_rew15", + "animals_paper_sweep/dg_bbresnet50_do0_run2_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do0_run2_rew3", + "animals_paper_sweep/dg_bbresnet50_do0_run2_rew6", + "animals_paper_sweep/dg_bbresnet50_do0_run3_rew10", + "animals_paper_sweep/dg_bbresnet50_do0_run3_rew15", + "animals_paper_sweep/dg_bbresnet50_do0_run3_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do0_run3_rew3", + "animals_paper_sweep/dg_bbresnet50_do0_run3_rew6", + "animals_paper_sweep/dg_bbresnet50_do0_run4_rew10", + "animals_paper_sweep/dg_bbresnet50_do0_run4_rew15", + "animals_paper_sweep/dg_bbresnet50_do0_run4_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do0_run4_rew3", + "animals_paper_sweep/dg_bbresnet50_do0_run4_rew6", + "animals_paper_sweep/dg_bbresnet50_do0_run5_rew10", + "animals_paper_sweep/dg_bbresnet50_do0_run5_rew15", + "animals_paper_sweep/dg_bbresnet50_do0_run5_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do0_run5_rew3", + "animals_paper_sweep/dg_bbresnet50_do0_run5_rew6", + "animals_paper_sweep/dg_bbresnet50_do1_run1_rew10", + "animals_paper_sweep/dg_bbresnet50_do1_run1_rew15", + "animals_paper_sweep/dg_bbresnet50_do1_run1_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do1_run1_rew3", + "animals_paper_sweep/dg_bbresnet50_do1_run1_rew6", + "animals_paper_sweep/dg_bbresnet50_do1_run2_rew10", + "animals_paper_sweep/dg_bbresnet50_do1_run2_rew15", + "animals_paper_sweep/dg_bbresnet50_do1_run2_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do1_run2_rew3", + "animals_paper_sweep/dg_bbresnet50_do1_run2_rew6", + "animals_paper_sweep/dg_bbresnet50_do1_run3_rew10", + "animals_paper_sweep/dg_bbresnet50_do1_run3_rew15", + "animals_paper_sweep/dg_bbresnet50_do1_run3_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do1_run3_rew3", + "animals_paper_sweep/dg_bbresnet50_do1_run3_rew6", + "animals_paper_sweep/dg_bbresnet50_do1_run4_rew10", + "animals_paper_sweep/dg_bbresnet50_do1_run4_rew15", + "animals_paper_sweep/dg_bbresnet50_do1_run4_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do1_run4_rew3", + "animals_paper_sweep/dg_bbresnet50_do1_run4_rew6", + "animals_paper_sweep/dg_bbresnet50_do1_run5_rew10", + "animals_paper_sweep/dg_bbresnet50_do1_run5_rew15", + "animals_paper_sweep/dg_bbresnet50_do1_run5_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do1_run5_rew3", + "animals_paper_sweep/dg_bbresnet50_do1_run5_rew6", + "breeds_paper_sweep/confidnet_bbresnet50_do0_run1_rew2.2", + "breeds_paper_sweep/confidnet_bbresnet50_do0_run2_rew2.2", + "breeds_paper_sweep/confidnet_bbresnet50_do1_run1_rew2.2", + "breeds_paper_sweep/confidnet_bbresnet50_do1_run2_rew2.2", + "breeds_paper_sweep/devries_bbresnet50_do0_run1_rew2.2", + "breeds_paper_sweep/devries_bbresnet50_do0_run2_rew2.2", + "breeds_paper_sweep/devries_bbresnet50_do1_run1_rew2.2", + "breeds_paper_sweep/devries_bbresnet50_do1_run2_rew2.2", + "breeds_paper_sweep/dg_bbresnet50_do0_run1_rew10", + "breeds_paper_sweep/dg_bbresnet50_do0_run1_rew15", + "breeds_paper_sweep/dg_bbresnet50_do0_run1_rew2.2", + "breeds_paper_sweep/dg_bbresnet50_do0_run1_rew3", + "breeds_paper_sweep/dg_bbresnet50_do0_run1_rew6", + "breeds_paper_sweep/dg_bbresnet50_do0_run2_rew10", + "breeds_paper_sweep/dg_bbresnet50_do0_run2_rew15", + "breeds_paper_sweep/dg_bbresnet50_do0_run2_rew2.2", + "breeds_paper_sweep/dg_bbresnet50_do0_run2_rew3", + "breeds_paper_sweep/dg_bbresnet50_do0_run2_rew6", + "breeds_paper_sweep/dg_bbresnet50_do1_run1_rew10", + "breeds_paper_sweep/dg_bbresnet50_do1_run1_rew15", + "breeds_paper_sweep/dg_bbresnet50_do1_run1_rew2.2", + "breeds_paper_sweep/dg_bbresnet50_do1_run1_rew3", + "breeds_paper_sweep/dg_bbresnet50_do1_run1_rew6", + "breeds_paper_sweep/dg_bbresnet50_do1_run2_rew10", + "breeds_paper_sweep/dg_bbresnet50_do1_run2_rew15", + "breeds_paper_sweep/dg_bbresnet50_do1_run2_rew2.2", + "breeds_paper_sweep/dg_bbresnet50_do1_run2_rew3", + "breeds_paper_sweep/dg_bbresnet50_do1_run2_rew6", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run10_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run1_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run2_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run3_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run4_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run5_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run6_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run7_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run8_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run9_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run10_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run1_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run2_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run3_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run4_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run5_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run6_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run7_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run8_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run9_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run10_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run1_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run2_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run3_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run4_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run5_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run6_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run7_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run8_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run9_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run10_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run1_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run2_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run3_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run4_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run5_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run6_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run7_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run8_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run9_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run10_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run10_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run10_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run10_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run1_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run1_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run1_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run1_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run2_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run2_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run2_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run2_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run3_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run3_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run3_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run3_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run4_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run4_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run4_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run4_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run5_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run5_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run5_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run5_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run6_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run6_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run6_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run6_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run7_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run7_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run7_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run7_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run8_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run8_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run8_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run8_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run9_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run9_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run9_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run9_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run10_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run10_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run10_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run10_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run1_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run1_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run1_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run1_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run2_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run2_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run2_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run2_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run3_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run3_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run3_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run3_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run4_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run4_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run4_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run4_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run5_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run5_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run5_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run5_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run6_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run6_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run6_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run6_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run7_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run7_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run7_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run7_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run8_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run8_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run8_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run8_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run9_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run9_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run9_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run9_rew6", + "cifar100_paper_sweep/confidnet_bbvgg13_do0_run1_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do0_run2_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do0_run3_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do0_run4_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do0_run5_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do1_run1_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do1_run2_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do1_run3_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do1_run4_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do1_run5_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do0_run1_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do0_run2_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do0_run3_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do0_run4_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do0_run5_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do1_run1_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do1_run2_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do1_run3_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do1_run4_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do1_run5_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do0_run1_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do0_run1_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do0_run1_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do0_run1_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do0_run1_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do0_run1_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do0_run1_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do0_run2_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do0_run2_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do0_run2_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do0_run2_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do0_run2_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do0_run2_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do0_run2_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do0_run3_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do0_run3_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do0_run3_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do0_run3_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do0_run3_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do0_run3_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do0_run3_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do0_run4_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do0_run4_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do0_run4_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do0_run4_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do0_run4_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do0_run4_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do0_run4_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do0_run5_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do0_run5_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do0_run5_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do0_run5_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do0_run5_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do0_run5_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do0_run5_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do1_run1_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do1_run1_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do1_run1_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do1_run1_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do1_run1_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do1_run1_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do1_run1_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do1_run2_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do1_run2_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do1_run2_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do1_run2_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do1_run2_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do1_run2_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do1_run2_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do1_run3_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do1_run3_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do1_run3_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do1_run3_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do1_run3_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do1_run3_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do1_run3_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do1_run4_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do1_run4_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do1_run4_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do1_run4_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do1_run4_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do1_run4_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do1_run4_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do1_run5_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do1_run5_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do1_run5_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do1_run5_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do1_run5_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do1_run5_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do1_run5_rew6", + "cifar10_paper_sweep/confidnet_bbvgg13_do0_run1_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do0_run2_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do0_run3_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do0_run4_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do0_run5_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do1_run1_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do1_run2_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do1_run3_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do1_run4_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do1_run5_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do0_run1_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do0_run2_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do0_run3_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do0_run4_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do0_run5_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do1_run1_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do1_run2_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do1_run3_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do1_run4_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do1_run5_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do0_run1_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do0_run1_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do0_run1_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do0_run1_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do0_run2_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do0_run2_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do0_run2_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do0_run2_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do0_run3_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do0_run3_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do0_run3_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do0_run3_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do0_run4_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do0_run4_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do0_run4_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do0_run4_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do0_run5_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do0_run5_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do0_run5_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do0_run5_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do1_run1_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do1_run1_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do1_run1_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do1_run1_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do1_run2_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do1_run2_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do1_run2_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do1_run2_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do1_run3_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do1_run3_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do1_run3_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do1_run3_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do1_run4_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do1_run4_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do1_run4_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do1_run4_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do1_run5_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do1_run5_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do1_run5_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do1_run5_rew6", + "supercifar_paper_sweep/confidnet_bbvgg13_do0_run1_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do0_run2_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do0_run3_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do0_run4_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do0_run5_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do1_run1_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do1_run2_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do1_run3_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do1_run4_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do1_run5_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do0_run1_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do0_run2_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do0_run3_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do0_run4_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do0_run5_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do1_run1_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do1_run2_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do1_run3_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do1_run4_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do1_run5_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do0_run1_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do0_run1_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do0_run1_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do0_run1_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do0_run1_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do0_run1_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do0_run1_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do0_run2_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do0_run2_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do0_run2_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do0_run2_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do0_run2_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do0_run2_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do0_run2_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do0_run3_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do0_run3_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do0_run3_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do0_run3_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do0_run3_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do0_run3_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do0_run3_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do0_run4_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do0_run4_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do0_run4_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do0_run4_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do0_run4_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do0_run4_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do0_run4_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do0_run5_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do0_run5_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do0_run5_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do0_run5_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do0_run5_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do0_run5_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do0_run5_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do1_run1_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do1_run1_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do1_run1_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do1_run1_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do1_run1_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do1_run1_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do1_run1_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do1_run2_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do1_run2_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do1_run2_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do1_run2_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do1_run2_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do1_run2_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do1_run2_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do1_run3_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do1_run3_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do1_run3_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do1_run3_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do1_run3_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do1_run3_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do1_run3_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do1_run4_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do1_run4_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do1_run4_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do1_run4_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do1_run4_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do1_run4_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do1_run4_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do1_run5_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do1_run5_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do1_run5_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do1_run5_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do1_run5_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do1_run5_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do1_run5_rew6", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do0_run1_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do0_run2_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do0_run3_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do0_run4_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do0_run5_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do1_run1_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do1_run2_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do1_run3_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do1_run4_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do1_run5_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do0_run1_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do0_run2_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do0_run3_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do0_run4_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do0_run5_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do1_run1_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do1_run2_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do1_run3_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do1_run4_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do1_run5_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run1_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run1_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run1_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run1_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run2_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run2_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run2_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run2_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run3_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run3_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run3_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run3_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run4_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run4_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run4_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run4_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run5_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run5_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run5_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run5_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run1_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run1_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run1_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run1_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run2_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run2_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run2_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run2_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run3_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run3_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run3_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run3_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run4_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run4_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run4_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run4_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run5_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run5_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run5_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run5_rew6", + "vit/breeds_modeldg_bbvit_lr0.001_bs128_run0_do0_rew10", + "vit/breeds_modeldg_bbvit_lr0.001_bs128_run0_do0_rew15", + "vit/breeds_modeldg_bbvit_lr0.001_bs128_run0_do0_rew2.2", + "vit/breeds_modeldg_bbvit_lr0.001_bs128_run0_do0_rew3", + "vit/breeds_modeldg_bbvit_lr0.001_bs128_run0_do0_rew6", + "vit/breeds_modeldg_bbvit_lr0.001_bs128_run1_do0_rew10", + "vit/breeds_modeldg_bbvit_lr0.001_bs128_run1_do0_rew15", + "vit/breeds_modeldg_bbvit_lr0.001_bs128_run1_do0_rew2.2", + "vit/breeds_modeldg_bbvit_lr0.001_bs128_run1_do0_rew3", + "vit/breeds_modeldg_bbvit_lr0.001_bs128_run1_do0_rew6", + "vit/breeds_modeldg_bbvit_lr0.003_bs128_run0_do0_rew10", + "vit/breeds_modeldg_bbvit_lr0.003_bs128_run0_do0_rew15", + "vit/breeds_modeldg_bbvit_lr0.003_bs128_run0_do0_rew2.2", + "vit/breeds_modeldg_bbvit_lr0.003_bs128_run0_do0_rew3", + "vit/breeds_modeldg_bbvit_lr0.003_bs128_run0_do0_rew6", + "vit/breeds_modeldg_bbvit_lr0.003_bs128_run1_do0_rew10", + "vit/breeds_modeldg_bbvit_lr0.003_bs128_run1_do0_rew15", + "vit/breeds_modeldg_bbvit_lr0.003_bs128_run1_do0_rew2.2", + "vit/breeds_modeldg_bbvit_lr0.003_bs128_run1_do0_rew3", + "vit/breeds_modeldg_bbvit_lr0.003_bs128_run1_do0_rew6", + "vit/breeds_modeldg_bbvit_lr0.01_bs128_run0_do1_rew10", + "vit/breeds_modeldg_bbvit_lr0.01_bs128_run0_do1_rew15", + "vit/breeds_modeldg_bbvit_lr0.01_bs128_run0_do1_rew2.2", + "vit/breeds_modeldg_bbvit_lr0.01_bs128_run0_do1_rew3", + "vit/breeds_modeldg_bbvit_lr0.01_bs128_run0_do1_rew6", + "vit/breeds_modeldg_bbvit_lr0.01_bs128_run1_do1_rew10", + "vit/breeds_modeldg_bbvit_lr0.01_bs128_run1_do1_rew15", + "vit/breeds_modeldg_bbvit_lr0.01_bs128_run1_do1_rew2.2", + "vit/breeds_modeldg_bbvit_lr0.01_bs128_run1_do1_rew3", + "vit/breeds_modeldg_bbvit_lr0.01_bs128_run1_do1_rew6", + "vit/breeds_modelvit_bbvit_lr0.001_bs128_run0_do0_rew0", + "vit/breeds_modelvit_bbvit_lr0.001_bs128_run1_do0_rew0", + "vit/breeds_modelvit_bbvit_lr0.003_bs128_run0_do0_rew0", + "vit/breeds_modelvit_bbvit_lr0.003_bs128_run1_do0_rew0", + "vit/breeds_modelvit_bbvit_lr0.01_bs128_run0_do1_rew0", + "vit/breeds_modelvit_bbvit_lr0.01_bs128_run1_do1_rew0", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run0_do0_rew10", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run0_do0_rew12", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run0_do0_rew15", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run0_do0_rew2.2", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run0_do0_rew20", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run0_do0_rew3", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run0_do0_rew6", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run0_do1_rew10", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run0_do1_rew12", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run0_do1_rew15", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run0_do1_rew2.2", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run0_do1_rew20", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run0_do1_rew3", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run0_do1_rew6", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run1_do0_rew10", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run1_do0_rew12", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run1_do0_rew15", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run1_do0_rew2.2", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run1_do0_rew20", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run1_do0_rew3", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run1_do0_rew6", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run1_do1_rew10", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run1_do1_rew12", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run1_do1_rew15", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run1_do1_rew2.2", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run1_do1_rew20", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run1_do1_rew3", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run1_do1_rew6", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run2_do0_rew10", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run2_do0_rew12", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run2_do0_rew15", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run2_do0_rew2.2", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run2_do0_rew20", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run2_do0_rew3", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run2_do0_rew6", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run2_do1_rew10", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run2_do1_rew12", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run2_do1_rew15", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run2_do1_rew2.2", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run2_do1_rew20", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run2_do1_rew3", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run2_do1_rew6", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run3_do0_rew10", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run3_do0_rew12", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run3_do0_rew15", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run3_do0_rew2.2", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run3_do0_rew20", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run3_do0_rew3", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run3_do0_rew6", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run3_do1_rew10", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run3_do1_rew12", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run3_do1_rew15", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run3_do1_rew2.2", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run3_do1_rew20", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run3_do1_rew3", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run3_do1_rew6", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run4_do0_rew10", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run4_do0_rew12", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run4_do0_rew15", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run4_do0_rew2.2", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run4_do0_rew20", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run4_do0_rew3", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run4_do0_rew6", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run4_do1_rew10", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run4_do1_rew12", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run4_do1_rew15", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run4_do1_rew2.2", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run4_do1_rew20", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run4_do1_rew3", + "vit/cifar100_modeldg_bbvit_lr0.01_bs128_run4_do1_rew6", + "vit/cifar100_modelvit_bbvit_lr0.01_bs128_run0_do0_rew0", + "vit/cifar100_modelvit_bbvit_lr0.01_bs128_run0_do1_rew0", + "vit/cifar100_modelvit_bbvit_lr0.01_bs128_run1_do0_rew0", + "vit/cifar100_modelvit_bbvit_lr0.01_bs128_run1_do1_rew0", + "vit/cifar100_modelvit_bbvit_lr0.01_bs128_run2_do0_rew0", + "vit/cifar100_modelvit_bbvit_lr0.01_bs128_run2_do1_rew0", + "vit/cifar100_modelvit_bbvit_lr0.01_bs128_run3_do0_rew0", + "vit/cifar100_modelvit_bbvit_lr0.01_bs128_run3_do1_rew0", + "vit/cifar100_modelvit_bbvit_lr0.01_bs128_run4_do0_rew0", + "vit/cifar100_modelvit_bbvit_lr0.01_bs128_run4_do1_rew0", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run0_do0_rew10", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run0_do0_rew2.2", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run0_do0_rew3", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run0_do0_rew6", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run1_do0_rew10", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run1_do0_rew2.2", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run1_do0_rew3", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run1_do0_rew6", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run2_do0_rew10", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run2_do0_rew2.2", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run2_do0_rew3", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run2_do0_rew6", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run3_do0_rew10", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run3_do0_rew2.2", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run3_do0_rew3", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run3_do0_rew6", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run4_do0_rew10", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run4_do0_rew2.2", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run4_do0_rew3", + "vit/cifar10_modeldg_bbvit_lr0.0003_bs128_run4_do0_rew6", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run0_do1_rew10", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run0_do1_rew2.2", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run0_do1_rew3", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run0_do1_rew6", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run1_do1_rew10", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run1_do1_rew2.2", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run1_do1_rew3", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run1_do1_rew6", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run2_do1_rew10", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run2_do1_rew2.2", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run2_do1_rew3", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run2_do1_rew6", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run3_do1_rew10", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run3_do1_rew2.2", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run3_do1_rew3", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run3_do1_rew6", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run4_do1_rew10", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run4_do1_rew2.2", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run4_do1_rew3", + "vit/cifar10_modeldg_bbvit_lr0.01_bs128_run4_do1_rew6", + "vit/cifar10_modelvit_bbvit_lr0.0003_bs128_run0_do0_rew0", + "vit/cifar10_modelvit_bbvit_lr0.0003_bs128_run1_do0_rew0", + "vit/cifar10_modelvit_bbvit_lr0.0003_bs128_run2_do0_rew0", + "vit/cifar10_modelvit_bbvit_lr0.0003_bs128_run3_do0_rew0", + "vit/cifar10_modelvit_bbvit_lr0.0003_bs128_run4_do0_rew0", + "vit/cifar10_modelvit_bbvit_lr0.01_bs128_run0_do1_rew0", + "vit/cifar10_modelvit_bbvit_lr0.01_bs128_run1_do1_rew0", + "vit/cifar10_modelvit_bbvit_lr0.01_bs128_run2_do1_rew0", + "vit/cifar10_modelvit_bbvit_lr0.01_bs128_run3_do1_rew0", + "vit/cifar10_modelvit_bbvit_lr0.01_bs128_run4_do1_rew0", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run0_do1_rew10", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run0_do1_rew12", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run0_do1_rew15", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run0_do1_rew2.2", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run0_do1_rew20", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run0_do1_rew3", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run0_do1_rew6", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run1_do1_rew10", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run1_do1_rew12", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run1_do1_rew15", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run1_do1_rew2.2", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run1_do1_rew20", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run1_do1_rew3", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run1_do1_rew6", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run2_do1_rew10", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run2_do1_rew12", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run2_do1_rew15", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run2_do1_rew2.2", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run2_do1_rew20", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run2_do1_rew3", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run2_do1_rew6", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run3_do1_rew10", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run3_do1_rew12", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run3_do1_rew15", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run3_do1_rew2.2", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run3_do1_rew20", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run3_do1_rew3", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run3_do1_rew6", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run4_do1_rew10", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run4_do1_rew12", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run4_do1_rew15", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run4_do1_rew2.2", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run4_do1_rew20", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run4_do1_rew3", + "vit/super_cifar100_modeldg_bbvit_lr0.001_bs128_run4_do1_rew6", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run0_do0_rew10", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run0_do0_rew12", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run0_do0_rew15", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run0_do0_rew2.2", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run0_do0_rew20", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run0_do0_rew3", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run0_do0_rew6", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run1_do0_rew10", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run1_do0_rew12", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run1_do0_rew15", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run1_do0_rew2.2", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run1_do0_rew20", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run1_do0_rew3", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run1_do0_rew6", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run2_do0_rew10", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run2_do0_rew12", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run2_do0_rew15", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run2_do0_rew2.2", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run2_do0_rew20", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run2_do0_rew3", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run2_do0_rew6", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run3_do0_rew10", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run3_do0_rew12", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run3_do0_rew15", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run3_do0_rew2.2", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run3_do0_rew20", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run3_do0_rew3", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run3_do0_rew6", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run4_do0_rew10", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run4_do0_rew12", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run4_do0_rew15", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run4_do0_rew2.2", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run4_do0_rew20", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run4_do0_rew3", + "vit/super_cifar100_modeldg_bbvit_lr0.003_bs128_run4_do0_rew6", + "vit/super_cifar100_modelvit_bbvit_lr0.001_bs128_run0_do1_rew0", + "vit/super_cifar100_modelvit_bbvit_lr0.001_bs128_run1_do1_rew0", + "vit/super_cifar100_modelvit_bbvit_lr0.001_bs128_run2_do1_rew0", + "vit/super_cifar100_modelvit_bbvit_lr0.001_bs128_run3_do1_rew0", + "vit/super_cifar100_modelvit_bbvit_lr0.001_bs128_run4_do1_rew0", + "vit/super_cifar100_modelvit_bbvit_lr0.003_bs128_run0_do0_rew0", + "vit/super_cifar100_modelvit_bbvit_lr0.003_bs128_run1_do0_rew0", + "vit/super_cifar100_modelvit_bbvit_lr0.003_bs128_run2_do0_rew0", + "vit/super_cifar100_modelvit_bbvit_lr0.003_bs128_run3_do0_rew0", + "vit/super_cifar100_modelvit_bbvit_lr0.003_bs128_run4_do0_rew0", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run0_do0_rew10", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run0_do0_rew2.2", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run0_do0_rew3", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run0_do0_rew6", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run0_do1_rew10", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run0_do1_rew2.2", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run0_do1_rew3", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run0_do1_rew6", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run1_do0_rew10", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run1_do0_rew2.2", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run1_do0_rew3", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run1_do0_rew6", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run1_do1_rew10", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run1_do1_rew2.2", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run1_do1_rew3", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run1_do1_rew6", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run2_do0_rew10", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run2_do0_rew2.2", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run2_do0_rew3", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run2_do0_rew6", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run2_do1_rew10", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run2_do1_rew2.2", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run2_do1_rew3", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run2_do1_rew6", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run3_do0_rew10", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run3_do0_rew2.2", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run3_do0_rew3", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run3_do0_rew6", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run3_do1_rew10", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run3_do1_rew2.2", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run3_do1_rew3", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run3_do1_rew6", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run4_do0_rew10", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run4_do0_rew2.2", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run4_do0_rew3", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run4_do0_rew6", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run4_do1_rew10", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run4_do1_rew2.2", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run4_do1_rew3", + "vit/svhn_modeldg_bbvit_lr0.01_bs128_run4_do1_rew6", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run0_do1_rew10", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run0_do1_rew2.2", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run0_do1_rew3", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run0_do1_rew6", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run1_do1_rew10", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run1_do1_rew2.2", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run1_do1_rew3", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run1_do1_rew6", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run2_do1_rew10", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run2_do1_rew2.2", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run2_do1_rew3", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run2_do1_rew6", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run3_do1_rew10", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run3_do1_rew2.2", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run3_do1_rew3", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run3_do1_rew6", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run4_do1_rew10", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run4_do1_rew2.2", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run4_do1_rew3", + "vit/svhn_modeldg_bbvit_lr0.03_bs128_run4_do1_rew6", + "vit/svhn_modelvit_bbvit_lr0.01_bs128_run0_do0_rew0", + "vit/svhn_modelvit_bbvit_lr0.01_bs128_run0_do1_rew0", + "vit/svhn_modelvit_bbvit_lr0.01_bs128_run1_do0_rew0", + "vit/svhn_modelvit_bbvit_lr0.01_bs128_run1_do1_rew0", + "vit/svhn_modelvit_bbvit_lr0.01_bs128_run2_do0_rew0", + "vit/svhn_modelvit_bbvit_lr0.01_bs128_run2_do1_rew0", + "vit/svhn_modelvit_bbvit_lr0.01_bs128_run3_do0_rew0", + "vit/svhn_modelvit_bbvit_lr0.01_bs128_run3_do1_rew0", + "vit/svhn_modelvit_bbvit_lr0.01_bs128_run4_do0_rew0", + "vit/svhn_modelvit_bbvit_lr0.01_bs128_run4_do1_rew0", + "vit/svhn_modelvit_bbvit_lr0.03_bs128_run0_do1_rew0", + "vit/svhn_modelvit_bbvit_lr0.03_bs128_run1_do1_rew0", + "vit/svhn_modelvit_bbvit_lr0.03_bs128_run2_do1_rew0", + "vit/svhn_modelvit_bbvit_lr0.03_bs128_run3_do1_rew0", + "vit/svhn_modelvit_bbvit_lr0.03_bs128_run4_do1_rew0", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run0_do0_rew10", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run0_do0_rew15", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run0_do0_rew2.2", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run0_do0_rew3", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run0_do0_rew6", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run1_do0_rew10", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run1_do0_rew15", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run1_do0_rew2.2", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run1_do0_rew3", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run1_do0_rew6", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run2_do0_rew10", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run2_do0_rew15", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run2_do0_rew2.2", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run2_do0_rew3", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run2_do0_rew6", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run3_do0_rew10", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run3_do0_rew15", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run3_do0_rew2.2", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run3_do0_rew3", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run3_do0_rew6", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run4_do0_rew10", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run4_do0_rew15", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run4_do0_rew2.2", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run4_do0_rew3", + "vit/wilds_animals_modeldg_bbvit_lr0.001_bs128_run4_do0_rew6", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run0_do0_rew10", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run0_do0_rew15", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run0_do0_rew2.2", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run0_do0_rew3", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run0_do0_rew6", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run0_do1_rew10", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run0_do1_rew15", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run0_do1_rew2.2", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run0_do1_rew3", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run0_do1_rew6", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run1_do0_rew10", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run1_do0_rew15", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run1_do0_rew2.2", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run1_do0_rew3", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run1_do0_rew6", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run1_do1_rew10", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run1_do1_rew15", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run1_do1_rew2.2", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run1_do1_rew3", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run1_do1_rew6", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run2_do0_rew10", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run2_do0_rew15", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run2_do0_rew2.2", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run2_do0_rew3", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run2_do0_rew6", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run2_do1_rew10", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run2_do1_rew15", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run2_do1_rew2.2", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run2_do1_rew3", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run2_do1_rew6", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run3_do0_rew10", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run3_do0_rew15", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run3_do0_rew2.2", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run3_do0_rew3", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run3_do0_rew6", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run3_do1_rew10", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run3_do1_rew15", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run3_do1_rew2.2", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run3_do1_rew3", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run3_do1_rew6", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run4_do0_rew10", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run4_do0_rew15", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run4_do0_rew2.2", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run4_do0_rew3", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run4_do0_rew6", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run4_do1_rew10", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run4_do1_rew15", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run4_do1_rew2.2", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run4_do1_rew3", + "vit/wilds_animals_modeldg_bbvit_lr0.003_bs128_run4_do1_rew6", + "vit/wilds_animals_modelvit_bbvit_lr0.001_bs128_run0_do0_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.001_bs128_run1_do0_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.001_bs128_run2_do0_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.001_bs128_run3_do0_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.001_bs128_run4_do0_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.003_bs128_run0_do0_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.003_bs128_run0_do1_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.003_bs128_run1_do0_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.003_bs128_run1_do1_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.003_bs128_run2_do0_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.003_bs128_run2_do1_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.003_bs128_run3_do0_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.003_bs128_run3_do1_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.003_bs128_run4_do0_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.003_bs128_run4_do1_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.01_bs128_run0_do0_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.01_bs128_run0_do1_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.01_bs128_run1_do0_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.01_bs128_run1_do1_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.01_bs128_run2_do0_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.01_bs128_run2_do1_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.01_bs128_run3_do0_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.01_bs128_run3_do1_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.01_bs128_run4_do0_rew0", + "vit/wilds_animals_modelvit_bbvit_lr0.01_bs128_run4_do1_rew0", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run0_do0_rew10", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run0_do0_rew2.2", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run0_do0_rew3", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run0_do0_rew6", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run1_do0_rew10", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run1_do0_rew2.2", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run1_do0_rew3", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run1_do0_rew6", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run2_do0_rew10", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run2_do0_rew2.2", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run2_do0_rew3", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run2_do0_rew6", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run3_do0_rew10", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run3_do0_rew2.2", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run3_do0_rew3", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run3_do0_rew6", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run4_do0_rew10", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run4_do0_rew2.2", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run4_do0_rew3", + "vit/wilds_camelyon_modeldg_bbvit_lr0.001_bs128_run4_do0_rew6", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run0_do1_rew10", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run0_do1_rew2.2", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run0_do1_rew3", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run0_do1_rew6", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run1_do1_rew10", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run1_do1_rew2.2", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run1_do1_rew3", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run1_do1_rew6", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run2_do1_rew10", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run2_do1_rew2.2", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run2_do1_rew3", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run2_do1_rew6", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run3_do1_rew10", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run3_do1_rew2.2", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run3_do1_rew3", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run3_do1_rew6", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run4_do1_rew10", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run4_do1_rew2.2", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run4_do1_rew3", + "vit/wilds_camelyon_modeldg_bbvit_lr0.003_bs128_run4_do1_rew6", + "vit/wilds_camelyon_modelvit_bbvit_lr0.001_bs128_run0_do0_rew0", + "vit/wilds_camelyon_modelvit_bbvit_lr0.001_bs128_run1_do0_rew0", + "vit/wilds_camelyon_modelvit_bbvit_lr0.001_bs128_run2_do0_rew0", + "vit/wilds_camelyon_modelvit_bbvit_lr0.001_bs128_run3_do0_rew0", + "vit/wilds_camelyon_modelvit_bbvit_lr0.001_bs128_run4_do0_rew0", + "vit/wilds_camelyon_modelvit_bbvit_lr0.003_bs128_run0_do1_rew0", + "vit/wilds_camelyon_modelvit_bbvit_lr0.003_bs128_run1_do1_rew0", + "vit/wilds_camelyon_modelvit_bbvit_lr0.003_bs128_run2_do1_rew0", + "vit/wilds_camelyon_modelvit_bbvit_lr0.003_bs128_run3_do1_rew0", + "vit/wilds_camelyon_modelvit_bbvit_lr0.003_bs128_run4_do1_rew0", +] diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 92bedee..24155da 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -21,6 +21,7 @@ from fd_shifts import reporting from fd_shifts.configs import Config, DataConfig, OutputPathsPerMode +from fd_shifts.experiments import launcher from fd_shifts.experiments.configs import list_experiment_configs if TYPE_CHECKING: @@ -562,10 +563,21 @@ def debug(config: Config) -> None: # noqa: ARG001 """Noop function for debugging purposes.""" -def _list_experiments() -> None: - from fd_shifts.experiments.configs import list_experiment_configs +def _list_experiments(args) -> None: + _experiments = launcher.filter_experiments( + dataset=args.dataset, + dropout=args.dropout, + model=args.model, + backbone=args.backbone, + exclude_model=args.exclude_model, + exclude_backbone=args.exclude_backbone, + exclude_group=args.exclude_group, + run_nr=args.run, + rew=args.reward, + experiment=args.experiment, + ) - for exp in sorted(list_experiment_configs()): + for exp in sorted(_experiments): print(exp) # noqa: T201 @@ -580,6 +592,7 @@ def get_parser() -> tuple[ArgumentParser, dict[str, ArgumentParser]]: subparsers: dict[str, ArgumentParser] = {} subparser = ArgumentParser() + launcher.add_filter_arguments(subparser) subcommands.add_subcommand("list-experiments", subparser) subparser = ArgumentParser() @@ -587,6 +600,7 @@ def get_parser() -> tuple[ArgumentParser, dict[str, ArgumentParser]]: subparsers["report"] = subparser subcommands.add_subcommand("report", subparser) + experiment_choices = list_experiment_configs() for name, func in __subcommands.items(): subparser = ArgumentParser() subparser.add_argument( @@ -595,7 +609,13 @@ def get_parser() -> tuple[ArgumentParser, dict[str, ArgumentParser]]: shtab.FILE ) subparser.add_argument( - "--experiment", action=ActionExperiment, choices=list_experiment_configs() + "--experiment", action=ActionExperiment, choices=experiment_choices + ) + subparser.print_help = lambda: print( + subparser.format_help().replace( + ",".join(experiment_choices), + "Run `fd-shifts list-experiments` for a list of valid experiment names", + ) ) subparser.add_function_arguments(func, sub_configs=True) subparsers[name] = subparser @@ -621,7 +641,7 @@ def main() -> None: args = parser.parse_args() if args.command == "list-experiments": - _list_experiments() + _list_experiments(args["list-experiments"]) return if args.command == "report": diff --git a/pyproject.toml b/pyproject.toml index 89a8caa..ae05856 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -64,9 +64,8 @@ docs = ["jupyterlab", "notebook", "ipykernel"] launcher = ["parallel-ssh"] [project.scripts] -fd_shifts = "fd_shifts.cli:main" +fd-shifts-launch = "fd_shifts.experiments.launcher:main" fd-shifts = "fd_shifts.main:main" -_fd_shifts_exec = "fd_shifts.exec:main" [tool.setuptools_scm] write_to = "fd_shifts/_version.py" From da9fa8e41a40280142df83a2383a5186b272f03d Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Fri, 14 Jun 2024 16:36:25 +0200 Subject: [PATCH 120/136] Update README --- README.md | 70 +++++++++++++++++++++++--------- docs/publications/iclr_2023.md | 64 +++++++++++++++++++++++++++++ docs/publications/miccai_2023.md | 0 3 files changed, 114 insertions(+), 20 deletions(-) create mode 100644 docs/publications/iclr_2023.md create mode 100644 docs/publications/miccai_2023.md diff --git a/README.md b/README.md index 36a7dd0..c2ceaa6 100644 --- a/README.md +++ b/README.md @@ -65,7 +65,7 @@ ## Citing This Work -If you use fd-shifts please cite our [paper](https://openreview.net/pdf?id=YnkGMIh0gvX) +If you use FD-Shifts please cite our [paper](https://openreview.net/pdf?id=YnkGMIh0gvX) ```bibtex @inproceedings{ @@ -88,6 +88,7 @@ If you use fd-shifts please cite our [paper](https://openreview.net/pdf?id=YnkGM - [Installation](#installation) - [How to Integrate Your Own Usecase](#how-to-integrate-your-own-usecase) - [Reproducing our results](#reproducing-our-results) +- [Working with FD-Shifts](#working-with-fd-shifts) - [Data Folder Requirements](#data-folder-requirements) - [Training](#training) - [Model Weights](#model-weights) @@ -104,13 +105,13 @@ install FD-Shifts in its own environment (venv, conda environment, ...). 1. **Install an appropriate version of [PyTorch](https://pytorch.org/).** Check that CUDA is available and that the CUDA toolkit version is compatible with - your hardware. The currently necessary version of + your hardware. The currently minimum necessary version of [pytorch is v.1.11.0](https://pytorch.org/get-started/previous-versions/#v1110). Testing and Development was done with the pytorch version using CUDA 11.3. 2. **Install FD-Shifts.** This will pull in all dependencies including some version of PyTorch, it is strongly recommended that you install a compatible - version of PyTorch beforehand. This will also make the `fd_shifts` cli + version of PyTorch beforehand. This will also make the `fd-shifts` cli available to you. ```bash pip install git+https://github.com/iml-dkfz/fd-shifts.git @@ -124,8 +125,15 @@ scoring functions check out the [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/iml-dkfz/fd-shifts/blob/main/docs/extending_fd-shifts.ipynb). ## Reproducing our results +This repository contains the benchmarks for the following publications: +- ["A Call to Reflect on Evaluation Practices for Failure Detection in Image Classification"](https://openreview.net/pdf?id=YnkGMIh0gvX) → [Documentation for reproducing](./docs/publications/iclr_2023.md) +- ["Understanding Silent Failures in Medical Image Classification"](https://arxiv.org/abs/2307.14729) (For the visualization tool presented in that work please see [sf-visuals](https://github.com/IML-DKFZ/sf-visuals).) → [Documentation for reproducing](./docs/publications/miccai_2023.md) -To use `fd_shifts` you need to set the following environment variables +While the following section on [working with FD-Shifts](#working-with-fd-shifts) describes the general usage, descriptions for reproducing specific publications are documented [here](./docs/publications). + +## Working with FD-Shifts + +To use `fd-shifts` you need to set the following environment variables ```bash export EXPERIMENT_ROOT_DIR=/absolute/path/to/your/experiments @@ -133,7 +141,7 @@ export DATASET_ROOT_DIR=/absolute/path/to/datasets ``` Alternatively, you may write them to a file and source that before running -`fd_shifts`, e.g. +`fd-shifts`, e.g. ```bash mv example.env .env @@ -145,6 +153,8 @@ Then edit `.env` to your needs and run source .env ``` +To get an overview of available subcommands, run `fd-shifts --help`. + ### Data Folder Requirements For the predefined experiments we expect the data to be in the following folder @@ -169,39 +179,41 @@ structure relative to the folder you set for `$DATASET_ROOT_DIR`. └── camelyon17_v1.0 ``` -For information regarding where to download these datasets from and what you have to do with them please check out [the documentation](./docs/datasets.md). +For information regarding where to download these datasets from and what you have to do with them please check out the [dataset documentation](./docs/datasets.md). ### Training To get a list of all fully qualified names for all experiments in the paper, use ```bash -fd_shifts list +fd-shifts list-experiments ``` -You can reproduce the results of the paper either all at once: +To run training for a specific experiment: ```bash -fd_shifts launch +fd-shifts train --experiment=svhn_paper_sweep/devries_bbsvhn_small_conv_do1_run1_rew2.2 ``` -Some at a time: +Alternatively, run training from a custom configuration file: ```bash -fd_shifts launch --model=devries --dataset=cifar10 +fd-shifts train --config=path/to/config/file ``` -Or one at a time (use `fd_shifts list` to find the names of experiments): +Check out `fd-shifts train --help` for more training options. + +The `fd-shifts-launch` cli allows for running multiple experiments, e.g. filtered by dataset: ```bash -fd_shifts launch --name=fd-shifts/svhn_paper_sweep/devries_bbsvhn_small_conv_do1_run1_rew2.2 +fd-shifts-launch --mode=train --dataset=cifar10 ``` -Check out `fd_shifts launch --help` for more filtering options. +Check out `fd-shifts-launch --help` for more filtering options. You can add custom experiment filters via the `register_filter` decorator. See [experiments/launcher.py](./fd_shifts/experiments/launcher.py) for an example. ### Model Weights -All pretrained model weights used for the benchmark can be found on Zenodo under the following links: +All pretrained model weights used for ["A Call to Reflect on Evaluation Practices for Failure Detection in Image Classification"](https://openreview.net/pdf?id=YnkGMIh0gvX) can be found on Zenodo under the following links: - [iWildCam-2020-Wilds](https://zenodo.org/record/7620946) - [iWildCam-2020-Wilds (OpenSet Training)](https://zenodo.org/record/7621150) @@ -215,15 +227,27 @@ All pretrained model weights used for the benchmark can be found on Zenodo under ### Inference -To run inference for one of the experiments, append `--mode=test` to any of the -commands above. +To run inference for one of the experiments: + +```bash +fd-shifts test --experiment=svhn_paper_sweep/devries_bbsvhn_small_conv_do1_run1_rew2.2 +``` + +Analogously, with the `fd-shifts-launch` cli: + +```bash +fd-shifts-launch --mode=test --dataset=cifar10 +``` ### Analysis -To run analysis for some of the predefined experiments, set `--mode=analysis` in -any of the commands above. +To run analysis for one of the experiments: + +```bash +fd-shifts analysis --experiment=svhn_paper_sweep/devries_bbsvhn_small_conv_do1_run1_rew2.2 +``` -To run analysis over an already available set of model outputs the outputs have +To run analysis over an already available set of inference outputs the outputs have to be in the following format: For a classifier with `d` outputs and `N` samples in total (over all tested @@ -299,6 +323,12 @@ external_confids_dist.npz NxM ``` +To load inference output from different locations than `$EXPERIMENT_ROOT_DIR`, you can specify one or multiple directories in the `FD_SHIFTS_STORE_PATH` environment variable (multiple paths are separated by `:`): + +```bash +export FD_SHIFTS_STORE_PATH=/absolute/path/to/fd-shifts/inference/output +``` + You may also use the `ExperimentData` class to load your data in another way. You also have to provide an adequate config, where all test datasets and query parameters are set. Check out the config files in `fd_shifts/configs` including diff --git a/docs/publications/iclr_2023.md b/docs/publications/iclr_2023.md new file mode 100644 index 0000000..1f560b1 --- /dev/null +++ b/docs/publications/iclr_2023.md @@ -0,0 +1,64 @@ +# Reproducing ["A Call to Reflect on Evaluation Practices for Failure Detection in Image Classification"](https://openreview.net/pdf?id=YnkGMIh0gvX) +For installation and general usage, follow the [FD-Shifts instructions](../../README.md). + +## Data Folder Requirements + +For the predefined experiments we expect the data to be in the following folder +structure relative to the folder you set for `$DATASET_ROOT_DIR`. + +``` +<$DATASET_ROOT_DIR> +├── breeds +│ └── ILSVRC ⇒ ../imagenet/ILSVRC +├── imagenet +│ ├── ILSVRC +├── cifar10 +├── cifar100 +├── corrupt_cifar10 +├── corrupt_cifar100 +├── svhn +├── tinyimagenet +├── tinyimagenet_resize +├── wilds_animals +│ └── iwildcam_v2.0 +└── wilds_camelyon + └── camelyon17_v1.0 +``` + +For information regarding where to download these datasets from and what you have to do with them please check out the [dataset documentation](../datasets.md). + +## Training + +To get a list of all fully qualified names for all experiments in the paper, use + +```bash +fd-shifts list-experiments --custom-filter=iclr2023 +``` + +To reproduce all results of the paper: + +```bash +fd-shifts-launch --mode=train --custom-filter=iclr2023 +fd-shifts-launch --mode=test --custom-filter=iclr2023 +fd-shifts-launch --mode=analysis --custom-filter=iclr2023 +``` + +### Model Weights + +All pretrained model weights used for the benchmark can be found on Zenodo under the following links: + +- [iWildCam-2020-Wilds](https://zenodo.org/record/7620946) +- [iWildCam-2020-Wilds (OpenSet Training)](https://zenodo.org/record/7621150) +- [BREEDS-ENTITY-13](https://zenodo.org/record/7621249) +- [CAMELYON-17-Wilds](https://zenodo.org/record/7621456) +- [CIFAR-100](https://zenodo.org/record/7622086) +- [CIFAR-100 (superclasses)](https://zenodo.org/record/7622116) +- [CIFAR-10](https://zenodo.org/record/7622047) +- [SVHN](https://zenodo.org/record/7622152) +- [SVHN (OpenSet Training)](https://zenodo.org/record/7622177) + +### Create results tables + +```bash +fd-shifts report +``` diff --git a/docs/publications/miccai_2023.md b/docs/publications/miccai_2023.md new file mode 100644 index 0000000..e69de29 From ea499d73d262e63c46d89b18ee6d0093b234bb41 Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Mon, 17 Jun 2024 10:44:22 +0200 Subject: [PATCH 121/136] Update Readme with version tag reference --- docs/publications/iclr_2023.md | 3 +++ docs/publications/miccai_2023.md | 7 +++++++ fd_shifts/experiments/publications.py | 2 ++ 3 files changed, 12 insertions(+) diff --git a/docs/publications/iclr_2023.md b/docs/publications/iclr_2023.md index 1f560b1..13e96f8 100644 --- a/docs/publications/iclr_2023.md +++ b/docs/publications/iclr_2023.md @@ -1,4 +1,7 @@ # Reproducing ["A Call to Reflect on Evaluation Practices for Failure Detection in Image Classification"](https://openreview.net/pdf?id=YnkGMIh0gvX) + +> :information_source: The original code publication can be accessed under the version tag [v.0.1.0](https://codebase.helmholtz.cloud/hi-dkfz/iml/failure-detection-benchmark/-/tree/v0.1.0?ref_type=tags). The instructions here describe how to reproduce the results with the current benchmark version. + For installation and general usage, follow the [FD-Shifts instructions](../../README.md). ## Data Folder Requirements diff --git a/docs/publications/miccai_2023.md b/docs/publications/miccai_2023.md index e69de29..bb15eab 100644 --- a/docs/publications/miccai_2023.md +++ b/docs/publications/miccai_2023.md @@ -0,0 +1,7 @@ +# Reproducing ["Understanding Silent Failures in Medical Image Classification"](https://arxiv.org/abs/2307.14729) + +> :information_source: The original code publication can be accessed under the version tag [](). The instructions here describe how to reproduce the results with the current benchmark version. + +For installation and general usage, follow the [FD-Shifts instructions](../../README.md). + +> :construction: WIP diff --git a/fd_shifts/experiments/publications.py b/fd_shifts/experiments/publications.py index 37bcb27..39f482d 100644 --- a/fd_shifts/experiments/publications.py +++ b/fd_shifts/experiments/publications.py @@ -1,3 +1,5 @@ +# Experiments for "A Call to Reflect on Evaluation Practices for Failure Detection in +# Image Classification". The original code can be accessed under the version tag v.0.1.0. ICLR2023 = [ "animals_paper_sweep/confidnet_bbresnet50_do0_run1_rew2.2", "animals_paper_sweep/confidnet_bbresnet50_do0_run2_rew2.2", From d14a47491ab77665a3f490527cb6e3c54af6548d Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Mon, 17 Jun 2024 15:29:21 +0200 Subject: [PATCH 122/136] Make launch a subcommand --- README.md | 10 +-- docs/publications/iclr_2023.md | 6 +- fd_shifts/experiments/launcher.py | 139 +++++++++++++----------------- fd_shifts/main.py | 15 ++-- pyproject.toml | 1 - 5 files changed, 79 insertions(+), 92 deletions(-) diff --git a/README.md b/README.md index c2ceaa6..bb6c2f9 100644 --- a/README.md +++ b/README.md @@ -203,13 +203,13 @@ fd-shifts train --config=path/to/config/file Check out `fd-shifts train --help` for more training options. -The `fd-shifts-launch` cli allows for running multiple experiments, e.g. filtered by dataset: +The `launch` subcommand allows for running multiple experiments, e.g. filtered by dataset: ```bash -fd-shifts-launch --mode=train --dataset=cifar10 +fd-shifts launch --mode=train --dataset=cifar10 ``` -Check out `fd-shifts-launch --help` for more filtering options. You can add custom experiment filters via the `register_filter` decorator. See [experiments/launcher.py](./fd_shifts/experiments/launcher.py) for an example. +Check out `fd-shifts launch --help` for more filtering options. You can add custom experiment filters via the `register_filter` decorator. See [experiments/launcher.py](./fd_shifts/experiments/launcher.py) for an example. ### Model Weights @@ -233,10 +233,10 @@ To run inference for one of the experiments: fd-shifts test --experiment=svhn_paper_sweep/devries_bbsvhn_small_conv_do1_run1_rew2.2 ``` -Analogously, with the `fd-shifts-launch` cli: +Analogously, with the `launch` subcommand: ```bash -fd-shifts-launch --mode=test --dataset=cifar10 +fd-shifts launch --mode=test --dataset=cifar10 ``` ### Analysis diff --git a/docs/publications/iclr_2023.md b/docs/publications/iclr_2023.md index 13e96f8..fc5b974 100644 --- a/docs/publications/iclr_2023.md +++ b/docs/publications/iclr_2023.md @@ -41,9 +41,9 @@ fd-shifts list-experiments --custom-filter=iclr2023 To reproduce all results of the paper: ```bash -fd-shifts-launch --mode=train --custom-filter=iclr2023 -fd-shifts-launch --mode=test --custom-filter=iclr2023 -fd-shifts-launch --mode=analysis --custom-filter=iclr2023 +fd-shifts launch --mode=train --custom-filter=iclr2023 +fd-shifts launch --mode=test --custom-filter=iclr2023 +fd-shifts launch --mode=analysis --custom-filter=iclr2023 ``` ### Model Weights diff --git a/fd_shifts/experiments/launcher.py b/fd_shifts/experiments/launcher.py index 2f1085c..a331541 100644 --- a/fd_shifts/experiments/launcher.py +++ b/fd_shifts/experiments/launcher.py @@ -20,7 +20,7 @@ """ -async def worker(name, queue: asyncio.Queue[str]): +async def worker(name, queue: asyncio.Queue[str], progress_bar=None): while True: # Get a "work item" out of the queue. cmd = await queue.get() @@ -37,21 +37,25 @@ async def worker(name, queue: asyncio.Queue[str]): else: logger.info(f"{name} running {cmd} finished") + if progress_bar is not None: + progress_bar.update(1) + # Notify the queue that the "work item" has been processed. queue.task_done() -async def run( +async def run_experiments( _experiments: list[str], mode: str, dry_run: bool, - overrides, + override: dict | None, ): if len(_experiments) == 0: print("Nothing to run") return Path("./logs").mkdir(exist_ok=True) + override = override if override is not None else {} # Create a queue that we will use to store our "workload". queue: asyncio.Queue[str] = asyncio.Queue() @@ -60,15 +64,15 @@ async def run( log_file_name = f"{datetime.now().strftime('%Y-%m-%d_%H-%M-%S')}-{experiment.replace('/', '_').replace('.','_')}" cmd = BASH_BASE_COMMAND.format( experiment=experiment, - overrides=" ".join(overrides), + overrides=" ".join([f"--{k}={v}" for k, v in override.items()]), mode=mode, ).strip() cmd = BASH_LOCAL_COMMAND.format( command=cmd, log_file_name=log_file_name ).strip() + rich.print(Syntax(cmd, "bash", word_wrap=True, background_color="default")) if not dry_run: - rich.print(Syntax(cmd, "bash", word_wrap=True, background_color="default")) queue.put_nowait(cmd) if queue.empty(): @@ -91,6 +95,37 @@ async def run( await asyncio.gather(*tasks, return_exceptions=True) +def launch(args): + _experiments = filter_experiments( + dataset=args.dataset, + dropout=args.dropout, + model=args.model, + backbone=args.backbone, + exclude_model=args.exclude_model, + exclude_backbone=args.exclude_backbone, + exclude_group=args.exclude_group, + run_nr=args.run, + rew=args.reward, + experiment=args.experiment, + ) + if args.custom_filter is not None: + print(f"Applying custom filter {args.custom_filter}...") + _experiments = get_filter(args.custom_filter)(_experiments) + + _experiments = list(_experiments) + + logger.info(f"Launching {len(_experiments)} experiments:") + for exp in _experiments: + logger.info(exp) + + if args.cluster: + raise NotImplementedError() + else: + asyncio.run( + run_experiments(_experiments, args.mode, args.dry_run, args.override) + ) + + def filter_experiments( dataset: str | None, dropout: int | None, @@ -174,6 +209,15 @@ def _inner_wrapper(func): return _inner_wrapper +def get_filter(name): + try: + return _FILTERS[name] + except KeyError as err: + raise ValueError( + f"Filter name '{name}' not valid. Available filters: {', '.join(_FILTERS)}" + ) from err + + @register_filter("iclr2023") def filter_iclr2023(experiments): from fd_shifts.experiments.publications import ICLR2023 @@ -184,55 +228,9 @@ def is_valid(exp): return filter(is_valid, experiments) -def launch( - dataset: str | None, - dropout: int | None, - model: str | None, - backbone: str | None, - exclude_model: str | None, - exclude_backbone: str | None, - exclude_group: str | None, - mode: str, - dry_run: bool, - run_nr: int | None, - rew: float | None, - cluster: bool, - experiment: str | None, - custom_filter: str | None, - overrides, -): - _experiments = filter_experiments( - dataset, - dropout, - model, - backbone, - exclude_model, - exclude_backbone, - exclude_group, - run_nr, - rew, - experiment, - ) - - if custom_filter is not None: - print(f"Applying custom filter {custom_filter}...") - _experiments = _FILTERS[custom_filter](_experiments) - - _experiments = list(_experiments) - - print(f"Launching {len(_experiments)} experiments:") - for exp in _experiments: - rich.print(exp) - - if cluster: - raise NotImplementedError() - else: - asyncio.run(run(_experiments, mode, dry_run, overrides)) - - def add_filter_arguments(parser: argparse.ArgumentParser): parser.add_argument("--dataset", default=None, type=str) - parser.add_argument("--dropout", default=None, type=int, choices=(0, 1)) + parser.add_argument("--dropout", default=None, type=int, help="0 or 1") parser.add_argument( "--model", default=None, type=str, choices=("vit", "dg", "devries", "confidnet") ) @@ -255,32 +253,17 @@ def add_filter_arguments(parser: argparse.ArgumentParser): def add_launch_arguments(parser: argparse.ArgumentParser): add_filter_arguments(parser) parser.add_argument("--dry-run", action="store_true") + parser.add_argument("--mode", required=True, choices=("train", "test", "analysis")) + parser.add_argument("--cluster", action="store_true") + # https://jsonargparse.readthedocs.io/en/stable/#dict-items parser.add_argument( - "--mode", default="train", choices=("train", "test", "analysis") + "--override", + type=dict, + default=None, + help=( + "Additional configurations passed to each `fd-shifts {mode}` call can be " + "specified via `--override.key=value` (e.g. " + "`override.config.trainer.batch_size=64`)" + ), ) - parser.add_argument("--cluster", action="store_true") return parser - - -def main(): - parser = argparse.ArgumentParser() - parser = add_launch_arguments(parser) - args, unknown = parser.parse_known_args() - - launch( - dataset=args.dataset, - dropout=args.dropout, - model=args.model, - backbone=args.backbone, - exclude_model=args.exclude_model, - exclude_backbone=args.exclude_backbone, - exclude_group=args.exclude_group, - mode=args.mode, - dry_run=args.dry_run, - run_nr=args.run, - rew=args.reward, - cluster=args.cluster, - experiment=args.experiment, - custom_filter=args.custom_filter, - overrides=unknown, - ) diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 24155da..5fe964e 100644 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -19,7 +19,7 @@ from omegaconf import OmegaConf from rich.pretty import pretty_repr -from fd_shifts import reporting +from fd_shifts import logger, reporting from fd_shifts.configs import Config, DataConfig, OutputPathsPerMode from fd_shifts.experiments import launcher from fd_shifts.experiments.configs import list_experiment_configs @@ -600,6 +600,11 @@ def get_parser() -> tuple[ArgumentParser, dict[str, ArgumentParser]]: subparsers["report"] = subparser subcommands.add_subcommand("report", subparser) + subparser = ArgumentParser() + launcher.add_launch_arguments(subparser) + subparsers["launch"] = subparser + subcommands.add_subcommand("launch", subparser) + experiment_choices = list_experiment_configs() for name, func in __subcommands.items(): subparser = ArgumentParser() @@ -632,8 +637,6 @@ def config_from_parser(parser: ArgumentParser, args: Namespace) -> Config: def main() -> None: """Main entry point for the command line interface.""" - from fd_shifts import logger - setup_logging() parser, subparsers = get_parser() @@ -643,10 +646,12 @@ def main() -> None: if args.command == "list-experiments": _list_experiments(args["list-experiments"]) return - - if args.command == "report": + elif args.command == "report": reporting.main(**args.report) return + elif args.command == "launch": + launcher.launch(args["launch"]) + return config = config_from_parser(parser, args) diff --git a/pyproject.toml b/pyproject.toml index ae05856..a96a90e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -64,7 +64,6 @@ docs = ["jupyterlab", "notebook", "ipykernel"] launcher = ["parallel-ssh"] [project.scripts] -fd-shifts-launch = "fd_shifts.experiments.launcher:main" fd-shifts = "fd_shifts.main:main" [tool.setuptools_scm] From e6a081780b0c5e8383ea5a9fdcfe127a52ae25e7 Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Mon, 17 Jun 2024 15:57:01 +0200 Subject: [PATCH 123/136] remove old cli --- fd_shifts/cli.py | 53 ------------------------------------------------ 1 file changed, 53 deletions(-) delete mode 100644 fd_shifts/cli.py diff --git a/fd_shifts/cli.py b/fd_shifts/cli.py deleted file mode 100644 index 7fca900..0000000 --- a/fd_shifts/cli.py +++ /dev/null @@ -1,53 +0,0 @@ -import argparse - -from fd_shifts import reporting -from fd_shifts.experiments import get_all_experiments, launcher -from fd_shifts.loaders import prepare - - -def _list_experiments(args) -> None: - _experiments = launcher.filter_experiments( - dataset=args.dataset, - dropout=args.dropout, - model=args.model, - backbone=args.backbone, - exclude_model=args.exclude_model, - run_nr=args.run, - rew=args.reward, - name=args.name, - ) - - for exp in _experiments: - print(exp.to_path()) - - -def main() -> None: - """Entry point for the command line interface - - This gets installed as a script named `fd_shifts` by pip. - """ - parser = argparse.ArgumentParser() - subparsers = parser.add_subparsers(title="commands") - parser.set_defaults(command=lambda _: parser.print_help()) - - list_parser = subparsers.add_parser("list") - launcher.add_filter_arguments(list_parser) - list_parser.set_defaults(command=_list_experiments) - - launch_parser = subparsers.add_parser("launch") - launcher.add_arguments(launch_parser) - launch_parser.set_defaults(command=launcher.main) - - reporting_parser = subparsers.add_parser("reporting") - reporting_parser.set_defaults(command=lambda _: reporting.main("./results")) - - prepare_parser = subparsers.add_parser("prepare") - prepare_parser = prepare.add_arguments(prepare_parser) - prepare_parser.set_defaults(command=lambda _: prepare.main) - - args = parser.parse_args() - args.command(args) - - -if __name__ == "__main__": - main() From 24f7142a89b27511d3cc9ccde949b237d6bc67d5 Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Mon, 17 Jun 2024 16:08:01 +0200 Subject: [PATCH 124/136] add AUGRC to default metrics --- fd_shifts/configs/__init__.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/fd_shifts/configs/__init__.py b/fd_shifts/configs/__init__.py index 1632717..b40e93b 100644 --- a/fd_shifts/configs/__init__.py +++ b/fd_shifts/configs/__init__.py @@ -306,6 +306,7 @@ class ConfidMetricsConfig(_IterableMixin): "fpr@95tpr", "e-aurc", "aurc", + "augrc", ] ) val: list[str] = field( @@ -316,6 +317,7 @@ class ConfidMetricsConfig(_IterableMixin): "fpr@95tpr", "e-aurc", "aurc", + "augrc", ] ) test: list[str] = field( @@ -327,6 +329,7 @@ class ConfidMetricsConfig(_IterableMixin): "ece", "e-aurc", "aurc", + "augrc", "fpr@95tpr", ] ) From a0fe0bcb9c8e4dc7906c7197ef2c2fce0f98aec1 Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Tue, 18 Jun 2024 11:30:46 +0200 Subject: [PATCH 125/136] Remove development code --- fd_shifts/analysis/bootstrap.py | 41 +++++---------- fd_shifts/analysis/rc_stats.py | 2 +- fd_shifts/experiments/tracker.py | 3 +- fd_shifts/main.py | 2 - fd_shifts/models/__init__.py | 3 +- fd_shifts/models/clip_model.py | 67 ------------------------- fd_shifts/reporting/__init__.py | 14 ++---- fd_shifts/reporting/report_bootstrap.py | 15 +----- pyproject.toml | 1 - 9 files changed, 21 insertions(+), 127 deletions(-) delete mode 100644 fd_shifts/models/clip_model.py diff --git a/fd_shifts/analysis/bootstrap.py b/fd_shifts/analysis/bootstrap.py index 8087597..a754b27 100644 --- a/fd_shifts/analysis/bootstrap.py +++ b/fd_shifts/analysis/bootstrap.py @@ -27,8 +27,8 @@ def bootstrap_new_class_data_iterator( iid_set_name, dataset_name, n_bs: int, - stratified: bool, bs_size: int, + stratified: bool = False, ): assert data.correct is not None iid_set_ix = data.dataset_name_to_idx(iid_set_name) @@ -137,7 +137,9 @@ def __filter_if_exists(data: npt.NDArray[Any] | None, mask): ) -def bootstrap_iterator(data: ExperimentData, n_bs: int, stratified: bool, bs_size: int): +def bootstrap_iterator( + data: ExperimentData, n_bs: int, bs_size: int, stratified: bool = False +): n = len(data.labels) bs_indices = np.vstack( [ @@ -183,11 +185,8 @@ def __filter_if_exists(data: npt.NDArray[Any] | None, mask): class AnalysisBS(Analysis): """Analysis wrapper function for bootstrap analysis""" - def __init__( - self, *args, stratified_bs: bool, n_bs: int, no_iid: bool = False, **kwargs - ): + def __init__(self, *args, n_bs: int, no_iid: bool = False, **kwargs): super().__init__(*args, **kwargs) - self.stratified_bs = stratified_bs self.n_bs = n_bs self._create_bs_indices_only = False self.no_iid = no_iid @@ -239,7 +238,6 @@ def register_and_perform_studies(self, bs_size: int = None): self.query_studies.iid_study, new_class, self.n_bs, - self.stratified_bs, bs_size, ): self._perform_bootstrap_study(bs_idx, data) @@ -261,7 +259,7 @@ def register_and_perform_studies(self, bs_size: int = None): logger.info(f"Performing bootstrap study {self.study_name}") for bs_idx, data in bootstrap_iterator( - study_data, self.n_bs, self.stratified_bs, bs_size + study_data, self.n_bs, bs_size ): self._perform_bootstrap_study(bs_idx, data) @@ -303,9 +301,11 @@ def _create_results_csv(self, study_data: ExperimentData, bs_index: int): backbone, self.cfg.exp.fold, confid_key, - study_data.mcd_softmax_mean.shape[0] - if "mcd" in confid_key - else study_data.softmax_output.shape[0], + ( + study_data.mcd_softmax_mean.shape[0] + if "mcd" in confid_key + else study_data.softmax_output.shape[0] + ), bs_index, ] submit_list += [ @@ -327,8 +327,6 @@ def _create_results_csv(self, study_data: ExperimentData, bs_index: int): def run_bs_analysis( config: configs.Config, - regenerate_bs_indices: bool = False, - stratified_bs: bool = False, n_bs: int = 500, iid_only: bool = False, no_iid: bool = False, @@ -338,24 +336,10 @@ def run_bs_analysis( Args: config (configs.Config): Complete Configuration - regenerate_bs_indices (bool, optional): If False, using previously generated - bootstrap indices. Defaults to True. - stratified_bs (bool, optional): Whether to stratify by failure label. Defaults to - False. n_bs (int, optional): Number of bootstrap samples. Defaults to 500. """ - if regenerate_bs_indices: - raise NotImplementedError("No longer writing out bs indices!") - - if stratified_bs: - raise ValueError("Stratified BS sampling makes no sense!") - path_to_test_dir = config.test.dir - analysis_out_dir = ( - config.exp.output_paths.analysis - / f"bootstrap{'-stratified' if stratified_bs else ''}" - ) - + analysis_out_dir = config.exp.output_paths.analysis / "bootstrap" analysis_out_dir.mkdir(exist_ok=True, parents=True) query_studies = config.eval.query_studies @@ -413,7 +397,6 @@ def run_bs_analysis( threshold_plot_confid=None, qual_plot_confid=None, cf=config, - stratified_bs=stratified_bs, n_bs=n_bs, no_iid=no_iid, ) diff --git a/fd_shifts/analysis/rc_stats.py b/fd_shifts/analysis/rc_stats.py index 1238436..563be2e 100644 --- a/fd_shifts/analysis/rc_stats.py +++ b/fd_shifts/analysis/rc_stats.py @@ -543,7 +543,7 @@ def evaluate_ci( residuals: npt.NDArray[Any] = None, labels: npt.NDArray[Any] = None, n_bs: int = 10000, - stratified: bool = True, + stratified: bool = False, ): """Compute confidence intervals based on bootstrapping.""" confids = confids if confids is not None else self.confids diff --git a/fd_shifts/experiments/tracker.py b/fd_shifts/experiments/tracker.py index 2b86707..81def99 100644 --- a/fd_shifts/experiments/tracker.py +++ b/fd_shifts/experiments/tracker.py @@ -60,11 +60,10 @@ def list_analysis_output_files(config: Config) -> list: def list_bootstrap_analysis_output_files( config: Config, - stratified_bs: bool, filter_study_name: list = None, original_new_class_mode: bool = False, ) -> list: - subdir = f"bootstrap{'-stratified' if stratified_bs else ''}/" + subdir = "bootstrap/" files = [] for study_name, testset in config.eval.query_studies: # Keep only studies that are in filter_study_name diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 70802df..9d31918 100755 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -693,8 +693,6 @@ def main() -> None: if args.command == "analysis_bootstrap": __subcommands[args.command]( config=config, - regenerate_bs_indices=args[args.command].regenerate_bs_indices, - stratified_bs=args[args.command].stratified_bs, n_bs=args[args.command].n_bs, iid_only=args[args.command].iid_only, no_iid=args[args.command].no_iid, diff --git a/fd_shifts/models/__init__.py b/fd_shifts/models/__init__.py index 6313a28..37356bf 100644 --- a/fd_shifts/models/__init__.py +++ b/fd_shifts/models/__init__.py @@ -1,12 +1,11 @@ import pytorch_lightning as pl -from fd_shifts.models import clip_model, confidnet_model, devries_model, vit_model +from fd_shifts.models import confidnet_model, devries_model, vit_model _model_factory: dict[str, type[pl.LightningModule]] = { "confidnet_model": confidnet_model.Module, "devries_model": devries_model.net, "vit_model": vit_model.net, - "clip_model": clip_model.ClipOodModel, } diff --git a/fd_shifts/models/clip_model.py b/fd_shifts/models/clip_model.py deleted file mode 100644 index 5fa8812..0000000 --- a/fd_shifts/models/clip_model.py +++ /dev/null @@ -1,67 +0,0 @@ -from __future__ import annotations - -from pathlib import Path -from typing import TYPE_CHECKING - -import open_clip as oc -import pytorch_lightning as pl -from torchvision import transforms - -from fd_shifts import logger -from fd_shifts.utils import to_dict - -if TYPE_CHECKING: - from fd_shifts import configs - - -class ClipOodModel(pl.LightningModule): - def __init__(self, cfg: configs.Config): - super().__init__() - self.save_hyperparameters(to_dict(cfg)) - self.conf = cfg - - self.class_prefix = cfg.model.clip_class_prefix - self.model, _, self.preprocess = oc.create_model_and_transforms( - "ViT-B-16", - pretrained="laion2b_s34b_b88k", - ) - self.tokenizer = oc.get_tokenizer("ViT-B-16") - - def on_test_start(self): - self.datasets = list( - map(lambda d: d.dataset, self.trainer.datamodule.test_dataloader()) - ) - - if hasattr(self.datasets[0], "classes"): - classes = self.datasets[0].classes - else: - classes = list(map(str, range(self.conf.data.num_classes))) - - if self.class_prefix is not None: - classes = list(map(lambda c: f"{self.class_prefix} {c}", classes)) - - logger.debug(f"{classes=}") - - text = self.tokenizer(classes).to(self.device) - self.text_features = self.model.encode_text(text) - self.text_features /= self.text_features.norm(dim=-1, keepdim=True) - - def test_step(self, batch, batch_idx, dataset_idx): - x, y = batch - - image_features = self.model.encode_image(x) - image_features /= image_features.norm(dim=-1, keepdim=True) - - logits = image_features @ self.text_features.T - - return { - "logits": logits, - "logits_dist": None, - "labels": y, - "confid": None, - "confid_dist": None, - "encoded": None, - } - - def load_only_state_dict(self, path: str | Path) -> None: - pass diff --git a/fd_shifts/reporting/__init__.py b/fd_shifts/reporting/__init__.py index 6e9b423..dadfb97 100644 --- a/fd_shifts/reporting/__init__.py +++ b/fd_shifts/reporting/__init__.py @@ -45,7 +45,7 @@ def _load_file(config: Config, name: str, file: str): def _load_experiment( - name: str, bootstrap_analysis: bool = False, stratified_bs: bool = False + name: str, bootstrap_analysis: bool = False ) -> pd.DataFrame | None: from fd_shifts.main import omegaconf_resolve @@ -57,7 +57,7 @@ def _load_experiment( data = list( map( functools.partial(_load_file, config, name), - list_bootstrap_analysis_output_files(config, stratified_bs), + list_bootstrap_analysis_output_files(config), ) ) else: @@ -94,11 +94,7 @@ def _load_experiment( return data -def load_all( - bootstrap_analysis: bool = False, - stratified_bs: bool = False, - include_vit: bool = False, -): +def load_all(bootstrap_analysis: bool = False, include_vit: bool = False): dataframes = [] # TODO: make this async with concurrent.futures.ProcessPoolExecutor(max_workers=12) as executor: @@ -107,9 +103,7 @@ def load_all( lambda d: d is not None, executor.map( functools.partial( - _load_experiment, - bootstrap_analysis=bootstrap_analysis, - stratified_bs=stratified_bs, + _load_experiment, bootstrap_analysis=bootstrap_analysis ), filter( ( diff --git a/fd_shifts/reporting/report_bootstrap.py b/fd_shifts/reporting/report_bootstrap.py index 771ce5f..074c952 100644 --- a/fd_shifts/reporting/report_bootstrap.py +++ b/fd_shifts/reporting/report_bootstrap.py @@ -34,7 +34,6 @@ def _load_bootstrap_experiment( name: str, - stratified_bs: bool = False, filter_study_name: list = None, filter_dataset: list = None, original_new_class_mode: bool = False, @@ -51,7 +50,7 @@ def _load_bootstrap_experiment( map( functools.partial(_load_file, config, name), list_bootstrap_analysis_output_files( - config, stratified_bs, filter_study_name, original_new_class_mode + config, filter_study_name, original_new_class_mode ), ) ) @@ -78,7 +77,6 @@ def _load_bootstrap_experiment( def load_all( - stratified_bs: bool = False, filter_study_name: list = None, filter_dataset: list = None, original_new_class_mode: bool = False, @@ -93,7 +91,6 @@ def load_all( executor.map( functools.partial( _load_bootstrap_experiment, - stratified_bs=stratified_bs, filter_study_name=filter_study_name, filter_dataset=filter_dataset, original_new_class_mode=original_new_class_mode, @@ -163,14 +160,12 @@ def create_plots_per_study( dset: str, metrics: list, out_dir: Path, - stratified_bs: bool = False, original_new_class_mode: bool = False, metric_hparam_search: str = None, ): logger.info(f"Reporting bootstrap results for dataset '{dset}', study '{study}'") data_raw = load_all( - stratified_bs=stratified_bs, filter_study_name=[study], filter_dataset=[dset], original_new_class_mode=original_new_class_mode, @@ -526,14 +521,9 @@ def ranking_change_arrows(out_dir: Path): def report_bootstrap_results( - out_path: str | Path = "./output/bootstrap", - stratified_bs: bool = False, - metric_hparam_search: str = None, + out_path: str | Path = "./output/bootstrap", metric_hparam_search: str = None ): """""" - if stratified_bs: - out_path = "./output/bootstrap-stratified" - if metric_hparam_search is not None: out_path = str(out_path) + f"-optimized-{metric_hparam_search}" @@ -558,7 +548,6 @@ def report_bootstrap_results( dset=dset, metrics=metrics, out_dir=data_dir, - stratified_bs=stratified_bs, original_new_class_mode=False, metric_hparam_search=metric_hparam_search, ): dict(study=study, dset=dset) diff --git a/pyproject.toml b/pyproject.toml index e7222de..590577b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -22,7 +22,6 @@ dependencies = [ "numpy>=1.22.2", "ogb>=1.3.1", "omegaconf>=2.1.1", - "open_clip_torch", "opencv-python-headless", "pandarallel>=1.6.5", "pandas>=1.2.3", From a6de8da57ae7365b36904a004debb13bad0ab6e1 Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Tue, 18 Jun 2024 15:13:44 +0200 Subject: [PATCH 126/136] Add bootstrap analysis script and update Readme --- README.md | 1 + docs/publications/augrc_2024.md | 69 ++++ fd_shifts/experiments/cluster.py | 159 -------- fd_shifts/experiments/launcher.py | 10 + fd_shifts/experiments/publications.py | 523 ++++++++++++++++++++++++++ fd_shifts/reporting/__init__.py | 10 - scripts/analysis_bootstrap.py | 187 +++++++++ 7 files changed, 790 insertions(+), 169 deletions(-) create mode 100644 docs/publications/augrc_2024.md delete mode 100644 fd_shifts/experiments/cluster.py create mode 100644 scripts/analysis_bootstrap.py diff --git a/README.md b/README.md index bb6c2f9..08c843b 100644 --- a/README.md +++ b/README.md @@ -128,6 +128,7 @@ scoring functions check out the This repository contains the benchmarks for the following publications: - ["A Call to Reflect on Evaluation Practices for Failure Detection in Image Classification"](https://openreview.net/pdf?id=YnkGMIh0gvX) → [Documentation for reproducing](./docs/publications/iclr_2023.md) - ["Understanding Silent Failures in Medical Image Classification"](https://arxiv.org/abs/2307.14729) (For the visualization tool presented in that work please see [sf-visuals](https://github.com/IML-DKFZ/sf-visuals).) → [Documentation for reproducing](./docs/publications/miccai_2023.md) +- ["Overcoming Common Flaws in the Evaluation of Selective Classification Systems"]() → [Documentation for reproducing](./docs/publications/augrc_2024.md) While the following section on [working with FD-Shifts](#working-with-fd-shifts) describes the general usage, descriptions for reproducing specific publications are documented [here](./docs/publications). diff --git a/docs/publications/augrc_2024.md b/docs/publications/augrc_2024.md new file mode 100644 index 0000000..19fe9a7 --- /dev/null +++ b/docs/publications/augrc_2024.md @@ -0,0 +1,69 @@ +# Reproducing ["Overcoming Common Flaws in the Evaluation of Selective Classification Systems"]() +For installation and general usage, follow the [FD-Shifts instructions](../../README.md). + +## Data Folder Requirements + +For the predefined experiments we expect the data to be in the following folder +structure relative to the folder you set for `$DATASET_ROOT_DIR`. + +``` +<$DATASET_ROOT_DIR> +├── breeds +│ └── ILSVRC ⇒ ../imagenet/ILSVRC +├── imagenet +│ ├── ILSVRC +├── cifar10 +├── cifar100 +├── corrupt_cifar10 +├── corrupt_cifar100 +├── svhn +├── tinyimagenet +├── tinyimagenet_resize +├── wilds_animals +│ └── iwildcam_v2.0 +└── wilds_camelyon + └── camelyon17_v1.0 +``` + +For information regarding where to download these datasets from and what you have to do with them please check out the [dataset documentation](../datasets.md). + +## Training & Analysis + +To get a list of all fully qualified names for all experiments in the paper, use + +```bash +fd-shifts list-experiments --custom-filter=augrc2024 +``` + +To reproduce all results of the paper: + +```bash +fd-shifts launch --mode=train --custom-filter=augrc2024 +fd-shifts launch --mode=test --custom-filter=augrc2024 +fd-shifts launch --mode=analysis --custom-filter=augrc2024 +``` + +```bash +python scripts/analysis_bootstrap.py --custom-filter=augrc2024 +``` + +### Model Weights + +All pretrained model weights used for the benchmark can be found on Zenodo under the following links: + +- [iWildCam-2020-Wilds](https://zenodo.org/record/7620946) +- [iWildCam-2020-Wilds (OpenSet Training)](https://zenodo.org/record/7621150) +- [BREEDS-ENTITY-13](https://zenodo.org/record/7621249) +- [CAMELYON-17-Wilds](https://zenodo.org/record/7621456) +- [CIFAR-100](https://zenodo.org/record/7622086) +- [CIFAR-100 (superclasses)](https://zenodo.org/record/7622116) +- [CIFAR-10](https://zenodo.org/record/7622047) +- [SVHN](https://zenodo.org/record/7622152) +- [SVHN (OpenSet Training)](https://zenodo.org/record/7622177) + +### Create results tables + +```bash +fd-shifts report +fd-shifts report_bootstrap +``` diff --git a/fd_shifts/experiments/cluster.py b/fd_shifts/experiments/cluster.py deleted file mode 100644 index 6ab1ad8..0000000 --- a/fd_shifts/experiments/cluster.py +++ /dev/null @@ -1,159 +0,0 @@ -import re -import subprocess -from typing import Any - -from rich import print -from rich.syntax import Syntax - -from fd_shifts import experiments - -# -R "select[hname!='e230-dgx2-2']" \ - -BASH_BSUB_COMMAND = r""" -bsub -gpu num=1:j_exclusive=yes:gmem={gmem}\ - -L /bin/bash \ - -q gpu \ - -u 'till.bungert@dkfz-heidelberg.de' \ - -B {nodes} \ - -g /t974t/train \ - -J "{name}" \ - bash -li -c 'set -o pipefail; echo $LSB_JOBID && source .envrc && {command} |& tee -a "/home/t974t/logs/$LSB_JOBID.log"' -""" - -BASH_BASE_COMMAND = r""" -_fd_shifts_exec {overrides} exp.mode={mode} -""" - - -def get_nodes(mode: str): - match mode: - case "train" | "train_test": - return "-sp 36" - case _: - return "" - - -def get_gmem(mode: str, model: str): - match mode: - case "train" | "train_test": - match model: - case "vit": - return "23G" - case _: - return "23G" - case _: - match model: - case "vit": - return "23G" - case _: - return "23G" - - -def update_overrides( - overrides: dict[str, Any], iid_only: bool = False, mode: str = "train_test" -) -> dict[str, Any]: - if mode in ["train", "train_test"] and overrides.get("trainer.batch_size", -1) > 32: - accum = overrides["trainer.batch_size"] // 32 - overrides["trainer.batch_size"] = 32 - overrides["trainer.accumulate_grad_batches"] = accum - - if mode in ["test"]: - overrides["trainer.batch_size"] = 256 - - if iid_only: - overrides["eval.query_studies.noise_study"] = [] - overrides["eval.query_studies.in_class_study"] = [] - overrides["eval.query_studies.new_class_study"] = [] - - return overrides - - -def submit( - _experiments: list[experiments.Experiment], mode: str, dry_run: bool, iid_only: bool -): - try: - from pssh.clients import SSHClient - from pssh.exceptions import Timeout - except ModuleNotFoundError as exc: - raise ModuleNotFoundError( - "You need to run pip install parallel-ssh to submit to the cluster" - ) from exc - - if len(_experiments) == 0: - print("Nothing to run") - return - - if not dry_run: - client = SSHClient("odcf-worker02.inet.dkfz-heidelberg.de") - - for experiment in _experiments: - try: - # if path := experiment.overrides().get( - # "trainer.callbacks.training_stages.pretrained_backbone_path" - # ): - # sync_to_dir_remote( - # path.replace("${EXPERIMENT_ROOT_DIR%/}/", "fd-shifts/"), - # dry_run=dry_run, - # ) - - overrides = update_overrides( - experiment.overrides(), iid_only=iid_only, mode=mode - ) - cmd = BASH_BASE_COMMAND.format( - overrides=" ".join(f"{k}={v}" for k, v in overrides.items()), - mode=mode, - ).strip() - - print( - Syntax( - re.sub(r"([^,]) ", "\\1 \\\n\t", cmd), - "bash", - word_wrap=True, - background_color="default", - ) - ) - - cmd = BASH_BSUB_COMMAND.format( - name=experiment.to_path().relative_to("fd-shifts"), - command=cmd, - nodes=get_nodes(mode), - gmem=get_gmem(mode, experiment.model), - ).strip() - - print( - Syntax( - cmd, - "bash", - word_wrap=True, - background_color="default", - ) - ) - - if dry_run: - continue - - with client.open_shell(read_timeout=1) as shell: - shell.run("cd ~/Projects/failure-detection-benchmark") - shell.run("source .envrc") - shell.run(cmd) - - try: - for line in shell.stdout: - print(line) - except Timeout: - pass - - try: - for line in shell.stderr: - print(line) - except Timeout: - pass - - for line in shell.stdout: - print(line) - - for line in shell.stderr: - print(line) - - except subprocess.CalledProcessError: - continue diff --git a/fd_shifts/experiments/launcher.py b/fd_shifts/experiments/launcher.py index a331541..b71e695 100644 --- a/fd_shifts/experiments/launcher.py +++ b/fd_shifts/experiments/launcher.py @@ -228,6 +228,16 @@ def is_valid(exp): return filter(is_valid, experiments) +@register_filter("augrc2024") +def filter_augrc2024(experiments): + from fd_shifts.experiments.publications import AUGRC2024 + + def is_valid(exp): + return exp in AUGRC2024 + + return filter(is_valid, experiments) + + def add_filter_arguments(parser: argparse.ArgumentParser): parser.add_argument("--dataset", default=None, type=str) parser.add_argument("--dropout", default=None, type=int, help="0 or 1") diff --git a/fd_shifts/experiments/publications.py b/fd_shifts/experiments/publications.py index 39f482d..70968f0 100644 --- a/fd_shifts/experiments/publications.py +++ b/fd_shifts/experiments/publications.py @@ -991,3 +991,526 @@ "vit/wilds_camelyon_modelvit_bbvit_lr0.003_bs128_run3_do1_rew0", "vit/wilds_camelyon_modelvit_bbvit_lr0.003_bs128_run4_do1_rew0", ] + +# Experiments for "Overcoming Common Flaws in the Evaluation of Selective Classification +# Systems". +AUGRC2024 = [ + "animals_paper_sweep/confidnet_bbresnet50_do0_run1_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do0_run2_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do0_run3_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do0_run4_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do0_run5_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do1_run1_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do1_run2_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do1_run3_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do1_run4_rew2.2", + "animals_paper_sweep/confidnet_bbresnet50_do1_run5_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do0_run1_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do0_run2_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do0_run3_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do0_run4_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do0_run5_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do1_run1_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do1_run2_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do1_run3_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do1_run4_rew2.2", + "animals_paper_sweep/devries_bbresnet50_do1_run5_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do0_run1_rew10", + "animals_paper_sweep/dg_bbresnet50_do0_run1_rew15", + "animals_paper_sweep/dg_bbresnet50_do0_run1_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do0_run1_rew3", + "animals_paper_sweep/dg_bbresnet50_do0_run1_rew6", + "animals_paper_sweep/dg_bbresnet50_do0_run2_rew10", + "animals_paper_sweep/dg_bbresnet50_do0_run2_rew15", + "animals_paper_sweep/dg_bbresnet50_do0_run2_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do0_run2_rew3", + "animals_paper_sweep/dg_bbresnet50_do0_run2_rew6", + "animals_paper_sweep/dg_bbresnet50_do0_run3_rew10", + "animals_paper_sweep/dg_bbresnet50_do0_run3_rew15", + "animals_paper_sweep/dg_bbresnet50_do0_run3_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do0_run3_rew3", + "animals_paper_sweep/dg_bbresnet50_do0_run3_rew6", + "animals_paper_sweep/dg_bbresnet50_do0_run4_rew10", + "animals_paper_sweep/dg_bbresnet50_do0_run4_rew15", + "animals_paper_sweep/dg_bbresnet50_do0_run4_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do0_run4_rew3", + "animals_paper_sweep/dg_bbresnet50_do0_run4_rew6", + "animals_paper_sweep/dg_bbresnet50_do0_run5_rew10", + "animals_paper_sweep/dg_bbresnet50_do0_run5_rew15", + "animals_paper_sweep/dg_bbresnet50_do0_run5_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do0_run5_rew3", + "animals_paper_sweep/dg_bbresnet50_do0_run5_rew6", + "animals_paper_sweep/dg_bbresnet50_do1_run1_rew10", + "animals_paper_sweep/dg_bbresnet50_do1_run1_rew15", + "animals_paper_sweep/dg_bbresnet50_do1_run1_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do1_run1_rew3", + "animals_paper_sweep/dg_bbresnet50_do1_run1_rew6", + "animals_paper_sweep/dg_bbresnet50_do1_run2_rew10", + "animals_paper_sweep/dg_bbresnet50_do1_run2_rew15", + "animals_paper_sweep/dg_bbresnet50_do1_run2_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do1_run2_rew3", + "animals_paper_sweep/dg_bbresnet50_do1_run2_rew6", + "animals_paper_sweep/dg_bbresnet50_do1_run3_rew10", + "animals_paper_sweep/dg_bbresnet50_do1_run3_rew15", + "animals_paper_sweep/dg_bbresnet50_do1_run3_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do1_run3_rew3", + "animals_paper_sweep/dg_bbresnet50_do1_run3_rew6", + "animals_paper_sweep/dg_bbresnet50_do1_run4_rew10", + "animals_paper_sweep/dg_bbresnet50_do1_run4_rew15", + "animals_paper_sweep/dg_bbresnet50_do1_run4_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do1_run4_rew3", + "animals_paper_sweep/dg_bbresnet50_do1_run4_rew6", + "animals_paper_sweep/dg_bbresnet50_do1_run5_rew10", + "animals_paper_sweep/dg_bbresnet50_do1_run5_rew15", + "animals_paper_sweep/dg_bbresnet50_do1_run5_rew2.2", + "animals_paper_sweep/dg_bbresnet50_do1_run5_rew3", + "animals_paper_sweep/dg_bbresnet50_do1_run5_rew6", + "breeds_paper_sweep/confidnet_bbresnet50_do0_run1_rew2.2", + "breeds_paper_sweep/confidnet_bbresnet50_do0_run2_rew2.2", + "breeds_paper_sweep/confidnet_bbresnet50_do1_run1_rew2.2", + "breeds_paper_sweep/confidnet_bbresnet50_do1_run2_rew2.2", + "breeds_paper_sweep/devries_bbresnet50_do0_run1_rew2.2", + "breeds_paper_sweep/devries_bbresnet50_do0_run2_rew2.2", + "breeds_paper_sweep/devries_bbresnet50_do1_run1_rew2.2", + "breeds_paper_sweep/devries_bbresnet50_do1_run2_rew2.2", + "breeds_paper_sweep/dg_bbresnet50_do0_run1_rew10", + "breeds_paper_sweep/dg_bbresnet50_do0_run1_rew15", + "breeds_paper_sweep/dg_bbresnet50_do0_run1_rew2.2", + "breeds_paper_sweep/dg_bbresnet50_do0_run1_rew3", + "breeds_paper_sweep/dg_bbresnet50_do0_run1_rew6", + "breeds_paper_sweep/dg_bbresnet50_do0_run2_rew10", + "breeds_paper_sweep/dg_bbresnet50_do0_run2_rew15", + "breeds_paper_sweep/dg_bbresnet50_do0_run2_rew2.2", + "breeds_paper_sweep/dg_bbresnet50_do0_run2_rew3", + "breeds_paper_sweep/dg_bbresnet50_do0_run2_rew6", + "breeds_paper_sweep/dg_bbresnet50_do1_run1_rew10", + "breeds_paper_sweep/dg_bbresnet50_do1_run1_rew15", + "breeds_paper_sweep/dg_bbresnet50_do1_run1_rew2.2", + "breeds_paper_sweep/dg_bbresnet50_do1_run1_rew3", + "breeds_paper_sweep/dg_bbresnet50_do1_run1_rew6", + "breeds_paper_sweep/dg_bbresnet50_do1_run2_rew10", + "breeds_paper_sweep/dg_bbresnet50_do1_run2_rew15", + "breeds_paper_sweep/dg_bbresnet50_do1_run2_rew2.2", + "breeds_paper_sweep/dg_bbresnet50_do1_run2_rew3", + "breeds_paper_sweep/dg_bbresnet50_do1_run2_rew6", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run10_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run1_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run2_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run3_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run4_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run5_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run6_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run7_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run8_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do0_run9_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run10_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run1_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run2_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run3_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run4_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run5_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run6_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run7_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run8_rew2.2", + "camelyon_paper_sweep/confidnet_bbresnet50_do1_run9_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run10_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run1_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run2_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run3_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run4_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run5_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run6_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run7_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run8_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do0_run9_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run10_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run1_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run2_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run3_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run4_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run5_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run6_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run7_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run8_rew2.2", + "camelyon_paper_sweep/devries_bbresnet50_do1_run9_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run10_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run10_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run10_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run10_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run1_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run1_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run1_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run1_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run2_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run2_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run2_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run2_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run3_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run3_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run3_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run3_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run4_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run4_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run4_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run4_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run5_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run5_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run5_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run5_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run6_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run6_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run6_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run6_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run7_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run7_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run7_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run7_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run8_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run8_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run8_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run8_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do0_run9_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do0_run9_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do0_run9_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do0_run9_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run10_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run10_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run10_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run10_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run1_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run1_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run1_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run1_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run2_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run2_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run2_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run2_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run3_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run3_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run3_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run3_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run4_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run4_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run4_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run4_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run5_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run5_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run5_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run5_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run6_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run6_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run6_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run6_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run7_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run7_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run7_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run7_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run8_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run8_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run8_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run8_rew6", + "camelyon_paper_sweep/dg_bbresnet50_do1_run9_rew10", + "camelyon_paper_sweep/dg_bbresnet50_do1_run9_rew2.2", + "camelyon_paper_sweep/dg_bbresnet50_do1_run9_rew3", + "camelyon_paper_sweep/dg_bbresnet50_do1_run9_rew6", + "cifar100_paper_sweep/confidnet_bbvgg13_do0_run1_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do0_run2_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do0_run3_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do0_run4_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do0_run5_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do1_run1_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do1_run2_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do1_run3_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do1_run4_rew2.2", + "cifar100_paper_sweep/confidnet_bbvgg13_do1_run5_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do0_run1_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do0_run2_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do0_run3_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do0_run4_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do0_run5_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do1_run1_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do1_run2_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do1_run3_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do1_run4_rew2.2", + "cifar100_paper_sweep/devries_bbvgg13_do1_run5_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do0_run1_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do0_run1_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do0_run1_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do0_run1_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do0_run1_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do0_run1_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do0_run1_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do0_run2_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do0_run2_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do0_run2_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do0_run2_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do0_run2_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do0_run2_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do0_run2_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do0_run3_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do0_run3_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do0_run3_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do0_run3_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do0_run3_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do0_run3_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do0_run3_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do0_run4_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do0_run4_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do0_run4_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do0_run4_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do0_run4_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do0_run4_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do0_run4_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do0_run5_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do0_run5_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do0_run5_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do0_run5_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do0_run5_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do0_run5_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do0_run5_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do1_run1_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do1_run1_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do1_run1_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do1_run1_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do1_run1_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do1_run1_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do1_run1_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do1_run2_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do1_run2_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do1_run2_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do1_run2_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do1_run2_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do1_run2_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do1_run2_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do1_run3_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do1_run3_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do1_run3_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do1_run3_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do1_run3_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do1_run3_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do1_run3_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do1_run4_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do1_run4_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do1_run4_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do1_run4_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do1_run4_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do1_run4_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do1_run4_rew6", + "cifar100_paper_sweep/dg_bbvgg13_do1_run5_rew10", + "cifar100_paper_sweep/dg_bbvgg13_do1_run5_rew12", + "cifar100_paper_sweep/dg_bbvgg13_do1_run5_rew15", + "cifar100_paper_sweep/dg_bbvgg13_do1_run5_rew2.2", + "cifar100_paper_sweep/dg_bbvgg13_do1_run5_rew20", + "cifar100_paper_sweep/dg_bbvgg13_do1_run5_rew3", + "cifar100_paper_sweep/dg_bbvgg13_do1_run5_rew6", + "cifar10_paper_sweep/confidnet_bbvgg13_do0_run1_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do0_run2_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do0_run3_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do0_run4_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do0_run5_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do1_run1_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do1_run2_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do1_run3_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do1_run4_rew2.2", + "cifar10_paper_sweep/confidnet_bbvgg13_do1_run5_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do0_run1_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do0_run2_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do0_run3_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do0_run4_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do0_run5_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do1_run1_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do1_run2_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do1_run3_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do1_run4_rew2.2", + "cifar10_paper_sweep/devries_bbvgg13_do1_run5_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do0_run1_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do0_run1_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do0_run1_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do0_run1_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do0_run2_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do0_run2_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do0_run2_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do0_run2_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do0_run3_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do0_run3_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do0_run3_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do0_run3_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do0_run4_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do0_run4_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do0_run4_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do0_run4_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do0_run5_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do0_run5_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do0_run5_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do0_run5_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do1_run1_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do1_run1_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do1_run1_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do1_run1_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do1_run2_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do1_run2_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do1_run2_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do1_run2_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do1_run3_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do1_run3_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do1_run3_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do1_run3_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do1_run4_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do1_run4_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do1_run4_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do1_run4_rew6", + "cifar10_paper_sweep/dg_bbvgg13_do1_run5_rew10", + "cifar10_paper_sweep/dg_bbvgg13_do1_run5_rew2.2", + "cifar10_paper_sweep/dg_bbvgg13_do1_run5_rew3", + "cifar10_paper_sweep/dg_bbvgg13_do1_run5_rew6", + "supercifar_paper_sweep/confidnet_bbvgg13_do0_run1_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do0_run2_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do0_run3_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do0_run4_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do0_run5_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do1_run1_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do1_run2_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do1_run3_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do1_run4_rew2.2", + "supercifar_paper_sweep/confidnet_bbvgg13_do1_run5_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do0_run1_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do0_run2_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do0_run3_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do0_run4_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do0_run5_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do1_run1_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do1_run2_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do1_run3_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do1_run4_rew2.2", + "supercifar_paper_sweep/devries_bbvgg13_do1_run5_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do0_run1_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do0_run1_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do0_run1_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do0_run1_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do0_run1_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do0_run1_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do0_run1_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do0_run2_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do0_run2_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do0_run2_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do0_run2_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do0_run2_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do0_run2_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do0_run2_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do0_run3_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do0_run3_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do0_run3_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do0_run3_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do0_run3_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do0_run3_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do0_run3_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do0_run4_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do0_run4_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do0_run4_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do0_run4_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do0_run4_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do0_run4_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do0_run4_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do0_run5_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do0_run5_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do0_run5_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do0_run5_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do0_run5_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do0_run5_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do0_run5_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do1_run1_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do1_run1_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do1_run1_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do1_run1_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do1_run1_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do1_run1_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do1_run1_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do1_run2_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do1_run2_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do1_run2_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do1_run2_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do1_run2_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do1_run2_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do1_run2_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do1_run3_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do1_run3_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do1_run3_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do1_run3_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do1_run3_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do1_run3_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do1_run3_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do1_run4_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do1_run4_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do1_run4_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do1_run4_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do1_run4_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do1_run4_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do1_run4_rew6", + "supercifar_paper_sweep/dg_bbvgg13_do1_run5_rew10", + "supercifar_paper_sweep/dg_bbvgg13_do1_run5_rew12", + "supercifar_paper_sweep/dg_bbvgg13_do1_run5_rew15", + "supercifar_paper_sweep/dg_bbvgg13_do1_run5_rew2.2", + "supercifar_paper_sweep/dg_bbvgg13_do1_run5_rew20", + "supercifar_paper_sweep/dg_bbvgg13_do1_run5_rew3", + "supercifar_paper_sweep/dg_bbvgg13_do1_run5_rew6", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do0_run1_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do0_run2_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do0_run3_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do0_run4_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do0_run5_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do1_run1_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do1_run2_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do1_run3_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do1_run4_rew2.2", + "svhn_paper_sweep/confidnet_bbsvhn_small_conv_do1_run5_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do0_run1_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do0_run2_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do0_run3_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do0_run4_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do0_run5_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do1_run1_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do1_run2_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do1_run3_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do1_run4_rew2.2", + "svhn_paper_sweep/devries_bbsvhn_small_conv_do1_run5_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run1_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run1_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run1_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run1_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run2_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run2_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run2_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run2_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run3_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run3_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run3_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run3_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run4_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run4_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run4_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run4_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run5_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run5_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run5_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do0_run5_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run1_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run1_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run1_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run1_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run2_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run2_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run2_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run2_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run3_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run3_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run3_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run3_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run4_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run4_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run4_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run4_rew6", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run5_rew10", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run5_rew2.2", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run5_rew3", + "svhn_paper_sweep/dg_bbsvhn_small_conv_do1_run5_rew6", +] diff --git a/fd_shifts/reporting/__init__.py b/fd_shifts/reporting/__init__.py index dadfb97..ce80284 100644 --- a/fd_shifts/reporting/__init__.py +++ b/fd_shifts/reporting/__init__.py @@ -527,7 +527,6 @@ def main( "DG-TEMP-MLS", ] data = data[data.confid.isin(CONFIDS_TO_REPORT)] - # data = data[data.confid.isin(CONFIDS_TO_REPORT + ["VIT-"+c for c in CONFIDS_TO_REPORT])] # -- Aggregate across runs --------------------------------------------------------- data, std = tables.aggregate_over_runs( @@ -581,12 +580,3 @@ def main( metric1_higherbetter=False, metric2_higherbetter=False, ) - - rank_comparison_metric( - data, - data_dir, - metric1="aurc-ba", - metric2="augrc-ba", - metric1_higherbetter=False, - metric2_higherbetter=False, - ) diff --git a/scripts/analysis_bootstrap.py b/scripts/analysis_bootstrap.py new file mode 100644 index 0000000..1351db3 --- /dev/null +++ b/scripts/analysis_bootstrap.py @@ -0,0 +1,187 @@ +import argparse +import asyncio +import multiprocessing +import subprocess +from datetime import datetime +from pathlib import Path + +import rich +from rich.syntax import Syntax +from tqdm import tqdm + +from fd_shifts.experiments.launcher import ( + add_filter_arguments, + filter_experiments, + get_filter, +) + +BASH_LOCAL_COMMAND = r""" +bash -c 'set -o pipefail; {command} |& tee -a "./logs_bootstrap/{log_file_name}.log"' +""" + +BASH_BASE_COMMAND = r""" +fd-shifts analysis_bootstrap \ + --experiment={experiment} \ + --n_bs={n_bs} \ + --exclude_noise_study={exclude_noise_study} \ + --no_iid={no_iid} \ + --iid_only={iid_only} {overrides} +""" + + +def run_command(command): + subprocess.run(command, shell=True) + + +async def run_experiments( + _experiments: list[str], + dry_run: bool, + iid_only: bool = False, + no_iid: bool = False, + exclude_noise_study: bool = False, + n_bs: int = 500, + num_workers: int = 12, +): + if len(_experiments) == 0: + print("Nothing to run") + return + + Path("./logs").mkdir(exist_ok=True) + + queue = [] + + for experiment in _experiments: + log_file_name = f"{datetime.now().strftime('%Y-%m-%d_%H-%M-%S')}-{experiment.replace('/', '_').replace('.','_')}" + + overrides = {} + + cmd = BASH_BASE_COMMAND.format( + experiment=experiment, + n_bs=n_bs, + iid_only=iid_only, + no_iid=no_iid, + exclude_noise_study=exclude_noise_study, + overrides=" ".join(f"--config.{k}={v}" for k, v in overrides.items()), + ).strip() + + cmd = BASH_LOCAL_COMMAND.format( + command=cmd, log_file_name=log_file_name + ).strip() + rich.print(Syntax(cmd, "bash", word_wrap=True, background_color="default")) + if not dry_run: + queue.append(cmd) + + if queue == []: + return + + # Create a tqdm progress bar + with tqdm(total=len(queue), desc="Experiments") as pbar: + # Create a pool of worker processes + pool = multiprocessing.Pool(processes=num_workers) + # Map the list of commands to the worker pool + for _ in pool.imap_unordered(run_command, queue): + pbar.update() + # Close the pool to prevent any more tasks from being submitted + pool.close() + # Wait for all processes to finish + pool.join() + + +def launch( + dataset: str | None, + dropout: int | None, + model: str | None, + backbone: str | None, + exclude_model: str | None, + exclude_backbone: str | None, + exclude_group: str | None, + dry_run: bool, + run: int | None, + reward: float | None, + cluster: bool, + experiment: str | None, + iid_only: bool, + no_iid: bool, + exclude_noise_study: bool, + n_bs: int, + num_workers: int, + custom_filter: str | None, +): + _experiments = list( + filter_experiments( + dataset, + dropout, + model, + backbone, + exclude_model, + exclude_backbone, + exclude_group, + run, + reward, + experiment, + ) + ) + + if custom_filter is not None: + print(f"Applying custom filter {custom_filter}...") + _experiments = get_filter(custom_filter)(_experiments) + + _experiments = list(_experiments) + + print(f"Launching {len(_experiments)} experiments:") + for exp in _experiments: + rich.print(exp) + + if cluster: + raise NotImplementedError() + else: + asyncio.run( + run_experiments( + _experiments, + dry_run, + iid_only, + no_iid, + exclude_noise_study, + n_bs, + num_workers, + ) + ) + + +def add_arguments(parser: argparse.ArgumentParser): + add_filter_arguments(parser) + parser.add_argument("--dry-run", action="store_true") + parser.add_argument("--cluster", action="store_true") + parser.add_argument("--iid-only", action="store_true") + parser.add_argument("--no_iid", action="store_true") + parser.add_argument("--exclude-noise-study", action="store_true") + parser.add_argument("--n-bs", default=500, type=int) + parser.add_argument("--num-workers", default=2, type=int) + return parser + + +if __name__ == "__main__": + parser = argparse.ArgumentParser() + parser = add_arguments(parser) + args = parser.parse_args() + + launch( + dataset=args.dataset, + dropout=args.dropout, + model=args.model, + backbone=args.backbone, + exclude_model=args.exclude_model, + exclude_backbone=args.exclude_backbone, + exclude_group=args.exclude_group, + dry_run=args.dry_run, + run=args.run, + reward=args.reward, + cluster=args.cluster, + experiment=args.experiment, + iid_only=args.iid_only, + no_iid=args.no_iid, + exclude_noise_study=args.exclude_noise_study, + n_bs=args.n_bs, + num_workers=args.num_workers, + custom_filter=args.custom_filter, + ) From 3fde06db1db54d50cacfac3963f6d6c2972d7fd0 Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Wed, 19 Jun 2024 16:51:49 +0200 Subject: [PATCH 127/136] set python version 3.11 in CI --- .github/workflows/pytest.yml | 4 ++-- .gitlab-ci.yml | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/pytest.yml b/.github/workflows/pytest.yml index 351085a..dca650c 100644 --- a/.github/workflows/pytest.yml +++ b/.github/workflows/pytest.yml @@ -7,7 +7,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: ["3.10"] + python-version: ["3.11"] steps: - uses: actions/checkout@v3 @@ -19,7 +19,7 @@ jobs: run: | python -m pip install --upgrade pip pip install .[dev] - python -m ipykernel install --user --name py310 + python -m ipykernel install --user --name py311 - name: Test library run: | python -m pytest -W ignore -m "not slow" diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 0fd2404..3dab672 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -8,7 +8,7 @@ variables: # controls whether the test job is executed TEST_NOTEBOOKS: "false" -image: "python:3.10" +image: "python:3.11" test:package: stage: test @@ -32,6 +32,6 @@ test:notebooks: before_script: - python --version - pip install .[dev] .[docs] - - python -m ipykernel install --user --name py310 + - python -m ipykernel install --user --name py311 script: - python -m pytest -W ignore --nbmake $NOTEBOOK_DIR From 0e9abc5666fe7ed6e6519927acddc14fe24b5e45 Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Thu, 20 Jun 2024 11:14:14 +0200 Subject: [PATCH 128/136] numpy v2.0.0 not supported by faiss --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 590577b..f982285 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -19,7 +19,7 @@ dependencies = [ "loguru", "matplotlib>=3.3.4", "medmnist", - "numpy>=1.22.2", + "numpy>=1.22.2,<2.0.0", "ogb>=1.3.1", "omegaconf>=2.1.1", "opencv-python-headless", From d3efd909e34069e6697815983cd8b9449f09a67b Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Thu, 20 Jun 2024 15:30:14 +0200 Subject: [PATCH 129/136] Update pyproject.toml, preventing jsonargparse and faiss incompatibility --- pyproject.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index a96a90e..be47c72 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -15,11 +15,11 @@ dependencies = [ "hydra-zen", "imageio>=2.9.0", "ipython", - "jsonargparse[signatures]", + "jsonargparse[signatures]>=4.29.0,<4.30.0", "loguru", "matplotlib>=3.3.4", "medmnist", - "numpy>=1.22.2", + "numpy>=1.22.2,<2.0.0", "ogb>=1.3.1", "omegaconf>=2.1.1", "opencv-python-headless", From df8b86b6aa21b2729183571389179d92523e9392 Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Fri, 21 Jun 2024 14:30:42 +0200 Subject: [PATCH 130/136] Update Readme --- README.md | 4 ++-- docs/publications/augrc_2024.md | 21 ++++++++++++++++++ docs/publications/augrc_2024_overview.png | Bin 0 -> 556764 bytes .../iclr_2023_overview.png} | Bin pyproject.toml | 2 +- 5 files changed, 24 insertions(+), 3 deletions(-) create mode 100644 docs/publications/augrc_2024_overview.png rename docs/{new_overview.png => publications/iclr_2023_overview.png} (100%) diff --git a/README.md b/README.md index 08c843b..506bb8a 100644 --- a/README.md +++ b/README.md @@ -40,7 +40,7 @@

- +
Holistic perspective on failure detection. Detecting failures should be seen in the context of the overarching goal of preventing silent failures of a classifier, which includes two tasks: @@ -79,7 +79,7 @@ If you use FD-Shifts please cite our [paper](https://openreview.net/pdf?id=YnkGM ``` > **Note** -> This repository also contains the benchmarks for our follow-up study ["Understanding Silent Failures in Medical Image Classification"](https://arxiv.org/abs/2307.14729). For the visualization tool presented in that work please see [sf-visuals](https://github.com/IML-DKFZ/sf-visuals). +> This repository also contains the benchmarks for our follow-up study ["Understanding Silent Failures in Medical Image Classification"](https://arxiv.org/abs/2307.14729) (for the visualization tool presented in that work please see [sf-visuals](https://github.com/IML-DKFZ/sf-visuals)) and for ["Overcoming Common Flaws in the Evaluation of Selective Classification Systems"](). ## Table Of Contents diff --git a/docs/publications/augrc_2024.md b/docs/publications/augrc_2024.md index 19fe9a7..731242e 100644 --- a/docs/publications/augrc_2024.md +++ b/docs/publications/augrc_2024.md @@ -1,6 +1,27 @@ # Reproducing ["Overcoming Common Flaws in the Evaluation of Selective Classification Systems"]() For installation and general usage, follow the [FD-Shifts instructions](../../README.md). +## Abstract +> Selective Classification, wherein models can reject low-confidence predictions, promises reliable translation of machine-learning based classification systems to real-world scenarios such as clinical diagnostics. While current evaluation of these systems typically assumes fixed working points based on pre-defined rejection thresholds, methodological progress requires benchmarking the general performance of systems akin to the AUROC in standard classification. In this work, we define 5 requirements for multi-threshold metrics in selective classification regarding task alignment, interpretability, and flexibility, and show how current approaches fail to meet them. We propose the Area under the Generalized Risk Coverage curve (AUGRC), which meets all requirements and can be directly interpreted as the average risk of undetected failures. We empirically demonstrate the relevance of AUGRC on a comprehensive benchmark spanning 6 data sets and 13 confidence scoring functions. We find that the proposed metric substantially changes metric rankings on 5 out of the 6 data sets. + +

+

+ +
+ The AUGRC metric based on Generalized Risk overcomes common flaws in current evaluation of Selective classification (SC). a) Refined task definition for SC. Analogously to standard classification, we distinguish between holistic evaluation for method development and benchmarking using multi-threshold metrics versus evaluation of specific application scenarios at pre-determined working points. The current most prevalent multi-threshold metric in SC, AURC, is based on Selective Risk, a concept for working point evaluation that is not suitable for aggregation over rejection thresholds (red arrow). To fill this gap, we formulate the new concept of Generalized Risk and a corresponding metric, AUGRC (green arrow). b) We formalize our perspective on SC evaluation by identifying five key requirements for multi-threshold metrics and analyze how previous metrics fail to fulfill them. Abbreviations, CSF: Confidence Scoring Function. +
+
+

+ +## AUGRC implementation +In [rc_stats.py](../../fd_shifts/analysis/rc_stats.py), we provide the standalone `RiskCoverageStats` class for evaluating metrics related to Risk-Coverage curves, including an implementation of the AUGRC. + +To evaluate the AUGRC for your SC model predictions: +```python +from fd_shifts.analysis.rc_stats import RiskCoverageStats +augrc = RiskCoverageStats(confids=my_confids, residuals=my_loss_values).augrc +``` + ## Data Folder Requirements For the predefined experiments we expect the data to be in the following folder diff --git a/docs/publications/augrc_2024_overview.png b/docs/publications/augrc_2024_overview.png new file mode 100644 index 0000000000000000000000000000000000000000..1ba2058730cc9fa4376a77508baa78d36710e8ee GIT binary patch literal 556764 zcmeFZS6EYR*Db7w3L>JQ6cJES5RqOY9Z^7f5$U}IDIrMj5v7PUks4w^q)C_FK|w$u zq4yRM37yb;;J@>H@3;5KfAadA?lUgXWUY12GRBx=t}sn?Md}OJFPu7cidyOE6YW!{ zs350KotvjP2Yy2(*VT0D)M-w;$B#7~9xFbEJHlO_Ia^rSJhFyc+Gs1v35bb3Jay_` zjFq{$_R|OVep=9)oBzaeb6s%p)PDOmLfahi{aeS)&Tm-rF7x;#W8+_pmwz>%BImz; z&9Aog8^ve7rPr9IxHhUPZSC;bz%90$UFy8|?pv6fV@{RCcdA^FU1q&$bcc%>V|vPx z;WP_{HT-mO|E*;@bCJtCEMJq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D!4C|KXGP@-nRK Z;Ks=vKFz?jWgYy{JgKFcp?vk`{{ee@{`CL= literal 0 HcmV?d00001 diff --git a/docs/new_overview.png b/docs/publications/iclr_2023_overview.png similarity index 100% rename from docs/new_overview.png rename to docs/publications/iclr_2023_overview.png diff --git a/pyproject.toml b/pyproject.toml index f982285..bc483a6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -15,7 +15,7 @@ dependencies = [ "hydra-zen", "imageio>=2.9.0", "ipython", - "jsonargparse[signatures]", + "jsonargparse[signatures]>=4.29.0,<4.30.0", "loguru", "matplotlib>=3.3.4", "medmnist", From 00ccb04b1a2a2e0f7a4e5d3cefaf67f79fbd1397 Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Fri, 21 Jun 2024 14:33:29 +0200 Subject: [PATCH 131/136] Pass on custom filter option --- fd_shifts/experiments/launcher.py | 12 ++++++------ fd_shifts/main.py | 1 + 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/fd_shifts/experiments/launcher.py b/fd_shifts/experiments/launcher.py index b71e695..16a6c01 100644 --- a/fd_shifts/experiments/launcher.py +++ b/fd_shifts/experiments/launcher.py @@ -107,13 +107,8 @@ def launch(args): run_nr=args.run, rew=args.reward, experiment=args.experiment, + custom_filter=args.custom_filter, ) - if args.custom_filter is not None: - print(f"Applying custom filter {args.custom_filter}...") - _experiments = get_filter(args.custom_filter)(_experiments) - - _experiments = list(_experiments) - logger.info(f"Launching {len(_experiments)} experiments:") for exp in _experiments: logger.info(exp) @@ -137,6 +132,7 @@ def filter_experiments( run_nr: int | None, rew: float | None, experiment: str | None, + custom_filter: str | None, ) -> filter: _experiments = list_experiment_configs() @@ -195,6 +191,10 @@ def filter_experiments( if experiment is not None: _experiments = filter(lambda e: e == experiment, _experiments) + if custom_filter is not None: + logger.info(f"Applying custom filter {custom_filter}...") + _experiments = get_filter(custom_filter)(_experiments) + return _experiments diff --git a/fd_shifts/main.py b/fd_shifts/main.py index 9d31918..f9abfbd 100755 --- a/fd_shifts/main.py +++ b/fd_shifts/main.py @@ -585,6 +585,7 @@ def _list_experiments(args) -> None: run_nr=args.run, rew=args.reward, experiment=args.experiment, + custom_filter=args.custom_filter, ) for exp in sorted(_experiments): From 482003a20d0b5655e16991aa282193be54e6640e Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Thu, 27 Jun 2024 11:45:29 +0200 Subject: [PATCH 132/136] Fix reporting --- fd_shifts/reporting/__init__.py | 47 +++++++------------------ fd_shifts/reporting/report_bootstrap.py | 17 ++++----- 2 files changed, 20 insertions(+), 44 deletions(-) diff --git a/fd_shifts/reporting/__init__.py b/fd_shifts/reporting/__init__.py index ce80284..0e6d38b 100644 --- a/fd_shifts/reporting/__init__.py +++ b/fd_shifts/reporting/__init__.py @@ -14,7 +14,7 @@ list_bootstrap_analysis_output_files, ) -pandarallel.initialize() +pandarallel.initialize(verbose=1) DATASETS = ( "svhn", @@ -94,7 +94,7 @@ def _load_experiment( return data -def load_all(bootstrap_analysis: bool = False, include_vit: bool = False): +def load_all(bootstrap_analysis: bool = False, include_vit: bool = True): dataframes = [] # TODO: make this async with concurrent.futures.ProcessPoolExecutor(max_workers=12) as executor: @@ -107,11 +107,9 @@ def load_all(bootstrap_analysis: bool = False, include_vit: bool = False): ), filter( ( - (lambda exp: ("clip" not in exp)) + (lambda exp: True) if include_vit - else lambda exp: ( - ("clip" not in exp) and (not exp.startswith("vit")) - ) + else lambda exp: not exp.startswith("vit") ), list_experiment_configs(), ), @@ -193,9 +191,6 @@ def assign_hparams_from_names(data: pd.DataFrame) -> pd.DataFrame: .mask(data["backbone"] == "vit", "vit_") + data.model.where( data.backbone == "vit", data.name.str.split("_", expand=True)[0] - ).mask( - data.backbone == "vit", - data.name.str.split("model", expand=True)[1].str.split("_", expand=True)[0], ), # Encode every detail into confid name _confid=data.confid, @@ -511,23 +506,6 @@ def main( data = rename_confids(data) data = rename_studies(data) - CONFIDS_TO_REPORT = [ - "MSR", - "MLS", - "PE", - "MCD-MSR", - "MCD-PE", - "MCD-EE", - "DG-MCD-MSR", - "ConfidNet", - "DG-Res", - "Devries et al.", - "TEMP-MLS", - "DG-PE", - "DG-TEMP-MLS", - ] - data = data[data.confid.isin(CONFIDS_TO_REPORT)] - # -- Aggregate across runs --------------------------------------------------------- data, std = tables.aggregate_over_runs( data, @@ -550,15 +528,16 @@ def main( # # -- Relative error (evaluated across runs) -------------------------------------- metric_list = ["aurc", "e-aurc", "augrc", "e-augrc", "aurc-ba", "augrc-ba"] - data_dir_std = data_dir / "rel_std" - data_dir_std.mkdir(exist_ok=True, parents=True) - for m in metric_list: - std[m] = std[m].astype(float) / data[m].astype(float) - std = str_format_metrics(std) - for m in metric_list: - # lower is better for all these metrics - paper_results(std, m, False, data_dir_std) + # data_dir_std = data_dir / "rel_std" + # data_dir_std.mkdir(exist_ok=True, parents=True) + # for m in metric_list: + # std[m] = std[m].astype(float) / data[m].astype(float) + # std = str_format_metrics(std) + + # for m in metric_list: + # # lower is better for all these metrics + # paper_results(std, m, False, data_dir_std) # # -- Metric tables ----------------------------------------------------------------- for m in metric_list: diff --git a/fd_shifts/reporting/report_bootstrap.py b/fd_shifts/reporting/report_bootstrap.py index 074c952..9c95491 100644 --- a/fd_shifts/reporting/report_bootstrap.py +++ b/fd_shifts/reporting/report_bootstrap.py @@ -80,7 +80,7 @@ def load_all( filter_study_name: list = None, filter_dataset: list = None, original_new_class_mode: bool = False, - include_vit: bool = False, + include_vit: bool = True, ): dataframes = [] # TODO: make this async @@ -97,11 +97,9 @@ def load_all( ), filter( ( - (lambda exp: ("clip" not in exp)) + (lambda exp: True) if include_vit - else lambda exp: ( - ("clip" not in exp) and (not exp.startswith("vit")) - ) + else lambda exp: not exp.startswith("vit") ), list_experiment_configs(), ), @@ -169,6 +167,7 @@ def create_plots_per_study( filter_study_name=[study], filter_dataset=[dset], original_new_class_mode=original_new_class_mode, + include_vit=False, ) data_raw = assign_hparams_from_names(data_raw) @@ -315,7 +314,7 @@ def create_plots_per_study( def create_kendall_tau_plot(out_dir: Path): logger.info(f"Performing iid-study kendall tau analysis across datasets...") - data_raw = load_all(filter_study_name=["iid_study"]) + data_raw = load_all(filter_study_name=["iid_study"], include_vit=False) data_raw = assign_hparams_from_names(data_raw) processed_data = {} @@ -383,7 +382,7 @@ def ranking_change_arrows(out_dir: Path): _DATASETS = ["wilds_animals", "wilds_camelyon", "cifar10", "breeds"] - data_raw = load_all(filter_dataset=_DATASETS) + data_raw = load_all(filter_dataset=_DATASETS, include_vit=False) data_raw = assign_hparams_from_names(data_raw) mean_rank_dict = {} @@ -553,8 +552,6 @@ def report_bootstrap_results( ): dict(study=study, dset=dset) for dset, study in product(datasets, studies) } - # future_to_arg = {} - # future_to_arg[ # executor.submit(ranking_change_arrows, out_dir=data_dir) # ] = "" @@ -587,7 +584,7 @@ def report_bootstrap_results( executor.shutdown(wait=False, cancel_futures=True) logger.info( "Executor shut down. Kill running futures using\n" - "'ps -ef | grep 'main.py report_bootstrap' | grep -v grep | awk '{print $2}' | " + "'ps -ef | grep 'fd-shifts report_bootstrap' | grep -v grep | awk '{print $2}' | " "xargs -r kill -9'" ) raise From 86dc82b0dc2c14d433aa800a3472c9d9f42ef2c5 Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Thu, 27 Jun 2024 12:05:46 +0200 Subject: [PATCH 133/136] Update Readme with bibtex citations --- README.md | 12 ++++++++++++ docs/publications/augrc_2024.md | 5 +++++ docs/publications/iclr_2023.md | 12 ++++++++++++ docs/publications/miccai_2023.md | 16 ++++++++++++++-- 4 files changed, 43 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 506bb8a..20f9cba 100644 --- a/README.md +++ b/README.md @@ -81,6 +81,18 @@ If you use FD-Shifts please cite our [paper](https://openreview.net/pdf?id=YnkGM > **Note** > This repository also contains the benchmarks for our follow-up study ["Understanding Silent Failures in Medical Image Classification"](https://arxiv.org/abs/2307.14729) (for the visualization tool presented in that work please see [sf-visuals](https://github.com/IML-DKFZ/sf-visuals)) and for ["Overcoming Common Flaws in the Evaluation of Selective Classification Systems"](). +```bibtex +@inproceedings{ + bungert2023understanding, + title={Understanding silent failures in medical image classification}, + author={Bungert, Till J and Kobelke, Levin and Jaeger, Paul F}, + booktitle={International Conference on Medical Image Computing and Computer-Assisted Intervention}, + pages={400--410}, + year={2023}, + organization={Springer} +} +``` + ## Table Of Contents diff --git a/docs/publications/augrc_2024.md b/docs/publications/augrc_2024.md index 731242e..8a35494 100644 --- a/docs/publications/augrc_2024.md +++ b/docs/publications/augrc_2024.md @@ -1,6 +1,11 @@ # Reproducing ["Overcoming Common Flaws in the Evaluation of Selective Classification Systems"]() For installation and general usage, follow the [FD-Shifts instructions](../../README.md). +## Citing this Work +```bibtex + +``` + ## Abstract > Selective Classification, wherein models can reject low-confidence predictions, promises reliable translation of machine-learning based classification systems to real-world scenarios such as clinical diagnostics. While current evaluation of these systems typically assumes fixed working points based on pre-defined rejection thresholds, methodological progress requires benchmarking the general performance of systems akin to the AUROC in standard classification. In this work, we define 5 requirements for multi-threshold metrics in selective classification regarding task alignment, interpretability, and flexibility, and show how current approaches fail to meet them. We propose the Area under the Generalized Risk Coverage curve (AUGRC), which meets all requirements and can be directly interpreted as the average risk of undetected failures. We empirically demonstrate the relevance of AUGRC on a comprehensive benchmark spanning 6 data sets and 13 confidence scoring functions. We find that the proposed metric substantially changes metric rankings on 5 out of the 6 data sets. diff --git a/docs/publications/iclr_2023.md b/docs/publications/iclr_2023.md index fc5b974..18094ba 100644 --- a/docs/publications/iclr_2023.md +++ b/docs/publications/iclr_2023.md @@ -4,6 +4,18 @@ For installation and general usage, follow the [FD-Shifts instructions](../../README.md). +## Citing this Work +```bibtex +@inproceedings{ + jaeger2023a, + title={A Call to Reflect on Evaluation Practices for Failure Detection in Image Classification}, + author={Paul F Jaeger and Carsten Tim L{\"u}th and Lukas Klein and Till J. Bungert}, + booktitle={International Conference on Learning Representations}, + year={2023}, + url={https://openreview.net/forum?id=YnkGMIh0gvX} +} +``` + ## Data Folder Requirements For the predefined experiments we expect the data to be in the following folder diff --git a/docs/publications/miccai_2023.md b/docs/publications/miccai_2023.md index bb15eab..aa464cc 100644 --- a/docs/publications/miccai_2023.md +++ b/docs/publications/miccai_2023.md @@ -1,7 +1,19 @@ # Reproducing ["Understanding Silent Failures in Medical Image Classification"](https://arxiv.org/abs/2307.14729) -> :information_source: The original code publication can be accessed under the version tag [](). The instructions here describe how to reproduce the results with the current benchmark version. +> :information_source: The original code publication can be accessed under the version tag [?](). For installation and general usage, follow the [FD-Shifts instructions](../../README.md). -> :construction: WIP +## Citing this Work + +```bibtex +@inproceedings{ + bungert2023understanding, + title={Understanding silent failures in medical image classification}, + author={Bungert, Till J and Kobelke, Levin and Jaeger, Paul F}, + booktitle={International Conference on Medical Image Computing and Computer-Assisted Intervention}, + pages={400--410}, + year={2023}, + organization={Springer} +} +``` From e045cdc6adc9aa0f3ec5c06c48eedba8fcd47e92 Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 27 Jun 2024 14:40:05 +0200 Subject: [PATCH 134/136] docs: add miccai publication note --- docs/publications/miccai_2023.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/publications/miccai_2023.md b/docs/publications/miccai_2023.md index bb15eab..2afaa81 100644 --- a/docs/publications/miccai_2023.md +++ b/docs/publications/miccai_2023.md @@ -1,7 +1,7 @@ # Reproducing ["Understanding Silent Failures in Medical Image Classification"](https://arxiv.org/abs/2307.14729) -> :information_source: The original code publication can be accessed under the version tag [](). The instructions here describe how to reproduce the results with the current benchmark version. +> :information_source: The original code publication can be accessed under the version tag [v0.1.1](https://github.com/IML-DKFZ/fd-shifts/releases/tag/v0.1.1). -For installation and general usage, follow the [FD-Shifts instructions](../../README.md). +For installation and general usage, follow the [FD-Shifts instructions](https://github.com/IML-DKFZ/fd-shifts/blob/v0.1.1/README.md). > :construction: WIP From 2b88730dbe8970f34eeb0b04067523c331c77eed Mon Sep 17 00:00:00 2001 From: Till Bungert Date: Thu, 27 Jun 2024 14:43:04 +0200 Subject: [PATCH 135/136] chore: remove legacy config yamls --- fd_shifts/configs/config.yaml | 175 ------------------ fd_shifts/configs/data/__init__.py | 0 fd_shifts/configs/data/breeds_384_data.yaml | 44 ----- fd_shifts/configs/data/breeds_data.yaml | 51 ----- .../data/breeds_ood_test_384_data.yaml | 29 --- .../configs/data/breeds_ood_test_data.yaml | 30 --- fd_shifts/configs/data/chestMIMC_data.yaml | 37 ---- fd_shifts/configs/data/cifar100_384_data.yaml | 48 ----- fd_shifts/configs/data/cifar100_data.yaml | 44 ----- fd_shifts/configs/data/cifar10_384_data.yaml | 48 ----- fd_shifts/configs/data/cifar10_data.yaml | 49 ----- .../data/corrupt_cifar100_384_data.yaml | 24 --- .../configs/data/corrupt_cifar100_data.yaml | 22 --- .../data/corrupt_cifar10_384_data.yaml | 24 --- .../configs/data/corrupt_cifar10_data.yaml | 22 --- .../configs/data/dermoscopyall_data.yaml | 52 ------ .../configs/data/emnist_balanced_data.yaml | 62 ------- .../configs/data/emnist_data_balanced.yaml | 62 ------- .../configs/data/emnist_data_byclass.yaml | 62 ------- .../configs/data/emnist_data_bymerge.yaml | 62 ------- .../configs/data/emnist_data_digits.yaml | 62 ------- .../configs/data/emnist_data_letters.yaml | 62 ------- fd_shifts/configs/data/emnist_data_mnist.yaml | 62 ------- .../data/ham10000subsmallprevadj_data.yaml | 26 --- fd_shifts/configs/data/isic_v01_cr_data.yaml | 67 ------- fd_shifts/configs/data/isic_v01_data.yaml | 70 ------- fd_shifts/configs/data/isic_winner_data.yaml | 34 ---- fd_shifts/configs/data/lidc_idriall_data.yaml | 60 ------ fd_shifts/configs/data/med_mnist_blood.yaml | 59 ------ fd_shifts/configs/data/med_mnist_breast.yaml | 63 ------- fd_shifts/configs/data/med_mnist_derma.yaml | 59 ------ fd_shifts/configs/data/med_mnist_oct.yaml | 62 ------- fd_shifts/configs/data/med_mnist_organ_a.yaml | 62 ------- fd_shifts/configs/data/med_mnist_path.yaml | 59 ------ fd_shifts/configs/data/med_mnist_pneu.yaml | 62 ------- fd_shifts/configs/data/med_mnist_tissue.yaml | 62 ------- fd_shifts/configs/data/rxrx1all_data.yaml | 65 ------- .../configs/data/super_cifar100_384_data.yaml | 38 ---- .../configs/data/super_cifar100_data.yaml | 39 ---- fd_shifts/configs/data/svhn_384_data.yaml | 44 ----- fd_shifts/configs/data/svhn_data.yaml | 55 ------ .../configs/data/svhn_openset_384_data.yaml | 42 ----- fd_shifts/configs/data/svhn_openset_data.yaml | 44 ----- .../configs/data/tinyimagenet_384_data.yaml | 24 --- .../data/tinyimagenet_resize_data.yaml | 25 --- .../configs/data/wilds_animals_384_data.yaml | 67 ------- .../configs/data/wilds_animals_data.yaml | 44 ----- .../data/wilds_animals_ood_test_384_data.yaml | 53 ------ .../data/wilds_animals_ood_test_data.yaml | 50 ----- .../data/wilds_animals_openset_384_data.yaml | 67 ------- .../data/wilds_animals_openset_data.yaml | 44 ----- .../configs/data/wilds_camelyon_384_data.yaml | 38 ---- .../configs/data/wilds_camelyon_data.yaml | 41 ---- .../wilds_camelyon_ood_test_384_data.yaml | 24 --- .../data/wilds_camelyon_ood_test_data.yaml | 21 --- .../configs/data/xray_chestall_data.yaml | 69 ------- fd_shifts/configs/study/__init__.py | 0 fd_shifts/configs/study/confidnet.yaml | 43 ----- fd_shifts/configs/study/deepgamblers.yaml | 33 ---- fd_shifts/configs/study/devries.yaml | 33 ---- fd_shifts/configs/study/vit.yaml | 25 --- 61 files changed, 2906 deletions(-) delete mode 100644 fd_shifts/configs/config.yaml delete mode 100644 fd_shifts/configs/data/__init__.py delete mode 100644 fd_shifts/configs/data/breeds_384_data.yaml delete mode 100644 fd_shifts/configs/data/breeds_data.yaml delete mode 100644 fd_shifts/configs/data/breeds_ood_test_384_data.yaml delete mode 100644 fd_shifts/configs/data/breeds_ood_test_data.yaml delete mode 100644 fd_shifts/configs/data/chestMIMC_data.yaml delete mode 100644 fd_shifts/configs/data/cifar100_384_data.yaml delete mode 100644 fd_shifts/configs/data/cifar100_data.yaml delete mode 100644 fd_shifts/configs/data/cifar10_384_data.yaml delete mode 100644 fd_shifts/configs/data/cifar10_data.yaml delete mode 100644 fd_shifts/configs/data/corrupt_cifar100_384_data.yaml delete mode 100644 fd_shifts/configs/data/corrupt_cifar100_data.yaml delete mode 100644 fd_shifts/configs/data/corrupt_cifar10_384_data.yaml delete mode 100644 fd_shifts/configs/data/corrupt_cifar10_data.yaml delete mode 100644 fd_shifts/configs/data/dermoscopyall_data.yaml delete mode 100644 fd_shifts/configs/data/emnist_balanced_data.yaml delete mode 100644 fd_shifts/configs/data/emnist_data_balanced.yaml delete mode 100644 fd_shifts/configs/data/emnist_data_byclass.yaml delete mode 100644 fd_shifts/configs/data/emnist_data_bymerge.yaml delete mode 100644 fd_shifts/configs/data/emnist_data_digits.yaml delete mode 100644 fd_shifts/configs/data/emnist_data_letters.yaml delete mode 100644 fd_shifts/configs/data/emnist_data_mnist.yaml delete mode 100644 fd_shifts/configs/data/ham10000subsmallprevadj_data.yaml delete mode 100644 fd_shifts/configs/data/isic_v01_cr_data.yaml delete mode 100644 fd_shifts/configs/data/isic_v01_data.yaml delete mode 100644 fd_shifts/configs/data/isic_winner_data.yaml delete mode 100644 fd_shifts/configs/data/lidc_idriall_data.yaml delete mode 100644 fd_shifts/configs/data/med_mnist_blood.yaml delete mode 100644 fd_shifts/configs/data/med_mnist_breast.yaml delete mode 100644 fd_shifts/configs/data/med_mnist_derma.yaml delete mode 100644 fd_shifts/configs/data/med_mnist_oct.yaml delete mode 100644 fd_shifts/configs/data/med_mnist_organ_a.yaml delete mode 100644 fd_shifts/configs/data/med_mnist_path.yaml delete mode 100644 fd_shifts/configs/data/med_mnist_pneu.yaml delete mode 100644 fd_shifts/configs/data/med_mnist_tissue.yaml delete mode 100644 fd_shifts/configs/data/rxrx1all_data.yaml delete mode 100644 fd_shifts/configs/data/super_cifar100_384_data.yaml delete mode 100644 fd_shifts/configs/data/super_cifar100_data.yaml delete mode 100644 fd_shifts/configs/data/svhn_384_data.yaml delete mode 100644 fd_shifts/configs/data/svhn_data.yaml delete mode 100644 fd_shifts/configs/data/svhn_openset_384_data.yaml delete mode 100644 fd_shifts/configs/data/svhn_openset_data.yaml delete mode 100644 fd_shifts/configs/data/tinyimagenet_384_data.yaml delete mode 100644 fd_shifts/configs/data/tinyimagenet_resize_data.yaml delete mode 100644 fd_shifts/configs/data/wilds_animals_384_data.yaml delete mode 100644 fd_shifts/configs/data/wilds_animals_data.yaml delete mode 100644 fd_shifts/configs/data/wilds_animals_ood_test_384_data.yaml delete mode 100644 fd_shifts/configs/data/wilds_animals_ood_test_data.yaml delete mode 100644 fd_shifts/configs/data/wilds_animals_openset_384_data.yaml delete mode 100644 fd_shifts/configs/data/wilds_animals_openset_data.yaml delete mode 100644 fd_shifts/configs/data/wilds_camelyon_384_data.yaml delete mode 100644 fd_shifts/configs/data/wilds_camelyon_data.yaml delete mode 100644 fd_shifts/configs/data/wilds_camelyon_ood_test_384_data.yaml delete mode 100644 fd_shifts/configs/data/wilds_camelyon_ood_test_data.yaml delete mode 100644 fd_shifts/configs/data/xray_chestall_data.yaml delete mode 100644 fd_shifts/configs/study/__init__.py delete mode 100644 fd_shifts/configs/study/confidnet.yaml delete mode 100644 fd_shifts/configs/study/deepgamblers.yaml delete mode 100644 fd_shifts/configs/study/devries.yaml delete mode 100644 fd_shifts/configs/study/vit.yaml diff --git a/fd_shifts/configs/config.yaml b/fd_shifts/configs/config.yaml deleted file mode 100644 index b3d17ba..0000000 --- a/fd_shifts/configs/config.yaml +++ /dev/null @@ -1,175 +0,0 @@ -defaults: - - config_schema - - /trainer/lr_scheduler: LinearWarmupCosineAnnealingLR - - /trainer/optimizer: SGD - - _self_ - - study: deepgamblers - - data: cifar10_data - - override hydra/job_logging: disabled - -hydra: - run: - dir: ${exp.dir} - output_subdir: hydra - -pkgversion: ${fd_shifts.version:} - -trainer: - num_epochs: 300 - num_steps: null - num_epochs_backbone: null - dg_pretrain_epochs: 100 - val_every_n_epoch: 5 - val_split: devries - do_val: true - batch_size: 128 - resume_from_ckpt: false - benchmark: true - fast_dev_run: false - callbacks: - model_checkpoint: - confid_monitor: - learning_rate_monitor: - learning_rate_confidnet: null - learning_rate_confidnet_finetune: null - resume_from_ckpt_confidnet: false - -exp: - group_name: ??? - name: ??? - version: null - mode: train_test - work_dir: ${hydra:runtime.cwd} - fold_dir: exp/${exp.fold} - root_dir: ${oc.env:EXPERIMENT_ROOT_DIR} - data_root_dir: ${oc.env:DATASET_ROOT_DIR} - group_dir: ${oc.env:EXPERIMENT_ROOT_DIR}/${exp.group_name} - dir: ${exp.group_dir}/${exp.name} - version_dir: ${exp.dir}/version_${exp.version} - fold: 0 - crossval_n_folds: 10 - crossval_ids_path: ${exp.dir}/crossval_ids.pickle - output_paths: - fit: - input_imgs_plot: ${exp.dir}/input_imgs.png - raw_output: ${exp.version_dir}/raw_output.npz - raw_output_dist: ${exp.version_dir}/raw_output_dist.npz - external_confids: ${exp.version_dir}/external_confids.npz - external_confids_dist: ${exp.version_dir}/external_confids_dist.npz - test: - input_imgs_plot: null - raw_output: ${test.dir}/raw_logits.npz - raw_output_dist: ${test.dir}/raw_logits_dist.npz - encoded_output: ${test.dir}/encoded_output.npz - attributions_output: ${test.dir}/attributions.csv - external_confids: ${test.dir}/external_confids.npz - external_confids_dist: ${test.dir}/external_confids_dist.npz - log_path: log.txt - global_seed: ${fd_shifts.random_seed:} - -model: - name: devries_model - fc_dim: 512 - confidnet_fc_dim: null - dg_reward: 2.2 - avg_pool: true - dropout_rate: 0 - monitor_mcd_samples: 50 - test_mcd_samples: 50 - budget: 0.3 - network: - name: vgg13 - backbone: null - imagenet_weights_path: null - load_dg_backbone_path: null - save_dg_backbone_path: ${exp.dir}/dg_backbone.ckpt - -eval: - performance_metrics: - train: - - loss - - nll - - accuracy - val: - - loss - - nll - - accuracy - - brier_score - test: - - nll - - accuracy - - brier_score - confid_metrics: - train: - - failauc - - failap_suc - - failap_err - - fpr@95tpr - - e-aurc - - aurc - val: - - failauc - - failap_suc - - failap_err - - fpr@95tpr - - e-aurc - - aurc - test: - - failauc - - failap_suc - - failap_err - - mce - - ece - - b-aurc - - e-aurc - - aurc - - fpr@95tpr - confidence_measures: - train: - - det_mcp - val: - - det_mcp - # Select confidences based on whether ext is defined and dropout is on - test: '${fd_shifts.concat: - [det_mcp, det_pe], - ${fd_shifts.if_else:${eval.ext_confid_name}, - [ext], - []}, - ${fd_shifts.if_else:${model.dropout_rate}, - [mcd_mcp, mcd_pe, mcd_ee, mcd_mi, mcd_sv, mcd_waic], - []}, - ${fd_shifts.if_else:${eval.ext_confid_name}, - ${fd_shifts.if_else:${model.dropout_rate}, - [ext_mcd, ext_waic], - []}, - []} - }' - monitor_plots: - - hist_per_confid - tb_hparams: - - fold - ext_confid_name: ??? - test_conf_scaling: false - val_tuning: true - r_star: 0.25 - r_delta: 0.05 - query_studies: - iid_study: ${data.dataset} - noise_study: [] - in_class_study: [] - new_class_study: [] - -test: - name: test_results - dir: ${exp.dir}/${test.name} - cf_path: ${exp.dir}/hydra/config.yaml - selection_criterion: latest - best_ckpt_path: ${exp.version_dir}/${test.selection_criterion}.ckpt - only_latest_version: true - devries_repro_ood_split: false - assim_ood_norm_flag: false - iid_set_split: devries - raw_output_path: raw_output.npz - external_confids_output_path: external_confids.npz - selection_mode: max - output_precision: 64 diff --git a/fd_shifts/configs/data/__init__.py b/fd_shifts/configs/data/__init__.py deleted file mode 100644 index e69de29..0000000 diff --git a/fd_shifts/configs/data/breeds_384_data.yaml b/fd_shifts/configs/data/breeds_384_data.yaml deleted file mode 100644 index 2897a21..0000000 --- a/fd_shifts/configs/data/breeds_384_data.yaml +++ /dev/null @@ -1,44 +0,0 @@ -# @package _global_ -defaults: - - override /trainer/lr_scheduler: LinearWarmupCosineAnnealingLR - -data: - dataset: breeds - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [384, 384, 3] - num_workers: 24 - num_classes: 13 # entitiy-13 - reproduce_confidnet_splits: False - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - resize: 384 - center_crop: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - val: - to_tensor: - resize: 384 - center_crop: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - test: - to_tensor: - resize: 384 - center_crop: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] # keep standard norm. corruptions deviate result a bit from training data but ok. - - kwargs: - info_dir_path: loaders/breeds_hierarchies - -eval: - query_studies: - iid_study: breeds_384 - in_class_study: - - breeds_ood_test_384 - -trainer: - num_epochs: - num_steps: ${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,60000,40000} - dg_pretrain_epochs: - dg_pretrain_steps: 20000 - lr_scheduler_interval: step diff --git a/fd_shifts/configs/data/breeds_data.yaml b/fd_shifts/configs/data/breeds_data.yaml deleted file mode 100644 index 07b6ba8..0000000 --- a/fd_shifts/configs/data/breeds_data.yaml +++ /dev/null @@ -1,51 +0,0 @@ -# @package _global_ - -data: - dataset: breeds - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [224, 224, 3] - num_workers: 12 - num_classes: 13 # entitiy-13 - reproduce_confidnet_splits: False - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - randomresized_crop: 224 - hflip: True - color_jitter: [0.1, 0.1, 0.1] - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - val: - resize: 256 - center_crop: 224 - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - test: - resize: 256 - center_crop: 224 - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] # keep standard norm. corruptions deviate result a bit from training data but ok. - - kwargs: - info_dir_path: loaders/breeds_hierarchies - -eval: - query_studies: - iid_study: breeds - in_class_study: - - breeds_ood_test - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,520,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,350,300}} - dg_pretrain_epochs: 50 - num_epochs_backbone: 300 - optimizer: - lr: 1e-1 - weight_decay: 1e-4 - -model: - fc_dim: 2048 - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,resnet50}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,resnet50,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,resnet50,null}} diff --git a/fd_shifts/configs/data/breeds_ood_test_384_data.yaml b/fd_shifts/configs/data/breeds_ood_test_384_data.yaml deleted file mode 100644 index c5e2dab..0000000 --- a/fd_shifts/configs/data/breeds_ood_test_384_data.yaml +++ /dev/null @@ -1,29 +0,0 @@ -# @package _global_ - -data: - dataset: breeds - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [384, 384, 3] - num_workers: 24 - num_classes: 13 # entitiy-13 - reproduce_confidnet_splits: False - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - resize: 384 - center_crop: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]] - val: - to_tensor: - resize: 384 - center_crop: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]] - test: - to_tensor: - resize: 384 - center_crop: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]] # keep standard norm. corruptions deviate result a bit from training data but ok. - - kwargs: - info_dir_path: loaders/breeds_hierarchies diff --git a/fd_shifts/configs/data/breeds_ood_test_data.yaml b/fd_shifts/configs/data/breeds_ood_test_data.yaml deleted file mode 100644 index 608e4b6..0000000 --- a/fd_shifts/configs/data/breeds_ood_test_data.yaml +++ /dev/null @@ -1,30 +0,0 @@ -# @package _global_ - -data: - dataset: breeds - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [224, 224, 3] - num_workers: 12 - num_classes: 13 # entitiy-13 - reproduce_confidnet_splits: False - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - randomresized_crop: 224 - hflip: True - color_jitter: [0.1, 0.1, 0.1] - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - val: - resize: 256 - center_crop: 224 - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - test: - resize: 256 - center_crop: 224 - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] # keep standard norm. corruptions deviate result a bit from training data but ok. - - kwargs: - info_dir_path: loaders/breeds_hierarchies diff --git a/fd_shifts/configs/data/chestMIMC_data.yaml b/fd_shifts/configs/data/chestMIMC_data.yaml deleted file mode 100644 index 11f7417..0000000 --- a/fd_shifts/configs/data/chestMIMC_data.yaml +++ /dev/null @@ -1,37 +0,0 @@ -# @package _group_ -dataset: dermoscopyallbarcelona -data_dir: ${env:DATASET_ROOT_DIR}/${data.dataset} -pin_memory: True -img_size: [512, 512, 3] #dataset is 28x28x1 either upscale it or need to adjust transforms and neural net -num_workers: 12 -num_classes: 2 -reproduce_confidnet_splits: True -target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - -augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - hflip: - rotate: 15 - scale: 256 - center_crop: 256 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - val: - to_tensor: - scale: 256 - center_crop: 256 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - test: - to_tensor: - scale: 256 - center_crop: 256 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - -kwargs: - \ No newline at end of file diff --git a/fd_shifts/configs/data/cifar100_384_data.yaml b/fd_shifts/configs/data/cifar100_384_data.yaml deleted file mode 100644 index 40cb730..0000000 --- a/fd_shifts/configs/data/cifar100_384_data.yaml +++ /dev/null @@ -1,48 +0,0 @@ -# @package _global_ -defaults: - - override /trainer/lr_scheduler: LinearWarmupCosineAnnealingLR - -data: - dataset: cifar100 - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [384, 384, 3] - num_workers: 24 - num_classes: 100 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - resize: 384 - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - val: - to_tensor: - resize: 384 - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - test: - to_tensor: - resize: 384 - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - - # standard values: [ [ 0.4914, 0.4822, 0.4465 ], [ 0.2023, 0.1994, 0.2010 ] ] - # tiny imagenet values: [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]] - # dvries values: [[0.4913725490196078, 0.4823529411764706, 0.4466666666666667], [0.24705882352941178, 0.24352941176470588, 0.2615686274509804]] - - kwargs: - -eval: - query_studies: - iid_study: cifar100_384 - noise_study: - - corrupt_cifar100_384 - new_class_study: - - cifar10_384 - - svhn_384 - - tinyimagenet_384 - -trainer: - num_epochs: - num_steps: ${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,15000,10000} - dg_pretrain_epochs: - dg_pretrain_steps: 5000 - lr_scheduler_interval: step diff --git a/fd_shifts/configs/data/cifar100_data.yaml b/fd_shifts/configs/data/cifar100_data.yaml deleted file mode 100644 index 4ea6eb8..0000000 --- a/fd_shifts/configs/data/cifar100_data.yaml +++ /dev/null @@ -1,44 +0,0 @@ -# @package _global_ - -data: - dataset: cifar100 - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [32, 32, 3] - num_workers: 12 - num_classes: 100 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - # rotate: 15 - random_crop: [32, 4] - hflip: True - to_tensor: - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - cutout: 16 - val: - to_tensor: - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - test: - to_tensor: - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - kwargs: - -eval: - query_studies: - iid_study: cifar100 - noise_study: - - corrupt_cifar100 - new_class_study: - - cifar10 - - svhn - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,470,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,300,250}} - num_epochs_backbone: 250 - dg_pretrain_epochs: 100 - optimizer: - lr: 1e-1 - weight_decay: 5e-4 diff --git a/fd_shifts/configs/data/cifar10_384_data.yaml b/fd_shifts/configs/data/cifar10_384_data.yaml deleted file mode 100644 index eb2519e..0000000 --- a/fd_shifts/configs/data/cifar10_384_data.yaml +++ /dev/null @@ -1,48 +0,0 @@ -# @package _global_ -defaults: - - override /trainer/lr_scheduler: LinearWarmupCosineAnnealingLR - -data: - dataset: cifar10 - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [384, 384, 3] - num_workers: 24 - num_classes: 10 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - resize: 384 - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - val: - to_tensor: - resize: 384 - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - test: - to_tensor: - resize: 384 - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - - # standard values: [ [ 0.4914, 0.4822, 0.4465 ], [ 0.2023, 0.1994, 0.2010 ] ] - # tiny imagenet values: [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]] - # dvries values: [[0.4913725490196078, 0.4823529411764706, 0.4466666666666667], [0.24705882352941178, 0.24352941176470588, 0.2615686274509804]] - - kwargs: - -eval: - query_studies: - iid_study: cifar10_384 - noise_study: - - corrupt_cifar10_384 - new_class_study: - - cifar100_384 - - svhn_384 - - tinyimagenet_384 - -trainer: - num_epochs: - num_steps: ${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,60000,40000} - dg_pretrain_epochs: - dg_pretrain_steps: 20000 - lr_scheduler_interval: step diff --git a/fd_shifts/configs/data/cifar10_data.yaml b/fd_shifts/configs/data/cifar10_data.yaml deleted file mode 100644 index 40bb0e3..0000000 --- a/fd_shifts/configs/data/cifar10_data.yaml +++ /dev/null @@ -1,49 +0,0 @@ -# @package _global_ - -data: - dataset: cifar10 - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [32, 32, 3] - num_workers: 12 - num_classes: 10 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - random_crop: [32, 4] # size, padding - hflip: True - # rotate: 15 - to_tensor: - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - cutout: 16 - val: - to_tensor: - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - test: - to_tensor: - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - - # standard values: [ [ 0.4914, 0.4822, 0.4465 ], [ 0.2023, 0.1994, 0.2010 ] ] - # tiny imagenet values: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - # dvries values: [[0.4913725490196078, 0.4823529411764706, 0.4466666666666667], [0.24705882352941178, 0.24352941176470588, 0.2615686274509804]] - - kwargs: - -eval: - query_studies: - iid_study: cifar10 - noise_study: - - corrupt_cifar10 - new_class_study: - - cifar100 - - svhn - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,470,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,300,250}} - num_epochs_backbone: 250 - dg_pretrain_epochs: 100 - optimizer: - lr: 1e-1 - weight_decay: 5e-4 diff --git a/fd_shifts/configs/data/corrupt_cifar100_384_data.yaml b/fd_shifts/configs/data/corrupt_cifar100_384_data.yaml deleted file mode 100644 index c179364..0000000 --- a/fd_shifts/configs/data/corrupt_cifar100_384_data.yaml +++ /dev/null @@ -1,24 +0,0 @@ -# @package _global_ - -data: - dataset: corrupt_cifar100 - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [384, 384, 3] - num_workers: 24 - num_classes: 100 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - resize: 384 - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - val: - to_tensor: - resize: 384 - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - test: - to_tensor: - resize: 384 - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] # keep standard norm. corruptions deviate result a bit from training data but ok. - kwargs: diff --git a/fd_shifts/configs/data/corrupt_cifar100_data.yaml b/fd_shifts/configs/data/corrupt_cifar100_data.yaml deleted file mode 100644 index 4afedf3..0000000 --- a/fd_shifts/configs/data/corrupt_cifar100_data.yaml +++ /dev/null @@ -1,22 +0,0 @@ -# @package _global_ - -data: - dataset: corrupt_cifar100 - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [32, 32, 3] - num_workers: 12 - num_classes: 100 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - hflip: True - rotate: 15 - random_crop: [32, 4] - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - val: - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - test: - to_tensor: - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] # keep standard norm. corruptions deviate result a bit from training data but ok. - kwargs: diff --git a/fd_shifts/configs/data/corrupt_cifar10_384_data.yaml b/fd_shifts/configs/data/corrupt_cifar10_384_data.yaml deleted file mode 100644 index d4f0e73..0000000 --- a/fd_shifts/configs/data/corrupt_cifar10_384_data.yaml +++ /dev/null @@ -1,24 +0,0 @@ -# @package _global_ - -data: - dataset: corrupt_cifar10 - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [384, 384, 3] - num_workers: 24 - num_classes: 10 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - resize: 384 - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - val: - to_tensor: - resize: 384 - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - test: - to_tensor: - resize: 384 - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] # keep standard norm. corruptions deviate result a bit from training data but ok. - kwargs: diff --git a/fd_shifts/configs/data/corrupt_cifar10_data.yaml b/fd_shifts/configs/data/corrupt_cifar10_data.yaml deleted file mode 100644 index e9b9f8f..0000000 --- a/fd_shifts/configs/data/corrupt_cifar10_data.yaml +++ /dev/null @@ -1,22 +0,0 @@ -# @package _global_ - -data: - dataset: corrupt_cifar10 - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [32, 32, 3] - num_workers: 12 - num_classes: 10 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - hflip: True - rotate: 15 - random_crop: [32, 4] - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - val: - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - test: - to_tensor: - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] # keep standard norm. corruptions deviate result a bit from training data but ok. - kwargs: diff --git a/fd_shifts/configs/data/dermoscopyall_data.yaml b/fd_shifts/configs/data/dermoscopyall_data.yaml deleted file mode 100644 index 30ffef4..0000000 --- a/fd_shifts/configs/data/dermoscopyall_data.yaml +++ /dev/null @@ -1,52 +0,0 @@ -# @package _global_ -defaults: - - override /trainer/lr_scheduler: CosineAnnealingLR - - override /trainer/optimizer: Adam - -data: - dataset: dermoscopyall - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [512, 512, 3] #dataset is 28x28x1 either upscale it or need to adjust transforms and neural net - num_workers: 12 - num_classes: 2 - reproduce_confidnet_splits: True - target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - - val: - - test: - - - - kwargs: - -eval: - query_studies: - iid_study: ${data.dataset} - -trainer: - batch_size: 16 - # num_epochs: 30 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,30,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,20,15}} - optimizer: - lr: 3e-5 - weight_decay: 0 - # nesterov: True - num_epochs_backbone: 20 - dg_pretrain_epochs: 15 - val_every_n_epoch: 5 - -model: - fc_dim: 1792 - network: - backbone: efficientnetb4 diff --git a/fd_shifts/configs/data/emnist_balanced_data.yaml b/fd_shifts/configs/data/emnist_balanced_data.yaml deleted file mode 100644 index dbfcaec..0000000 --- a/fd_shifts/configs/data/emnist_balanced_data.yaml +++ /dev/null @@ -1,62 +0,0 @@ -# @package _group_ - -data: - dataset: emnist_balanced - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [28, 28, 1] #dataset is 28x28x1 either upscale it or need to adjust transforms and neural net - num_workers: 12 - num_classes: 47 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - tothreechannel: #copies data into three channels - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - pad4: #zero padding 4 pixels around edges - - val: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - test: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - - kwargs: - - # corbeire: 0.5 is not precise enough for OoD! - #ByClass: 62 C unbalanced - #MyMerge 47 C unbalanced - #Balanced: 47 C - #Letters: 26C - #Digits: 10 C - #MNIST: 10 C - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/emnist_data_balanced.yaml b/fd_shifts/configs/data/emnist_data_balanced.yaml deleted file mode 100644 index dbfcaec..0000000 --- a/fd_shifts/configs/data/emnist_data_balanced.yaml +++ /dev/null @@ -1,62 +0,0 @@ -# @package _group_ - -data: - dataset: emnist_balanced - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [28, 28, 1] #dataset is 28x28x1 either upscale it or need to adjust transforms and neural net - num_workers: 12 - num_classes: 47 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - tothreechannel: #copies data into three channels - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - pad4: #zero padding 4 pixels around edges - - val: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - test: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - - kwargs: - - # corbeire: 0.5 is not precise enough for OoD! - #ByClass: 62 C unbalanced - #MyMerge 47 C unbalanced - #Balanced: 47 C - #Letters: 26C - #Digits: 10 C - #MNIST: 10 C - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/emnist_data_byclass.yaml b/fd_shifts/configs/data/emnist_data_byclass.yaml deleted file mode 100644 index f2d8cd6..0000000 --- a/fd_shifts/configs/data/emnist_data_byclass.yaml +++ /dev/null @@ -1,62 +0,0 @@ -# @package _group_ - -data: - dataset: emnist_byclass - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [28, 28, 1] #dataset is 28x28x1 either upscale it or need to adjust transforms and neural net - num_workers: 12 - num_classes: 62 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - tothreechannel: #copies data into three channels - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - pad4: #zero padding 4 pixels around edges - - val: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - test: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - - kwargs: - - # corbeire: 0.5 is not precise enough for OoD! - #ByClass: 62 C unbalanced - #MyMerge 47 C unbalanced - #Balanced: 47 C - #Letters: 26C - #Digits: 10 C - #MNIST: 10 C - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/emnist_data_bymerge.yaml b/fd_shifts/configs/data/emnist_data_bymerge.yaml deleted file mode 100644 index 3af1939..0000000 --- a/fd_shifts/configs/data/emnist_data_bymerge.yaml +++ /dev/null @@ -1,62 +0,0 @@ -# @package _group_ - -data: - dataset: emnist_bymerge - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [28, 28, 1] #dataset is 28x28x1 either upscale it or need to adjust transforms and neural net - num_workers: 12 - num_classes: 47 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - tothreechannel: #copies data into three channels - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - pad4: #zero padding 4 pixels around edges - - val: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - test: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - - kwargs: - - # corbeire: 0.5 is not precise enough for OoD! - #ByClass: 62 C unbalanced - #MyMerge 47 C unbalanced - #Balanced: 47 C - #Letters: 26C - #Digits: 10 C - #MNIST: 10 C - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/emnist_data_digits.yaml b/fd_shifts/configs/data/emnist_data_digits.yaml deleted file mode 100644 index e92a301..0000000 --- a/fd_shifts/configs/data/emnist_data_digits.yaml +++ /dev/null @@ -1,62 +0,0 @@ -# @package _group_ - -data: - dataset: emnist_digits - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [28, 28, 1] #dataset is 28x28x1 either upscale it or need to adjust transforms and neural net - num_workers: 12 - num_classes: 10 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - tothreechannel: #copies data into three channels - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - pad4: #zero padding 4 pixels around edges - - val: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - test: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - - kwargs: - - # corbeire: 0.5 is not precise enough for OoD! - #ByClass: 62 C unbalanced - #MyMerge 47 C unbalanced - #Balanced: 47 C - #Letters: 26C - #Digits: 10 C - #MNIST: 10 C - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/emnist_data_letters.yaml b/fd_shifts/configs/data/emnist_data_letters.yaml deleted file mode 100644 index e72998f..0000000 --- a/fd_shifts/configs/data/emnist_data_letters.yaml +++ /dev/null @@ -1,62 +0,0 @@ -# @package _group_ - -data: - dataset: emnist_letters - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [28, 28, 1] #dataset is 28x28x1 either upscale it or need to adjust transforms and neural net - num_workers: 12 - num_classes: 37 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - tothreechannel: #copies data into three channels - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - pad4: #zero padding 4 pixels around edges - - val: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - test: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - - kwargs: - - # corbeire: 0.5 is not precise enough for OoD! - #ByClass: 62 C unbalanced - #MyMerge 47 C unbalanced - #Balanced: 47 C - #Letters: 26C - #Digits: 10 C - #MNIST: 10 C - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/emnist_data_mnist.yaml b/fd_shifts/configs/data/emnist_data_mnist.yaml deleted file mode 100644 index 65fb496..0000000 --- a/fd_shifts/configs/data/emnist_data_mnist.yaml +++ /dev/null @@ -1,62 +0,0 @@ -# @package _group_ - -data: - dataset: emnist_mnist - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [28, 28, 1] #dataset is 28x28x1 either upscale it or need to adjust transforms and neural net - num_workers: 12 - num_classes: 10 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - tothreechannel: #copies data into three channels - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - pad4: #zero padding 4 pixels around edges - - val: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - test: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - - kwargs: - - # corbeire: 0.5 is not precise enough for OoD! - #ByClass: 62 C unbalanced - #MyMerge 47 C unbalanced - #Balanced: 47 C - #Letters: 26C - #Digits: 10 C - #MNIST: 10 C - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/ham10000subsmallprevadj_data.yaml b/fd_shifts/configs/data/ham10000subsmallprevadj_data.yaml deleted file mode 100644 index 3e97bc3..0000000 --- a/fd_shifts/configs/data/ham10000subsmallprevadj_data.yaml +++ /dev/null @@ -1,26 +0,0 @@ -# @package _group_ -dataset: ham10000subsmallprevadj -data_dir: ${env:DATASET_ROOT_DIR}/${data.dataset} -pin_memory: True -img_size: [512, 512, 3] #dataset is 28x28x1 either upscale it or need to adjust transforms and neural net -num_workers: 12 -num_classes: 2 -reproduce_confidnet_splits: True -target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - -augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - - val: - - test: - - -kwargs: - \ No newline at end of file diff --git a/fd_shifts/configs/data/isic_v01_cr_data.yaml b/fd_shifts/configs/data/isic_v01_cr_data.yaml deleted file mode 100644 index b4f65bc..0000000 --- a/fd_shifts/configs/data/isic_v01_cr_data.yaml +++ /dev/null @@ -1,67 +0,0 @@ -# @package _group_ - -data: - dataset: isic_v01_cr - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [256, 256, 3] #dataset is 28x28x1 either upscale it or need to adjust transforms and neural net - num_workers: 12 - num_classes: 2 - reproduce_confidnet_splits: True - target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - - - val: - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - - test: - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - - - kwargs: - - # corbeire: 0.5 is not precise enough for OoD! - #ByClass: 62 C unbalanced - #MyMerge 47 C unbalanced - #Balanced: 47 C - #Letters: 26C - #Digits: 10 C - #MNIST: 10 C - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/isic_v01_data.yaml b/fd_shifts/configs/data/isic_v01_data.yaml deleted file mode 100644 index fc78b22..0000000 --- a/fd_shifts/configs/data/isic_v01_data.yaml +++ /dev/null @@ -1,70 +0,0 @@ -# @package _group_ - -data: - dataset: isic_v01 - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [128, 128, 3] #dataset is 28x28x1 either upscale it or need to adjust transforms and neural net - num_workers: 1 - num_classes: 2 - reproduce_confidnet_splits: True - target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - resize: [128, 128] - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - - - val: - resize: [128, 128] - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - - test: - resize: [128, 128] - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - - - kwargs: - - # corbeire: 0.5 is not precise enough for OoD! - #ByClass: 62 C unbalanced - #MyMerge 47 C unbalanced - #Balanced: 47 C - #Letters: 26C - #Digits: 10 C - #MNIST: 10 C - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/isic_winner_data.yaml b/fd_shifts/configs/data/isic_winner_data.yaml deleted file mode 100644 index 0fd165e..0000000 --- a/fd_shifts/configs/data/isic_winner_data.yaml +++ /dev/null @@ -1,34 +0,0 @@ -# @package _group_ -dataset: isic_winner -data_dir: ${env:DATASET_ROOT_DIR}/${data.dataset} -pin_memory: True -img_size: [512, 512, 3] #dataset is 28x28x1 either upscale it or need to adjust transforms and neural net -num_workers: 12 -num_classes: 9 -reproduce_confidnet_splits: True -target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - -augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - - val: - - test: - - - -kwargs: - -# corbeire: 0.5 is not precise enough for OoD! -#ByClass: 62 C unbalanced -#MyMerge 47 C unbalanced -#Balanced: 47 C -#Letters: 26C -#Digits: 10 C -#MNIST: 10 C diff --git a/fd_shifts/configs/data/lidc_idriall_data.yaml b/fd_shifts/configs/data/lidc_idriall_data.yaml deleted file mode 100644 index 5d55626..0000000 --- a/fd_shifts/configs/data/lidc_idriall_data.yaml +++ /dev/null @@ -1,60 +0,0 @@ -# @package _global_ -defaults: - - override /trainer/lr_scheduler: CosineAnnealingLR - - override /trainer/optimizer: Adam - -data: - dataset: lidc_idriall - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [64, 64, 3] #dataset is 28x28x1 either upscale it or need to adjust transforms and neural net - num_workers: 24 - num_classes: 2 - reproduce_confidnet_splits: True - target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - hflip: 1 - rotate: 180 - gaussian_blur: - rand_erase: - normalize: [[0.2299,0.2299,0.2299], [0.2402,0.2402,0.2402]] - val: - to_tensor: - normalize: [[0.2299,0.2299,0.2299], [0.2402,0.2402,0.2402]] - test: - to_tensor: - normalize: [[0.2299,0.2299,0.2299], [0.2402,0.2402,0.2402]] - - - kwargs: - -eval: - query_studies: - iid_study: ${data.dataset} - -trainer: - batch_size: 512 - # num_epochs: 30 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,75,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,60,45}} - optimizer: - lr: 3e-5 - weight_decay: 0.1 - # nesterov: False - # momentum: 0 - num_epochs_backbone: 45 - dg_pretrain_epochs: 45 - val_every_n_epoch: 5 - -model: - fc_dim: 1024 - network: - backbone: densenet121 diff --git a/fd_shifts/configs/data/med_mnist_blood.yaml b/fd_shifts/configs/data/med_mnist_blood.yaml deleted file mode 100644 index b8baeb0..0000000 --- a/fd_shifts/configs/data/med_mnist_blood.yaml +++ /dev/null @@ -1,59 +0,0 @@ -# @package _group_ - -data: - dataset: med_mnist_blood - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [28, 28, 3] - num_workers: 12 - num_classes: 8 - reproduce_confidnet_splits: True - target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - pad4: #zero padding 4 pixels around edges - - val: - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - test: - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - - kwargs: - - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/med_mnist_breast.yaml b/fd_shifts/configs/data/med_mnist_breast.yaml deleted file mode 100644 index e109265..0000000 --- a/fd_shifts/configs/data/med_mnist_breast.yaml +++ /dev/null @@ -1,63 +0,0 @@ -# @package _group_ - -data: - dataset: med_mnist_breast - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [28, 28, 3] - num_workers: 12 - num_classes: 2 - reproduce_confidnet_splits: True - target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - pad4: #zero padding 4 pixels around edges - - val: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - test: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - - kwargs: - - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/med_mnist_derma.yaml b/fd_shifts/configs/data/med_mnist_derma.yaml deleted file mode 100644 index 2930d1b..0000000 --- a/fd_shifts/configs/data/med_mnist_derma.yaml +++ /dev/null @@ -1,59 +0,0 @@ -# @package _group_ - -data: - dataset: med_mnist_derma - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [28, 28, 3] - num_workers: 12 - num_classes: 7 - reproduce_confidnet_splits: True - target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - pad4: #zero padding 4 pixels around edges - - val: - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - test: - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - - kwargs: - - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/med_mnist_oct.yaml b/fd_shifts/configs/data/med_mnist_oct.yaml deleted file mode 100644 index 355b7cf..0000000 --- a/fd_shifts/configs/data/med_mnist_oct.yaml +++ /dev/null @@ -1,62 +0,0 @@ -# @package _group_ - -data: - dataset: med_mnist_oct - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [28, 28, 1] - num_workers: 12 - num_classes: 4 - reproduce_confidnet_splits: True - target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - pad4: #zero padding 4 pixels around edges - - val: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - test: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - - kwargs: - - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/med_mnist_organ_a.yaml b/fd_shifts/configs/data/med_mnist_organ_a.yaml deleted file mode 100644 index 96e3688..0000000 --- a/fd_shifts/configs/data/med_mnist_organ_a.yaml +++ /dev/null @@ -1,62 +0,0 @@ -# @package _group_ - -data: - dataset: med_mnist_organ_a - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [28, 28, 1] - num_workers: 12 - num_classes: 11 - reproduce_confidnet_splits: True - target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - pad4: #zero padding 4 pixels around edges - - val: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - test: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - -kwargs: - - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/med_mnist_path.yaml b/fd_shifts/configs/data/med_mnist_path.yaml deleted file mode 100644 index 95e9a62..0000000 --- a/fd_shifts/configs/data/med_mnist_path.yaml +++ /dev/null @@ -1,59 +0,0 @@ -# @package _group_ - -data: - dataset: med_mnist_path - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [28, 28, 3] - num_workers: 12 - num_classes: 9 - reproduce_confidnet_splits: True - target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - pad4: #zero padding 4 pixels around edges - - val: - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - test: - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - - kwargs: - - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/med_mnist_pneu.yaml b/fd_shifts/configs/data/med_mnist_pneu.yaml deleted file mode 100644 index 3b91470..0000000 --- a/fd_shifts/configs/data/med_mnist_pneu.yaml +++ /dev/null @@ -1,62 +0,0 @@ -# @package _group_ - -data: - dataset: med_mnist_pneu - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [28, 28, 1] - num_workers: 12 - num_classes: 2 - reproduce_confidnet_splits: True - target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - pad4: #zero padding 4 pixels around edges - - val: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - test: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - - kwargs: - - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/med_mnist_tissue.yaml b/fd_shifts/configs/data/med_mnist_tissue.yaml deleted file mode 100644 index 0d77a42..0000000 --- a/fd_shifts/configs/data/med_mnist_tissue.yaml +++ /dev/null @@ -1,62 +0,0 @@ -# @package _group_ - -data: - dataset: med_mnist_tissue - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [28, 28, 1] - num_workers: 12 - num_classes: 8 - reproduce_confidnet_splits: True - target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.4728044], [0.19803012, 0.20101562, 0.19703614]] - pad4: #zero padding 4 pixels around edges - - val: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - test: - to_tensor: - tothreechannel: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - pad4: - - kwargs: - - -eval: - query_studies: - iid_study: ${data.dataset} - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/rxrx1all_data.yaml b/fd_shifts/configs/data/rxrx1all_data.yaml deleted file mode 100644 index 2a30035..0000000 --- a/fd_shifts/configs/data/rxrx1all_data.yaml +++ /dev/null @@ -1,65 +0,0 @@ -# @package _global_ -defaults: - - override /trainer/lr_scheduler: CosineAnnealingLR - - override /trainer/optimizer: Adam - -data: - dataset: rxrx1all - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [512, 512, 6] #dataset is 28x28x1 either upscale it or need to adjust transforms and neural net - num_workers: 24 - num_classes: 1139 - reproduce_confidnet_splits: True - target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - hflip: 1 - randomresized_crop: 224 - rotate: 15 - normalize: [[0.485, 0.456, 0.406,0.485,0.485,0.485], [0.229, 0.224, 0.225,0.229,0.229,0.229]] - val: - to_tensor: - normalize: [[0.485, 0.456, 0.406,0.485,0.485,0.485], [0.229, 0.224, 0.225,0.229,0.229,0.229]] - test: - to_tensor: - normalize: [[0.485, 0.456, 0.406,0.485,0.485,0.485], [0.229, 0.224, 0.225,0.229,0.229,0.229]] - - - kwargs: - -eval: - performance_metrics: - test: - - nll - - accuracy - - brier_score - - b-accuracy - query_studies: - iid_study: ${data.dataset} - -trainer: - batch_size: 70 - # num_epochs: 30 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,150,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,120,90}} - optimizer: - lr: 3e-5 - weight_decay: 1e-5 - # nesterov: False - # momentum: 0 - num_epochs_backbone: 90 - dg_pretrain_epochs: 90 - val_every_n_epoch: 5 - -model: - fc_dim: 2208 - network: - backbone: densenet161 diff --git a/fd_shifts/configs/data/super_cifar100_384_data.yaml b/fd_shifts/configs/data/super_cifar100_384_data.yaml deleted file mode 100644 index 93ad700..0000000 --- a/fd_shifts/configs/data/super_cifar100_384_data.yaml +++ /dev/null @@ -1,38 +0,0 @@ -# @package _global_ -defaults: - - override /trainer/lr_scheduler: LinearWarmupCosineAnnealingLR - -data: - dataset: super_cifar100 - data_dir: ${oc.env:DATASET_ROOT_DIR}/cifar100 - pin_memory: True - img_size: [384, 384, 3] - num_workers: 24 - num_classes: 19 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - # rotate: 15 - to_tensor: - resize: 384 - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - val: - to_tensor: - resize: 384 - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - test: - to_tensor: - resize: 384 - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - kwargs: - -eval: - query_studies: # iid_study, new_class_study, sub_class_study, noise_study - iid_study: super_cifar100_384 - -trainer: - num_epochs: - num_steps: ${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,15000,10000} - dg_pretrain_epochs: - dg_pretrain_steps: 5000 - lr_scheduler_interval: step diff --git a/fd_shifts/configs/data/super_cifar100_data.yaml b/fd_shifts/configs/data/super_cifar100_data.yaml deleted file mode 100644 index 59284b9..0000000 --- a/fd_shifts/configs/data/super_cifar100_data.yaml +++ /dev/null @@ -1,39 +0,0 @@ -# @package _global_ - -data: - dataset: super_cifar100 - data_dir: ${oc.env:DATASET_ROOT_DIR}/cifar100 - pin_memory: True - img_size: [32, 32, 3] - num_workers: 12 - num_classes: 19 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - # rotate: 15 - random_crop: [32, 4] - hflip: True - to_tensor: - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - cutout: 16 - val: - to_tensor: - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - test: - to_tensor: - normalize: [[0.4914, 0.4822, 0.4465], [0.2023, 0.1994, 0.2010]] - - kwargs: - -eval: - query_studies: # iid_study, new_class_study, sub_class_study, noise_study - iid_study: super_cifar100 - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,470,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,300,250}} - num_epochs_backbone: 250 - dg_pretrain_epochs: 100 - optimizer: - lr: 1e-1 - weight_decay: 5e-4 diff --git a/fd_shifts/configs/data/svhn_384_data.yaml b/fd_shifts/configs/data/svhn_384_data.yaml deleted file mode 100644 index d15a1e5..0000000 --- a/fd_shifts/configs/data/svhn_384_data.yaml +++ /dev/null @@ -1,44 +0,0 @@ -# @package _global_ -defaults: - - override /trainer/lr_scheduler: LinearWarmupCosineAnnealingLR - -data: - dataset: svhn - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [384, 384, 3] - num_workers: 24 - num_classes: 10 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - resize: 384 - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - val: - to_tensor: - resize: 384 - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - test: - to_tensor: - resize: 384 - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - kwargs: - -eval: - query_studies: - iid_study: svhn_384 - new_class_study: - - cifar10_384 - - cifar100_384 - - tinyimagenet_384 - -trainer: - num_epochs: - num_steps: ${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,60000,40000} - dg_pretrain_epochs: - dg_pretrain_steps: 20000 - lr_scheduler_interval: step diff --git a/fd_shifts/configs/data/svhn_data.yaml b/fd_shifts/configs/data/svhn_data.yaml deleted file mode 100644 index b506e13..0000000 --- a/fd_shifts/configs/data/svhn_data.yaml +++ /dev/null @@ -1,55 +0,0 @@ -# @package _global_ - -data: - dataset: svhn - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [32, 32, 3] - num_workers: 12 - num_classes: 10 - reproduce_confidnet_splits: True - augmentations: - train: - to_tensor: - normalize: - [ - [0.4376821, 0.4437697, 0.47280442], - [0.19803012, 0.20101562, 0.19703614], - ] - val: - to_tensor: - normalize: - [ - [0.4376821, 0.4437697, 0.47280442], - [0.19803012, 0.20101562, 0.19703614], - ] - test: - to_tensor: - normalize: - [ - [0.4376821, 0.4437697, 0.47280442], - [0.19803012, 0.20101562, 0.19703614], - ] - kwargs: - -eval: - query_studies: - iid_study: svhn - new_class_study: - - cifar10 - - cifar100 - - tinyimagenet_resize - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/svhn_openset_384_data.yaml b/fd_shifts/configs/data/svhn_openset_384_data.yaml deleted file mode 100644 index 5983100..0000000 --- a/fd_shifts/configs/data/svhn_openset_384_data.yaml +++ /dev/null @@ -1,42 +0,0 @@ -# @package _global_ -defaults: - - override /trainer/lr_scheduler: LinearWarmupCosineAnnealingLR - -data: - dataset: svhn_openset - data_dir: ${oc.env:DATASET_ROOT_DIR}/svhn - pin_memory: True - img_size: [384, 384, 3] - num_workers: 24 - num_classes: 10 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - resize: 384 - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - val: - to_tensor: - resize: 384 - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - test: - to_tensor: - resize: 384 - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - kwargs: - out_classes: [6, 7, 8, 9] - # corbeire: 0.5 is not precise enough for OoD! - -eval: - query_studies: - iid_study: svhn_openset_384 - -trainer: - num_epochs: - num_steps: ${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,60000,40000} - dg_pretrain_epochs: - dg_pretrain_steps: 20000 - lr_scheduler_interval: step diff --git a/fd_shifts/configs/data/svhn_openset_data.yaml b/fd_shifts/configs/data/svhn_openset_data.yaml deleted file mode 100644 index 712d9e5..0000000 --- a/fd_shifts/configs/data/svhn_openset_data.yaml +++ /dev/null @@ -1,44 +0,0 @@ -# @package _global_ - -data: - dataset: svhn_openset - data_dir: ${oc.env:DATASET_ROOT_DIR}/svhn - pin_memory: True - img_size: [32, 32, 3] - num_workers: 12 - num_classes: 10 - reproduce_confidnet_splits: True - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - val: - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - test: - to_tensor: - normalize: - [[0.4376821, 0.4437697, 0.47280442], [0.19803012, 0.20101562, 0.19703614]] - kwargs: - out_classes: [6, 7, 8, 9] - # corbeire: 0.5 is not precise enough for OoD! - -eval: - query_studies: - iid_study: svhn_openset - -trainer: - batch_size: 128 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,320,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,150,100}} - num_epochs_backbone: 100 - dg_pretrain_epochs: 50 - optimizer: - lr: 1e-2 - weight_decay: 5e-4 - -model: - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,svhn_small_conv}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,svhn_small_conv,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,svhn_small_conv,null}} diff --git a/fd_shifts/configs/data/tinyimagenet_384_data.yaml b/fd_shifts/configs/data/tinyimagenet_384_data.yaml deleted file mode 100644 index 97a5619..0000000 --- a/fd_shifts/configs/data/tinyimagenet_384_data.yaml +++ /dev/null @@ -1,24 +0,0 @@ -# @package _global_ - -data: - dataset: tinyimagenet - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [384, 384, 3] - num_workers: 24 - num_classes: 200 - reproduce_confidnet_splits: False - augmentations: - train: - to_tensor: - resize: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]] - val: - to_tensor: - resize: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]] - test: - to_tensor: - resize: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]] - kwargs: diff --git a/fd_shifts/configs/data/tinyimagenet_resize_data.yaml b/fd_shifts/configs/data/tinyimagenet_resize_data.yaml deleted file mode 100644 index 1d16d66..0000000 --- a/fd_shifts/configs/data/tinyimagenet_resize_data.yaml +++ /dev/null @@ -1,25 +0,0 @@ -# @package _global_ - -data: - dataset: tinyimagenet_resize - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [64, 64, 3] - num_workers: 12 - num_classes: 200 - reproduce_confidnet_splits: False - augmentations: - train: - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - val: - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - test: - # center_crop: [32, 32] # OoD for Cifar - # resize: 32 - to_tensor: - # normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - - kwargs: diff --git a/fd_shifts/configs/data/wilds_animals_384_data.yaml b/fd_shifts/configs/data/wilds_animals_384_data.yaml deleted file mode 100644 index 4dc83a0..0000000 --- a/fd_shifts/configs/data/wilds_animals_384_data.yaml +++ /dev/null @@ -1,67 +0,0 @@ -# @package _global_ -defaults: - - override /trainer/lr_scheduler: LinearWarmupCosineAnnealingLR - -data: - dataset: wilds_animals - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [384, 384, 3] - num_workers: 24 - num_classes: 182 - reproduce_confidnet_splits: False - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - resize: 384 - center_crop: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - val: - to_tensor: - resize: 384 - center_crop: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - test: - to_tensor: - resize: 384 - center_crop: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - kwargs: - # not doing group sampling because I am not interested in their subpopulation shift or "worst group accuracy" and improving those. - # - # 'iwildcam': { - # 'loss_function': 'cross_entropy', - # 'val_metric': 'F1-macro_all', - # 'model_kwargs': {'pretrained': True}, - # 'train_transform': 'image_base', - # 'eval_transform': 'image_base', - # 'target_resolution': (448, 448), - # 'val_metric_decreasing': False, - # 'algo_log_metric': 'accuracy', - # 'model': 'resnet50', - # 'lr': 3e-5, - # 'weight_decay': 0.0, - # 'batch_size': 16, - # 'n_epochs': 12, - # 'optimizer': 'Adam', - # 'split_scheme': 'official', - # 'scheduler': None, - # 'groupby_fields': ['location',], - # 'n_groups_per_batch': 2, - # 'irm_lambda': 1., - # 'coral_penalty_weight': 10., - # 'no_group_logging': True, - # 'process_outputs_function': 'multiclass_logits_to_pred' - # }, - -eval: - query_studies: - iid_study: wilds_animals_384 - in_class_study: [wilds_animals_ood_test_384] - -trainer: - num_epochs: - num_steps: ${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,60000,40000} - dg_pretrain_epochs: - dg_pretrain_steps: 20000 - lr_scheduler_interval: step diff --git a/fd_shifts/configs/data/wilds_animals_data.yaml b/fd_shifts/configs/data/wilds_animals_data.yaml deleted file mode 100644 index 2182480..0000000 --- a/fd_shifts/configs/data/wilds_animals_data.yaml +++ /dev/null @@ -1,44 +0,0 @@ -# @package _global_ - -data: - dataset: wilds_animals - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [448, 448, 3] - num_workers: 12 - num_classes: 182 - reproduce_confidnet_splits: False - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - resize: [448, 448] - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - val: - resize: [448, 448] - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - test: - resize: [448, 448] - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - kwargs: - -eval: - query_studies: - iid_study: ${data.dataset} - in_class_study: [wilds_animals_ood_test] - -trainer: - batch_size: 16 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,20,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,18,12}} - num_epochs_backbone: 12 - dg_pretrain_epochs: 6 - optimizer: - lr: 1e-3 - weight_decay: 0 - -model: - fc_dim: 2048 - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,resnet50}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,resnet50,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,resnet50,null}} diff --git a/fd_shifts/configs/data/wilds_animals_ood_test_384_data.yaml b/fd_shifts/configs/data/wilds_animals_ood_test_384_data.yaml deleted file mode 100644 index d925614..0000000 --- a/fd_shifts/configs/data/wilds_animals_ood_test_384_data.yaml +++ /dev/null @@ -1,53 +0,0 @@ -# @package _global_ - -data: - dataset: wilds_animals - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [384, 384, 3] - num_workers: 24 - num_classes: 182 - reproduce_confidnet_splits: False - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - resize: 384 - center_crop: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - val: - to_tensor: - resize: 384 - center_crop: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - test: - to_tensor: - resize: 384 - center_crop: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - kwargs: - # not doing group sampling because I am not interested in their subpopulation shift or "worst group accuracy" and improving those. - # - # 'iwildcam': { - # 'loss_function': 'cross_entropy', - # 'val_metric': 'F1-macro_all', - # 'model_kwargs': {'pretrained': True}, - # 'train_transform': 'image_base', - # 'eval_transform': 'image_base', - # 'target_resolution': (448, 448), - # 'val_metric_decreasing': False, - # 'algo_log_metric': 'accuracy', - # 'model': 'resnet50', - # 'lr': 3e-5, - # 'weight_decay': 0.0, - # 'batch_size': 16, - # 'n_epochs': 12, - # 'optimizer': 'Adam', - # 'split_scheme': 'official', - # 'scheduler': None, - # 'groupby_fields': ['location',], - # 'n_groups_per_batch': 2, - # 'irm_lambda': 1., - # 'coral_penalty_weight': 10., - # 'no_group_logging': True, - # 'process_outputs_function': 'multiclass_logits_to_pred' - # }, diff --git a/fd_shifts/configs/data/wilds_animals_ood_test_data.yaml b/fd_shifts/configs/data/wilds_animals_ood_test_data.yaml deleted file mode 100644 index 992d49b..0000000 --- a/fd_shifts/configs/data/wilds_animals_ood_test_data.yaml +++ /dev/null @@ -1,50 +0,0 @@ -# @package _global_ - -data: - dataset: wilds_animals - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [448, 448, 3] - num_workers: 12 - num_classes: 182 - reproduce_confidnet_splits: False - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - resize: [448, 448] - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - val: - resize: [448, 448] - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - test: - resize: [448, 448] - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - kwargs: - # not doing group sampling because I am not interested in their subpopulation shift or "worst group accuracy" and improving those. - # - # 'iwildcam': { - # 'loss_function': 'cross_entropy', - # 'val_metric': 'F1-macro_all', - # 'model_kwargs': {'pretrained': True}, - # 'train_transform': 'image_base', - # 'eval_transform': 'image_base', - # 'target_resolution': (448, 448), - # 'val_metric_decreasing': False, - # 'algo_log_metric': 'accuracy', - # 'model': 'resnet50', - # 'lr': 3e-5, - # 'weight_decay': 0.0, - # 'batch_size': 16, - # 'n_epochs': 12, - # 'optimizer': 'Adam', - # 'split_scheme': 'official', - # 'scheduler': None, - # 'groupby_fields': ['location',], - # 'n_groups_per_batch': 2, - # 'irm_lambda': 1., - # 'coral_penalty_weight': 10., - # 'no_group_logging': True, - # 'process_outputs_function': 'multiclass_logits_to_pred' - # }, diff --git a/fd_shifts/configs/data/wilds_animals_openset_384_data.yaml b/fd_shifts/configs/data/wilds_animals_openset_384_data.yaml deleted file mode 100644 index 5352852..0000000 --- a/fd_shifts/configs/data/wilds_animals_openset_384_data.yaml +++ /dev/null @@ -1,67 +0,0 @@ -# @package _global_ -defaults: - - override /trainer/lr_scheduler: LinearWarmupCosineAnnealingLR - -data: - dataset: wilds_animals_openset - data_dir: ${oc.env:DATASET_ROOT_DIR}/wilds_animals - pin_memory: True - img_size: [384, 384, 3] - num_workers: 24 - num_classes: 182 - reproduce_confidnet_splits: False - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - resize: 384 - center_crop: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - val: - to_tensor: - resize: 384 - center_crop: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - test: - to_tensor: - resize: 384 - center_crop: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - kwargs: - out_classes: [6, 7, 8, 9] - # not doing group sampling because I am not interested in their subpopulation shift or "worst group accuracy" and improving those. - # - # 'iwildcam': { - # 'loss_function': 'cross_entropy', - # 'val_metric': 'F1-macro_all', - # 'model_kwargs': {'pretrained': True}, - # 'train_transform': 'image_base', - # 'eval_transform': 'image_base', - # 'target_resolution': (448, 448), - # 'val_metric_decreasing': False, - # 'algo_log_metric': 'accuracy', - # 'model': 'resnet50', - # 'lr': 3e-5, - # 'weight_decay': 0.0, - # 'batch_size': 16, - # 'n_epochs': 12, - # 'optimizer': 'Adam', - # 'split_scheme': 'official', - # 'scheduler': None, - # 'groupby_fields': ['location',], - # 'n_groups_per_batch': 2, - # 'irm_lambda': 1., - # 'coral_penalty_weight': 10., - # 'no_group_logging': True, - # 'process_outputs_function': 'multiclass_logits_to_pred' - # }, - -eval: - query_studies: - iid_study: wilds_animals_openset_384 - -trainer: - num_epochs: - num_steps: ${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,60000,40000} - dg_pretrain_epochs: - dg_pretrain_steps: 20000 - lr_scheduler_interval: step diff --git a/fd_shifts/configs/data/wilds_animals_openset_data.yaml b/fd_shifts/configs/data/wilds_animals_openset_data.yaml deleted file mode 100644 index 67b29f3..0000000 --- a/fd_shifts/configs/data/wilds_animals_openset_data.yaml +++ /dev/null @@ -1,44 +0,0 @@ -# @package _global_ - -data: - dataset: wilds_animals_openset - data_dir: ${oc.env:DATASET_ROOT_DIR}/wilds_animals - pin_memory: True - img_size: [448, 448, 3] - num_workers: 12 - num_classes: 182 - reproduce_confidnet_splits: False - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - resize: [448, 448] - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - val: - resize: [448, 448] - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - test: - resize: [448, 448] - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - kwargs: - out_classes: [6, 7, 8, 9] - -eval: - query_studies: - iid_study: ${data.dataset} - -trainer: - batch_size: 16 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,20,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,18,12}} - num_epochs_backbone: 12 - dg_pretrain_epochs: 6 - optimizer: - lr: 1e-3 - weight_decay: 0 - -model: - fc_dim: 2048 - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,resnet50}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,resnet50,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,resnet50,null}} diff --git a/fd_shifts/configs/data/wilds_camelyon_384_data.yaml b/fd_shifts/configs/data/wilds_camelyon_384_data.yaml deleted file mode 100644 index 4bfa548..0000000 --- a/fd_shifts/configs/data/wilds_camelyon_384_data.yaml +++ /dev/null @@ -1,38 +0,0 @@ -# @package _global_ -defaults: - - override /trainer/lr_scheduler: LinearWarmupCosineAnnealingLR - -data: - dataset: wilds_camelyon - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [384, 384, 3] - num_workers: 24 - num_classes: 2 - reproduce_confidnet_splits: False - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - resize: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]] - val: - to_tensor: - resize: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]] - test: - to_tensor: - resize: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]] - kwargs: - -eval: - query_studies: # iid_study, new_class_study, sub_class_study, noise_study - iid_study: wilds_camelyon_384 - in_class_study: [wilds_camelyon_ood_test_384] - -trainer: - num_epochs: - num_steps: ${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,60000,40000} - dg_pretrain_epochs: - dg_pretrain_steps: 20000 - lr_scheduler_interval: step diff --git a/fd_shifts/configs/data/wilds_camelyon_data.yaml b/fd_shifts/configs/data/wilds_camelyon_data.yaml deleted file mode 100644 index b0d1025..0000000 --- a/fd_shifts/configs/data/wilds_camelyon_data.yaml +++ /dev/null @@ -1,41 +0,0 @@ -# @package _global_ - -data: - dataset: wilds_camelyon - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [96, 96, 3] - num_workers: 12 - num_classes: 2 - reproduce_confidnet_splits: False - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - val: - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - test: - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - kwargs: - -eval: - query_studies: # iid_study, new_class_study, sub_class_study, noise_study - iid_study: ${data.dataset} - in_class_study: [wilds_camelyon_ood_test] - -trainer: - batch_size: 32 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,9,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,8,5}} - num_epochs_backbone: 5 - dg_pretrain_epochs: 3 - optimizer: - lr: 1e-2 - weight_decay: 1e-2 - -model: - fc_dim: 2048 - network: - name: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,devries_and_enc,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,confidnet_and_enc,resnet50}} - backbone: ${fd_shifts.ifeq_else:${eval.ext_confid_name},devries,resnet50,${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,resnet50,null}} diff --git a/fd_shifts/configs/data/wilds_camelyon_ood_test_384_data.yaml b/fd_shifts/configs/data/wilds_camelyon_ood_test_384_data.yaml deleted file mode 100644 index 2e10743..0000000 --- a/fd_shifts/configs/data/wilds_camelyon_ood_test_384_data.yaml +++ /dev/null @@ -1,24 +0,0 @@ -# @package _global_ - -data: - dataset: wilds_camelyon - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [384, 384, 3] - num_workers: 24 - num_classes: 2 - reproduce_confidnet_splits: False - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - resize: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]] - val: - to_tensor: - resize: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]] - test: - to_tensor: - resize: 384 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.384, 0.225]] - kwargs: diff --git a/fd_shifts/configs/data/wilds_camelyon_ood_test_data.yaml b/fd_shifts/configs/data/wilds_camelyon_ood_test_data.yaml deleted file mode 100644 index 247055f..0000000 --- a/fd_shifts/configs/data/wilds_camelyon_ood_test_data.yaml +++ /dev/null @@ -1,21 +0,0 @@ -# @package _global_ - -data: - dataset: wilds_camelyon - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [96, 96, 3] - num_workers: 12 - num_classes: 2 - reproduce_confidnet_splits: False - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - val: - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - test: - to_tensor: - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - kwargs: diff --git a/fd_shifts/configs/data/xray_chestall_data.yaml b/fd_shifts/configs/data/xray_chestall_data.yaml deleted file mode 100644 index 3c840e8..0000000 --- a/fd_shifts/configs/data/xray_chestall_data.yaml +++ /dev/null @@ -1,69 +0,0 @@ -# @package _global_ -defaults: - - override /trainer/lr_scheduler: CosineAnnealingLR - - override /trainer/optimizer: Adam - -data: - dataset: xray_chestall - data_dir: ${oc.env:DATASET_ROOT_DIR}/${data.dataset} - pin_memory: True - img_size: [256, 256, 3] #dataset is 28x28x1 either upscale it or need to adjust transforms and neural net - num_workers: 24 - num_classes: 8 - reproduce_confidnet_splits: True - target_transforms: - train: - extractZeroDim: - val: - extractZeroDim: - test: - extractZeroDim: - - augmentations: - train: # careful, the order here will determine the order of transforms (except normalize will be executed manually at the end after toTensor) - to_tensor: - hflip: 1 - rotate: 15 - resize: 256 - center_crop: 256 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - val: - to_tensor: - resize: 256 - center_crop: 256 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - test: - to_tensor: - resize: 256 - center_crop: 256 - normalize: [[0.485, 0.456, 0.406], [0.229, 0.224, 0.225]] - - - kwargs: - -eval: - performance_metrics: - test: - - nll - - accuracy - - brier_score - # - b-accuracy - query_studies: - iid_study: ${data.dataset} - -trainer: - batch_size: 96 - num_epochs: ${fd_shifts.ifeq_else:${eval.ext_confid_name},tcp,60,${fd_shifts.ifeq_else:${eval.ext_confid_name},dg,40,30}} - optimizer: - lr: 3e-5 - weight_decay: 1e-4 - # nesterov: False - # momentum: 0.9 - num_epochs_backbone: 30 - dg_pretrain_epochs: 30 - val_every_n_epoch: 5 - -model: - fc_dim: 1024 - network: - backbone: densenet121 diff --git a/fd_shifts/configs/study/__init__.py b/fd_shifts/configs/study/__init__.py deleted file mode 100644 index e69de29..0000000 diff --git a/fd_shifts/configs/study/confidnet.yaml b/fd_shifts/configs/study/confidnet.yaml deleted file mode 100644 index acc4d42..0000000 --- a/fd_shifts/configs/study/confidnet.yaml +++ /dev/null @@ -1,43 +0,0 @@ -# @package _global_ -defaults: - - override /trainer/lr_scheduler: CosineAnnealingLR - -exp: - group_name: confidnet - name: cifar10 - -trainer: - num_epochs: 470 - num_epochs_backbone: 250 - optimizer: - lr: 1e-1 - learning_rate_confidnet: 1e-4 - learning_rate_confidnet_finetune: 1e-6 - lr_scheduler: - T_max: ${trainer.num_epochs_backbone} - callbacks: - model_checkpoint: - confid_monitor: - training_stages: - milestones: [250, 450] - pretrained_backbone_path: - pretrained_confidnet_path: - disable_dropout_at_finetuning: True - confidnet_lr_scheduler: False - learning_rate_monitor: - -model: - name: confidnet_model - fc_dim: 512 - avg_pool: True - confidnet_fc_dim: 400 - dropout_rate: 1 - monitor_mcd_samples: 50 # only activated if "mcd" substring in train or val monitor confids. - test_mcd_samples: 50 # only activated if "mcd" substring in test confids. - network: - name: confidnet_and_enc # confidnet_small_conv_and_enc / small_conv - backbone: vgg13 - imagenet_weights_path: #${oc.env:EXPERIMENT_ROOT_DIR}/pretrained_weights/vgg16-397923af.pth - -eval: - ext_confid_name: "tcp" diff --git a/fd_shifts/configs/study/deepgamblers.yaml b/fd_shifts/configs/study/deepgamblers.yaml deleted file mode 100644 index fbd6a4f..0000000 --- a/fd_shifts/configs/study/deepgamblers.yaml +++ /dev/null @@ -1,33 +0,0 @@ -# @package _global_ - -defaults: - - override /trainer/lr_scheduler: CosineAnnealingLR - -exp: - group_name: deepgamblers - name: ${data.dataset} - -trainer: - num_epochs: 300 - dg_pretrain_epochs: 100 - - optimizer: - lr: 1e-1 - -model: - name: devries_model - fc_dim: 512 - dg_reward: 2.2 - avg_pool: True - dropout_rate: 0 - monitor_mcd_samples: 50 - test_mcd_samples: 50 - budget: 0.3 - network: - name: vgg13 - imagenet_weights_path: - load_dg_backbone_path: - save_dg_backbone_path: ${exp.dir}/dg_backbone.ckpt - -eval: - ext_confid_name: "dg" diff --git a/fd_shifts/configs/study/devries.yaml b/fd_shifts/configs/study/devries.yaml deleted file mode 100644 index aa8eb9d..0000000 --- a/fd_shifts/configs/study/devries.yaml +++ /dev/null @@ -1,33 +0,0 @@ -# @package _global_ -defaults: - - override /trainer/lr_scheduler: CosineAnnealingLR - -exp: - group_name: devries - name: ${data.dataset} - -trainer: - num_epochs: 250 - lr_scheduler: - T_max: ${trainer.num_epochs} - optimizer: - lr: 1e-1 - -model: - name: devries_model - fc_dim: 512 - dg_reward: 0 - avg_pool: True - dropout_rate: 0 - monitor_mcd_samples: 50 - test_mcd_samples: 50 - budget: 0.3 - network: - name: devries_and_enc - backbone: vgg13 - imagenet_weights_path: - load_dg_backbone_path: - save_dg_backbone_path: - -eval: - ext_confid_name: "devries" diff --git a/fd_shifts/configs/study/vit.yaml b/fd_shifts/configs/study/vit.yaml deleted file mode 100644 index 05ac488..0000000 --- a/fd_shifts/configs/study/vit.yaml +++ /dev/null @@ -1,25 +0,0 @@ -# @package _global_ -defaults: - - override /trainer/lr_scheduler: LinearWarmupCosineAnnealingLR - - override /trainer/optimizer: SGD - - override /data: cifar10_384_data - -exp: - group_name: vit - name: cifar10 - -trainer: - num_epochs: - num_steps: 40000 - optimizer: - lr: 0.003 - momentum: 0.9 - weight_decay: 0.0 - -model: - name: vit_model - network: - name: vit - -eval: - ext_confid_name: "maha" From 6161a68e28fb535f6098b433ee05b3354d93c79f Mon Sep 17 00:00:00 2001 From: Jeremias Traub Date: Thu, 27 Jun 2024 16:46:08 +0200 Subject: [PATCH 136/136] Update baurc test --- fd_shifts/tests/test_baurc.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/fd_shifts/tests/test_baurc.py b/fd_shifts/tests/test_baurc.py index f7c527f..77fbef9 100644 --- a/fd_shifts/tests/test_baurc.py +++ b/fd_shifts/tests/test_baurc.py @@ -48,9 +48,8 @@ def test_all_false(correct): aurc_value = aurc(stat) baurc_value = baurc(stat) - assert aurc_value == pytest.approx(999, 1) + assert aurc_value == 1000 assert baurc_value == pytest.approx(999, 1) - assert baurc_value == aurc_value @pytest.mark.baurc

h_AUN(5Xh#{op1$ELo<6(mCRKFRYe zm>6W&Rsl%-f_GI|rU_+L#0X|h3?nAPHHSyPCJp8S^%bcTp-Uw2&k~VlFX38sV3)aD z{cC}cIHUu+q&%=bFqOTR)So&}83ajW_UXt{8iW%@t*gU6J|kvXnIYe4j*QH&#*C@7 zq=OcvwUnO$95c^L!;~ulFI3K4^VS%fzJu;e79Fw9Ya)cUX=HjDtSMs3)sipb_+jjIHbDK z7grYi!5l76v2bz;4q7U4wy_H}Ju^(#pL)mgi;TrsshI8LbaF&-LEe3)b;ot{g z;dDYG&W7AhzbL_OyGI$5nOE|`{c=cC^gy&!4LEfR-x#lfe-{IT`~&OoK@&SsJTyo= znUpNr%ETgPYGaG$pM(w+t8#~fj9F;Wxjo!nh>I3CGUY7QSMwkJc-9FdihE1to?3@L zq|}Mph0N;R#u0F5Mj#@ng~XSvcZ2)~{yjgz@n%_K#*M(^#;3+$dS3p2Kg zy+tS6j(1oq9^{&_`D%!;tvh7L65&DW0Tg%_c=m45KTgMOHKXnoGJhI;3mW zrCY0|CPdC)mMu3p`ho#z?;2%){Z4*QB?FCWSqFQf`v?*CQDat{EbH|q)Zh%5tmqzX zW4fdQLo@IAN(nrjvEcOYtc}gqFaevu&t|$-l^W#Dwwsz_m}USjyJ!%rt?2f+eCfF(r+mCH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