divisor.interaction_context
1from dataclasses import dataclass 2from typing import Callable 3 4import torch 5 6from nnll.random import RNGState 7 8 9@dataclass 10class InteractionContext: 11 """Container for functions and utilities needed during interactive routing.""" 12 13 clear_prediction_cache: Callable[[], None] 14 rng: RNGState 15 variation_rng: RNGState 16 ae: torch.nn.Module | None = None 17 t5: torch.nn.Module | None = None 18 clip: torch.nn.Module | None = None 19 recompute_text_embeddings: Callable[[str], None] | None = None
@dataclass
class
InteractionContext:
10@dataclass 11class InteractionContext: 12 """Container for functions and utilities needed during interactive routing.""" 13 14 clear_prediction_cache: Callable[[], None] 15 rng: RNGState 16 variation_rng: RNGState 17 ae: torch.nn.Module | None = None 18 t5: torch.nn.Module | None = None 19 clip: torch.nn.Module | None = None 20 recompute_text_embeddings: Callable[[str], None] | None = None
Container for functions and utilities needed during interactive routing.
InteractionContext( clear_prediction_cache: Callable[[], NoneType], rng: nnll.random.RNGState, variation_rng: nnll.random.RNGState, ae: torch.nn.modules.module.Module | None = None, t5: torch.nn.modules.module.Module | None = None, clip: torch.nn.modules.module.Module | None = None, recompute_text_embeddings: Optional[Callable[[str], NoneType]] = None)