cellmap_flow.models.configs.script
ScriptModelConfig: a model that a Python script defines.
load_safe_config checks the script, runs it and returns its globals as
a Config: the model (or a predict) and its geometry. Sizes in voxels
(input_size, output_size) and shapes in nm (read_shape,
write_shape) are each derived from the other when only one is given.
Attributes
Classes
Functions
|
Loads the configuration script at config_path after verifying its safety. |
Module Contents
- cellmap_flow.models.configs.script.logger
- cellmap_flow.models.configs.script.load_safe_config(config_path, force_safe=None)
Loads the configuration script at config_path after verifying its safety. If force_safe is True, raises an error if the script is deemed unsafe. When it is None, the FORCE_SAFE_CONFIG environment variable decides.