Skip to content

Imagix Module

Imagix

Bases: BasePipeline

Imagix specific version of the BasePipeline class.

This class extends BasePipeline. See the parent class for a full list of attributes and methods.

Additional Attributes

_default_config: Is set to DefaultConfig here.

Source code in src/autoencodix/imagix.py
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
class Imagix(BasePipeline):
    """Imagix specific version of the BasePipeline class.

    This class extends BasePipeline. See the parent class for a full list
    of attributes and methods.

    Additional Attributes:
        _default_config: Is set to DefaultConfig here.

    """

    def __init__(
        self,
        data: Optional[Union[DataPackage, DatasetContainer]] = None,
        trainer_type: Type[BaseTrainer] = GeneralTrainer,
        dataset_type: Type[BaseDataset] = ImageDataset,
        model_type: Type[BaseAutoencoder] = ImageVAEArchitecture,
        loss_type: Type[BaseLoss] = VarixLoss,
        preprocessor_type: Type[BasePreprocessor] = ImagePreprocessor,
        visualizer: Optional[Type[BaseVisualizer]] = ImagixVisualizer,
        evaluator: Optional[Type[GeneralEvaluator]] = GeneralEvaluator,
        result: Optional[Result] = None,
        datasplitter_type: Type[DataSplitter] = DataSplitter,
        custom_splits: Optional[Dict[str, np.ndarray]] = None,
        config: Optional[DefaultConfig] = None,
    ) -> None:
        """Initialize Imagix pipeline with customizable components.

        Some components are passed as types rather than instances because they require
        data that is only available after preprocessing.

        See Parentclass for full list of Args.

        """
        self._default_config = DefaultConfig()
        super().__init__(
            data=data,
            dataset_type=dataset_type,
            trainer_type=trainer_type,
            model_type=model_type,
            loss_type=loss_type,
            preprocessor_type=preprocessor_type,
            visualizer=visualizer,
            evaluator=evaluator,
            result=result,
            datasplitter_type=datasplitter_type,
            config=config,
            custom_split=custom_splits,
        )

__init__(data=None, trainer_type=GeneralTrainer, dataset_type=ImageDataset, model_type=ImageVAEArchitecture, loss_type=VarixLoss, preprocessor_type=ImagePreprocessor, visualizer=ImagixVisualizer, evaluator=GeneralEvaluator, result=None, datasplitter_type=DataSplitter, custom_splits=None, config=None)

Initialize Imagix pipeline with customizable components.

Some components are passed as types rather than instances because they require data that is only available after preprocessing.

See Parentclass for full list of Args.

Source code in src/autoencodix/imagix.py
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
def __init__(
    self,
    data: Optional[Union[DataPackage, DatasetContainer]] = None,
    trainer_type: Type[BaseTrainer] = GeneralTrainer,
    dataset_type: Type[BaseDataset] = ImageDataset,
    model_type: Type[BaseAutoencoder] = ImageVAEArchitecture,
    loss_type: Type[BaseLoss] = VarixLoss,
    preprocessor_type: Type[BasePreprocessor] = ImagePreprocessor,
    visualizer: Optional[Type[BaseVisualizer]] = ImagixVisualizer,
    evaluator: Optional[Type[GeneralEvaluator]] = GeneralEvaluator,
    result: Optional[Result] = None,
    datasplitter_type: Type[DataSplitter] = DataSplitter,
    custom_splits: Optional[Dict[str, np.ndarray]] = None,
    config: Optional[DefaultConfig] = None,
) -> None:
    """Initialize Imagix pipeline with customizable components.

    Some components are passed as types rather than instances because they require
    data that is only available after preprocessing.

    See Parentclass for full list of Args.

    """
    self._default_config = DefaultConfig()
    super().__init__(
        data=data,
        dataset_type=dataset_type,
        trainer_type=trainer_type,
        model_type=model_type,
        loss_type=loss_type,
        preprocessor_type=preprocessor_type,
        visualizer=visualizer,
        evaluator=evaluator,
        result=result,
        datasplitter_type=datasplitter_type,
        config=config,
        custom_split=custom_splits,
    )