API Documentation: Transforms
Implemented transformations and default options.
get_flow_builder(model)
Returns the transformation class based on the specified model type.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
model
|
str
|
The model type. |
required |
Returns:
| Name | Type | Description |
|---|---|---|
get_transform |
function
|
The transformation class to use. |
Source code in flowevidence/transforms.py
85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 | |
get_tranform_kwargs(model)
Returns the default keyword arguments for the specified model type.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
model
|
str
|
The model type. |
required |
Returns:
| Name | Type | Description |
|---|---|---|
kwargs |
dict
|
The default keyword arguments for the model type. |
Source code in flowevidence/transforms.py
104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 | |
get_flow_transforms(num_dims, num_flow_steps, model='maf', extra_kwargs={})
Returns the transformation class and its default keyword arguments based on the specified model type.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
num_dims
|
int
|
The number of dimensions in the input. |
required |
num_flow_steps
|
int
|
The number of flow steps in the transformation. |
required |
model
|
str
|
The model type. |
'maf'
|
extra_kwargs
|
dict
|
Additional keyword arguments for the transformation. |
{}
|
Returns:
| Name | Type | Description |
|---|---|---|
transform_class |
Transform
|
The transformation class to use. |
default_kwargs |
dict
|
The default keyword arguments for the transformation class. |
Source code in flowevidence/transforms.py
145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 | |