Revert "Add switchable DIFF V1 attention"

This reverts commit bf5cae8758.
This commit is contained in:
2026-08-21 13:16:39 +08:00
parent bf5cae8758
commit 9ccc6b56ec
7 changed files with 4 additions and 453 deletions

View File

@@ -25,7 +25,6 @@ from torch.optim import AdamW
from torch.utils.data import DataLoader, RandomSampler
from tqdm.auto import tqdm
from attention_types import DEFAULT_ATTENTION_TYPE, SUPPORTED_ATTENTION_TYPES
from dataset import (
DISEASE_HISTORY_MODES,
DISEASE_HISTORY_MODE_TIMED,
@@ -120,12 +119,6 @@ def parse_args() -> argparse.Namespace:
default=DEFAULT_MODEL_ARCHITECTURE,
choices=SUPPORTED_MODEL_ARCHITECTURES,
)
parser.add_argument(
"--attention_type",
type=str,
default=DEFAULT_ATTENTION_TYPE,
choices=SUPPORTED_ATTENTION_TYPES,
)
parser.add_argument("--batch_size", type=int, default=128)
parser.add_argument("--base_lr", type=float, default=3e-4)
@@ -211,7 +204,6 @@ def build_model(
dist_mode=args.dist_mode,
dropout=args.dropout,
model_architecture=args.model_architecture,
attention_type=args.attention_type,
)
@@ -341,7 +333,6 @@ def build_metadata(
"collate_fn": "all_future_collate_fn",
"model_class": "DeepHealth",
"model_architecture": args.model_architecture,
"attention_type": args.attention_type,
"model_target_mode": "all_future",
"target_mode": "all_future",
"event_stream_version": "disease_death_only_v1",
@@ -402,7 +393,6 @@ def main() -> None:
logger.info(f"Starting all-future training run: {run_name}")
logger.info(f"Device: {device}")
logger.info(f"Model architecture: {args.model_architecture}")
logger.info(f"Attention type: {args.attention_type}")
logger.info(f"Disease history mode: {args.disease_history_mode}")
logger.info(f"extra_info_types: {format_extra_info_types(args.extra_info_types)}")
logger.info("Continuous value scaling: RobustScale (required)")